CREATE_PROJECT: Explicitly add /opt/local/lib to support MacPorts #48
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: CI | |
on: [push, pull_request] | |
# schedule: | |
# - cron: '0 0-23/4 * * *' | |
permissions: | |
contents: read | |
jobs: | |
windows: | |
name: Windows | |
runs-on: windows-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- platform: win32 | |
triplet: x86-windows | |
arch: x86 | |
configFlags: --enable-discord --enable-faad --enable-gif --enable-mikmod --enable-mpeg2 --enable-vpx | |
useNasm: 'true' | |
- platform: x64 | |
arch: x64 | |
triplet: x64-windows | |
configFlags: --enable-discord --enable-faad --enable-gif --enable-mikmod --enable-mpeg2 --enable-vpx | |
- platform: arm64 | |
arch: arm64 | |
triplet: arm64-windows | |
configFlags: --enable-discord --enable-faad --enable-gif --enable-mikmod --enable-mpeg2 --enable-vpx --disable-opengl | |
env: | |
CONFIGURATION: Debug | |
PLATFORM: ${{ matrix.platform }} | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
VCPKG_FEATURE_FLAGS: dependencygraph | |
VCPKG_DEFAULT_TRIPLET: ${{ matrix.triplet }} | |
VCPKG_INSTALLED_DIR: ${{ github.workspace }}/vcpkg_installed | |
permissions: | |
contents: write # For dependencygraph | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- uses: ilammy/setup-nasm@v1 | |
if: ${{ matrix.useNasm }} == 'true' | |
- name: Install vcpkg | |
uses: lukka/run-vcpkg@v11 | |
id: runvcpkg | |
with: | |
vcpkgGitCommitId: 56954f1db97f38635782d5ad7cdfd45d2731c854 | |
- name: Integrate vcpkg | |
run: | | |
${{ steps.runvcpkg.outputs.RUNVCPKG_VCPKG_ROOT_OUT }}/vcpkg integrate install | |
- name: Upload libs | |
uses: actions/upload-artifact@v3 | |
if: ${{ matrix.buildArtifacts }} == 'true' | |
with: | |
name: libs-${{ matrix.triplet }} | |
path: ${{ env.VCPKG_INSTALLED_DIR }}\\${{ matrix.triplet }} | |
- name: Build create_project | |
run: | | |
cd devtools/create_project/cmake | |
cmake . | |
cmake --build . -j 2 | |
ls | |
cd ../../../ | |
- name: Call create_project | |
run: | | |
mkdir build-scummvm | |
cd build-scummvm | |
../devtools/create_project/cmake/Debug/create_project.exe .. --msvc --vcpkg --enable-all-engines ${{ matrix.configFlags }} | |
ls | |
- name: Add msbuild to PATH | |
uses: microsoft/[email protected] | |
- name: Build scummvm | |
run: | | |
cd build-scummvm | |
ls | |
msbuild scummvm.sln /m /p:VcpkgEnableManifest=true /p:BuildInParallel=true /p:Configuration=${{ env.CONFIGURATION }} /p:PreferredToolArchitecture=x64 /p:Platform=${{ matrix.platform }} /v:minimal | |
- name: Upload scummvm | |
uses: actions/upload-artifact@v3 | |
if: ${{ matrix.buildArtifacts }} == 'true' | |
with: | |
name: scummvm-${{ matrix.arch }} | |
path: build-scummvm/${{ env.CONFIGURATION }}${{ matrix.arch }}/*.exe | |
- name: Upload scummvm libs | |
uses: actions/upload-artifact@v3 | |
if: ${{ matrix.buildArtifacts }} == 'true' | |
with: | |
name: scummvm-${{ matrix.arch }} | |
path: ${{ env.VCPKG_INSTALLED_DIR }}\\${{ matrix.triplet }}\\bin\\*.dll | |
- name: Upload scummvm symbols | |
uses: actions/upload-artifact@v3 | |
if: ${{ matrix.buildArtifacts }} == 'true' | |
with: | |
name: symbols-${{ matrix.arch }} | |
path: build-scummvm/${{ env.CONFIGURATION }}${{ matrix.arch }}/*.pdb | |
- name: Upload scummvm libs symbols | |
uses: actions/upload-artifact@v3 | |
if: ${{ matrix.buildArtifacts }} == 'true' | |
with: | |
name: symbols-${{ matrix.arch }} | |
path: ${{ env.VCPKG_INSTALLED_DIR }}\\${{ matrix.triplet }}\\bin\\*.pdb | |
xcode: | |
name: Xcode | |
runs-on: macos-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- platform: macosx | |
buildFlags: -scheme ScummVM-macOS | |
configFlags: --disable-nasm --enable-faad --enable-gif --enable-mikmod --enable-mpeg2 --enable-vpx | |
brewPackages: a52dec faad2 flac fluid-synth freetype fribidi giflib jpeg mad libmikmod libmpeg2 libogg libpng libvorbis libvpx sdl2 sdl2_net theora | |
- platform: ios7 | |
buildFlags: -scheme ScummVM-iOS CODE_SIGN_IDENTITY="" CODE_SIGNING_ALLOWED=NO | |
configFlags: --use-xcframework --enable-faad --enable-gif --enable-mikmod --enable-mpeg2 --enable-vpx --disable-nasm --disable-taskbar --disable-tts | |
packagesUrl: https://downloads.scummvm.org/frs/build/scummvm-ios7-libs-v3.zip | |
env: | |
BUILDCACHE_MAX_CACHE_SIZE: 2000000000 | |
BUILDCACHE_HARD_LINKS: true | |
defaults: | |
run: | |
# Must be explicit for proper pipefail support | |
shell: bash | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Install packages | |
if: ${{ matrix.brewPackages }} | |
run: brew install ${{ matrix.brewPackages }} | |
- name: Download libraries | |
if: ${{ matrix.packagesUrl }} | |
run: | | |
curl -L -o libs.zip ${{ matrix.packagesUrl }} | |
unzip libs.zip | |
ls | |
- name: Build create_project | |
run: | | |
cd devtools/create_project/xcode | |
xcodebuild | |
ls | |
cd ../../../ | |
- name: Call create_project | |
run: | | |
./devtools/create_project/xcode/build/Release/create_project . --xcode --enable-all-engines ${{ matrix.configFlags }} | |
ls | |
- name: Build cache | |
uses: mikehardy/buildcache-action@v2 | |
with: | |
cache_key: ${{ matrix.platform }} | |
- name: Build scummvm | |
run: | | |
xcodebuild CC=clang CPLUSPLUS=clang++ LD=clang LDPLUSPLUS=clang++ build -project scummvm.xcodeproj ${{ matrix.buildFlags }} | awk '$1 !~ /^(export|cd|clang++)/' | |
ls | |
ubuntu: | |
name: Ubuntu | |
runs-on: ${{ matrix.platform }} | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- platform: ubuntu-latest | |
sdlConfig: sdl2-config | |
cxx: ccache g++ | |
aptPackages: 'liba52-dev libcurl4-openssl-dev libfaad-dev libflac-dev libfluidsynth-dev libfreetype6-dev libfribidi-dev libgif-dev libgtk-3-dev libjpeg-turbo8-dev libmad0-dev libmikmod-dev libmpeg2-4-dev libogg-dev libpng-dev libsdl2-dev libsdl2-net-dev libsndio-dev libspeechd-dev libtheora-dev libunity-dev libvorbis-dev libvpx-dev zlib1g-dev' | |
- platform: ubuntu-20.04 | |
sdlConfig: sdl-config | |
cxx: ccache g++-4.8 | |
aptPackages: 'g++-4.8 liba52-dev libcurl4-openssl-dev libfaad-dev libflac-dev libfluidsynth-dev libfreetype6-dev libfribidi-dev libgif-dev libgtk-3-dev libjpeg-turbo8-dev libmad0-dev libmikmod-dev libmpeg2-4-dev libogg-dev libpng-dev libsdl-net1.2-dev libsdl1.2-dev libsndio-dev libspeechd-dev libtheora-dev libunity-dev libvorbis-dev libvpx-dev zlib1g-dev' | |
env: | |
SDL_CONFIG: ${{ matrix.sdlConfig }} | |
defaults: | |
run: | |
# Must be explicit for proper pipefail support | |
shell: bash | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Add Ubuntu Xenial package sources | |
if: matrix.platform == 'ubuntu-20.04' | |
run: | | |
sudo apt-add-repository 'deb http://archive.ubuntu.com/ubuntu/ xenial main' | |
sudo apt-add-repository 'deb http://archive.ubuntu.com/ubuntu/ xenial universe' | |
- name: Install packages | |
run: | | |
sudo apt-get update | |
sudo apt-get install ${{ matrix.aptPackages }} | |
- name: ccache | |
uses: hendrikmuhs/[email protected] | |
with: | |
key: ${{ matrix.platform }} | |
max-size: 1G | |
- name: Call configure | |
run: | | |
CXX='${{ matrix.cxx }}' ./configure --enable-all-engines ${{ matrix.configFlags }} | |
- name: Build scummvm | |
run: | | |
make -j2 | |
- name: Build tests | |
run: | | |
make test | |
- name: Build devtools | |
run: | | |
make devtools |