From 3f6901afe50ce261cf10b14cfb7a74938600eda9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Prante?= Date: Sat, 30 Sep 2023 15:33:07 +0200 Subject: [PATCH] move to OpenJDK 21 --- config/checkstyle/checkstyle.xml | 321 ------------------------------- gradle/compile/java.gradle | 15 +- 2 files changed, 5 insertions(+), 331 deletions(-) delete mode 100644 config/checkstyle/checkstyle.xml diff --git a/config/checkstyle/checkstyle.xml b/config/checkstyle/checkstyle.xml deleted file mode 100644 index 14a1edc..0000000 --- a/config/checkstyle/checkstyle.xml +++ /dev/null @@ -1,321 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/gradle/compile/java.gradle b/gradle/compile/java.gradle index f99230f..be4708e 100644 --- a/gradle/compile/java.gradle +++ b/gradle/compile/java.gradle @@ -1,21 +1,14 @@ apply plugin: 'java-library' java { + toolchain { + languageVersion = JavaLanguageVersion.of(21) + } modularity.inferModulePath.set(true) withSourcesJar() withJavadocJar() } -compileJava { - sourceCompatibility = JavaVersion.VERSION_17 - targetCompatibility = JavaVersion.VERSION_17 -} - -compileTestJava { - sourceCompatibility = JavaVersion.VERSION_17 - targetCompatibility = JavaVersion.VERSION_17 -} - jar { manifest { attributes('Implementation-Version': project.version) @@ -24,6 +17,8 @@ jar { } tasks.withType(JavaCompile) { + options.fork = true + options.forkOptions.jvmArgs += ['-Duser.language=en','-Duser.country=US'] options.compilerArgs.add('-Xlint:all') options.encoding = 'UTF-8' }