Use script system
This commit is contained in:
@@ -18,12 +18,8 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
apt-get update
|
apt-get update
|
||||||
apt-get install -y build-essential cmake python3 python3-pip python3-polib python3-pil libsdl2-dev libgl1-mesa-dev libzip-dev python3-dotenv python3-pyqt5 python3-opengl liblua5.3-dev
|
apt-get install -y build-essential cmake python3 python3-pip python3-polib python3-pil libsdl2-dev libgl1-mesa-dev libzip-dev python3-dotenv python3-pyqt5 python3-opengl liblua5.3-dev
|
||||||
- name: Configure CMake for tests
|
|
||||||
run: cmake -S . -B build -DDUSK_BUILD_TESTS=ON -DDUSK_TARGET_SYSTEM=linux
|
|
||||||
- name: Build tests
|
|
||||||
run: cmake --build build -- -j$(nproc)
|
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: ctest --output-on-failure --test-dir build
|
run: ./scripts/test-linux.sh
|
||||||
|
|
||||||
build-linux:
|
build-linux:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@@ -34,17 +30,13 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
apt-get update
|
apt-get update
|
||||||
apt-get install -y build-essential cmake python3 python3-pip python3-polib python3-pil libsdl2-dev libgl1-mesa-dev libzip-dev python3-dotenv python3-pyqt5 python3-opengl liblua5.3-dev
|
apt-get install -y build-essential cmake python3 python3-pip python3-polib python3-pil libsdl2-dev libgl1-mesa-dev libzip-dev python3-dotenv python3-pyqt5 python3-opengl liblua5.3-dev
|
||||||
- name: Configure CMake
|
- name: Build Linux
|
||||||
run: cmake -S . -B build -DDUSK_TARGET_SYSTEM=linux
|
run: ./scripts/build-linux.sh
|
||||||
- name: Build
|
|
||||||
run: cmake --build build -- -j$(nproc)
|
|
||||||
- name: List build output
|
|
||||||
run: ls -lh build
|
|
||||||
- name: Upload Linux binary
|
- name: Upload Linux binary
|
||||||
uses: https://git.wish.moe/YourWishes/upload-artifact@v3/node20
|
uses: https://git.wish.moe/YourWishes/upload-artifact@v3/node20
|
||||||
with:
|
with:
|
||||||
name: dusk-linux
|
name: dusk-linux
|
||||||
path: build/Dusk
|
path: build-linux/Dusk
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
|
|
||||||
# build-psp:
|
# build-psp:
|
||||||
|
|||||||
3
scripts/build-linux.sh
Executable file
3
scripts/build-linux.sh
Executable file
@@ -0,0 +1,3 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
cmake -S . -B build-linux -DDUSK_BUILD_TESTS=ON -DDUSK_TARGET_SYSTEM=linux
|
||||||
|
cmake --build build-linux -- -j$(nproc)
|
||||||
4
scripts/test-linux.sh
Executable file
4
scripts/test-linux.sh
Executable file
@@ -0,0 +1,4 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
cmake -S . -B build-tests -DDUSK_BUILD_TESTS=ON -DDUSK_TARGET_SYSTEM=linux
|
||||||
|
cmake --build build-tests -- -j$(nproc)
|
||||||
|
ctest --output-on-failure --test-dir build-tests
|
||||||
Reference in New Issue
Block a user