ci: add arm64 linux

This commit is contained in:
Rosalie Wanders
2025-10-01 09:51:57 +02:00
parent 9c53a846b8
commit 8682c1a583
2 changed files with 18 additions and 12 deletions
+11 -7
View File
@@ -4,17 +4,21 @@ on: [push, pull_request]
jobs:
build-linux:
runs-on: ubuntu-24.04
strategy:
matrix:
features: [ ON, OFF ]
include:
- { os: ubuntu-24.04, features: ON, architecture: x86_64 }
- { os: ubuntu-24.04, features: OFF, architecture: x86_64 }
- { os: ubuntu-24.04-arm, features: ON, architecture: aarch64 }
- { os: ubuntu-24.04-arm, features: OFF, architecture: aarch64 }
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: hendrikmuhs/ccache-action@v1.2
with:
key: linux-features-${{ matrix.features }}
key: linux-${{ matrix.architecture }}-features-${{ matrix.features }}
- name: Install Packages
run: |
sudo apt-get -y update
@@ -42,8 +46,8 @@ jobs:
mkdir -p "$sdl_dir/build"
cmake -S "$sdl_dir" -B "$sdl_dir/build" \
-DCMAKE_BUILD_TYPE="Release" \
-DCMAKE_INSTALL_LIBDIR="lib/x86_64-linux-gnu" \
-DCMAKE_INSTALL_FULL_LIBDIR="/usr/lib/x86_64-linux-gnu" \
-DCMAKE_INSTALL_LIBDIR="lib/${{ matrix.architecture }}-linux-gnu" \
-DCMAKE_INSTALL_FULL_LIBDIR="/usr/lib/${{ matrix.architecture }}-linux-gnu" \
-DCMAKE_C_COMPILER_LAUNCHER=ccache \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
@@ -73,12 +77,12 @@ jobs:
cmake --install "$build_dir" --strip --prefix="$bin_dir/usr"
shell: bash
- name: Create AppImage
if: ${{ matrix.features == 'ON' }}
if: ${{ matrix.features == 'ON' && matrix.architecture == 'x86_64' }}
run: |
./Package/AppImage/Create.sh
shell: bash
- name: Upload RMG (AppImage)
if: ${{ matrix.features == 'ON' }}
if: ${{ matrix.features == 'ON' && matrix.architecture == 'x86_64' }}
uses: actions/upload-artifact@v4
with:
name: RMG-Portable-Linux64-${{ env.GIT_REVISION }}
+7 -5
View File
@@ -5,13 +5,15 @@ script_dir="$(dirname "$0")"
toplvl_dir="$(realpath "$script_dir/../../")"
bin_dir="$toplvl_dir/Bin/AppImage" # RMG should be installed here
lib_dir="/usr/lib64"
arch="$(uname -m)"
XVFB_RUN="xvfb-run -a --"
LIB4BIN_URL="https://raw.githubusercontent.com/VHSgunzo/sharun/refs/heads/main/lib4bin"
APPIMAGETOOL_URL="https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-x86_64.AppImage"
SHARUN_URL="https://github.com/VHSgunzo/sharun/releases/latest/download/sharun-x86_64"
APPIMAGETOOL_URL="https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-$arch.AppImage"
SHARUN_URL="https://github.com/VHSgunzo/sharun/releases/latest/download/sharun-$arch"
export ARCH="$(uname -m)"
export ARCH="$arch"
export APPIMAGE_EXTRACT_AND_RUN=1
export VERSION="$(git describe --tags --always)"
export OUTPUT="$bin_dir/../RMG-Portable-Linux64-$VERSION.AppImage"
@@ -41,9 +43,9 @@ then
XVFB_RUN=""
fi
if [[ -d "/usr/lib/x86_64-linux-gnu/" ]]
if [[ -d "/usr/lib/$arch-linux-gnu/" ]]
then
lib_dir="/usr/lib/x86_64-linux-gnu/"
lib_dir="/usr/lib/$arch-linux-gnu/"
fi
cp "$bin_dir/usr/share/applications/com.github.Rosalie241.RMG.desktop" "$bin_dir"