ci: Add iOS builds

This commit is contained in:
ksagameng
2025-11-02 21:47:14 +03:00
committed by a1batross
parent 43066656bd
commit a6108b7930
3 changed files with 36 additions and 0 deletions

20
scripts/gha/build_ios.sh Executable file
View File

@@ -0,0 +1,20 @@
#!/bin/bash
. scripts/lib.sh
cd $GITHUB_WORKSPACE || die
./waf configure --enable-utils --enable-lto --ios build install --destdir=build/ios || die_configure
cp -vr /Library/Frameworks/SDL2.framework ./build
pushd hlsdk || die
cmake -DCMAKE_SYSTEM_NAME=iOS -DGAMEDIR=$(realpath ../build/ios) -DCMAKE_BUILD_TYPE=Debug -B build -S .
cmake --build build --target install || die
popd
./scripts/ios/createipa.sh
mkdir -p artifacts/
mv "build/xash3d.ipa" "build/xash3d-fwgs-ios-arm64.ipa"
cp "build/xash3d-fwgs-ios-arm64.ipa" artifacts

13
scripts/gha/deps_ios.sh Normal file
View File

@@ -0,0 +1,13 @@
#!/bin/bash
cd $GITHUB_WORKSPACE
git clone https://github.com/libsdl-org/SDL -b SDL2
cd SDL/Xcode/SDL
xcodebuild -scheme xcFramework-iOS -target xcFramework-iOS build -configuration Release
sudo cp -vr Products/SDL2.xcframework/ios-arm64/SDL2.framework /Library/Frameworks
cd $GITHUB_WORKSPACE
git clone https://github.com/FWGS/hlsdk-portable hlsdk --depth=1