|
|
@ -5,7 +5,7 @@ on: [push, pull_request]
|
|
|
|
jobs:
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
build:
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
name: build (Linux, GCC ${{ matrix.gcc }})
|
|
|
|
name: build (Linux, GCC ${{ matrix.gcc }}, ${{ matrix.plugins }} plugins)
|
|
|
|
strategy:
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
matrix:
|
|
|
@ -14,9 +14,18 @@ jobs:
|
|
|
|
gcc:
|
|
|
|
gcc:
|
|
|
|
- 4.8
|
|
|
|
- 4.8
|
|
|
|
- 7
|
|
|
|
- 7
|
|
|
|
|
|
|
|
plugins:
|
|
|
|
|
|
|
|
- supported
|
|
|
|
include:
|
|
|
|
include:
|
|
|
|
- os: ubuntu-20.04
|
|
|
|
- os: ubuntu-20.04
|
|
|
|
gcc: 10
|
|
|
|
gcc: 10
|
|
|
|
|
|
|
|
plugins: supported
|
|
|
|
|
|
|
|
- os: ubuntu-20.04
|
|
|
|
|
|
|
|
gcc: 10
|
|
|
|
|
|
|
|
plugins: dev
|
|
|
|
|
|
|
|
- os: ubuntu-20.04
|
|
|
|
|
|
|
|
gcc: 10
|
|
|
|
|
|
|
|
plugins: stonesense
|
|
|
|
steps:
|
|
|
|
steps:
|
|
|
|
- name: Set up Python 3
|
|
|
|
- name: Set up Python 3
|
|
|
|
uses: actions/setup-python@v2
|
|
|
|
uses: actions/setup-python@v2
|
|
|
@ -37,7 +46,6 @@ jobs:
|
|
|
|
zlib1g-dev
|
|
|
|
zlib1g-dev
|
|
|
|
pip install sphinx
|
|
|
|
pip install sphinx
|
|
|
|
- name: Install GCC
|
|
|
|
- name: Install GCC
|
|
|
|
if: ${{ matrix.gcc < 7 || matrix.gcc > 9 }}
|
|
|
|
|
|
|
|
run: |
|
|
|
|
run: |
|
|
|
|
sudo apt-get install gcc-${{ matrix.gcc }} g++-${{ matrix.gcc }}
|
|
|
|
sudo apt-get install gcc-${{ matrix.gcc }} g++-${{ matrix.gcc }}
|
|
|
|
- name: Clone DFHack
|
|
|
|
- name: Clone DFHack
|
|
|
@ -70,11 +78,16 @@ jobs:
|
|
|
|
-B build-ci \
|
|
|
|
-B build-ci \
|
|
|
|
-G Ninja \
|
|
|
|
-G Ninja \
|
|
|
|
-DDFHACK_BUILD_ARCH=64 \
|
|
|
|
-DDFHACK_BUILD_ARCH=64 \
|
|
|
|
-DBUILD_DOCS:BOOL=ON \
|
|
|
|
|
|
|
|
-DBUILD_TESTS:BOOL=ON \
|
|
|
|
-DBUILD_TESTS:BOOL=ON \
|
|
|
|
|
|
|
|
-DBUILD_DEV_PLUGINS:BOOL=${{ matrix.plugins == 'dev' }} \
|
|
|
|
|
|
|
|
-DBUILD_SIZECHECK:BOOL=${{ matrix.plugins == 'dev' }} \
|
|
|
|
|
|
|
|
-DBUILD_STONESENSE:BOOL=${{ matrix.plugins == 'stonesense' }} \
|
|
|
|
|
|
|
|
-DBUILD_SUPPORTED:BOOL=${{ matrix.plugins == 'supported' }} \
|
|
|
|
-DCMAKE_INSTALL_PREFIX="$DF_FOLDER"
|
|
|
|
-DCMAKE_INSTALL_PREFIX="$DF_FOLDER"
|
|
|
|
ninja -C build-ci install
|
|
|
|
ninja -C build-ci install
|
|
|
|
- name: Run tests
|
|
|
|
- name: Run tests
|
|
|
|
|
|
|
|
id: run_tests
|
|
|
|
|
|
|
|
if: ${{ matrix.plugins == 'supported' }}
|
|
|
|
run: |
|
|
|
|
run: |
|
|
|
|
export TERM=dumb
|
|
|
|
export TERM=dumb
|
|
|
|
mv "$DF_FOLDER"/dfhack.init-example "$DF_FOLDER"/dfhack.init
|
|
|
|
mv "$DF_FOLDER"/dfhack.init-example "$DF_FOLDER"/dfhack.init
|
|
|
@ -84,9 +97,10 @@ jobs:
|
|
|
|
cp "$DF_FOLDER/test_status.json" "$DF_FOLDER"/*.log artifacts
|
|
|
|
cp "$DF_FOLDER/test_status.json" "$DF_FOLDER"/*.log artifacts
|
|
|
|
- name: Upload test artifacts
|
|
|
|
- name: Upload test artifacts
|
|
|
|
uses: actions/upload-artifact@v1
|
|
|
|
uses: actions/upload-artifact@v1
|
|
|
|
if: success() || failure()
|
|
|
|
if: (success() || failure()) && steps.run_tests.outcome != 'skipped'
|
|
|
|
|
|
|
|
continue-on-error: true
|
|
|
|
with:
|
|
|
|
with:
|
|
|
|
name: test-artifacts
|
|
|
|
name: test-artifacts-${{ matrix.gcc }}
|
|
|
|
path: artifacts
|
|
|
|
path: artifacts
|
|
|
|
- name: Clean up DF folder
|
|
|
|
- name: Clean up DF folder
|
|
|
|
# prevent DFHack-generated files from ending up in the cache
|
|
|
|
# prevent DFHack-generated files from ending up in the cache
|
|
|
|