7575 files : |
7676 src-tauri/target/release/bundle/**/*.AppImage
7777 src-tauri/target/release/bundle/**/*.deb
78- - runner : macos-13
78+ - runner : macos-latest
7979 platform_label : macos
8080 files : |
8181 src-tauri/target/release/bundle/**/*.dmg
@@ -101,25 +101,25 @@ jobs:
101101 if : runner.os == 'Linux'
102102 shell : bash
103103 run : |
104+ set -euo pipefail
104105 sudo apt-get update
105- if sudo apt-get install -y \
106- libwebkit2gtk-4.1-dev \
106+ if apt-cache show libwebkit2gtk-4.1-dev >/dev/null 2>&1; then
107+ WEBKIT_PKG="libwebkit2gtk-4.1-dev"
108+ else
109+ WEBKIT_PKG="libwebkit2gtk-4.0-dev"
110+ fi
111+ if apt-cache show libayatana-appindicator3-dev >/dev/null 2>&1; then
112+ APPINDICATOR_PKG="libayatana-appindicator3-dev"
113+ else
114+ APPINDICATOR_PKG="libappindicator3-dev"
115+ fi
116+ sudo apt-get install -y \
117+ "${WEBKIT_PKG}" \
107118 libgtk-3-dev \
108119 librsvg2-dev \
109120 patchelf \
110- libappindicator3-dev \
111- libayatana-appindicator3-dev; then
112- echo "Installed WebKitGTK 4.1 dependency stack."
113- else
114- sudo apt-get install -y \
115- libwebkit2gtk-4.0-dev \
116- libgtk-3-dev \
117- librsvg2-dev \
118- patchelf \
119- libappindicator3-dev \
120- libayatana-appindicator3-dev
121- echo "Installed WebKitGTK 4.0 fallback dependency stack."
122- fi
121+ "${APPINDICATOR_PKG}"
122+ echo "Installed Linux native dependencies with ${WEBKIT_PKG} and ${APPINDICATOR_PKG}."
123123
124124 - name : Install dependencies
125125 run : npm ci
@@ -133,10 +133,16 @@ jobs:
133133 $archive = "build\godot\godot-win64.zip"
134134 Invoke-WebRequest -Uri "https://github.com/godotengine/godot/releases/download/4.3-stable/Godot_v4.3-stable_win64.exe.zip" -OutFile $archive
135135 Expand-Archive -Path $archive -DestinationPath "build\godot\extract" -Force
136- $godotExe = Get-ChildItem -Path "build\godot\extract" -Filter "*.exe" -Recurse | Select-Object -First 1
136+ $godotExe = Get-ChildItem -Path "build\godot\extract" -Filter "Godot_v4.3-stable_win64.exe" -Recurse | Select-Object -First 1
137+ if (-not $godotExe) {
138+ $godotExe = Get-ChildItem -Path "build\godot\extract" -Filter "*.exe" -Recurse | Where-Object { $_.Name -notmatch "_console\.exe$" } | Sort-Object Length -Descending | Select-Object -First 1
139+ }
137140 if (-not $godotExe) {
138141 throw "Failed to locate extracted Godot Windows executable."
139142 }
143+ if ($godotExe.Length -lt 1048576) {
144+ throw "Resolved Godot executable is too small ($($godotExe.Length) bytes): $($godotExe.FullName)"
145+ }
140146 Copy-Item -Path $godotExe.FullName -Destination "src-tauri\bin\godot-x86_64-pc-windows-msvc.exe" -Force
141147
142148 - name : Prepare Godot sidecar binary (Linux)
@@ -168,8 +174,14 @@ jobs:
168174 echo "Failed to locate extracted Godot macOS executable."
169175 exit 1
170176 fi
171- cp "${GODOT_BIN}" src-tauri/bin/godot-x86_64-apple-darwin
172- chmod +x src-tauri/bin/godot-x86_64-apple-darwin
177+ ARCH="$(uname -m)"
178+ if [ "${ARCH}" = "arm64" ] || [ "${ARCH}" = "aarch64" ]; then
179+ TARGET_BIN="src-tauri/bin/godot-aarch64-apple-darwin"
180+ else
181+ TARGET_BIN="src-tauri/bin/godot-x86_64-apple-darwin"
182+ fi
183+ cp "${GODOT_BIN}" "${TARGET_BIN}"
184+ chmod +x "${TARGET_BIN}"
173185
174186 - name : Build desktop bundle
175187 run : npm run tauri:build:mini
0 commit comments