You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@gluten.apache.org by ph...@apache.org on 2026/04/24 03:45:27 UTC

(gluten) branch main updated: [GLUTEN-11969] Enable Java 17 release flag for Spark 4+ build (#11971)

This is an automated email from the ASF dual-hosted git repository.

philo-he pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/gluten.git


The following commit(s) were added to refs/heads/main by this push:
     new 6cdcfe88ed [GLUTEN-11969] Enable Java 17 release flag for Spark 4+ build (#11971)
6cdcfe88ed is described below

commit 6cdcfe88ed6638ed625a0bdd9f504960288f1aea
Author: Yao-MR <ya...@gmail.com>
AuthorDate: Fri Apr 24 11:45:22 2026 +0800

    [GLUTEN-11969] Enable Java 17 release flag for Spark 4+ build (#11971)
---
 dev/buildbundle-veloxbe.sh | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/dev/buildbundle-veloxbe.sh b/dev/buildbundle-veloxbe.sh
index 380a2a569c..62bea6cd4a 100755
--- a/dev/buildbundle-veloxbe.sh
+++ b/dev/buildbundle-veloxbe.sh
@@ -27,7 +27,10 @@ function build_for_spark {
   major_version=$(echo $spark_version | cut -d'.' -f1)
 
   if [ "$major_version" -ge 4 ]; then
-    ${MVN_CMD} clean install -Pbackends-velox -Pspark-$spark_version -Pjava-17 -Pscala-2.13 -DskipTests
+    # Force Java 17 release target to override any `maven.compiler.source/target=1.8`
+    # that may be injected by a user's ~/.m2/settings.xml (e.g. an active jdk-8 profile),
+    # which would otherwise cause scalac to fail with: "'1.8' is not a valid choice for '-release'".
+    ${MVN_CMD} clean install -Pbackends-velox -Pspark-$spark_version -Pjava-17 -Pscala-2.13 -DskipTests -Dmaven.compiler.release=17
   else
     ${MVN_CMD} clean install -Pbackends-velox -Pspark-$spark_version -DskipTests
   fi


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@gluten.apache.org
For additional commands, e-mail: commits-help@gluten.apache.org