From a53f9c38dd0656722d80819d605d7842e201b374 Mon Sep 17 00:00:00 2001 From: Claudio Bley Date: Thu, 23 Nov 2023 18:12:57 +0100 Subject: [PATCH] Use non-prebuild Java toolchain configuration On NixOS we cannot use the pre-built `ijar` and `singlejar` tools as they are not statically build and fail to find the dynamic linker. Fixes #278 --- toolchains/java/local_java_repository.bzl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/toolchains/java/local_java_repository.bzl b/toolchains/java/local_java_repository.bzl index cccc4465f..4b889c819 100644 --- a/toolchains/java/local_java_repository.bzl +++ b/toolchains/java/local_java_repository.bzl @@ -14,7 +14,7 @@ """Rules for importing and registering a local JDK.""" -load(":default_java_toolchain.bzl", "default_java_toolchain") +load(":default_java_toolchain.bzl", "NONPREBUILT_TOOLCHAIN_CONFIGURATION", "default_java_toolchain") def _detect_java_version(repository_ctx, java_bin): properties_out = repository_ctx.execute([java_bin, "-XshowSettings:properties"]).stderr @@ -99,10 +99,10 @@ def local_java_runtime(name, java_home, version, runtime_name = None, visibility for version in range(8, int(version) + 1): default_java_toolchain( name = name + "_toolchain_java" + str(version), + configuration = NONPREBUILT_TOOLCHAIN_CONFIGURATION, source_version = str(version), target_version = str(version), java_runtime = runtime_name, - exec_compatible_with = exec_compatible_with, target_compatible_with = target_compatible_with, )