another small change (that will hopefully trigger github actions into… #53
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: General build matrix | |
on: | |
push: | |
branches: | |
- master | |
- lua | |
paths-ignore: | |
- 'android/**' | |
- 'build-data/osx/**' | |
- 'doc/**' | |
- 'doxygen_doc/**' | |
- 'lgtm/**' | |
- 'msvc-full-features/**' | |
- 'msvc-object_creator/**' | |
- 'object_creator/**' | |
- 'tools/**' | |
- 'utilities/**' | |
pull_request: | |
branches: | |
- master | |
paths-ignore: | |
- 'android/**' | |
- 'build-data/osx/**' | |
- 'doc/**' | |
- 'doxygen_doc/**' | |
- 'lgtm/**' | |
- 'msvc-full-features/**' | |
- 'msvc-object_creator/**' | |
- 'object_creator/**' | |
- 'tools/**' | |
- 'utilities/**' | |
jobs: | |
varied_builds: | |
strategy: | |
matrix: | |
include: | |
- compiler: g++-9 | |
os: ubuntu-latest | |
cmake: 0 | |
tiles: 0 | |
test-stage: 1 | |
native: linux64 | |
gold: 1 | |
lto: 1 | |
title: GCC 9, Ubuntu, Curses, LTO | |
- compiler: g++-7 | |
os: ubuntu-latest | |
cmake: 1 | |
tiles: 1 | |
native: linux64 | |
title: GCC 7, Ubuntu, Tiles, CMake | |
- compiler: g++-8 | |
os: ubuntu-latest | |
cmake: 0 | |
tiles: 1 | |
sanitize: address | |
native: linux64 | |
title: GCC 8, Ubuntu, Tiles, ASan | |
- compiler: clang++-12 | |
os: ubuntu-latest | |
cmake: 0 | |
tiles: 1 | |
sanitize: address,undefined | |
native: linux64 | |
title: Clang 12, Ubuntu, Tiles, ASan, UBSan | |
- compiler: clang++ | |
os: macos-10.15 | |
cmake: 0 | |
tiles: 1 | |
native: osx | |
title: Clang 12, macOS 10.15, Tiles | |
name: ${{ matrix.title }} | |
runs-on: ${{ matrix.os }} | |
env: | |
CMAKE: ${{ matrix.cmake }} | |
COMPILER: ${{ matrix.compiler }} | |
OS: ${{ matrix.os }} | |
TILES: ${{ matrix.tiles }} | |
SOUND: ${{ matrix.tiles }} | |
SANITIZE: ${{ matrix.sanitize }} | |
TEST_STAGE: ${{ matrix.test-stage }} | |
EXTRA_TEST_OPTS: --error-format=github-action | |
NATIVE: ${{ matrix.native }} | |
GOLD: ${{ matrix.gold }} | |
LTO: ${{ matrix.lto }} | |
RELEASE: 1 | |
steps: | |
- name: checkout repository | |
uses: actions/checkout@v1 | |
with: | |
fetch-depth: 1 | |
- name: install dependencies (ubuntu) | |
if: runner.os == 'Linux' | |
run: | | |
sudo apt update | |
sudo apt-get install liblua5.3-dev lua5.3 liblua5.2 lua5.2 lua libncursesw5-dev libsdl2-dev libsdl2-ttf-dev libsdl2-image-dev \ | |
libsdl2-mixer-dev libpulse-dev ccache gettext parallel | |
- name: install old GCC (ubuntu) | |
if: runner.os == 'Linux' && (matrix.compiler == 'g++-7' || matrix.compiler == 'g++-8') | |
run: | | |
sudo apt install g++-7 g++-8 | |
- name: install dependencies (mac) | |
if: runner.os == 'macOS' | |
run: | | |
HOMEBREW_NO_AUTO_UPDATE=yes HOMEBREW_NO_INSTALL_CLEANUP=yes brew install [email protected] [email protected] sdl2 sdl2_image sdl2_ttf sdl2_mixer gettext ccache parallel | |
- name: prepare | |
run: bash ./build-scripts/requirements.sh | |
- name: Get Date | |
id: get-date | |
run: | | |
echo "::set-output name=date::$(/bin/date -u "+%Y%m%d%H%M")" | |
shell: bash | |
- name: ccache cache files (ubuntu) | |
if: runner.os == 'Linux' | |
uses: actions/cache@v2 | |
with: | |
path: ~/.ccache | |
key: ccache-linux-${{ matrix.compiler }}-${{ steps.get-date.outputs.date }} | |
restore-keys: | | |
ccache-linux-${{ matrix.compiler }}- | |
- name: ccache cache files (mac) | |
if: runner.os == 'macOS' | |
uses: actions/cache@v2 | |
with: | |
path: /Users/runner/Library/Caches/ccache | |
key: ccache-mac-${{ matrix.compiler }}-${{ steps.get-date.outputs.date }} | |
restore-keys: | | |
ccache-mac-${{ matrix.compiler }}- | |
- uses: ammaraskar/gcc-problem-matcher@master | |
- name: build and test | |
run: bash ./build-scripts/build.sh | |
- name: upload artifacts if failed | |
uses: actions/upload-artifact@v1 | |
if: failure() | |
with: | |
name: cata_test | |
path: tests/cata_test |