From 7c4db1b3b747100dec7b7e44b0c1a7ee5935bc2c Mon Sep 17 00:00:00 2001 From: "Dimitri A." Date: Wed, 6 Nov 2024 15:59:26 +0100 Subject: [PATCH] Upgrade build code for Gradle 8 to remove deprecated uses Fixes build errors that appeared as warnings in Gradle 7: * Configurations no longer allowed as Dependencies * AbstractArchiveTask API Cleanup: Deprecated properties `baseName`, `extension`, `destinationDir`, and `version` have been removed in Gradle 8. Instead use `archiveBaseName`, `archiveExtension`, `destinationDirectory`, and `archiveVersion`. https://docs.gradle.org/current/userguide/upgrading_version_7.html#abstractarchivetask_api_cleanup --- build.gradle | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/build.gradle b/build.gradle index 8e09ace..e543135 100644 --- a/build.gradle +++ b/build.gradle @@ -45,7 +45,6 @@ def getGitHash = { } wrapper { - gradleVersion = '7.5.1' gradleVersion = '8.10.2' distributionType = Wrapper.DistributionType.BIN } @@ -61,14 +60,13 @@ configurations { dependencies { implementation fileTree(dir: ghidraInstallDir + '/Ghidra/Processors', include: "**/*.jar") localDeps group: 'org.lz4', name: 'lz4-java', version: '1.5.1' - implementation configurations.localDeps } buildExtension { - baseName "${project.name}-${project.version}-${getGitHash()}-Ghidra_${ghidra_version}".replace(' ', '_') - extension 'zip' - destinationDir DISTRIBUTION_DIR - version '' + archiveBaseName = "${project.name}-${project.version}-${getGitHash()}-Ghidra_${ghidra_version}".replace(' ', '_') + archiveExtension = 'zip' + destinationDirectory = DISTRIBUTION_DIR + archiveVersion = '' // Make sure that we don't try to copy the same file with the same path into the // zip (this can happen!) @@ -121,7 +119,7 @@ buildExtension { } doLast { - println "\nCreated " + baseName + "." + extension + " in " + destinationDir + println "\nCreated " + archiveBaseName + "." + archiveExtension + " in " + destinationDirectory } }