diff --git a/linux/ca-certificates/debian/build.gradle b/linux/ca-certificates/debian/build.gradle index bc134b070..c8c743656 100644 --- a/linux/ca-certificates/debian/build.gradle +++ b/linux/ca-certificates/debian/build.gradle @@ -78,11 +78,11 @@ task packageCaCertificatesDebian { def containerRegistry = getContainerRegistry() doLast { - project.copy { + copy { from("src/main/packaging/") into("${buildDir}/generated/packaging") } - project.exec { + exec { workingDir "src/main/packaging" commandLine "docker", "build", "--no-cache", "--pull", "-t", "adoptium-packages-linux-cacerts-debian", @@ -91,7 +91,7 @@ task packageCaCertificatesDebian { getProjectDir().absolutePath + "/src/main/packaging" } - project.exec { + exec { workingDir getRootDir() commandLine "docker", "run", "--rm", "--mount", "type=bind,source=${buildDir},target=/home/builder/build", diff --git a/linux/gradle/wrapper/gradle-wrapper.jar b/linux/gradle/wrapper/gradle-wrapper.jar index d64cd4917..61285a659 100644 Binary files a/linux/gradle/wrapper/gradle-wrapper.jar and b/linux/gradle/wrapper/gradle-wrapper.jar differ diff --git a/linux/gradle/wrapper/gradle-wrapper.properties b/linux/gradle/wrapper/gradle-wrapper.properties index d4081da47..19a6bdeb8 100644 --- a/linux/gradle/wrapper/gradle-wrapper.properties +++ b/linux/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-9.3.0-bin.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/linux/gradlew b/linux/gradlew index 1aa94a426..adff685a0 100755 --- a/linux/gradlew +++ b/linux/gradlew @@ -1,7 +1,7 @@ #!/bin/sh # -# Copyright © 2015-2021 the original authors. +# Copyright © 2015 the original authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -15,6 +15,8 @@ # See the License for the specific language governing permissions and # limitations under the License. # +# SPDX-License-Identifier: Apache-2.0 +# ############################################################################## # @@ -55,7 +57,7 @@ # Darwin, MinGW, and NonStop. # # (3) This script is generated from the Groovy template -# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt +# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt # within the Gradle project. # # You can find Gradle at https://github.com/gradle/gradle/. @@ -84,7 +86,7 @@ done # shellcheck disable=SC2034 APP_BASE_NAME=${0##*/} # Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036) -APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit +APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s\n' "$PWD" ) || exit # Use the maximum available, or set MAX_FD != -1 to use that value. MAX_FD=maximum @@ -112,7 +114,6 @@ case "$( uname )" in #( NONSTOP* ) nonstop=true ;; esac -CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar # Determine the Java command to use to start the JVM. @@ -170,7 +171,6 @@ fi # For Cygwin or MSYS, switch paths to Windows format before running java if "$cygwin" || "$msys" ; then APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) - CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) JAVACMD=$( cygpath --unix "$JAVACMD" ) @@ -203,15 +203,14 @@ fi DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' # Collect all arguments for the java command: -# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments, +# * DEFAULT_JVM_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments, # and any embedded shellness will be escaped. # * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be # treated as '${Hostname}' itself on the command line. set -- \ "-Dorg.gradle.appname=$APP_BASE_NAME" \ - -classpath "$CLASSPATH" \ - org.gradle.wrapper.GradleWrapperMain \ + -jar "$APP_HOME/gradle/wrapper/gradle-wrapper.jar" \ "$@" # Stop when "xargs" is not available. diff --git a/linux/gradlew.bat b/linux/gradlew.bat old mode 100644 new mode 100755 index 6689b85be..e509b2dd8 --- a/linux/gradlew.bat +++ b/linux/gradlew.bat @@ -13,6 +13,8 @@ @rem See the License for the specific language governing permissions and @rem limitations under the License. @rem +@rem SPDX-License-Identifier: Apache-2.0 +@rem @if "%DEBUG%"=="" @echo off @rem ########################################################################## @@ -43,11 +45,11 @@ set JAVA_EXE=java.exe %JAVA_EXE% -version >NUL 2>&1 if %ERRORLEVEL% equ 0 goto execute -echo. -echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. +echo. 1>&2 +echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2 +echo. 1>&2 +echo Please set the JAVA_HOME variable in your environment to match the 1>&2 +echo location of your Java installation. 1>&2 goto fail @@ -57,22 +59,21 @@ set JAVA_EXE=%JAVA_HOME%/bin/java.exe if exist "%JAVA_EXE%" goto execute -echo. -echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. +echo. 1>&2 +echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2 +echo. 1>&2 +echo Please set the JAVA_HOME variable in your environment to match the 1>&2 +echo location of your Java installation. 1>&2 goto fail :execute @rem Setup the command line -set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar @rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %* :end @rem End local scope for the variables with windows NT shell diff --git a/linux/jdk/debian/build.gradle b/linux/jdk/debian/build.gradle index 805f2465e..6406aa825 100644 --- a/linux/jdk/debian/build.gradle +++ b/linux/jdk/debian/build.gradle @@ -82,7 +82,7 @@ task packageJdkDebian { throw new IllegalArgumentException("Input directory '$input_dir' not found") } - project.copy { + copy { from("src/main/packaging/$product/$productVersion/") into("${buildDir}/generated/packaging") } @@ -102,46 +102,44 @@ task packageJdkDebian { } } -println "The Value Of ARCH is: $arch" - -if ("$arch" == "armhf") { - project.exec { - workingDir "src/main/packaging" - commandLine "docker", "build", "--no-cache", "--pull", - "--build-arg", "IMAGE=arm32v7/debian:bullseye", - "-t", "adoptium-packages-linux-jdk-debian", - "--build-arg=CONTAINER_REGISTRY=${containerRegistry}", - "-f", "Dockerfile", - getProjectDir().absolutePath + "/src/main/packaging" + println "The Value Of ARCH is: $arch" + + if ("$arch" == "armhf") { + exec { + workingDir "src/main/packaging" + commandLine "docker", "build", "--no-cache", "--pull", + "--build-arg", "IMAGE=arm32v7/debian:bullseye", + "-t", "adoptium-packages-linux-jdk-debian", + "--build-arg=CONTAINER_REGISTRY=${containerRegistry}", + "-f", "Dockerfile", + getProjectDir().absolutePath + "/src/main/packaging" + } } - } -if ("$arch" == "riscv64") { - project.exec { - workingDir "src/main/packaging" - commandLine "docker", "build", "--no-cache", "--pull", - "--build-arg", "IMAGE=riscv64/ubuntu:jammy", - "-t", "adoptium-packages-linux-jdk-debian", - "--build-arg=CONTAINER_REGISTRY=${containerRegistry}", - "-f", "Dockerfile", - getProjectDir().absolutePath + "/src/main/packaging" + if ("$arch" == "riscv64") { + exec { + workingDir "src/main/packaging" + commandLine "docker", "build", "--no-cache", "--pull", + "--build-arg", "IMAGE=riscv64/ubuntu:jammy", + "-t", "adoptium-packages-linux-jdk-debian", + "--build-arg=CONTAINER_REGISTRY=${containerRegistry}", + "-f", "Dockerfile", + getProjectDir().absolutePath + "/src/main/packaging" } } -if ("$arch" != "armhf" && "$arch" != "riscv64"){ - project.exec { - workingDir "src/main/packaging" - commandLine "docker", "build", "--no-cache", "--pull", - "-t", "adoptium-packages-linux-jdk-debian", - "--build-arg=CONTAINER_REGISTRY=${containerRegistry}", - "-f", "Dockerfile", - getProjectDir().absolutePath + "/src/main/packaging" - } - } - - + if ("$arch" != "armhf" && "$arch" != "riscv64"){ + exec { + workingDir "src/main/packaging" + commandLine "docker", "build", "--no-cache", "--pull", + "-t", "adoptium-packages-linux-jdk-debian", + "--build-arg=CONTAINER_REGISTRY=${containerRegistry}", + "-f", "Dockerfile", + getProjectDir().absolutePath + "/src/main/packaging" + } + } - project.exec { + exec { workingDir getRootDir() commandLine "docker", "run", "--rm", diff --git a/linux/jre/debian/build.gradle b/linux/jre/debian/build.gradle index 3fa7ac409..818717d40 100644 --- a/linux/jre/debian/build.gradle +++ b/linux/jre/debian/build.gradle @@ -82,7 +82,7 @@ task packageJreDebian { throw new IllegalArgumentException("Input directory '$input_dir' not found") } - project.copy { + copy { from("src/main/packaging/$product/$productVersion/") into("${buildDir}/generated/packaging") } @@ -106,7 +106,7 @@ task packageJreDebian { if ("$arch" == "armhf") { - project.exec { + exec { workingDir "src/main/packaging" commandLine "docker", "build", "--no-cache", "--pull", "--build-arg", "IMAGE=arm32v7/debian:bullseye", @@ -118,7 +118,7 @@ task packageJreDebian { } if ("$arch" == "riscv64") { - project.exec { + exec { workingDir "src/main/packaging" commandLine "docker", "build", "--no-cache", "--pull", "--build-arg", "IMAGE=riscv64/ubuntu:jammy", @@ -130,7 +130,7 @@ task packageJreDebian { } if ("$arch" != "armhf" && "$arch" != "riscv64"){ - project.exec { + exec { workingDir "src/main/packaging" commandLine "docker", "build", "--no-cache", "--pull", "-t", "adoptium-packages-linux-jdk-debian", @@ -140,7 +140,7 @@ task packageJreDebian { } } - project.exec { + exec { workingDir getRootDir() commandLine "docker", "run", "--rm",