aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/util/c++/clang.cpp
diff options
context:
space:
mode:
authorWang Nan <[email protected]>2016-11-26 07:03:31 +0000
committerArnaldo Carvalho de Melo <[email protected]>2016-12-05 15:51:42 -0300
commitcb40d55b595cd117ef7c1880247605875b2115e8 (patch)
treed5ba1a94d6f7d451f95e70feb17b93a7d5da65b0 /tools/perf/util/c++/clang.cpp
parent2bd42de0e196f89994cbae1990d2c7c5a9b6a529 (diff)
tools build: Add feature detection for LLVM
Check if basic LLVM compiling environment is ready. Use llvm-config to detect include and library directories. Avoid using 'llvm-config --cxxflags' because its result contain some unwanted flags like --sysroot (if LLVM is built by yocto). Use '?=' to set LLVM_CONFIG, so explicitly passing LLVM_CONFIG to make would override it. Use 'llvm-config --libs BPF' to check if BPF backend is compiled in. Since now BPF bytecode is the only required backend, no need to waste time linking llvm and clang if BPF backend is missing. This also introduce an implicit requirement that LLVM should be new enough. Old LLVM doesn't support BPF backend. Signed-off-by: Wang Nan <[email protected]> Cc: Alexei Starovoitov <[email protected]> Cc: He Kuang <[email protected]> Cc: Jiri Olsa <[email protected]> Cc: Joe Stringer <[email protected]> Cc: Zefan Li <[email protected]> Cc: [email protected] Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
Diffstat (limited to 'tools/perf/util/c++/clang.cpp')
0 files changed, 0 insertions, 0 deletions