diff --git a/build.gradle.kts b/build.gradle.kts index 89a837e5..8d623f35 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -224,6 +224,9 @@ allprojects { dependencies { "errorprone"(libs.tools.errorprone.core) "annotationProcessor"(libs.tools.errorprone.guava) + if (!JavaVersion.current().isJava9Compatible) { + "errorproneJavac"(libs.tools.errorprone.javac) + } } tasks.withType().configureEach { options.compilerArgs.addAll(listOf("-Xmaxerrs", "10000", "-Xmaxwarns", "10000", "-Werror")) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index cf91ba73..4a055af7 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -13,6 +13,7 @@ nullabilityAnnotations = "16.0.2" macOSFramework = "latest.release" javaNativeFoundation = "1.1.1" errorprone = "2.8.1" +errorproneCompiler = "9+181-r4173-1" guava = "1.0" javaxAnnotations = "1.3.2" @@ -48,6 +49,7 @@ test-jna = { module = "net.java.dev.jna:jna", version.ref = "jna" } tools-errorprone-core = { module = "com.google.errorprone:error_prone_core", version.ref = "errorprone" } tools-errorprone-annotations = { module = "com.google.errorprone:error_prone_annotations", version.ref = "errorprone" } tools-errorprone-guava = { module = "com.google.guava:guava-beta-checker", version.ref = "guava" } +tools-errorprone-javac = { module = "com.google.errorprone:javac", version.ref = "errorproneCompiler" } [bundles] test-miglayout = ["test-miglayout-core", "test-miglayout-swing"]