-
-
Notifications
You must be signed in to change notification settings - Fork 289
Closed
Description
When running rules_scala (trying to compile some Scala code) with JDK 21, I receive the following exception:
Exception in thread "main" java.lang.UnsupportedOperationException: The Security Manager is deprecated and will be removed in a future release
at java.base/java.lang.System.setSecurityManager(System.java:429)
at io.bazel.rulesscala.worker.Worker.persistentWorkerMain(Worker.java:47)
at io.bazel.rulesscala.worker.Worker.workerMain(Worker.java:39)
at io.bazel.rulesscala.scalac.ScalacWorker.main(ScalacWorker.java:36)
Reproduced on Linux with:
# WORKSPACE:
# Idea from: https://gist.github.com/ghostbear/b0aa3bf1a323b38be98bb1a66db65b41
# Link can be found at: https://www.azul.com/downloads/?package=jdk#zulu
remote_java_repository(
name = "java_21_repository",
prefix = "zulujdk",
sha256 = "bf4842dd3a17cfe85523be5848b5ec3bc3d811afc74feab791befa4c895c4449",
strip_prefix = "zulu21.30.15-ca-jdk21.0.1-linux_x64",
target_compatible_with = ["@platforms//os:linux"],
urls = ["https://cdn.azul.com/zulu/bin/zulu21.30.15-ca-jdk21.0.1-linux_x64.tar.gz"],
version = "21",
)
register_toolchains("//tools/jdk:java21_toolchain_definition")
# //tools/jdk:BUILD
default_java_toolchain(
name = "java21_toolchain",
configuration = DEFAULT_TOOLCHAIN_CONFIGURATION,
java_runtime = "@java_21_repository//:jdk",
javacopts = DEFAULT_JAVACOPTS,
# jvm_opts needs to stay this one also for Java 11, it seems to be common for Java 9+ versions.
# It includes e.g. Java module system options.
jvm_opts = BASE_JDK9_JVM_OPTS,
source_version = "21",
target_version = "21",
visibility = ["//visibility:public"],
)
Metadata
Metadata
Assignees
Labels
No labels