Skip to content

Commit 8349c95

Browse files
fmeumcopybara-github
authored andcommitted
Also collect clang resource directory with -no-canonical-prefixes
`clang -print-resource-dir` without `-no-canonical-prefixes` returns a different path than is actually used to include `asan_blacklist.txt` on macOS with non-Apple clang. Closes bazelbuild#16730. PiperOrigin-RevId: 489475662 Change-Id: If17f347d76f86e0ec5804f9e8789f44f46ab27b4
1 parent 66c22f4 commit 8349c95

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/cpp/unix_cc_configure.bzl

+1-1
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ def _get_cxx_include_directories(repository_ctx, cc, lang_flag, additional_flags
143143

144144
if _is_compiler_option_supported(repository_ctx, cc, "-print-resource-dir"):
145145
resource_dir = repository_ctx.execute(
146-
[cc, "-print-resource-dir"],
146+
[cc, "-print-resource-dir"] + additional_flags,
147147
).stdout.strip() + "/share"
148148
inc_directories.append(_prepare_include_path(repository_ctx, resource_dir))
149149

0 commit comments

Comments
 (0)