diff --git a/ant/build.gradle b/ant/build.gradle index ddb6063f..ed589528 100644 --- a/ant/build.gradle +++ b/ant/build.gradle @@ -17,6 +17,7 @@ targetCompatibility = "${target}" sourceSets.main { java { srcDirs = ['src'] + include '**/*.java' } resources { srcDirs = ['src'] @@ -28,16 +29,16 @@ sourceSets.main { } dependencies { - compile project(':base') - compile 'com.guardsquare:proguard-core' - compile 'org.apache.ant:ant:1.9.7' + implementation project(':base') + implementation 'com.guardsquare:proguard-core' + implementation 'org.apache.ant:ant:1.9.7' } task fatJar(type: ShadowJar) { destinationDirectory.set(file("$rootDir/lib")) archiveFileName.set('proguard-ant.jar') from sourceSets.main.output - configurations = [project.configurations.runtime] + configurations = [project.configurations.runtimeClasspath] manifest { attributes( 'Manifest-Version': '1.0', diff --git a/base/build.gradle b/base/build.gradle index 5102cc8f..49059f11 100644 --- a/base/build.gradle +++ b/base/build.gradle @@ -28,8 +28,8 @@ sourceSets.main { } dependencies { - compile "com.guardsquare:proguard-core:${proguardCoreVersion}" - compile "com.google.code.gson:gson:${gsonVersion}" + implementation "com.guardsquare:proguard-core:${proguardCoreVersion}" + implementation "com.google.code.gson:gson:${gsonVersion}" } jar.manifest.attributes('Implementation-Version': version) @@ -38,7 +38,7 @@ task fatJar(type: ShadowJar) { destinationDirectory.set(file("$rootDir/lib")) archiveFileName.set('proguard.jar') from sourceSets.main.output - configurations = [project.configurations.runtime] + configurations = [project.configurations.runtimeClasspath] manifest { attributes( 'Main-Class': 'proguard.ProGuard', diff --git a/build.gradle b/build.gradle index 66edb62a..58bbbb6e 100644 --- a/build.gradle +++ b/build.gradle @@ -10,11 +10,6 @@ allprojects { version = proguardVersion } -wrapper { - gradleVersion = '6.8' - distributionType = Wrapper.DistributionType.ALL -} - task buildDocumentation(type: Exec) { inputs.dir 'docs/md' inputs.file 'docs/mkdocs.yml' diff --git a/examples/android-plugin/gradle/wrapper/gradle-wrapper.jar b/examples/android-plugin/gradle/wrapper/gradle-wrapper.jar index 5c2d1cf0..e708b1c0 100644 Binary files a/examples/android-plugin/gradle/wrapper/gradle-wrapper.jar and b/examples/android-plugin/gradle/wrapper/gradle-wrapper.jar differ diff --git a/examples/android-plugin/gradle/wrapper/gradle-wrapper.properties b/examples/android-plugin/gradle/wrapper/gradle-wrapper.properties index f4d7b2bf..2a563242 100644 --- a/examples/android-plugin/gradle/wrapper/gradle-wrapper.properties +++ b/examples/android-plugin/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.2-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/examples/gradlekotlindsl/gradle/wrapper/gradle-wrapper.jar b/examples/gradlekotlindsl/gradle/wrapper/gradle-wrapper.jar index f3d88b1c..e708b1c0 100644 Binary files a/examples/gradlekotlindsl/gradle/wrapper/gradle-wrapper.jar and b/examples/gradlekotlindsl/gradle/wrapper/gradle-wrapper.jar differ diff --git a/examples/gradlekotlindsl/gradle/wrapper/gradle-wrapper.properties b/examples/gradlekotlindsl/gradle/wrapper/gradle-wrapper.properties index 1b16c34a..2a563242 100644 --- a/examples/gradlekotlindsl/gradle/wrapper/gradle-wrapper.properties +++ b/examples/gradlekotlindsl/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.1.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.2-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/examples/gradlekotlindsl/gradlew b/examples/gradlekotlindsl/gradlew index 2fe81a7d..4f906e0c 100755 --- a/examples/gradlekotlindsl/gradlew +++ b/examples/gradlekotlindsl/gradlew @@ -82,6 +82,7 @@ esac CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar + # Determine the Java command to use to start the JVM. if [ -n "$JAVA_HOME" ] ; then if [ -x "$JAVA_HOME/jre/sh/java" ] ; then @@ -129,6 +130,7 @@ fi if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then APP_HOME=`cygpath --path --mixed "$APP_HOME"` CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` + JAVACMD=`cygpath --unix "$JAVACMD"` # We build the pattern for arguments to be converted via cygpath diff --git a/examples/gradlekotlindsl/gradlew.bat b/examples/gradlekotlindsl/gradlew.bat index 9618d8d9..107acd32 100644 --- a/examples/gradlekotlindsl/gradlew.bat +++ b/examples/gradlekotlindsl/gradlew.bat @@ -29,6 +29,9 @@ if "%DIRNAME%" == "" set DIRNAME=. set APP_BASE_NAME=%~n0 set APP_HOME=%DIRNAME% +@rem Resolve any "." and ".." in APP_HOME to make it shorter. +for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi + @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" @@ -37,7 +40,7 @@ if defined JAVA_HOME goto findJavaFromJavaHome set JAVA_EXE=java.exe %JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto init +if "%ERRORLEVEL%" == "0" goto execute echo. echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. @@ -51,7 +54,7 @@ goto fail set JAVA_HOME=%JAVA_HOME:"=% set JAVA_EXE=%JAVA_HOME%/bin/java.exe -if exist "%JAVA_EXE%" goto init +if exist "%JAVA_EXE%" goto execute echo. echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% @@ -61,28 +64,14 @@ echo location of your Java installation. goto fail -:init -@rem Get command-line arguments, handling Windows variants - -if not "%OS%" == "Windows_NT" goto win9xME_args - -:win9xME_args -@rem Slurp the command line arguments. -set CMD_LINE_ARGS= -set _SKIP=2 - -:win9xME_args_slurp -if "x%~1" == "x" goto execute - -set CMD_LINE_ARGS=%* - :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 %CMD_LINE_ARGS% +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* :end @rem End local scope for the variables with windows NT shell diff --git a/examples/spring-boot/build.gradle b/examples/spring-boot/build.gradle index 4b3ee567..5cdb86fb 100644 --- a/examples/spring-boot/build.gradle +++ b/examples/spring-boot/build.gradle @@ -60,8 +60,8 @@ task repackage(type: Zip) { from "${buildDir}/extracted" entryCompression ZipEntryCompression.STORED - archiveName "demo-$version-obfuscated.jar" - destinationDir(file("${buildDir}/libs")) + archiveFileName= "demo-$archiveVersion-obfuscated.jar" + destinationDirectory = file("${buildDir}/libs") } task proguard(type: ProGuardTask) { diff --git a/examples/spring-boot/gradle/wrapper/gradle-wrapper.properties b/examples/spring-boot/gradle/wrapper/gradle-wrapper.properties index 12d38de6..2a563242 100644 --- a/examples/spring-boot/gradle/wrapper/gradle-wrapper.properties +++ b/examples/spring-boot/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.6.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.2-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/gradle-plugin/build.gradle b/gradle-plugin/build.gradle index 12920766..1dee1171 100644 --- a/gradle-plugin/build.gradle +++ b/gradle-plugin/build.gradle @@ -16,10 +16,14 @@ targetCompatibility = "${target}" sourceSets.main { java { srcDirs = ['src'] + include '**/*.java' + exclude 'META-INF/**' } groovy { srcDirs = ['src'] + include '**/*.groovy' + exclude 'META-INF/**' } resources { @@ -57,11 +61,6 @@ jar { metaInf.from 'src/META-INF' } -repositories { - google() - jcenter() -} - dependencies { implementation project(':base') implementation 'com.guardsquare:proguard-core' @@ -70,7 +69,7 @@ dependencies { implementation localGroovy() testImplementation gradleTestKit() testImplementation 'junit:junit:4.13.1' - testImplementation "org.spockframework:spock-core:1.1-groovy-2.4@jar" + testImplementation "org.spockframework:spock-core:1.3-groovy-2.5" testImplementation "commons-io:commons-io:2.8.0" } diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 80cf08e7..2a563242 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.8-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.2-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/gui/build.gradle b/gui/build.gradle index db0fc8d6..c642dfb5 100644 --- a/gui/build.gradle +++ b/gui/build.gradle @@ -17,6 +17,7 @@ targetCompatibility = "${target}" sourceSets.main { java { srcDirs = ['src'] + include '**/*.java' } resources { srcDirs = ['src'] @@ -28,16 +29,16 @@ sourceSets.main { } dependencies { - compile project(':base') - compile 'com.guardsquare:proguard-core' - compile project(':retrace') + implementation project(':base') + implementation 'com.guardsquare:proguard-core' + implementation project(':retrace') } task fatJar(type: ShadowJar) { destinationDirectory.set(file("$rootDir/lib")) archiveFileName.set('proguardgui.jar') from sourceSets.main.output - configurations = [project.configurations.runtime] + configurations = [project.configurations.runtimeClasspath] manifest { attributes( 'Manifest-Version': '1.0', diff --git a/retrace/build.gradle b/retrace/build.gradle index 10783bbe..2a4fbf5e 100644 --- a/retrace/build.gradle +++ b/retrace/build.gradle @@ -28,15 +28,15 @@ sourceSets.main { } dependencies { - compile project(':base') - compile 'com.guardsquare:proguard-core' + implementation project(':base') + implementation 'com.guardsquare:proguard-core' } task fatJar(type: ShadowJar) { destinationDirectory.set(file("$rootDir/lib")) archiveFileName.set('retrace.jar') from sourceSets.main.output - configurations = [project.configurations.runtime] + configurations = [project.configurations.runtimeClasspath] manifest { attributes( 'Manifest-Version': '1.0', @@ -44,4 +44,4 @@ task fatJar(type: ShadowJar) { } } -assemble.dependsOn fatJar \ No newline at end of file +assemble.dependsOn fatJar