Trying to get `ktor` to build locally on `macOS` `...
# ktor
m
Trying to get
ktor
to build locally on
macOS
Arm64
machine in order to work on a PR, but keep getting errors when running
jvmTest
as described in
CONTRIBUTING.md
.
./gradlew assemble
runs successfully. Any suggestions?
Copy code
admin@Mac_Mini ktor % java --version
openjdk 21.0.5 2024-10-15
OpenJDK Runtime Environment Homebrew (build 21.0.5)
OpenJDK 64-Bit Server VM Homebrew (build 21.0.5, mixed mode, sharing)
Copy code
admin@Mac_Mini ktor % echo $JAVA_HOME  
/opt/homebrew/Cellar/openjdk@21/21.0.5/libexec/openjdk.jdk/Contents/Home
h
Unsupported class version is caused by a class that is compiled with an higher jdk loaded with a lower JVM. So try to use a lower JVM, like 8/11. While Ktor does use the Java toolchain, it does not work everywhere in Ktor project.
o
Yes, currently tests pass only if
JAVA_HOME
specifies path to JVM 1.8 This problem is going to be solved after #4500 merged.
❤️ 1
Should be fixed. Though, now the project requires JDK 21 installed.