diff --git a/build.gradle b/build.gradle index 77633f4..54ac9a5 100644 --- a/build.gradle +++ b/build.gradle @@ -29,8 +29,13 @@ repositories { } java { - toolchain { - languageVersion = JavaLanguageVersion.of(18) + // It seems that specifying the minimum supported Java version while allowing the use of newer + // ones isn't possible in Gradle. To test the library against multiple Java versions, the + // workaround proposed in https://github.com/gradle/gradle/issues/16256 has been applied: + if (!JavaVersion.current().isCompatibleWith(JavaVersion.VERSION_18)) { + toolchain { + languageVersion = JavaLanguageVersion.of(18) + } } withJavadocJar() withSourcesJar() diff --git a/settings.gradle b/settings.gradle index 88e1d4b..743e03f 100644 --- a/settings.gradle +++ b/settings.gradle @@ -1,5 +1 @@ -plugins { - id("org.gradle.toolchains.foojay-resolver-convention") version "0.7.0" -} - rootProject.name = 'simdjson-java'