Skip to content

Commit a7a713a

Browse files
committed
[scan-build-py] use explicit compiler wrapper paths for intercept
1 parent 66d1c37 commit a7a713a

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

clang/tools/scan-build-py/lib/libscanbuild/intercept.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,11 @@
4646
RS = chr(0x1E)
4747
US = chr(0x1F)
4848

49-
COMPILER_WRAPPER_CC = "intercept-cc"
50-
COMPILER_WRAPPER_CXX = "intercept-c++"
49+
scanbuild_dir = os.path.dirname(os.path.realpath(__import__("sys").argv[0]))
50+
51+
COMPILER_WRAPPER_CC = os.path.join(scanbuild_dir, "..", "libexec", "intercept-cc")
52+
COMPILER_WRAPPER_CXX = os.path.join(scanbuild_dir, "..", "libexec", "intercept-c++")
53+
5154
TRACE_FILE_EXTENSION = ".cmd" # same as in ear.c
5255
WRAPPER_ONLY_PLATFORMS = frozenset({"win32", "cygwin"})
5356

0 commit comments

Comments
 (0)