Skip to content

lucidsoftware/toolchains_llvm_bootstrapped_path_mapping_repro

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

toolchains_llvm_bootstrapped path mapping repro

This is a minimal repro case to demonstrate that toolchains_llvm_bootstrapped fails to compile cc targets when path mapping --experimental_output_paths=strip is enabled.

How to repro

  1. Build the following target:
bazel build //hello
  1. An error like the following will occur. It won't always be an error for libc++.a - sometimes the error is for libunwind.a, Scrt1.o, libclang_rt.builtins.a, libc++abi.a, libld.so.2, or another similar file.
ERROR: /home/redacted/.cache/bazel/_bazel_redacted/c1aba044061d2d9d86019fc7d2ccee63/external/llvm+/runtimes/libcxx/BUILD.bazel:28:13: RunBinary external/llvm+/runtimes/libcxx/libc++.a failed: (Exit 1): llvm-ar failed: error executing RunBinary command (from _run_binary rule target @@llvm+//runtimes/libcxx:c++) external/llvm++http_archive+llvm-toolchain-minimal-21.1.8-linux-amd64/bin/llvm-ar rc bazel-out/k8-fastbuild/bin/external/llvm+/runtimes/libcxx/libc++.a '--format=gnu'

Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging
external/llvm++http_archive+llvm-toolchain-minimal-21.1.8-linux-amd64/bin/llvm-ar: error: bazel-out/k8-fastbuild/bin/external/llvm+/runtimes/libcxx/libc++.a: No such file or directory
  1. Uncomment these two lines in .bazelrc
common --modify_execution_info=RunBinary=-supports-path-mapping
common --modify_execution_info=CopyToDirectory=-supports-path-mapping

Then build //hello again.

This time the build passes.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors