Continuous Integration #522
Workflow file for this run
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: Continuous Integration | |
on: | |
push: | |
pull_request: | |
branches: | |
- g3.3mgw* | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
jobs: | |
build: | |
name: ${{ matrix.config.name }} | ${{ matrix.config.build_type }} | |
runs-on: ${{ matrix.config.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
config: | |
- { | |
name: "Visual Studio 64-bit", | |
os: windows-2019, | |
extra_options: "-A x64", | |
build_type: "Release" | |
} | |
- { | |
name: "Visual Studio 64-bit", | |
os: windows-2019, | |
extra_options: "-A x64", | |
build_type: "Debug" | |
} | |
- { | |
name: "Visual Studio 32-bit", | |
os: windows-2019, | |
extra_options: "-A Win32 -DFORCE_INTERNAL_ZLIB=ON", | |
build_type: "Release" | |
} | |
- { | |
name: "macOS", | |
os: macos-11, | |
build_type: "Release" | |
} | |
- { | |
name: "macOS", | |
os: macos-11, | |
extra_options: "-DDYN_FLUIDSYNTH=OFF -DDYN_OPENAL=OFF -DDYN_SNDFILE=OFF -DDYN_MPG123=OFF", | |
deps_cmdline: "brew install fluidsynth mpg123 libsndfile", | |
build_type: "Debug" | |
} | |
- { | |
name: "Linux GCC 7", | |
os: ubuntu-20.04, | |
extra_options: "-DCMAKE_C_COMPILER=gcc-7 -DCMAKE_CXX_COMPILER=g++-7", | |
deps_cmdline: "sudo apt update && sudo apt install g++-7 libsdl2-dev libgtk2.0-dev", | |
build_type: "RelWithDebInfo" | |
} | |
- { | |
name: "Linux GCC 11", | |
os: ubuntu-20.04, | |
extra_options: "-DCMAKE_C_COMPILER=gcc-11 -DCMAKE_CXX_COMPILER=g++-11", | |
deps_cmdline: "sudo apt update && sudo apt install g++-11 libsdl2-dev libgtk-3-dev", | |
build_type: "MinSizeRel" | |
} | |
- { | |
name: "Linux Clang 6", | |
os: ubuntu-20.04, | |
extra_options: "-DCMAKE_C_COMPILER=clang-6.0 -DCMAKE_CXX_COMPILER=clang++-6.0 \ | |
-DDYN_FLUIDSYNTH=OFF -DDYN_OPENAL=OFF -DDYN_SNDFILE=OFF -DDYN_MPG123=OFF", | |
deps_cmdline: "sudo apt update && sudo apt install clang-6.0 libsdl2-dev libopenal-dev libfluidsynth-dev libmpg123-dev libsndfile1-dev", | |
build_type: "Debug" | |
} | |
- { | |
name: "Linux Clang 12", | |
os: ubuntu-20.04, | |
extra_options: "-DCMAKE_C_COMPILER=clang-12 -DCMAKE_CXX_COMPILER=clang++-12", | |
deps_cmdline: "sudo apt update && sudo apt install clang-12 libsdl2-dev", | |
build_type: "Release" | |
} | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Install Dependencies | |
shell: bash | |
run: | | |
if [[ ! -z "${{ matrix.config.deps_cmdline }}" ]]; then | |
eval ${{ matrix.config.deps_cmdline }} | |
fi | |
- name: Configure | |
shell: bash | |
run: | | |
cmake -B build -DCMAKE_BUILD_TYPE=${{ matrix.config.build_type }} -DPK3_QUIET_ZIPDIR=ON ${{ matrix.config.extra_options }} . | |
- name: Build | |
shell: bash | |
run: | | |
export MAKEFLAGS=--keep-going | |
cmake --build build --config ${{ matrix.config.build_type }} --parallel 3 | |
- name: Create Package | |
if: runner.os == 'Windows' # Remove to make packages of all targets | |
shell: bash | |
run: | | |
cd build | |
mkdir package | |
if [[ "${{ runner.os }}" == 'Windows' ]]; then | |
cp ${{ matrix.config.build_type }}/lzdoom.exe ${{ matrix.config.build_type }}/*.pk3 package | |
elif [[ "${{ runner.os }}" == 'macOS' ]]; then | |
cp -r lzdoom.app package | |
elif [[ "${{ runner.os }}" == 'Linux' ]]; then | |
cp lzdoom *.pk3 package | |
fi | |
- name: Upload Package | |
if: runner.os == 'Windows' # Remove to store packages of all targets | |
uses: actions/upload-artifact@v1 | |
with: | |
path: build/package | |
name: ${{ matrix.config.name }} ${{ matrix.config.build_type }} | |
- name: List Build Directory | |
if: always() | |
shell: bash | |
run: | | |
git status | |
ls -lR build |