Hi, I am trying to build kotlin repo, but getting ...
# kontributors
l
Hi, I am trying to build kotlin repo, but getting
Copy code
No compatible toolchains found for request filter: {languageVersion=6, vendor=any, implementation=vendor-specific} (auto-detect true, auto-download true)
error, how do I resolve this error? I am on macOS and have insatlled java6 using brew as mentioned in the README.
d
Add
kotlin.build.isObsoleteJdkOverrideEnabled=true
to
local.properties
file https://github.com/JetBrains/kotlin/blob/master/ReadMe.md#build-environment-requirements
i
Try running
gradlew javaToolchains
to see if the installed JDK 6 is detected by gradle.
If it's not, set the
JDK_16
environment variable to the path to that JDK.
l
I tried running this command
gradlew -q javaToolchains
but even that failed with the error I've mentioned in the starting of this thread. Surprisingly it didn't give me the detected JDK versions on my device (even though I had multiple JDK installed on the standard path). I didn't try setting this
JDK_16
env variable (will try it now), but uncommenting the flag mentioned by Dmitriy in
gradle.properties
file did the job. Thanks!