From dc6d11893e7ed122db0848100e6887aed8096a79 Mon Sep 17 00:00:00 2001 From: PJ Reiniger Date: Thu, 2 Jan 2025 17:50:36 -0500 Subject: [PATCH] Try again --- toolchains/configure_cross_compiler.bzl | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/toolchains/configure_cross_compiler.bzl b/toolchains/configure_cross_compiler.bzl index 1fb471f..4209e83 100644 --- a/toolchains/configure_cross_compiler.bzl +++ b/toolchains/configure_cross_compiler.bzl @@ -39,6 +39,7 @@ def configure_cross_compiler_impl(repository_ctx): BINARIES = [ "ar", + "as", "cpp", "gcc", "gcov", @@ -51,15 +52,22 @@ def configure_cross_compiler_impl(repository_ctx): compiler_workspace = Label("@" + substitutions["{compiler_repo}"]).workspace_name substitutions["{actual_compiler_path}"] = compiler_workspace + print(substitutions["{compiler_repo}"]) + print(substitutions["{bin_subfolder}"]) + print(substitutions) + + dist_rel_path = "../../external/" + compiler_workspace + "/" + substitutions["{bin_subfolder}"] + "/" for binary in BINARIES: bin_substitution = dict(substitutions) bin_substitution["{binary_target}"] = binary bin_substitution["{compiler_workspace}"] = compiler_workspace repository_ctx.template( - "bin/" + binary + substitutions["{wrapper_extension}"], + "bin/" + binary + "2" + substitutions["{wrapper_extension}"], repository_ctx.path(Label("@rules_bzlmodrio_toolchains//toolchains/cross_compiler:command_wrapper.tpl")), substitutions = bin_substitution, ) + + repository_ctx.symlink(dist_rel_path + substitutions["{binary_prefix}"] + binary, "bin/" + binary + substitutions["{wrapper_extension}"],) repository_ctx.template( "BUILD.bazel",