[build] Upgrade to Gradle 8.14.3 (#8164)

This fixes local builds with JDK 24.

I fixed deprecation warnings from `./gradlew wrapper --warning-mode all`
as well.
This commit is contained in:
Tyler Veness
2025-08-08 08:08:34 -07:00
committed by GitHub
parent 2d11946d98
commit 0a0adebd89
30 changed files with 75 additions and 77 deletions

View File

@@ -81,7 +81,7 @@ task libraryBuild() {}
build.dependsOn outputVersions
task copyAllOutputs(type: Copy) {
destinationDir outputsFolder
destinationDir = outputsFolder
}
build.dependsOn copyAllOutputs
@@ -170,5 +170,5 @@ ext.getCurrentArch = {
}
wrapper {
gradleVersion = '8.11'
gradleVersion = '8.14.3'
}

View File

@@ -5,7 +5,7 @@ repositories {
url = 'https://frcmaven.wpi.edu/artifactory/ex-gradle'
}
mavenCentral()
url "https://plugins.gradle.org/m2/"
url = "https://plugins.gradle.org/m2/"
}
}
dependencies {

View File

@@ -31,7 +31,7 @@ model {
// Create the ZIP.
def task = project.tasks.create("copyDataLogToolExecutable" + binary.targetPlatform.operatingSystem.name + binary.targetPlatform.architecture.name, Zip) {
description("Copies the DataLogTool executable to the outputs directory.")
description = "Copies the DataLogTool executable to the outputs directory."
destinationDirectory = outputsFolder
archiveBaseName = zipBaseName
@@ -117,7 +117,7 @@ model {
artifactId = baseArtifactId
groupId = artifactGroupId
version wpilibVersioning.version.get()
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -177,7 +177,7 @@ tasks.register("zipCppDocs", Zip) {
// Java
configurations {
javaSource {
transitive false
transitive = false
}
}
@@ -265,15 +265,15 @@ publishing {
artifact zipJavaDocs
artifactId = "${baseArtifactIdJava}"
groupId artifactGroupIdJava
version wpilibVersioning.version.get()
groupId = artifactGroupIdJava
version = wpilibVersioning.version.get()
}
cpp(MavenPublication) {
artifact zipCppDocs
artifactId = "${baseArtifactIdCpp}"
groupId artifactGroupIdCpp
version wpilibVersioning.version.get()
groupId = artifactGroupIdCpp
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -63,8 +63,8 @@ model {
artifact cppSourcesZip
artifactId = "${baseArtifactId}-cpp"
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -86,7 +86,7 @@ model {
// Create the ZIP.
def task = project.tasks.create("copyGlassExecutable" + binary.targetPlatform.operatingSystem.name + binary.targetPlatform.architecture.name, Zip) {
description("Copies the Glass executable to the outputs directory.")
description = "Copies the Glass executable to the outputs directory."
destinationDirectory = outputsFolder
archiveBaseName = zipBaseName
@@ -175,7 +175,7 @@ model {
artifactId = baseArtifactId
groupId = artifactGroupId
version wpilibVersioning.version.get()
version = wpilibVersioning.version.get()
}
libglass(MavenPublication) {
libGlassTaskList.each { artifact it }
@@ -185,7 +185,7 @@ model {
artifactId = libBaseArtifactId
groupId = libArtifactGroupId
version wpilibVersioning.version.get()
version = wpilibVersioning.version.get()
}
libglassnt(MavenPublication) {
libGlassntTaskList.each { artifact it }
@@ -195,7 +195,7 @@ model {
artifactId = libntBaseArtifactId
groupId = libntArtifactGroupId
version wpilibVersioning.version.get()
version = wpilibVersioning.version.get()
}
}
}

Binary file not shown.

View File

@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME

9
gradlew vendored
View File

@@ -86,8 +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 -P "${APP_HOME:-./}" > /dev/null && printf '%s
' "$PWD" ) || 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
@@ -115,7 +114,7 @@ case "$( uname )" in #(
NONSTOP* ) nonstop=true ;;
esac
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
CLASSPATH="\\\"\\\""
# Determine the Java command to use to start the JVM.
@@ -206,7 +205,7 @@ 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.
@@ -214,7 +213,7 @@ DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
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.

4
gradlew.bat vendored
View File

@@ -70,11 +70,11 @@ goto fail
:execute
@rem Setup the command line
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
set CLASSPATH=
@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%" -classpath "%CLASSPATH%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %*
:end
@rem End local scope for the variables with windows NT shell

View File

@@ -1,6 +1,5 @@
import org.gradle.nativeplatform.toolchain.internal.msvcpp.VisualStudioLocator
import org.gradle.internal.os.OperatingSystem
import org.gradle.util.VersionNumber
plugins {
id 'cpp'

View File

@@ -140,8 +140,8 @@ model {
artifact cppHeadersZip
artifactId = "${baseArtifactId}-cpp"
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -31,7 +31,7 @@ model {
// Create the ZIP.
def task = project.tasks.create("copyOutlineViewerExecutable" + binary.targetPlatform.operatingSystem.name + binary.targetPlatform.architecture.name, Zip) {
description("Copies the OutlineViewer executable to the outputs directory.")
description = "Copies the OutlineViewer executable to the outputs directory."
destinationDirectory = outputsFolder
archiveBaseName = zipBaseName
@@ -117,7 +117,7 @@ model {
artifactId = baseArtifactId
groupId = artifactGroupId
version wpilibVersioning.version.get()
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -30,7 +30,7 @@ model {
// Create the ZIP.
def task = project.tasks.create("copyprocessstarterExecutable" + binary.targetPlatform.architecture.name, Zip) {
description("Copies the processstarter executable to the outputs directory.")
description = "Copies the processstarter executable to the outputs directory."
destinationDirectory = outputsFolder
archiveBaseName = zipBaseName
@@ -60,7 +60,7 @@ model {
artifactId = baseArtifactId
groupId = artifactGroupId
version wpilibVersioning.version.get()
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -31,7 +31,7 @@ model {
// Create the ZIP.
def task = project.tasks.create("copyroboRIOTeamNumberSetterExecutable" + binary.targetPlatform.operatingSystem.name + binary.targetPlatform.architecture.name, Zip) {
description("Copies the roboRIOTeamNumberSetter executable to the outputs directory.")
description = "Copies the roboRIOTeamNumberSetter executable to the outputs directory."
destinationDirectory = outputsFolder
archiveBaseName = zipBaseName
@@ -117,7 +117,7 @@ model {
artifactId = baseArtifactId
groupId = artifactGroupId
version wpilibVersioning.version.get()
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -65,8 +65,8 @@ publishing {
artifact javadocJar
artifactId = "${baseArtifactId}-java"
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}
@@ -76,7 +76,7 @@ test {
systemProperty 'junit.jupiter.extensions.autodetection.enabled', 'true'
testLogging {
events "failed"
exceptionFormat "full"
exceptionFormat = "full"
}
finalizedBy jacocoTestReport
}

View File

@@ -67,8 +67,8 @@ model {
artifact cppSourcesZip
artifactId = "${baseArtifactId}-cpp"
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -85,8 +85,8 @@ model {
artifact cppSourcesZip
artifactId = "${baseArtifactId}-cpp"
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
@@ -118,8 +118,8 @@ model {
}
artifactId = "${baseArtifactId}-jnicvstatic"
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -56,8 +56,8 @@ model {
artifactId = baseArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -31,7 +31,7 @@ model {
// Create the macOS bundle.
def bundleTask = project.tasks.create("bundleSysIdOsxApp" + binary.targetPlatform.architecture.name, Copy) {
description("Creates a macOS application bundle for SysId")
description = "Creates a macOS application bundle for SysId"
from(file("$project.projectDir/Info.plist"))
into(file("$project.buildDir/outputs/bundles/$binary.targetPlatform.architecture.name/SysId.app/Contents"))
into("MacOS") {
@@ -74,7 +74,7 @@ model {
// Create the ZIP.
def task = project.tasks.create("copySysIdExecutable" + binary.targetPlatform.architecture.name, Zip) {
description("Copies the SysId executable to the outputs directory.")
description = "Copies the SysId executable to the outputs directory."
destinationDirectory = outputsFolder
archiveBaseName = zipBaseName
@@ -118,7 +118,7 @@ model {
artifactId = baseArtifactId
groupId = artifactGroupId
version wpilibVersioning.version.get()
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -54,8 +54,8 @@ model {
artifact cppSourcesZip
artifactId = baseArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -85,8 +85,8 @@ model {
artifact cppSourcesZip
artifactId = baseArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -31,7 +31,7 @@ model {
// Create the ZIP.
def task = project.tasks.create("copywpicalExecutable" + binary.targetPlatform.operatingSystem.name + binary.targetPlatform.architecture.name, Zip) {
description("Copies the wpical executable to the outputs directory.")
description = "Copies the wpical executable to the outputs directory."
destinationDirectory = outputsFolder
archiveBaseName = zipBaseName
@@ -121,7 +121,7 @@ model {
artifactId = baseArtifactId
groupId = artifactGroupId
version wpilibVersioning.version.get()
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -63,8 +63,8 @@ model {
artifact cppSourcesZip
artifactId = baseArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -66,8 +66,8 @@ model {
artifact cppSourcesZip
artifactId = baseArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -76,24 +76,24 @@ publishing {
artifact cppExamplesZip
artifactId = baseExamplesArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
templates(MavenPublication) {
artifact cppTemplatesZip
artifactId = baseTemplatesArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
commands(MavenPublication) {
artifact cppCommandsZip
artifactId = baseCommandsArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -94,7 +94,7 @@ model {
}
}
}
destinationDir testOutputFolder
destinationDir = testOutputFolder
}
// This is in a separate if statement because of what I would assume is a bug in grade.
// Will file an issue on their side.

View File

@@ -162,7 +162,7 @@ model {
new groovy.json.JsonSlurper().parseText(exampleFile.text).each { entry ->
project.tasks.create("run${entry.foldername}", JavaExec) { run ->
run.group "run examples"
run.group = "run examples"
run.mainClass = "edu.wpi.first.wpilibj.examples." + entry.foldername + "." + entry.mainclass
run.classpath = sourceSets.main.runtimeClasspath
run.dependsOn it.tasks.install
@@ -174,7 +174,7 @@ model {
}
}
project.tasks.create("test${entry.foldername}", Test) { testTask ->
testTask.group "verification"
testTask.group = "verification"
testTask.useJUnitPlatform()
testTask.filter {
includeTestsMatching("edu.wpi.first.wpilibj.examples.${entry.foldername}.*")
@@ -195,7 +195,7 @@ model {
testTask.systemProperty 'junit.jupiter.extensions.autodetection.enabled', 'true'
testTask.testLogging {
events "failed"
exceptionFormat "full"
exceptionFormat = "full"
}
testTask.systemProperty 'java.library.path', filePath
@@ -207,7 +207,7 @@ model {
}
new groovy.json.JsonSlurper().parseText(snippetsFile.text).each { entry ->
project.tasks.create("runSnippet${entry.foldername}", JavaExec) { run ->
run.group "run snippets"
run.group = "run snippets"
run.mainClass = "edu.wpi.first.wpilibj.snippets." + entry.foldername + "." + entry.mainclass
run.classpath = sourceSets.main.runtimeClasspath
run.dependsOn it.tasks.install
@@ -219,7 +219,7 @@ model {
}
}
project.tasks.create("testSnippet${entry.foldername}", Test) { testTask ->
testTask.group "verification"
testTask.group = "verification"
testTask.useJUnitPlatform()
testTask.filter {
includeTestsMatching("edu.wpi.first.wpilibj.snippets.${entry.foldername}.*")
@@ -236,7 +236,7 @@ model {
testTask.systemProperty 'junit.jupiter.extensions.autodetection.enabled', 'true'
testTask.testLogging {
events "failed"
exceptionFormat "full"
exceptionFormat = "full"
}
testTask.systemProperty 'java.library.path', filePath

View File

@@ -76,24 +76,24 @@ publishing {
artifact javaExamplesZip
artifactId = baseExamplesArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
templates(MavenPublication) {
artifact javaTemplatesZip
artifactId = baseTemplatesArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
commands(MavenPublication) {
artifact javaCommandsZip
artifactId = baseCommandsArtifactId
groupId artifactGroupId
version wpilibVersioning.version.get()
groupId = artifactGroupId
version = wpilibVersioning.version.get()
}
}
}

View File

@@ -44,7 +44,7 @@ build.dependsOn shadowJar
def testOutputFolder = file("${project(':').buildDir}/integrationTestFiles")
task copyWpilibJIntegrationTestJarToOutput(type: Copy) {
destinationDir testOutputFolder
destinationDir = testOutputFolder
dependsOn shadowJar
inputs.file shadowJar.archiveFile
from(shadowJar) {