Skip to content

Fixed build

Fixed build #496

Workflow file for this run

name: 'Linux (Cross-compile)'
on:
push:
branches:
- '*'
pull_request:
types: [ opened, synchronize ]
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
Build:
strategy:
fail-fast: false
matrix:
include:
- BuildType: Release
Platform: aarch64
Backend: GLFW
Distro: ubuntu_latest
CC: gcc
CXX: g++
- BuildType: Release
Platform: aarch64
Backend: SDL2
Distro: ubuntu_latest
CC: gcc
CXX: g++
runs-on: 'ubuntu-latest'
steps:
- name: 'Checkout Repository'
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: 'Configure CMake and Build'
uses: uraimo/run-on-arch-action@v2
with:
arch: ${{ matrix.Platform }}
distro: ${{ matrix.Distro }}
githubToken: ${{ github.token }}
dockerRunArgs: --volume "${PWD}:/_current"
install: |
case "${{ matrix.Distro }}" in
ubuntu*|jessie|stretch|buster|bullseye)
apt-get update -y
apt-get install -y cmake curl git g++ libgles2-mesa-dev libglfw3-dev libsdl2-dev libopenal-dev libopenmpt-dev rpm
;;
esac
run: |
echo "::group::Configure CMake"
export CC=${{ matrix.CC }}
export CXX=${{ matrix.CXX }}
git config --global --add safe.directory '*'
cd /_current/
rm -f ./Content/Translations/*.po
cmake -B ./_build/ -D CMAKE_BUILD_TYPE=${{ matrix.BuildType }} -D NCINE_STRIP_BINARIES=ON -D NCINE_PREFERRED_BACKEND=${{ matrix.Backend }} -D NCINE_DOWNLOAD_DEPENDENCIES=OFF
echo "::endgroup::"
echo "::group::Build"
make -j $(nproc) -C ./_build/
echo "::endgroup::"
- name: 'Create Package'
run: |
mkdir ./_package/
cp -f ./_build/jazz2 ./_package/jazz2
cp -f -r ./Content/ ./_package/Content/
cp -f ./LICENSE ./_package/LICENSE
- name: 'Upload Package'
uses: actions/upload-artifact@v4
with:
name: Jazz2_Linux_${{ matrix.Platform }}_${{ matrix.Backend }}
path: ./_package/