fix: build linux packages with webkitgtk 4.1

This commit is contained in:
ant-black
2026-06-28 17:26:38 +08:00
parent 5518481eb1
commit f406aa6d67
+11 -1
View File
@@ -186,9 +186,19 @@ if [[ "$SKIP_BUILD" -ne 1 ]]; then
echo "[3/5] Building app binary with Wails..."
rm -f "$APP_BIN"
WAILS_BUILD_TAGS=()
if pkg-config --exists webkit2gtk-4.0; then
echo " WebKitGTK pkg-config: webkit2gtk-4.0"
elif pkg-config --exists webkit2gtk-4.1; then
echo " WebKitGTK pkg-config: webkit2gtk-4.1 (using Wails webkit2_41 tag)"
WAILS_BUILD_TAGS=(-tags webkit2_41)
else
echo "[ERROR] missing WebKitGTK development package: webkit2gtk-4.0 or webkit2gtk-4.1" >&2
exit 1
fi
(
cd "$ROOT_DIR"
wails build -s -platform "linux/$ARCH" -o ant-chrome
wails build -s -platform "linux/$ARCH" "${WAILS_BUILD_TAGS[@]}" -o ant-chrome
)
else
echo "[WARN] skipping build step"