From 553175fedbebdbc04ac475aa33dd0f1374b9e247 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Fri, 14 Feb 2025 22:56:18 +0100 Subject: [PATCH 1/5] Update to Node 20. --- .github/workflows/build-natives.yml | 8 ++++---- .github/workflows/build-nuget.yml | 14 +++++++------- .github/workflows/build-openal.yml | 6 +++--- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build-natives.yml b/.github/workflows/build-natives.yml index c1281e9..8af1eb6 100644 --- a/.github/workflows/build-natives.yml +++ b/.github/workflows/build-natives.yml @@ -29,7 +29,7 @@ jobs: unzip -j -d artifacts/x64 openal-soft-${OPENALSOFT_VERSION}-bin.zip openal-soft-${OPENALSOFT_VERSION}-bin/bin/Win64/soft_oal.dll - name: Upload Artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: Natives-Windows path: ./artifacts @@ -54,7 +54,7 @@ jobs: lipo -thin arm64 build/libopenal.${OPENALSOFT_VERSION}.dylib -output ../artifacts/arm64/soft_oal.dylib - name: Upload Artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: Natives-MacOS path: ./artifacts @@ -84,7 +84,7 @@ jobs: cp libopenal.so ../../artifacts/x64/soft_oal.so - name: Upload Artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: Natives-Linux(x64) path: ./artifacts @@ -119,7 +119,7 @@ jobs: cp libopenal.so /artifacts/arm64/soft_oal.so - name: Upload Artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: Natives-Linux(arm64) path: ./artifacts diff --git a/.github/workflows/build-nuget.yml b/.github/workflows/build-nuget.yml index ff2064d..9d3cc35 100644 --- a/.github/workflows/build-nuget.yml +++ b/.github/workflows/build-nuget.yml @@ -33,7 +33,7 @@ jobs: needs: [compile-openal, compile-natives] steps: - name: Clone repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Prepare environment variables run: | @@ -46,31 +46,31 @@ jobs: fi - name: Download artifacts - OpenAL-CS.dll - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: OpenAL-CS path: ./bin - name: Download artifacts - native - Windows - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: Natives-Windows path: ./native/win - name: Download artifacts - native - MacOS - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: Natives-MacOS path: ./native/osx - name: Download artifacts - native - Linux (x64) - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: Natives-Linux(x64) path: ./native/linux - name: Download artifacts - native - Linux (arm64) - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: Natives-Linux(arm64) path: ./native/linux @@ -83,7 +83,7 @@ jobs: nuget pack OpenRA-OpenAL-CS.nuspec -OutputDirectory ./nuget -version ${{ env.PACKAGE_VERSION }} - name: Upload NuGet package to Artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: NuGet Package ${{ env.PACKAGE_VERSION }} path: ./nuget diff --git a/.github/workflows/build-openal.yml b/.github/workflows/build-openal.yml index ae6642e..6426d58 100644 --- a/.github/workflows/build-openal.yml +++ b/.github/workflows/build-openal.yml @@ -14,11 +14,11 @@ jobs: runs-on: ubuntu-22.04 steps: - name: Clone Repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 # Since OpenAL-CS.csproj targets netstandard2.0 we don't need .NET 6, but let's not risk having outdated support for older versions. - name: Install .NET 6 - uses: actions/setup-dotnet@v3 + uses: actions/setup-dotnet@v4 with: dotnet-version: '6.0.x' @@ -27,7 +27,7 @@ jobs: dotnet build OpenAL-CS.sln - name: Upload Artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: OpenAL-CS path: ./bin From f77a9212a7ead09b32f10d0184f8ed29d16b28a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Fri, 14 Feb 2025 22:56:25 +0100 Subject: [PATCH 2/5] Bump macOS. --- .github/workflows/build-natives.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-natives.yml b/.github/workflows/build-natives.yml index 8af1eb6..4f5a4fb 100644 --- a/.github/workflows/build-natives.yml +++ b/.github/workflows/build-natives.yml @@ -36,7 +36,7 @@ jobs: macos: name: macOS (x64 + arm64) - runs-on: macos-11 + runs-on: macos-13 steps: - name: Setup Dependencies run: | From 409224421417712b60688cc37f1368ea11c12b14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Fri, 14 Feb 2025 22:56:54 +0100 Subject: [PATCH 3/5] Use ARM runner. --- .github/workflows/build-natives.yml | 38 ++++++++++------------------- 1 file changed, 13 insertions(+), 25 deletions(-) diff --git a/.github/workflows/build-natives.yml b/.github/workflows/build-natives.yml index 4f5a4fb..3c27172 100644 --- a/.github/workflows/build-natives.yml +++ b/.github/workflows/build-natives.yml @@ -89,34 +89,22 @@ jobs: name: Natives-Linux(x64) path: ./artifacts - # Note: Using the run-on-arch action is *very* slow, but is the only way to simulate arm64 architecture. linux-arm64: name: Linux (arm64) - runs-on: ubuntu-22.04 + runs-on: ubuntu-22.04-arm steps: - - name: Setup dependencies and compile natives - uses: uraimo/run-on-arch-action@v2 - with: - arch: aarch64 - distro: ubuntu22.04 - shell: /bin/sh - githubToken: ${{ github.token }} - setup: | - mkdir -p "${PWD}/artifacts/arm64" - dockerRunArgs: | - --volume "${PWD}/artifacts:/artifacts" - env: | - OPENALSOFT_VERSION: ${{ env.OPENALSOFT_VERSION }} - install: | - apt-get update -q -y - apt-get install -y build-essential curl cmake libasound2-dev portaudio19-dev libpulse-dev - run: | - curl -s -L -O https://openal-soft.org/openal-releases/openal-soft-${OPENALSOFT_VERSION}.tar.bz2 - tar xf openal-soft-${OPENALSOFT_VERSION}.tar.bz2 - cd openal-soft-${OPENALSOFT_VERSION}/build - cmake .. -DBUILD_SHARED_LIBS=true -DCMAKE_BUILD_TYPE=Release - cmake --build . - cp libopenal.so /artifacts/arm64/soft_oal.so + - name: Setup Dependencies + run: | + mkdir -p artifacts/arm64 + sudo apt-get install -y build-essential curl cmake libasound2-dev portaudio19-dev libpulse-dev + - name: Compile Natives + run: | + curl -s -L -O https://openal-soft.org/openal-releases/openal-soft-${OPENALSOFT_VERSION}.tar.bz2 + tar xf openal-soft-${OPENALSOFT_VERSION}.tar.bz2 + cd openal-soft-${OPENALSOFT_VERSION}/build + cmake .. -DBUILD_SHARED_LIBS=true -DCMAKE_BUILD_TYPE=Release + cmake --build . + cp libopenal.so ../../artifacts/arm64/soft_oal.so - name: Upload Artifacts uses: actions/upload-artifact@v4 From bff71eb603ef5cedc2dc03eb3b067c59529faa44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Fri, 14 Feb 2025 23:02:54 +0100 Subject: [PATCH 4/5] Switch to Rocky Linux 8. --- .github/workflows/build-natives.yml | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build-natives.yml b/.github/workflows/build-natives.yml index 3c27172..42ac96b 100644 --- a/.github/workflows/build-natives.yml +++ b/.github/workflows/build-natives.yml @@ -59,28 +59,27 @@ jobs: name: Natives-MacOS path: ./artifacts - # Note: Running inside a CentOS container because we want to compile using a version of glibc + # Note: Running inside a Rocky Linux container because we want to compile using a version of glibc # that is as old as reasonably possible to ensure backwards compatibility of the compiled binaries. linux-x64: name: Linux (x64) runs-on: ubuntu-22.04 - container: centos:centos7 + container: rockylinux:8 steps: - name: Setup Dependencies run: | mkdir -p artifacts/x64 - yum -y install https://repo.ius.io/ius-release-el7.rpm centos-release-scl scl-utils - yum -y install devtoolset-8 cmake3 bzip2 - yum -y install alsa-lib-devel portaudio-devel pulseaudio-libs-devel libsoundio-devel + dnf -y install epel-release + yum -y install gcc-c++ gcc cmake bzip2 + yum -y install alsa-lib-devel portaudio-devel pulseaudio-libs-devel - name: Compile natives run: | - source /opt/rh/devtoolset-8/enable curl -s -L -O https://openal-soft.org/openal-releases/openal-soft-${OPENALSOFT_VERSION}.tar.bz2 tar xf openal-soft-${OPENALSOFT_VERSION}.tar.bz2 cd openal-soft-${OPENALSOFT_VERSION}/build - cmake3 .. -DBUILD_SHARED_LIBS=true -DCMAKE_BUILD_TYPE=Release - cmake3 --build . + cmake .. -DBUILD_SHARED_LIBS=true -DCMAKE_BUILD_TYPE=Release + cmake --build . cp libopenal.so ../../artifacts/x64/soft_oal.so - name: Upload Artifacts From d25e4e04eddaac16bca653b47cccd40eaa18773e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Fri, 14 Feb 2025 23:38:30 +0100 Subject: [PATCH 5/5] Add Pipewire support. --- .github/workflows/build-natives.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-natives.yml b/.github/workflows/build-natives.yml index 42ac96b..778450c 100644 --- a/.github/workflows/build-natives.yml +++ b/.github/workflows/build-natives.yml @@ -71,7 +71,7 @@ jobs: mkdir -p artifacts/x64 dnf -y install epel-release yum -y install gcc-c++ gcc cmake bzip2 - yum -y install alsa-lib-devel portaudio-devel pulseaudio-libs-devel + yum -y install alsa-lib-devel portaudio-devel pulseaudio-libs-devel pipewire-devel - name: Compile natives run: | @@ -95,7 +95,7 @@ jobs: - name: Setup Dependencies run: | mkdir -p artifacts/arm64 - sudo apt-get install -y build-essential curl cmake libasound2-dev portaudio19-dev libpulse-dev + sudo apt-get install -y build-essential curl cmake libasound2-dev portaudio19-dev libpulse-dev libpipewire-0.3-dev - name: Compile Natives run: | curl -s -L -O https://openal-soft.org/openal-releases/openal-soft-${OPENALSOFT_VERSION}.tar.bz2