Adding Dual screen support for DS port #160
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: macos | |
on: | |
pull_request: | |
push: | |
jobs: | |
vanilla-macos: | |
runs-on: macos-10.15 | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: 'true' | |
fetch-depth: 0 | |
ref: ${{ github.event.pull_request.head.sha }} | |
- uses: seanmiddleditch/gha-setup-ninja@master | |
- name: Set Git Info | |
id: gitinfo | |
run: echo "::set-output name=sha_short::$(git rev-parse --short HEAD)" | |
- name: Install dependencies | |
run: | | |
brew install sdl2 | |
brew install dylibbundler | |
brew install imagemagick | |
brew install openal-soft | |
- name: Configure Vanilla Conquer | |
run: | | |
cmake -G Ninja -DOPENAL_LIBRARY=/usr/local/opt/openal-soft/lib/libopenal.dylib -DOPENAL_INCLUDE_DIR=/usr/local/opt/openal-soft/include/AL -DCMAKE_BUILD_TYPE=RelWithDebInfo -DMAP_EDITORTD=ON -DMAP_EDITORRA=ON -DBUILD_TOOLS=ON -B build | |
- name: Build Vanilla Conquer | |
run: | | |
cmake --build build | |
dsymutil build/vanillatd.app/Contents/MacOS/vanillatd -o build/vanillatd.dSYM | |
dsymutil build/vanillara.app/Contents/MacOS/vanillara -o build/vanillara.dSYM | |
dsymutil build/vanillamix -o build/vanillamix.dSYM | |
strip -Sx build/vanillatd.app/Contents/MacOS/vanillatd | |
strip -Sx build/vanillara.app/Contents/MacOS/vanillara | |
strip -Sx build/vanillamix | |
dylibbundler --create-dir --bundle-deps --overwrite-files --dest-dir ./build/vanillatd.app/Contents/libs --fix-file build/vanillatd.app/Contents/MacOS/vanillatd | |
dylibbundler --create-dir --bundle-deps --overwrite-files --dest-dir ./build/vanillara.app/Contents/libs --fix-file build/vanillara.app/Contents/MacOS/vanillara | |
- name: Create archives | |
run: | | |
mkdir artifact | |
7z a artifact/vanilla-conquer-macos-clang-x86_64-${{ steps.gitinfo.outputs.sha_short }}.zip ./build/vanillatd.app ./build/vanillara.app ./build/vanillamix | |
7z a artifact/vanilla-conquer-macos-clang-x86_64-${{ steps.gitinfo.outputs.sha_short }}-debug.zip ./build/vanillatd.dSYM ./build/vanillara.dSYM ./build/vanillamix.dSYM | |
- name: Upload artifact | |
uses: actions/upload-artifact@v2 | |
with: | |
name: vanilla-conquer-macos-clang-x86_64 | |
path: artifact | |
- name: Upload development release | |
if: ${{ github.event_name != 'pull_request' && github.ref == 'refs/heads/vanilla' }} | |
uses: softprops/action-gh-release@v1 | |
with: | |
name: Development Build | |
tag_name: "latest" | |
prerelease: true | |
files: | | |
artifact/* | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Upload tagged release | |
if: ${{ startsWith(github.ref, 'refs/tags/') }} | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: | | |
artifact/* | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |