File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed
Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change @@ -28,8 +28,20 @@ ifneq ($(wildcard $(LLVM_BUILD_DIR)/bin/llvm-config),)
2828 LLVM_SRC =$(shell cd `$(LLVM_CONFIG ) --includedir`/../..;pwd)
2929 CLANG_CXXFLAGS =-I$(LLVM_BUILD_DIR ) /tools/clang/include -I$(LLVM_SRC ) /clang/include
3030else
31- LLVM_CONFIG =llvm-config
32- CLANG_CXXFLAGS =
31+ # Allows the use of alternate named binaries
32+ ifneq ($(LLVM_CONFIG),)
33+ LLVM_CONFIG:=$(LLVM_CONFIG)
34+ else
35+ LLVM_CONFIG=llvm-config
36+ endif
37+
38+ # Allows the use of a custom LLVM prefix
39+ ifneq ($(LLVM_PREFIX),)
40+ LLVM_CONFIG:=$(LLVM_PREFIX)/$(LLVM_CONFIG)
41+ CLANG_CXXFLAGS=-I$(shell $(LLVM_CONFIG) --prefix)/tools/clang/include -I$(shell cd `$(LLVM_CONFIG) --prefix`/..;pwd)/clang/include
42+ else
43+ CLANG_CXXFLAGS=
44+ endif
3345endif
3446
3547LDFLAGS =$(shell $(LLVM_CONFIG ) --libs all --ldflags --system-libs)
You can’t perform that action at this time.
0 commit comments