Skip to content

Commit 99dd2c6

Browse files
committed
use a symlink instead of replacing
1 parent cc619c7 commit 99dd2c6

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

clang_tidy/clang_tidy_test.bzl

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ load(":clang_tidy.bzl", "deps_flags", "is_c_translation_unit", "rule_sources", "
77
# Tests run with a different directory structure than normal compiles. This
88
# fixes up include paths or any other arguments that are sensitive to this
99
def _fix_argument_path(ctx, arg):
10-
return arg.replace(ctx.bin_dir.path, ".").replace("external/", "../")
10+
return arg.replace(ctx.bin_dir.path, ".")
1111

1212
def _get_copts_attr(ctx, copts_attr):
1313
copts = []
@@ -53,6 +53,8 @@ if [[ ! -f .clang-tidy ]]; then
5353
exit 1
5454
fi
5555
56+
ln -s .. external
57+
5658
has_srcs=false
5759
if [[ -n "{c_sources}" ]]; then
5860
"$bin" --quiet {c_sources} -- {c_flags}

0 commit comments

Comments
 (0)