mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-03 08:03:50 +00:00
fix(ci): bundle libssl in macOS app
This commit is contained in:
parent
8d78976904
commit
0a164cfb6e
2 changed files with 649 additions and 666 deletions
722
.github/workflows/build.yml
vendored
722
.github/workflows/build.yml
vendored
|
|
@ -2,9 +2,9 @@ name: Build
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [master]
|
branches: [ master ]
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [master]
|
branches: [ master ]
|
||||||
|
|
||||||
env:
|
env:
|
||||||
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
|
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
|
||||||
|
|
@ -21,107 +21,107 @@ jobs:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- arch: x86-64
|
- arch: x86-64
|
||||||
runner: ubuntu-24.04
|
runner: ubuntu-24.04
|
||||||
deb_arch: amd64
|
deb_arch: amd64
|
||||||
build_jobs: $(nproc)
|
build_jobs: $(nproc)
|
||||||
- arch: arm64
|
- arch: arm64
|
||||||
runner: ubuntu-24.04-arm
|
runner: ubuntu-24.04-arm
|
||||||
deb_arch: arm64
|
deb_arch: arm64
|
||||||
build_jobs: 2
|
build_jobs: 2
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
submodules: true
|
submodules: true
|
||||||
|
|
||||||
- name: Cache apt packages
|
- name: Cache apt packages
|
||||||
uses: actions/cache@v4
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: /var/cache/apt/archives/*.deb
|
path: /var/cache/apt/archives/*.deb
|
||||||
key: apt-${{ matrix.arch }}-${{ hashFiles('.github/workflows/build.yml') }}
|
key: apt-${{ matrix.arch }}-${{ hashFiles('.github/workflows/build.yml') }}
|
||||||
restore-keys: apt-${{ matrix.arch }}-
|
restore-keys: apt-${{ matrix.arch }}-
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install -y \
|
sudo apt-get install -y \
|
||||||
cmake \
|
cmake \
|
||||||
build-essential \
|
build-essential \
|
||||||
pkg-config \
|
pkg-config \
|
||||||
libsdl2-dev \
|
libsdl2-dev \
|
||||||
libglew-dev \
|
libglew-dev \
|
||||||
libglm-dev \
|
libglm-dev \
|
||||||
libssl-dev \
|
libssl-dev \
|
||||||
zlib1g-dev \
|
zlib1g-dev \
|
||||||
libvulkan-dev \
|
libvulkan-dev \
|
||||||
vulkan-tools \
|
vulkan-tools \
|
||||||
glslc \
|
glslc \
|
||||||
libavformat-dev \
|
libavformat-dev \
|
||||||
libavcodec-dev \
|
libavcodec-dev \
|
||||||
libswscale-dev \
|
libswscale-dev \
|
||||||
libavutil-dev \
|
libavutil-dev \
|
||||||
libunicorn-dev \
|
libunicorn-dev \
|
||||||
libx11-dev
|
libx11-dev
|
||||||
sudo apt-get install -y libstorm-dev || true
|
sudo apt-get install -y libstorm-dev || true
|
||||||
|
|
||||||
- name: Fetch AMD FSR2 SDK
|
- name: Fetch AMD FSR2 SDK
|
||||||
run: |
|
run: |
|
||||||
rm -rf extern/FidelityFX-FSR2
|
rm -rf extern/FidelityFX-FSR2
|
||||||
git clone --depth 1 --branch "${WOWEE_AMD_FSR2_REF}" "${WOWEE_AMD_FSR2_REPO}" extern/FidelityFX-FSR2
|
git clone --depth 1 --branch "${WOWEE_AMD_FSR2_REF}" "${WOWEE_AMD_FSR2_REPO}" extern/FidelityFX-FSR2
|
||||||
rm -rf extern/FidelityFX-SDK
|
rm -rf extern/FidelityFX-SDK
|
||||||
git clone --depth 1 --branch "${WOWEE_FFX_SDK_REF}" "${WOWEE_FFX_SDK_REPO}" extern/FidelityFX-SDK
|
git clone --depth 1 --branch "${WOWEE_FFX_SDK_REF}" "${WOWEE_FFX_SDK_REPO}" extern/FidelityFX-SDK
|
||||||
|
|
||||||
- name: Check AMD FSR2 Vulkan permutation headers
|
- name: Check AMD FSR2 Vulkan permutation headers
|
||||||
run: |
|
run: |
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
SDK_DIR="$PWD/extern/FidelityFX-FSR2"
|
SDK_DIR="$PWD/extern/FidelityFX-FSR2"
|
||||||
OUT_DIR="$SDK_DIR/src/ffx-fsr2-api/vk/shaders"
|
OUT_DIR="$SDK_DIR/src/ffx-fsr2-api/vk/shaders"
|
||||||
if [ -f "$OUT_DIR/ffx_fsr2_accumulate_pass_permutations.h" ]; then
|
if [ -f "$OUT_DIR/ffx_fsr2_accumulate_pass_permutations.h" ]; then
|
||||||
echo "AMD FSR2 Vulkan permutation headers detected."
|
echo "AMD FSR2 Vulkan permutation headers detected."
|
||||||
else
|
else
|
||||||
echo "AMD FSR2 Vulkan permutation headers not found in SDK checkout."
|
echo "AMD FSR2 Vulkan permutation headers not found in SDK checkout."
|
||||||
echo "WoWee CMake will bootstrap vendored headers."
|
echo "WoWee CMake will bootstrap vendored headers."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Check FidelityFX-SDK Kits framegen headers
|
- name: Check FidelityFX-SDK Kits framegen headers
|
||||||
run: |
|
run: |
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
KITS_DIR="$PWD/extern/FidelityFX-SDK/Kits/FidelityFX"
|
KITS_DIR="$PWD/extern/FidelityFX-SDK/Kits/FidelityFX"
|
||||||
test -f "$KITS_DIR/upscalers/fsr3/include/ffx_fsr3upscaler.h"
|
test -f "$KITS_DIR/upscalers/fsr3/include/ffx_fsr3upscaler.h"
|
||||||
test -f "$KITS_DIR/framegeneration/fsr3/include/ffx_frameinterpolation.h"
|
test -f "$KITS_DIR/framegeneration/fsr3/include/ffx_frameinterpolation.h"
|
||||||
test -f "$KITS_DIR/framegeneration/fsr3/include/ffx_opticalflow.h"
|
test -f "$KITS_DIR/framegeneration/fsr3/include/ffx_opticalflow.h"
|
||||||
test -f "$KITS_DIR/backend/vk/ffx_vk.h"
|
test -f "$KITS_DIR/backend/vk/ffx_vk.h"
|
||||||
echo "FidelityFX-SDK Kits framegen headers detected."
|
echo "FidelityFX-SDK Kits framegen headers detected."
|
||||||
|
|
||||||
- name: Configure (AMD ON)
|
- name: Configure (AMD ON)
|
||||||
run: cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DWOWEE_ENABLE_AMD_FSR2=ON
|
run: cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DWOWEE_ENABLE_AMD_FSR2=ON
|
||||||
|
|
||||||
- name: Assert AMD FSR2 target
|
- name: Assert AMD FSR2 target
|
||||||
run: cmake --build build --target wowee_fsr2_amd_vk --parallel ${{ matrix.build_jobs }}
|
run: cmake --build build --target wowee_fsr2_amd_vk --parallel ${{ matrix.build_jobs }}
|
||||||
|
|
||||||
- name: Assert AMD FSR3 framegen probe target (if present)
|
- name: Assert AMD FSR3 framegen probe target (if present)
|
||||||
run: |
|
run: |
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
if cmake --build build --target help | grep -q 'wowee_fsr3_framegen_amd_vk_probe'; then
|
if cmake --build build --target help | grep -q 'wowee_fsr3_framegen_amd_vk_probe'; then
|
||||||
cmake --build build --target wowee_fsr3_framegen_amd_vk_probe --parallel ${{ matrix.build_jobs }}
|
cmake --build build --target wowee_fsr3_framegen_amd_vk_probe --parallel ${{ matrix.build_jobs }}
|
||||||
else
|
else
|
||||||
echo "FSR3 framegen probe target not generated for this SDK layout; continuing."
|
echo "FSR3 framegen probe target not generated for this SDK layout; continuing."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: cmake --build build --parallel ${{ matrix.build_jobs }}
|
run: cmake --build build --parallel ${{ matrix.build_jobs }}
|
||||||
|
|
||||||
- name: Package (DEB)
|
- name: Package (DEB)
|
||||||
run: cd build && cpack -G DEB
|
run: cd build && cpack -G DEB
|
||||||
|
|
||||||
- name: Upload DEB
|
- name: Upload DEB
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wowee-linux-${{ matrix.arch }}-deb
|
name: wowee-linux-${{ matrix.arch }}-deb
|
||||||
path: build/wowee-*.deb
|
path: build/wowee-*.deb
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
|
|
||||||
build-macos:
|
build-macos:
|
||||||
name: Build (macOS ${{ matrix.arch }})
|
name: Build (macOS ${{ matrix.arch }})
|
||||||
|
|
@ -130,325 +130,309 @@ jobs:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- arch: arm64
|
- arch: arm64
|
||||||
runner: macos-15
|
runner: macos-15
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
submodules: true
|
submodules: true
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
brew install cmake pkg-config sdl2 glew glm openssl@3 zlib ffmpeg unicorn \
|
brew install cmake pkg-config sdl2 glew glm openssl@3 zlib ffmpeg unicorn \
|
||||||
stormlib vulkan-loader vulkan-headers shaderc dylibbundler || true
|
stormlib vulkan-loader vulkan-headers shaderc dylibbundler || true
|
||||||
# dylibbundler may not be in all brew mirrors; install separately to not block others
|
# dylibbundler may not be in all brew mirrors; install separately to not block others
|
||||||
brew install dylibbundler 2>/dev/null || true
|
brew install dylibbundler 2>/dev/null || true
|
||||||
|
|
||||||
- name: Fetch AMD FSR2 SDK
|
- name: Fetch AMD FSR2 SDK
|
||||||
run: |
|
run: |
|
||||||
rm -rf extern/FidelityFX-FSR2
|
rm -rf extern/FidelityFX-FSR2
|
||||||
git clone --depth 1 --branch "${WOWEE_AMD_FSR2_REF}" "${WOWEE_AMD_FSR2_REPO}" extern/FidelityFX-FSR2
|
git clone --depth 1 --branch "${WOWEE_AMD_FSR2_REF}" "${WOWEE_AMD_FSR2_REPO}" extern/FidelityFX-FSR2
|
||||||
rm -rf extern/FidelityFX-SDK
|
rm -rf extern/FidelityFX-SDK
|
||||||
git clone --depth 1 --branch "${WOWEE_FFX_SDK_REF}" "${WOWEE_FFX_SDK_REPO}" extern/FidelityFX-SDK
|
git clone --depth 1 --branch "${WOWEE_FFX_SDK_REF}" "${WOWEE_FFX_SDK_REPO}" extern/FidelityFX-SDK
|
||||||
|
|
||||||
- name: Configure
|
- name: Configure
|
||||||
run: |
|
run: |
|
||||||
BREW=$(brew --prefix)
|
BREW=$(brew --prefix)
|
||||||
export PKG_CONFIG_PATH="$BREW/lib/pkgconfig:$(brew --prefix ffmpeg)/lib/pkgconfig:$(brew --prefix openssl@3)/lib/pkgconfig:$(brew --prefix vulkan-loader)/lib/pkgconfig:$(brew --prefix shaderc)/lib/pkgconfig"
|
export PKG_CONFIG_PATH="$BREW/lib/pkgconfig:$(brew --prefix ffmpeg)/lib/pkgconfig:$(brew --prefix openssl@3)/lib/pkgconfig:$(brew --prefix vulkan-loader)/lib/pkgconfig:$(brew --prefix shaderc)/lib/pkgconfig"
|
||||||
cmake -S . -B build \
|
cmake -S . -B build \
|
||||||
-DCMAKE_BUILD_TYPE=Release \
|
-DCMAKE_BUILD_TYPE=Release \
|
||||||
-DCMAKE_PREFIX_PATH="$BREW" \
|
-DCMAKE_PREFIX_PATH="$BREW" \
|
||||||
-DOPENSSL_ROOT_DIR="$(brew --prefix openssl@3)" \
|
-DOPENSSL_ROOT_DIR="$(brew --prefix openssl@3)" \
|
||||||
-DWOWEE_ENABLE_AMD_FSR2=ON
|
-DWOWEE_ENABLE_AMD_FSR2=ON
|
||||||
|
|
||||||
- name: Assert AMD FSR2 target
|
- name: Assert AMD FSR2 target
|
||||||
run: cmake --build build --target wowee_fsr2_amd_vk --parallel $(sysctl -n hw.logicalcpu)
|
run: cmake --build build --target wowee_fsr2_amd_vk --parallel $(sysctl -n hw.logicalcpu)
|
||||||
|
|
||||||
- name: Assert AMD FSR3 framegen probe target (if present)
|
- name: Assert AMD FSR3 framegen probe target (if present)
|
||||||
run: |
|
run: |
|
||||||
if cmake --build build --target help | grep -q 'wowee_fsr3_framegen_amd_vk_probe'; then
|
if cmake --build build --target help | grep -q 'wowee_fsr3_framegen_amd_vk_probe'; then
|
||||||
cmake --build build --target wowee_fsr3_framegen_amd_vk_probe --parallel $(sysctl -n hw.logicalcpu)
|
cmake --build build --target wowee_fsr3_framegen_amd_vk_probe --parallel $(sysctl -n hw.logicalcpu)
|
||||||
else
|
else
|
||||||
echo "FSR3 framegen probe target not generated for this SDK layout; continuing."
|
echo "FSR3 framegen probe target not generated for this SDK layout; continuing."
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: Build
|
||||||
|
run: cmake --build build --parallel $(sysctl -n hw.logicalcpu)
|
||||||
|
|
||||||
|
- name: Create .app bundle
|
||||||
|
run: |
|
||||||
|
mkdir -p Wowee.app/Contents/{MacOS,Frameworks,Resources}
|
||||||
|
|
||||||
|
# Wrapper launch script — cd to MacOS/ so ./assets/ resolves correctly
|
||||||
|
printf '#!/bin/bash\ncd "$(dirname "$0")"\nexec ./wowee_bin "$@"\n' \
|
||||||
|
> Wowee.app/Contents/MacOS/wowee
|
||||||
|
chmod +x Wowee.app/Contents/MacOS/wowee
|
||||||
|
|
||||||
|
# Actual binary
|
||||||
|
cp build/bin/wowee Wowee.app/Contents/MacOS/wowee_bin
|
||||||
|
|
||||||
|
# Assets (exclude proprietary music)
|
||||||
|
rsync -a --exclude='Original Music' build/bin/assets/ \
|
||||||
|
Wowee.app/Contents/MacOS/assets/
|
||||||
|
|
||||||
|
# Bundle dylibs (if dylibbundler available)
|
||||||
|
if command -v dylibbundler &>/dev/null; then
|
||||||
|
dylibbundler -od -b \
|
||||||
|
-x Wowee.app/Contents/MacOS/wowee_bin \
|
||||||
|
-d Wowee.app/Contents/Frameworks/ \
|
||||||
|
-p @executable_path/../Frameworks/
|
||||||
|
fi
|
||||||
|
|
||||||
|
# dylibbundler may miss Homebrew's Vulkan loader on some runner images.
|
||||||
|
# Copy all vulkan-loader dylib names so wowee_bin can resolve whichever
|
||||||
|
# install_name it was linked against (e.g. libvulkan.1.4.341.dylib).
|
||||||
|
VULKAN_LIB_DIR="$(brew --prefix vulkan-loader)/lib"
|
||||||
|
for lib in "${VULKAN_LIB_DIR}"/libvulkan*.dylib; do
|
||||||
|
[ -e "${lib}" ] || continue
|
||||||
|
cp -f "${lib}" Wowee.app/Contents/Frameworks/
|
||||||
|
done
|
||||||
|
|
||||||
|
if ! ls Wowee.app/Contents/Frameworks/libvulkan*.dylib >/dev/null 2>&1; then
|
||||||
|
echo "Missing Vulkan loader dylib(s) in app bundle Frameworks/" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# dylibbundler may miss Homebrew's OpenSSL on some runner images.
|
||||||
|
# Copy libssl and libcrypto so wowee_bin can resolve them at runtime.
|
||||||
|
OPENSSL_LIB_DIR="$(brew --prefix openssl@3)/lib"
|
||||||
|
for lib in "${OPENSSL_LIB_DIR}"/libssl*.dylib "${OPENSSL_LIB_DIR}"/libcrypto*.dylib; do
|
||||||
|
[ -e "${lib}" ] || continue
|
||||||
|
cp -f "${lib}" Wowee.app/Contents/Frameworks/
|
||||||
|
done
|
||||||
|
|
||||||
|
if ! ls Wowee.app/Contents/Frameworks/libssl*.dylib >/dev/null 2>&1; then
|
||||||
|
echo "Missing OpenSSL libssl dylib(s) in app bundle Frameworks/" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Info.plist
|
||||||
|
cat > Wowee.app/Contents/Info.plist << 'EOF'
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
|
||||||
|
"http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||||
|
<plist version="1.0"><dict>
|
||||||
|
<key>CFBundleExecutable</key><string>wowee</string>
|
||||||
|
<key>CFBundleIdentifier</key><string>com.wowee.app</string>
|
||||||
|
<key>CFBundleName</key><string>Wowee</string>
|
||||||
|
<key>CFBundleVersion</key><string>1.0.0</string>
|
||||||
|
<key>CFBundleShortVersionString</key><string>1.0.0</string>
|
||||||
|
<key>CFBundlePackageType</key><string>APPL</string>
|
||||||
|
</dict></plist>
|
||||||
|
EOF
|
||||||
|
|
||||||
|
# Ad-hoc codesign (allows running on the local machine)
|
||||||
|
codesign --force --deep --sign - Wowee.app
|
||||||
|
|
||||||
|
- name: Create DMG
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
rm -f Wowee.dmg
|
||||||
|
# CI runners can occasionally leave a mounted volume around; detach if present.
|
||||||
|
if [ -d "/Volumes/Wowee" ]; then
|
||||||
|
hdiutil detach "/Volumes/Wowee" -force || true
|
||||||
|
sleep 2
|
||||||
|
fi
|
||||||
|
|
||||||
|
ok=0
|
||||||
|
for attempt in 1 2 3 4 5; do
|
||||||
|
if hdiutil create -volname Wowee -srcfolder Wowee.app -ov -format UDZO Wowee.dmg; then
|
||||||
|
ok=1
|
||||||
|
break
|
||||||
fi
|
fi
|
||||||
|
echo "hdiutil create failed on attempt ${attempt}; retrying..."
|
||||||
- name: Build
|
|
||||||
run: cmake --build build --parallel $(sysctl -n hw.logicalcpu)
|
|
||||||
|
|
||||||
- name: Create .app bundle
|
|
||||||
run: |
|
|
||||||
mkdir -p Wowee.app/Contents/{MacOS,Frameworks,Resources}
|
|
||||||
|
|
||||||
# Wrapper launch script — cd to MacOS/ so ./assets/ resolves correctly
|
|
||||||
printf '#!/bin/bash\ncd "$(dirname "$0")"\nexec ./wowee_bin "$@"\n' \
|
|
||||||
> Wowee.app/Contents/MacOS/wowee
|
|
||||||
chmod +x Wowee.app/Contents/MacOS/wowee
|
|
||||||
|
|
||||||
# Actual binary
|
|
||||||
cp build/bin/wowee Wowee.app/Contents/MacOS/wowee_bin
|
|
||||||
|
|
||||||
# Assets (exclude proprietary music)
|
|
||||||
rsync -a --exclude='Original Music' build/bin/assets/ \
|
|
||||||
Wowee.app/Contents/MacOS/assets/
|
|
||||||
|
|
||||||
# Bundle dylibs (if dylibbundler available)
|
|
||||||
if command -v dylibbundler &>/dev/null; then
|
|
||||||
dylibbundler -od -b \
|
|
||||||
-x Wowee.app/Contents/MacOS/wowee_bin \
|
|
||||||
-d Wowee.app/Contents/Frameworks/ \
|
|
||||||
-p @executable_path/../Frameworks/
|
|
||||||
fi
|
|
||||||
|
|
||||||
# dylibbundler may miss Homebrew's Vulkan loader on some runner images.
|
|
||||||
# Copy all vulkan-loader dylib names so wowee_bin can resolve whichever
|
|
||||||
# install_name it was linked against (e.g. libvulkan.1.4.341.dylib).
|
|
||||||
VULKAN_LIB_DIR="$(brew --prefix vulkan-loader)/lib"
|
|
||||||
for lib in "${VULKAN_LIB_DIR}"/libvulkan*.dylib; do
|
|
||||||
[ -e "${lib}" ] || continue
|
|
||||||
cp -f "${lib}" Wowee.app/Contents/Frameworks/
|
|
||||||
done
|
|
||||||
|
|
||||||
if ! ls Wowee.app/Contents/Frameworks/libvulkan*.dylib >/dev/null 2>&1; then
|
|
||||||
echo "Missing Vulkan loader dylib(s) in app bundle Frameworks/" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Info.plist
|
|
||||||
cat > Wowee.app/Contents/Info.plist << 'EOF'
|
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
|
|
||||||
"http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
||||||
<plist version="1.0"><dict>
|
|
||||||
<key>CFBundleExecutable</key><string>wowee</string>
|
|
||||||
<key>CFBundleIdentifier</key><string>com.wowee.app</string>
|
|
||||||
<key>CFBundleName</key><string>Wowee</string>
|
|
||||||
<key>CFBundleVersion</key><string>1.0.0</string>
|
|
||||||
<key>CFBundleShortVersionString</key><string>1.0.0</string>
|
|
||||||
<key>CFBundlePackageType</key><string>APPL</string>
|
|
||||||
</dict></plist>
|
|
||||||
EOF
|
|
||||||
|
|
||||||
# Ad-hoc codesign (allows running on the local machine)
|
|
||||||
codesign --force --deep --sign - Wowee.app
|
|
||||||
|
|
||||||
- name: Create DMG
|
|
||||||
run: |
|
|
||||||
set -euo pipefail
|
|
||||||
rm -f Wowee.dmg
|
|
||||||
# CI runners can occasionally leave a mounted volume around; detach if present.
|
|
||||||
if [ -d "/Volumes/Wowee" ]; then
|
if [ -d "/Volumes/Wowee" ]; then
|
||||||
hdiutil detach "/Volumes/Wowee" -force || true
|
hdiutil detach "/Volumes/Wowee" -force || true
|
||||||
sleep 2
|
|
||||||
fi
|
fi
|
||||||
|
sleep 3
|
||||||
|
done
|
||||||
|
|
||||||
ok=0
|
if [ "$ok" -ne 1 ] || [ ! -f Wowee.dmg ]; then
|
||||||
for attempt in 1 2 3 4 5; do
|
echo "Failed to create Wowee.dmg after retries."
|
||||||
if hdiutil create -volname Wowee -srcfolder Wowee.app -ov -format UDZO Wowee.dmg; then
|
exit 1
|
||||||
ok=1
|
fi
|
||||||
break
|
|
||||||
fi
|
|
||||||
echo "hdiutil create failed on attempt ${attempt}; retrying..."
|
|
||||||
if [ -d "/Volumes/Wowee" ]; then
|
|
||||||
hdiutil detach "/Volumes/Wowee" -force || true
|
|
||||||
fi
|
|
||||||
sleep 3
|
|
||||||
done
|
|
||||||
|
|
||||||
if [ "$ok" -ne 1 ] || [ ! -f Wowee.dmg ]; then
|
- name: Upload DMG
|
||||||
echo "Failed to create Wowee.dmg after retries."
|
uses: actions/upload-artifact@v4
|
||||||
exit 1
|
with:
|
||||||
fi
|
name: wowee-macos-${{ matrix.arch }}-dmg
|
||||||
|
path: Wowee.dmg
|
||||||
- name: Upload DMG
|
if-no-files-found: error
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: wowee-macos-${{ matrix.arch }}-dmg
|
|
||||||
path: Wowee.dmg
|
|
||||||
if-no-files-found: error
|
|
||||||
|
|
||||||
build-windows-arm:
|
build-windows-arm:
|
||||||
name: Build (windows-arm64)
|
name: Build (windows-arm64)
|
||||||
runs-on: windows-11-arm
|
runs-on: windows-11-arm
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
submodules: true
|
submodules: true
|
||||||
|
|
||||||
- name: Set up MSYS2
|
- name: Set up MSYS2
|
||||||
uses: msys2/setup-msys2@v2
|
uses: msys2/setup-msys2@v2
|
||||||
with:
|
with:
|
||||||
msystem: CLANGARM64
|
msystem: CLANGARM64
|
||||||
update: true
|
update: true
|
||||||
install: >-
|
install: >-
|
||||||
mingw-w64-clang-aarch64-cmake
|
mingw-w64-clang-aarch64-cmake mingw-w64-clang-aarch64-clang mingw-w64-clang-aarch64-ninja mingw-w64-clang-aarch64-pkgconf mingw-w64-clang-aarch64-SDL2 mingw-w64-clang-aarch64-glew mingw-w64-clang-aarch64-glm mingw-w64-clang-aarch64-openssl mingw-w64-clang-aarch64-zlib mingw-w64-clang-aarch64-ffmpeg mingw-w64-clang-aarch64-unicorn mingw-w64-clang-aarch64-vulkan-loader mingw-w64-clang-aarch64-vulkan-headers mingw-w64-clang-aarch64-shaderc git
|
||||||
mingw-w64-clang-aarch64-clang
|
|
||||||
mingw-w64-clang-aarch64-ninja
|
|
||||||
mingw-w64-clang-aarch64-pkgconf
|
|
||||||
mingw-w64-clang-aarch64-SDL2
|
|
||||||
mingw-w64-clang-aarch64-glew
|
|
||||||
mingw-w64-clang-aarch64-glm
|
|
||||||
mingw-w64-clang-aarch64-openssl
|
|
||||||
mingw-w64-clang-aarch64-zlib
|
|
||||||
mingw-w64-clang-aarch64-ffmpeg
|
|
||||||
mingw-w64-clang-aarch64-unicorn
|
|
||||||
mingw-w64-clang-aarch64-vulkan-loader
|
|
||||||
mingw-w64-clang-aarch64-vulkan-headers
|
|
||||||
mingw-w64-clang-aarch64-shaderc
|
|
||||||
git
|
|
||||||
|
|
||||||
- name: Build StormLib from source
|
- name: Build StormLib from source
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
git clone --depth 1 https://github.com/ladislav-zezula/StormLib.git /tmp/StormLib
|
git clone --depth 1 https://github.com/ladislav-zezula/StormLib.git /tmp/StormLib
|
||||||
# Disable x86 inline asm in bundled libtomcrypt (bswapl/movl) —
|
# Disable x86 inline asm in bundled libtomcrypt (bswapl/movl) —
|
||||||
# __MINGW32__ is defined on CLANGARM64 which incorrectly enables x86 asm
|
# __MINGW32__ is defined on CLANGARM64 which incorrectly enables x86 asm
|
||||||
cmake -S /tmp/StormLib -B /tmp/StormLib/build -G Ninja \
|
cmake -S /tmp/StormLib -B /tmp/StormLib/build -G Ninja \
|
||||||
-DCMAKE_BUILD_TYPE=Release \
|
-DCMAKE_BUILD_TYPE=Release \
|
||||||
-DCMAKE_INSTALL_PREFIX="$MINGW_PREFIX" \
|
-DCMAKE_INSTALL_PREFIX="$MINGW_PREFIX" \
|
||||||
-DBUILD_SHARED_LIBS=OFF \
|
-DBUILD_SHARED_LIBS=OFF \
|
||||||
-DCMAKE_C_FLAGS="-DLTC_NO_BSWAP" \
|
-DCMAKE_C_FLAGS="-DLTC_NO_BSWAP" \
|
||||||
-DCMAKE_CXX_FLAGS="-DLTC_NO_BSWAP"
|
-DCMAKE_CXX_FLAGS="-DLTC_NO_BSWAP"
|
||||||
cmake --build /tmp/StormLib/build --parallel $(nproc)
|
cmake --build /tmp/StormLib/build --parallel $(nproc)
|
||||||
cmake --install /tmp/StormLib/build
|
cmake --install /tmp/StormLib/build
|
||||||
|
|
||||||
- name: Fetch AMD FSR2 SDK
|
- name: Fetch AMD FSR2 SDK
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
rm -rf extern/FidelityFX-FSR2
|
rm -rf extern/FidelityFX-FSR2
|
||||||
git clone --depth 1 --branch "${WOWEE_AMD_FSR2_REF}" "${WOWEE_AMD_FSR2_REPO}" extern/FidelityFX-FSR2
|
git clone --depth 1 --branch "${WOWEE_AMD_FSR2_REF}" "${WOWEE_AMD_FSR2_REPO}" extern/FidelityFX-FSR2
|
||||||
rm -rf extern/FidelityFX-SDK
|
rm -rf extern/FidelityFX-SDK
|
||||||
git clone --depth 1 --branch "${WOWEE_FFX_SDK_REF}" "${WOWEE_FFX_SDK_REPO}" extern/FidelityFX-SDK
|
git clone --depth 1 --branch "${WOWEE_FFX_SDK_REF}" "${WOWEE_FFX_SDK_REPO}" extern/FidelityFX-SDK
|
||||||
|
|
||||||
- name: Configure
|
- name: Configure
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DWOWEE_ENABLE_AMD_FSR2=ON
|
run: cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DWOWEE_ENABLE_AMD_FSR2=ON
|
||||||
|
|
||||||
- name: Assert AMD FSR2 target
|
- name: Assert AMD FSR2 target
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: cmake --build build --target wowee_fsr2_amd_vk --parallel $(nproc)
|
run: cmake --build build --target wowee_fsr2_amd_vk --parallel $(nproc)
|
||||||
|
|
||||||
- name: Assert AMD FSR3 framegen probe target (if present)
|
- name: Assert AMD FSR3 framegen probe target (if present)
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
if cmake --build build --target help | grep -q 'wowee_fsr3_framegen_amd_vk_probe'; then
|
if cmake --build build --target help | grep -q 'wowee_fsr3_framegen_amd_vk_probe'; then
|
||||||
cmake --build build --target wowee_fsr3_framegen_amd_vk_probe --parallel $(nproc)
|
cmake --build build --target wowee_fsr3_framegen_amd_vk_probe --parallel $(nproc)
|
||||||
else
|
else
|
||||||
echo "FSR3 framegen probe target not generated for this SDK layout; continuing."
|
echo "FSR3 framegen probe target not generated for this SDK layout; continuing."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: cmake --build build --parallel $(nproc)
|
run: cmake --build build --parallel $(nproc)
|
||||||
|
|
||||||
- name: Bundle DLLs
|
- name: Bundle DLLs
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
ldd build/bin/wowee.exe \
|
ldd build/bin/wowee.exe \
|
||||||
| awk '/=> \// { print $3 }' \
|
| awk '/=> \// { print $3 }' \
|
||||||
| grep -iv '^/c/Windows' \
|
| grep -iv '^/c/Windows' \
|
||||||
| xargs -I{} sh -c 'cp -n "{}" build/bin/ 2>/dev/null || true'
|
| xargs -I{} sh -c 'cp -n "{}" build/bin/ 2>/dev/null || true'
|
||||||
|
|
||||||
- name: Package (ZIP)
|
- name: Package (ZIP)
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: cd build && cpack -G ZIP
|
run: cd build && cpack -G ZIP
|
||||||
|
|
||||||
- name: Upload ZIP
|
- name: Upload ZIP
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wowee-windows-arm64-zip
|
name: wowee-windows-arm64-zip
|
||||||
path: build/wowee-*.zip
|
path: build/wowee-*.zip
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
|
|
||||||
build-windows:
|
build-windows:
|
||||||
name: Build (windows-x86-64)
|
name: Build (windows-x86-64)
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
submodules: true
|
submodules: true
|
||||||
|
|
||||||
- name: Set up MSYS2
|
- name: Set up MSYS2
|
||||||
uses: msys2/setup-msys2@v2
|
uses: msys2/setup-msys2@v2
|
||||||
with:
|
with:
|
||||||
msystem: MINGW64
|
msystem: MINGW64
|
||||||
update: false
|
update: false
|
||||||
install: >-
|
install: >-
|
||||||
mingw-w64-x86_64-cmake
|
mingw-w64-x86_64-cmake mingw-w64-x86_64-gcc mingw-w64-x86_64-ninja mingw-w64-x86_64-pkgconf mingw-w64-x86_64-SDL2 mingw-w64-x86_64-glew mingw-w64-x86_64-glm mingw-w64-x86_64-openssl mingw-w64-x86_64-zlib mingw-w64-x86_64-ffmpeg mingw-w64-x86_64-unicorn mingw-w64-x86_64-vulkan-loader mingw-w64-x86_64-vulkan-headers mingw-w64-x86_64-shaderc mingw-w64-x86_64-nsis git
|
||||||
mingw-w64-x86_64-gcc
|
|
||||||
mingw-w64-x86_64-ninja
|
|
||||||
mingw-w64-x86_64-pkgconf
|
|
||||||
mingw-w64-x86_64-SDL2
|
|
||||||
mingw-w64-x86_64-glew
|
|
||||||
mingw-w64-x86_64-glm
|
|
||||||
mingw-w64-x86_64-openssl
|
|
||||||
mingw-w64-x86_64-zlib
|
|
||||||
mingw-w64-x86_64-ffmpeg
|
|
||||||
mingw-w64-x86_64-unicorn
|
|
||||||
mingw-w64-x86_64-vulkan-loader
|
|
||||||
mingw-w64-x86_64-vulkan-headers
|
|
||||||
mingw-w64-x86_64-shaderc
|
|
||||||
mingw-w64-x86_64-nsis
|
|
||||||
git
|
|
||||||
|
|
||||||
- name: Build StormLib from source
|
- name: Build StormLib from source
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
git clone --depth 1 https://github.com/ladislav-zezula/StormLib.git /tmp/StormLib
|
git clone --depth 1 https://github.com/ladislav-zezula/StormLib.git /tmp/StormLib
|
||||||
cmake -S /tmp/StormLib -B /tmp/StormLib/build -G Ninja \
|
cmake -S /tmp/StormLib -B /tmp/StormLib/build -G Ninja \
|
||||||
-DCMAKE_BUILD_TYPE=Release \
|
-DCMAKE_BUILD_TYPE=Release \
|
||||||
-DCMAKE_INSTALL_PREFIX="$MINGW_PREFIX" \
|
-DCMAKE_INSTALL_PREFIX="$MINGW_PREFIX" \
|
||||||
-DBUILD_SHARED_LIBS=OFF
|
-DBUILD_SHARED_LIBS=OFF
|
||||||
cmake --build /tmp/StormLib/build --parallel $(nproc)
|
cmake --build /tmp/StormLib/build --parallel $(nproc)
|
||||||
cmake --install /tmp/StormLib/build
|
cmake --install /tmp/StormLib/build
|
||||||
|
|
||||||
- name: Fetch AMD FSR2 SDK
|
- name: Fetch AMD FSR2 SDK
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
rm -rf extern/FidelityFX-FSR2
|
rm -rf extern/FidelityFX-FSR2
|
||||||
git clone --depth 1 --branch "${WOWEE_AMD_FSR2_REF}" "${WOWEE_AMD_FSR2_REPO}" extern/FidelityFX-FSR2
|
git clone --depth 1 --branch "${WOWEE_AMD_FSR2_REF}" "${WOWEE_AMD_FSR2_REPO}" extern/FidelityFX-FSR2
|
||||||
rm -rf extern/FidelityFX-SDK
|
rm -rf extern/FidelityFX-SDK
|
||||||
git clone --depth 1 --branch "${WOWEE_FFX_SDK_REF}" "${WOWEE_FFX_SDK_REPO}" extern/FidelityFX-SDK
|
git clone --depth 1 --branch "${WOWEE_FFX_SDK_REF}" "${WOWEE_FFX_SDK_REPO}" extern/FidelityFX-SDK
|
||||||
|
|
||||||
- name: Configure
|
- name: Configure
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DWOWEE_ENABLE_AMD_FSR2=ON
|
run: cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DWOWEE_ENABLE_AMD_FSR2=ON
|
||||||
|
|
||||||
- name: Assert AMD FSR2 target
|
- name: Assert AMD FSR2 target
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: cmake --build build --target wowee_fsr2_amd_vk --parallel $(nproc)
|
run: cmake --build build --target wowee_fsr2_amd_vk --parallel $(nproc)
|
||||||
|
|
||||||
- name: Assert AMD FSR3 framegen probe target (if present)
|
- name: Assert AMD FSR3 framegen probe target (if present)
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
if cmake --build build --target help | grep -q 'wowee_fsr3_framegen_amd_vk_probe'; then
|
if cmake --build build --target help | grep -q 'wowee_fsr3_framegen_amd_vk_probe'; then
|
||||||
cmake --build build --target wowee_fsr3_framegen_amd_vk_probe --parallel $(nproc)
|
cmake --build build --target wowee_fsr3_framegen_amd_vk_probe --parallel $(nproc)
|
||||||
else
|
else
|
||||||
echo "FSR3 framegen probe target not generated for this SDK layout; continuing."
|
echo "FSR3 framegen probe target not generated for this SDK layout; continuing."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: cmake --build build --parallel $(nproc)
|
run: cmake --build build --parallel $(nproc)
|
||||||
|
|
||||||
- name: Bundle DLLs
|
- name: Bundle DLLs
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
ldd build/bin/wowee.exe \
|
ldd build/bin/wowee.exe \
|
||||||
| awk '/=> \// { print $3 }' \
|
| awk '/=> \// { print $3 }' \
|
||||||
| grep -iv '^/c/Windows' \
|
| grep -iv '^/c/Windows' \
|
||||||
| xargs -I{} sh -c 'cp -n "{}" build/bin/ 2>/dev/null || true'
|
| xargs -I{} sh -c 'cp -n "{}" build/bin/ 2>/dev/null || true'
|
||||||
|
|
||||||
- name: Package (NSIS)
|
- name: Package (NSIS)
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: cd build && cpack -G NSIS
|
run: cd build && cpack -G NSIS
|
||||||
|
|
||||||
- name: Upload installer
|
- name: Upload installer
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wowee-windows-x86-64-installer
|
name: wowee-windows-x86-64-installer
|
||||||
path: build/wowee-*.exe
|
path: build/wowee-*.exe
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
|
|
|
||||||
593
.github/workflows/release.yml
vendored
593
.github/workflows/release.yml
vendored
|
|
@ -2,7 +2,7 @@ name: Release
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
tags: ['v*']
|
tags: [ 'v*' ]
|
||||||
|
|
||||||
env:
|
env:
|
||||||
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
|
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
|
||||||
|
|
@ -18,215 +18,228 @@ jobs:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- arch: x86-64
|
- arch: x86-64
|
||||||
runner: ubuntu-24.04
|
runner: ubuntu-24.04
|
||||||
- arch: arm64
|
- arch: arm64
|
||||||
runner: ubuntu-24.04-arm
|
runner: ubuntu-24.04-arm
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
submodules: true
|
submodules: true
|
||||||
|
|
||||||
- name: Cache apt packages
|
- name: Cache apt packages
|
||||||
uses: actions/cache@v4
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: /var/cache/apt/archives/*.deb
|
path: /var/cache/apt/archives/*.deb
|
||||||
key: apt-${{ matrix.arch }}-${{ hashFiles('.github/workflows/release.yml') }}
|
key: apt-${{ matrix.arch }}-${{ hashFiles('.github/workflows/release.yml') }}
|
||||||
restore-keys: apt-${{ matrix.arch }}-
|
restore-keys: apt-${{ matrix.arch }}-
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install -y \
|
sudo apt-get install -y \
|
||||||
cmake \
|
cmake \
|
||||||
build-essential \
|
build-essential \
|
||||||
pkg-config \
|
pkg-config \
|
||||||
libsdl2-dev \
|
libsdl2-dev \
|
||||||
libglew-dev \
|
libglew-dev \
|
||||||
libglm-dev \
|
libglm-dev \
|
||||||
libssl-dev \
|
libssl-dev \
|
||||||
zlib1g-dev \
|
zlib1g-dev \
|
||||||
libvulkan-dev \
|
libvulkan-dev \
|
||||||
vulkan-tools \
|
vulkan-tools \
|
||||||
glslc \
|
glslc \
|
||||||
libavformat-dev \
|
libavformat-dev \
|
||||||
libavcodec-dev \
|
libavcodec-dev \
|
||||||
libswscale-dev \
|
libswscale-dev \
|
||||||
libavutil-dev \
|
libavutil-dev \
|
||||||
libunicorn-dev \
|
libunicorn-dev \
|
||||||
libx11-dev
|
libx11-dev
|
||||||
sudo apt-get install -y libstorm-dev || true
|
sudo apt-get install -y libstorm-dev || true
|
||||||
|
|
||||||
- name: Configure
|
- name: Configure
|
||||||
run: cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
|
run: cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
|
||||||
|
|
||||||
- name: Verify Release Config
|
- name: Verify Release Config
|
||||||
run: |
|
run: |
|
||||||
cmake -LA -N build | grep -E '^CMAKE_BUILD_TYPE:STRING=Release$'
|
cmake -LA -N build | grep -E '^CMAKE_BUILD_TYPE:STRING=Release$'
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: cmake --build build --parallel $(nproc)
|
run: cmake --build build --parallel $(nproc)
|
||||||
|
|
||||||
- name: Package
|
- name: Package
|
||||||
run: |
|
run: |
|
||||||
TAG="${GITHUB_REF_NAME}"
|
TAG="${GITHUB_REF_NAME}"
|
||||||
STAGING="wowee-${TAG}-linux-${{ matrix.arch }}"
|
STAGING="wowee-${TAG}-linux-${{ matrix.arch }}"
|
||||||
mkdir -p "${STAGING}"
|
mkdir -p "${STAGING}"
|
||||||
|
|
||||||
# Binary
|
# Binary
|
||||||
cp build/bin/wowee "${STAGING}/"
|
cp build/bin/wowee "${STAGING}/"
|
||||||
|
|
||||||
# Asset extraction tool (if built — requires StormLib)
|
# Asset extraction tool (if built — requires StormLib)
|
||||||
if [ -f build/bin/asset_extract ]; then
|
if [ -f build/bin/asset_extract ]; then
|
||||||
cp build/bin/asset_extract "${STAGING}/"
|
cp build/bin/asset_extract "${STAGING}/"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Extraction scripts and GUI
|
# Extraction scripts and GUI
|
||||||
cp extract_assets.sh "${STAGING}/"
|
cp extract_assets.sh "${STAGING}/"
|
||||||
cp tools/asset_pipeline_gui.py "${STAGING}/"
|
cp tools/asset_pipeline_gui.py "${STAGING}/"
|
||||||
|
|
||||||
# Assets (exclude proprietary music)
|
# Assets (exclude proprietary music)
|
||||||
rsync -a --exclude='Original Music' build/bin/assets/ "${STAGING}/assets/"
|
rsync -a --exclude='Original Music' build/bin/assets/ "${STAGING}/assets/"
|
||||||
|
|
||||||
# Data directory (git-tracked files only)
|
# Data directory (git-tracked files only)
|
||||||
git ls-files Data/ | while read -r f; do
|
git ls-files Data/ | while read -r f; do
|
||||||
mkdir -p "${STAGING}/$(dirname "$f")"
|
mkdir -p "${STAGING}/$(dirname "$f")"
|
||||||
cp "$f" "${STAGING}/$f"
|
cp "$f" "${STAGING}/$f"
|
||||||
done
|
done
|
||||||
|
|
||||||
tar czf "${STAGING}.tar.gz" "${STAGING}"
|
tar czf "${STAGING}.tar.gz" "${STAGING}"
|
||||||
|
|
||||||
- name: Upload artifact
|
- name: Upload artifact
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wowee-linux-${{ matrix.arch }}
|
name: wowee-linux-${{ matrix.arch }}
|
||||||
path: wowee-*.tar.gz
|
path: wowee-*.tar.gz
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
|
|
||||||
build-macos:
|
build-macos:
|
||||||
name: Build (macOS arm64)
|
name: Build (macOS arm64)
|
||||||
runs-on: macos-15
|
runs-on: macos-15
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
submodules: true
|
submodules: true
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
brew install cmake pkg-config sdl2 glew glm openssl@3 zlib ffmpeg unicorn \
|
brew install cmake pkg-config sdl2 glew glm openssl@3 zlib ffmpeg unicorn \
|
||||||
stormlib vulkan-loader vulkan-headers shaderc dylibbundler || true
|
stormlib vulkan-loader vulkan-headers shaderc dylibbundler || true
|
||||||
brew install dylibbundler 2>/dev/null || true
|
brew install dylibbundler 2>/dev/null || true
|
||||||
|
|
||||||
- name: Configure
|
- name: Configure
|
||||||
run: |
|
run: |
|
||||||
BREW=$(brew --prefix)
|
BREW=$(brew --prefix)
|
||||||
export PKG_CONFIG_PATH="$BREW/lib/pkgconfig:$(brew --prefix ffmpeg)/lib/pkgconfig:$(brew --prefix openssl@3)/lib/pkgconfig:$(brew --prefix vulkan-loader)/lib/pkgconfig:$(brew --prefix shaderc)/lib/pkgconfig"
|
export PKG_CONFIG_PATH="$BREW/lib/pkgconfig:$(brew --prefix ffmpeg)/lib/pkgconfig:$(brew --prefix openssl@3)/lib/pkgconfig:$(brew --prefix vulkan-loader)/lib/pkgconfig:$(brew --prefix shaderc)/lib/pkgconfig"
|
||||||
cmake -S . -B build \
|
cmake -S . -B build \
|
||||||
-DCMAKE_BUILD_TYPE=Release \
|
-DCMAKE_BUILD_TYPE=Release \
|
||||||
-DCMAKE_PREFIX_PATH="$BREW" \
|
-DCMAKE_PREFIX_PATH="$BREW" \
|
||||||
-DOPENSSL_ROOT_DIR="$(brew --prefix openssl@3)"
|
-DOPENSSL_ROOT_DIR="$(brew --prefix openssl@3)"
|
||||||
|
|
||||||
- name: Verify Release Config
|
- name: Verify Release Config
|
||||||
run: |
|
run: |
|
||||||
cmake -LA -N build | grep -E '^CMAKE_BUILD_TYPE:STRING=Release$'
|
cmake -LA -N build | grep -E '^CMAKE_BUILD_TYPE:STRING=Release$'
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: cmake --build build --parallel $(sysctl -n hw.logicalcpu)
|
run: cmake --build build --parallel $(sysctl -n hw.logicalcpu)
|
||||||
|
|
||||||
- name: Create .app bundle
|
- name: Create .app bundle
|
||||||
run: |
|
run: |
|
||||||
TAG="${GITHUB_REF_NAME}"
|
TAG="${GITHUB_REF_NAME}"
|
||||||
mkdir -p Wowee.app/Contents/{MacOS,Frameworks,Resources}
|
mkdir -p Wowee.app/Contents/{MacOS,Frameworks,Resources}
|
||||||
|
|
||||||
# Wrapper launch script
|
# Wrapper launch script
|
||||||
printf '#!/bin/bash\ncd "$(dirname "$0")"\nexec ./wowee_bin "$@"\n' \
|
printf '#!/bin/bash\ncd "$(dirname "$0")"\nexec ./wowee_bin "$@"\n' \
|
||||||
> Wowee.app/Contents/MacOS/wowee
|
> Wowee.app/Contents/MacOS/wowee
|
||||||
chmod +x Wowee.app/Contents/MacOS/wowee
|
chmod +x Wowee.app/Contents/MacOS/wowee
|
||||||
|
|
||||||
# Actual binary
|
# Actual binary
|
||||||
cp build/bin/wowee Wowee.app/Contents/MacOS/wowee_bin
|
cp build/bin/wowee Wowee.app/Contents/MacOS/wowee_bin
|
||||||
|
|
||||||
# Asset extraction tool (if built — requires StormLib)
|
# Asset extraction tool (if built — requires StormLib)
|
||||||
if [ -f build/bin/asset_extract ]; then
|
if [ -f build/bin/asset_extract ]; then
|
||||||
cp build/bin/asset_extract Wowee.app/Contents/MacOS/
|
cp build/bin/asset_extract Wowee.app/Contents/MacOS/
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Extraction scripts and GUI
|
# Extraction scripts and GUI
|
||||||
cp extract_assets.sh Wowee.app/Contents/MacOS/
|
cp extract_assets.sh Wowee.app/Contents/MacOS/
|
||||||
cp tools/asset_pipeline_gui.py Wowee.app/Contents/MacOS/
|
cp tools/asset_pipeline_gui.py Wowee.app/Contents/MacOS/
|
||||||
|
|
||||||
# Assets (exclude proprietary music)
|
# Assets (exclude proprietary music)
|
||||||
rsync -a --exclude='Original Music' build/bin/assets/ \
|
rsync -a --exclude='Original Music' build/bin/assets/ \
|
||||||
Wowee.app/Contents/MacOS/assets/
|
Wowee.app/Contents/MacOS/assets/
|
||||||
|
|
||||||
# Data directory (git-tracked files only)
|
# Data directory (git-tracked files only)
|
||||||
git ls-files Data/ | while read -r f; do
|
git ls-files Data/ | while read -r f; do
|
||||||
mkdir -p "Wowee.app/Contents/MacOS/$(dirname "$f")"
|
mkdir -p "Wowee.app/Contents/MacOS/$(dirname "$f")"
|
||||||
cp "$f" "Wowee.app/Contents/MacOS/$f"
|
cp "$f" "Wowee.app/Contents/MacOS/$f"
|
||||||
done
|
done
|
||||||
|
|
||||||
# Bundle dylibs
|
# Bundle dylibs
|
||||||
if command -v dylibbundler &>/dev/null; then
|
if command -v dylibbundler &>/dev/null; then
|
||||||
|
dylibbundler -od -b \
|
||||||
|
-x Wowee.app/Contents/MacOS/wowee_bin \
|
||||||
|
-d Wowee.app/Contents/Frameworks/ \
|
||||||
|
-p @executable_path/../Frameworks/
|
||||||
|
if [ -f Wowee.app/Contents/MacOS/asset_extract ]; then
|
||||||
dylibbundler -od -b \
|
dylibbundler -od -b \
|
||||||
-x Wowee.app/Contents/MacOS/wowee_bin \
|
-x Wowee.app/Contents/MacOS/asset_extract \
|
||||||
-d Wowee.app/Contents/Frameworks/ \
|
-d Wowee.app/Contents/Frameworks/ \
|
||||||
-p @executable_path/../Frameworks/
|
-p @executable_path/../Frameworks/
|
||||||
if [ -f Wowee.app/Contents/MacOS/asset_extract ]; then
|
|
||||||
dylibbundler -od -b \
|
|
||||||
-x Wowee.app/Contents/MacOS/asset_extract \
|
|
||||||
-d Wowee.app/Contents/Frameworks/ \
|
|
||||||
-p @executable_path/../Frameworks/
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
# dylibbundler may miss Homebrew's Vulkan loader on some runner images.
|
# dylibbundler may miss Homebrew's Vulkan loader on some runner images.
|
||||||
# Copy all vulkan-loader dylib names so wowee_bin can resolve whichever
|
# Copy all vulkan-loader dylib names so wowee_bin can resolve whichever
|
||||||
# install_name it was linked against (e.g. libvulkan.1.4.341.dylib).
|
# install_name it was linked against (e.g. libvulkan.1.4.341.dylib).
|
||||||
VULKAN_LIB_DIR="$(brew --prefix vulkan-loader)/lib"
|
VULKAN_LIB_DIR="$(brew --prefix vulkan-loader)/lib"
|
||||||
for lib in "${VULKAN_LIB_DIR}"/libvulkan*.dylib; do
|
for lib in "${VULKAN_LIB_DIR}"/libvulkan*.dylib; do
|
||||||
[ -e "${lib}" ] || continue
|
[ -e "${lib}" ] || continue
|
||||||
cp -f "${lib}" Wowee.app/Contents/Frameworks/
|
cp -f "${lib}" Wowee.app/Contents/Frameworks/
|
||||||
done
|
done
|
||||||
|
|
||||||
if ! ls Wowee.app/Contents/Frameworks/libvulkan*.dylib >/dev/null 2>&1; then
|
if ! ls Wowee.app/Contents/Frameworks/libvulkan*.dylib >/dev/null 2>&1; then
|
||||||
echo "Missing Vulkan loader dylib(s) in app bundle Frameworks/" >&2
|
echo "Missing Vulkan loader dylib(s) in app bundle Frameworks/" >&2
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Info.plist
|
# dylibbundler may miss Homebrew's OpenSSL on some runner images.
|
||||||
cat > Wowee.app/Contents/Info.plist << EOF
|
# Copy libssl and libcrypto so wowee_bin can resolve them at runtime.
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
OPENSSL_LIB_DIR="$(brew --prefix openssl@3)/lib"
|
||||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
|
for lib in "${OPENSSL_LIB_DIR}"/libssl*.dylib "${OPENSSL_LIB_DIR}"/libcrypto*.dylib; do
|
||||||
"http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
[ -e "${lib}" ] || continue
|
||||||
<plist version="1.0"><dict>
|
cp -f "${lib}" Wowee.app/Contents/Frameworks/
|
||||||
<key>CFBundleExecutable</key><string>wowee</string>
|
done
|
||||||
<key>CFBundleIdentifier</key><string>com.wowee.app</string>
|
|
||||||
<key>CFBundleName</key><string>Wowee</string>
|
|
||||||
<key>CFBundleVersion</key><string>${TAG}</string>
|
|
||||||
<key>CFBundleShortVersionString</key><string>${TAG}</string>
|
|
||||||
<key>CFBundlePackageType</key><string>APPL</string>
|
|
||||||
</dict></plist>
|
|
||||||
EOF
|
|
||||||
|
|
||||||
# Ad-hoc codesign
|
if ! ls Wowee.app/Contents/Frameworks/libssl*.dylib >/dev/null 2>&1; then
|
||||||
codesign --force --deep --sign - Wowee.app
|
echo "Missing OpenSSL libssl dylib(s) in app bundle Frameworks/" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
- name: Create DMG
|
# Info.plist
|
||||||
run: |
|
cat > Wowee.app/Contents/Info.plist << EOF
|
||||||
TAG="${GITHUB_REF_NAME}"
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
hdiutil create -volname Wowee -srcfolder Wowee.app -ov -format UDZO \
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
|
||||||
"wowee-${TAG}-macos-arm64.dmg"
|
"http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||||
|
<plist version="1.0"><dict>
|
||||||
|
<key>CFBundleExecutable</key><string>wowee</string>
|
||||||
|
<key>CFBundleIdentifier</key><string>com.wowee.app</string>
|
||||||
|
<key>CFBundleName</key><string>Wowee</string>
|
||||||
|
<key>CFBundleVersion</key><string>${TAG}</string>
|
||||||
|
<key>CFBundleShortVersionString</key><string>${TAG}</string>
|
||||||
|
<key>CFBundlePackageType</key><string>APPL</string>
|
||||||
|
</dict></plist>
|
||||||
|
EOF
|
||||||
|
|
||||||
- name: Upload artifact
|
# Ad-hoc codesign
|
||||||
uses: actions/upload-artifact@v4
|
codesign --force --deep --sign - Wowee.app
|
||||||
with:
|
|
||||||
name: wowee-macos-arm64
|
- name: Create DMG
|
||||||
path: wowee-*.dmg
|
run: |
|
||||||
if-no-files-found: error
|
TAG="${GITHUB_REF_NAME}"
|
||||||
|
hdiutil create -volname Wowee -srcfolder Wowee.app -ov -format UDZO \
|
||||||
|
"wowee-${TAG}-macos-arm64.dmg"
|
||||||
|
|
||||||
|
- name: Upload artifact
|
||||||
|
uses: actions/upload-artifact@v4
|
||||||
|
with:
|
||||||
|
name: wowee-macos-arm64
|
||||||
|
path: wowee-*.dmg
|
||||||
|
if-no-files-found: error
|
||||||
|
|
||||||
build-windows:
|
build-windows:
|
||||||
name: Build (windows-${{ matrix.arch }})
|
name: Build (windows-${{ matrix.arch }})
|
||||||
|
|
@ -235,159 +248,145 @@ jobs:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- arch: x86-64
|
- arch: x86-64
|
||||||
runner: windows-latest
|
runner: windows-latest
|
||||||
msystem: MINGW64
|
msystem: MINGW64
|
||||||
prefix: mingw-w64-x86_64
|
prefix: mingw-w64-x86_64
|
||||||
- arch: arm64
|
- arch: arm64
|
||||||
runner: windows-11-arm
|
runner: windows-11-arm
|
||||||
msystem: CLANGARM64
|
msystem: CLANGARM64
|
||||||
prefix: mingw-w64-clang-aarch64
|
prefix: mingw-w64-clang-aarch64
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
submodules: true
|
submodules: true
|
||||||
|
|
||||||
- name: Set up MSYS2
|
- name: Set up MSYS2
|
||||||
uses: msys2/setup-msys2@v2
|
uses: msys2/setup-msys2@v2
|
||||||
with:
|
with:
|
||||||
msystem: ${{ matrix.msystem }}
|
msystem: ${{ matrix.msystem }}
|
||||||
update: ${{ matrix.arch == 'arm64' }}
|
update: ${{ matrix.arch == 'arm64' }}
|
||||||
install: >-
|
install: >-
|
||||||
${{ matrix.prefix }}-cmake
|
${{ matrix.prefix }}-cmake ${{ matrix.arch == 'x86-64' && format('{0}-gcc', matrix.prefix) || format('{0}-clang', matrix.prefix) }} ${{ matrix.prefix }}-ninja ${{ matrix.prefix }}-pkgconf ${{ matrix.prefix }}-SDL2 ${{ matrix.prefix }}-glew ${{ matrix.prefix }}-glm ${{ matrix.prefix }}-openssl ${{ matrix.prefix }}-zlib ${{ matrix.prefix }}-ffmpeg ${{ matrix.prefix }}-unicorn ${{ matrix.prefix }}-vulkan-loader ${{ matrix.prefix }}-vulkan-headers ${{ matrix.prefix }}-shaderc git
|
||||||
${{ matrix.arch == 'x86-64' && format('{0}-gcc', matrix.prefix) || format('{0}-clang', matrix.prefix) }}
|
|
||||||
${{ matrix.prefix }}-ninja
|
|
||||||
${{ matrix.prefix }}-pkgconf
|
|
||||||
${{ matrix.prefix }}-SDL2
|
|
||||||
${{ matrix.prefix }}-glew
|
|
||||||
${{ matrix.prefix }}-glm
|
|
||||||
${{ matrix.prefix }}-openssl
|
|
||||||
${{ matrix.prefix }}-zlib
|
|
||||||
${{ matrix.prefix }}-ffmpeg
|
|
||||||
${{ matrix.prefix }}-unicorn
|
|
||||||
${{ matrix.prefix }}-vulkan-loader
|
|
||||||
${{ matrix.prefix }}-vulkan-headers
|
|
||||||
${{ matrix.prefix }}-shaderc
|
|
||||||
git
|
|
||||||
|
|
||||||
- name: Install optional packages
|
- name: Install optional packages
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
pacman -S --noconfirm --needed zip
|
pacman -S --noconfirm --needed zip
|
||||||
|
|
||||||
- name: Build StormLib from source
|
- name: Build StormLib from source
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
git clone --depth 1 https://github.com/ladislav-zezula/StormLib.git /tmp/StormLib
|
git clone --depth 1 https://github.com/ladislav-zezula/StormLib.git /tmp/StormLib
|
||||||
# Disable x86 inline asm in bundled libtomcrypt (bswapl/movl) —
|
# Disable x86 inline asm in bundled libtomcrypt (bswapl/movl) —
|
||||||
# __MINGW32__ is defined on CLANGARM64 which incorrectly enables x86 asm
|
# __MINGW32__ is defined on CLANGARM64 which incorrectly enables x86 asm
|
||||||
cmake -S /tmp/StormLib -B /tmp/StormLib/build -G Ninja \
|
cmake -S /tmp/StormLib -B /tmp/StormLib/build -G Ninja \
|
||||||
-DCMAKE_BUILD_TYPE=Release \
|
-DCMAKE_BUILD_TYPE=Release \
|
||||||
-DCMAKE_INSTALL_PREFIX="$MINGW_PREFIX" \
|
-DCMAKE_INSTALL_PREFIX="$MINGW_PREFIX" \
|
||||||
-DBUILD_SHARED_LIBS=OFF \
|
-DBUILD_SHARED_LIBS=OFF \
|
||||||
-DCMAKE_C_FLAGS="-DLTC_NO_BSWAP" \
|
-DCMAKE_C_FLAGS="-DLTC_NO_BSWAP" \
|
||||||
-DCMAKE_CXX_FLAGS="-DLTC_NO_BSWAP"
|
-DCMAKE_CXX_FLAGS="-DLTC_NO_BSWAP"
|
||||||
cmake --build /tmp/StormLib/build --parallel $(nproc)
|
cmake --build /tmp/StormLib/build --parallel $(nproc)
|
||||||
cmake --install /tmp/StormLib/build
|
cmake --install /tmp/StormLib/build
|
||||||
|
|
||||||
- name: Configure
|
- name: Configure
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
|
run: cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
|
||||||
|
|
||||||
- name: Verify Release Config
|
- name: Verify Release Config
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
cmake -LA -N build | grep -E '^CMAKE_BUILD_TYPE:STRING=Release$'
|
cmake -LA -N build | grep -E '^CMAKE_BUILD_TYPE:STRING=Release$'
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: cmake --build build --parallel $(nproc)
|
run: cmake --build build --parallel $(nproc)
|
||||||
|
|
||||||
- name: Bundle DLLs
|
- name: Bundle DLLs
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
for exe in build/bin/wowee.exe build/bin/asset_extract.exe; do
|
for exe in build/bin/wowee.exe build/bin/asset_extract.exe; do
|
||||||
[ -f "$exe" ] || continue
|
[ -f "$exe" ] || continue
|
||||||
ldd "$exe" \
|
ldd "$exe" \
|
||||||
| awk '/=> \// { print $3 }' \
|
| awk '/=> \// { print $3 }' \
|
||||||
| grep -iv '^/c/Windows' \
|
| grep -iv '^/c/Windows' \
|
||||||
| xargs -I{} sh -c 'cp -n "{}" build/bin/ 2>/dev/null || true'
|
| xargs -I{} sh -c 'cp -n "{}" build/bin/ 2>/dev/null || true'
|
||||||
done
|
done
|
||||||
|
|
||||||
- name: Package
|
- name: Package
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
TAG="${GITHUB_REF_NAME}"
|
TAG="${GITHUB_REF_NAME}"
|
||||||
STAGING="wowee-${TAG}-windows-${{ matrix.arch }}"
|
STAGING="wowee-${TAG}-windows-${{ matrix.arch }}"
|
||||||
mkdir -p "${STAGING}"
|
mkdir -p "${STAGING}"
|
||||||
|
|
||||||
# Binary and DLLs
|
# Binary and DLLs
|
||||||
cp build/bin/wowee.exe "${STAGING}/"
|
cp build/bin/wowee.exe "${STAGING}/"
|
||||||
cp build/bin/*.dll "${STAGING}/" 2>/dev/null || true
|
cp build/bin/*.dll "${STAGING}/" 2>/dev/null || true
|
||||||
|
|
||||||
# Asset extraction tool (if built — requires StormLib)
|
# Asset extraction tool (if built — requires StormLib)
|
||||||
if [ -f build/bin/asset_extract.exe ]; then
|
if [ -f build/bin/asset_extract.exe ]; then
|
||||||
cp build/bin/asset_extract.exe "${STAGING}/"
|
cp build/bin/asset_extract.exe "${STAGING}/"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Extraction scripts and GUI
|
# Extraction scripts and GUI
|
||||||
cp extract_assets.ps1 "${STAGING}/"
|
cp extract_assets.ps1 "${STAGING}/"
|
||||||
cp extract_assets.bat "${STAGING}/"
|
cp extract_assets.bat "${STAGING}/"
|
||||||
cp tools/asset_pipeline_gui.py "${STAGING}/"
|
cp tools/asset_pipeline_gui.py "${STAGING}/"
|
||||||
|
|
||||||
# Assets (exclude proprietary music)
|
# Assets (exclude proprietary music)
|
||||||
mkdir -p "${STAGING}/assets"
|
mkdir -p "${STAGING}/assets"
|
||||||
for d in build/bin/assets/*/; do
|
for d in build/bin/assets/*/; do
|
||||||
dirname="$(basename "$d")"
|
dirname="$(basename "$d")"
|
||||||
[ "$dirname" = "Original Music" ] && continue
|
[ "$dirname" = "Original Music" ] && continue
|
||||||
cp -r "$d" "${STAGING}/assets/"
|
cp -r "$d" "${STAGING}/assets/"
|
||||||
done
|
done
|
||||||
# Copy top-level asset files
|
# Copy top-level asset files
|
||||||
cp build/bin/assets/* "${STAGING}/assets/" 2>/dev/null || true
|
cp build/bin/assets/* "${STAGING}/assets/" 2>/dev/null || true
|
||||||
|
|
||||||
# Data directory (git-tracked files only)
|
# Data directory (git-tracked files only)
|
||||||
git ls-files Data/ | while read -r f; do
|
git ls-files Data/ | while read -r f; do
|
||||||
mkdir -p "${STAGING}/$(dirname "$f")"
|
mkdir -p "${STAGING}/$(dirname "$f")"
|
||||||
cp "$f" "${STAGING}/$f"
|
cp "$f" "${STAGING}/$f"
|
||||||
done
|
done
|
||||||
|
|
||||||
# Create ZIP
|
# Create ZIP
|
||||||
zip -r "${STAGING}.zip" "${STAGING}"
|
zip -r "${STAGING}.zip" "${STAGING}"
|
||||||
|
|
||||||
- name: Upload artifact
|
- name: Upload artifact
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wowee-windows-${{ matrix.arch }}
|
name: wowee-windows-${{ matrix.arch }}
|
||||||
path: wowee-*.zip
|
path: wowee-*.zip
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
|
|
||||||
release:
|
release:
|
||||||
name: Create Release
|
name: Create Release
|
||||||
needs: [build-linux, build-macos, build-windows]
|
needs: [ build-linux, build-macos, build-windows ]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Download all artifacts
|
- name: Download all artifacts
|
||||||
uses: actions/download-artifact@v4
|
uses: actions/download-artifact@v4
|
||||||
with:
|
with:
|
||||||
path: artifacts/
|
path: artifacts/
|
||||||
|
|
||||||
- name: Create GitHub Release
|
- name: Create GitHub Release
|
||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ github.token }}
|
GH_TOKEN: ${{ github.token }}
|
||||||
GH_REPO: ${{ github.repository }}
|
GH_REPO: ${{ github.repository }}
|
||||||
run: |
|
run: |
|
||||||
TAG="${GITHUB_REF_NAME}"
|
TAG="${GITHUB_REF_NAME}"
|
||||||
|
|
||||||
# Collect all release files
|
# Collect all release files
|
||||||
FILES=()
|
FILES=()
|
||||||
for f in artifacts/*/*; do
|
for f in artifacts/*/*; do
|
||||||
FILES+=("$f")
|
FILES+=("$f")
|
||||||
done
|
done
|
||||||
|
|
||||||
gh release create "${TAG}" \
|
gh release create "${TAG}" \
|
||||||
--title "Wowee ${TAG}" \
|
--title "Wowee ${TAG}" \
|
||||||
--generate-notes \
|
--generate-notes \
|
||||||
"${FILES[@]}"
|
"${FILES[@]}"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue