From 0fd10cc08eac06b85d7aebedb2aa694c97a52404 Mon Sep 17 00:00:00 2001 From: Mitchell Syer Date: Wed, 1 Jul 2026 17:23:17 -0400 Subject: [PATCH] Fix chmod attempts on Windows Java (#2156) --- CHANGELOG.md | 1 + scripts/bundler.sh | 11 +++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 610c6b704..82fcfa10d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,6 +21,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/). - (**Extension/API**) Fix GQL handling of extensions without an extension store - (**Build/Bundler**) Fix build continuing if errors happen - (**Build/Bundler**) Remove jogamp from build script +- (**Build/Bundler**) Fix chmod attempts on Windows Java ## [v2.3.2223] + [WebUI: v20260509.01] - 2026-06-30 diff --git a/scripts/bundler.sh b/scripts/bundler.sh index 6ab2f4669..bcd9adfb1 100755 --- a/scripts/bundler.sh +++ b/scripts/bundler.sh @@ -161,8 +161,10 @@ download_electron() { setup_jre() { if [ -d "jre" ]; then - chmod +x ./jre/bin/java || error $LINENO "Failed to set java executable permission" 1 - chmod +x ./jre/lib/jspawnhelper || error $LINENO "Failed to set jspawnhelper executable permission" 1 + if [ ! -f "./jre/bin/java.exe" ]; then + chmod +x ./jre/bin/java || error $LINENO "Failed to set java executable permission" 1 + chmod +x ./jre/lib/jspawnhelper || error $LINENO "Failed to set jspawnhelper executable permission" 1 + fi mv "jre" "$RELEASE_NAME/jre" || error $LINENO "Failed to move jre" 1 else if [ ! -f "$JRE" ]; then @@ -176,6 +178,11 @@ setup_jre() { tar xvf "$JRE" || error $LINENO "Failed to extract JRE tar" 1 fi mv "$JRE_DIR" "$RELEASE_NAME/jre" || error $LINENO "Failed to move extracted JRE" 1 + + if [ ! -f "$RELEASE_NAME/jre/bin/java.exe" ]; then + chmod +x "$RELEASE_NAME/jre/bin/java" || error $LINENO "Failed to set java executable permission" 1 + chmod +x "$RELEASE_NAME/jre/lib/jspawnhelper" || error $LINENO "Failed to set jspawnhelper executable permission" 1 + fi fi }