Skip to content

Toolchain is incompatible with --experimental_sibling_repository_layout flag #226

@pikinier20

Description

@pikinier20

I've prepared a small repro for the issue:

https://github.com/pikinier20/hermetic_cc_toolchain_repro

Basically, the issue is described properly by the title. Trying to build the target with the flag enabled leads to error:

ERROR: /Volumes/LMP_2TB/work/bazel_hermetic_cc_toolchain_test/BUILD.bazel:1:10: Compiling hello_world.cc failed: absolute path inclusion(s) found in rule '//:hello_world':
the source file 'hello_world.cc' includes the following non-builtin files with absolute paths (if these are builtin files, make sure these paths are in your toolchain):
  '/private/var/tmp/_bazel_fzybala/096f4fcdb4de284ed2c5a33ed1889d5a/sandbox/darwin-sandbox/4/execroot/hermetic_cc_toolchain++toolchains+zig_sdk/lib/libcxx/include/iostream'
  '/private/var/tmp/_bazel_fzybala/096f4fcdb4de284ed2c5a33ed1889d5a/sandbox/darwin-sandbox/4/execroot/hermetic_cc_toolchain++toolchains+zig_sdk/lib/libcxx/include/__assert'
  '/private/var/tmp/_bazel_fzybala/096f4fcdb4de284ed2c5a33ed1889d5a/sandbox/darwin-sandbox/4/execroot/hermetic_cc_toolchain++toolchains+zig_sdk/lib/libcxx/include/__config'
  '/private/var/tmp/_bazel_fzybala/096f4fcdb4de284ed2c5a33ed1889d5a/sandbox/darwin-sandbox/4/execroot/hermetic_cc_toolchain++toolchains+zig_sdk/lib/libcxx/include/__verbose_abort'
  '/private/var/tmp/_bazel_fzybala/096f4fcdb4de284ed2c5a33ed1889d5a/sandbox/darwin-sandbox/4/execroot/hermetic_cc_toolchain++toolchains+zig_sdk/lib/libcxx/include/__availability'
  '/private/var/tmp/_bazel_fzybala/096f4fcdb4de284ed2c5a33ed1889d5a/sandbox/darwin-sandbox/4/execroot/hermetic_cc_toolchain++toolchains+zig_sdk/lib/libcxx/include/version'
  '/private/var/tmp/_bazel_fzybala/096f4fcdb4de284ed2c5a33ed1889d5a/sandbox/darwin-sandbox/4/execroot/hermetic_cc_toolchain++toolchains+zig_sdk/lib/libcxx/include/ios'
...

removing the flag fixes the problem

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions