diff options
author | Oscar Fuentes <ofv@wanadoo.es> | 2011-02-14 20:14:11 +0000 |
---|---|---|
committer | Oscar Fuentes <ofv@wanadoo.es> | 2011-02-14 20:14:11 +0000 |
commit | b641f08cbee230ce872b37816d241cef081af803 (patch) | |
tree | 75f63603225a6c0be649677479fe5fd99ee0bb64 | |
parent | 6173ef4a0a204f9627ece97573f2e95017f04547 (diff) |
Add current binary and source directories to the header search list
for all compiler invocations.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125514 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | CMakeLists.txt | 1 | ||||
-rw-r--r-- | lib/StaticAnalyzer/Checkers/CMakeLists.txt | 4 |
2 files changed, 1 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 4189739521..fb5933fd95 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -38,6 +38,7 @@ if( CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR ) set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") set(LLVM_BINARY_DIR ${CMAKE_BINARY_DIR}) + set(CMAKE_INCLUDE_CURRENT_DIR ON) include_directories("${PATH_TO_LLVM_BUILD}/include" "${LLVM_MAIN_INCLUDE_DIR}") if( NOT PATH_TO_LLVM_BUILD STREQUAL LLVM_MAIN_SRC_DIR ) include_directories("${LLVM_MAIN_INCLUDE_DIR}") diff --git a/lib/StaticAnalyzer/Checkers/CMakeLists.txt b/lib/StaticAnalyzer/Checkers/CMakeLists.txt index c96b42db1e..8c1f91f0c2 100644 --- a/lib/StaticAnalyzer/Checkers/CMakeLists.txt +++ b/lib/StaticAnalyzer/Checkers/CMakeLists.txt @@ -5,10 +5,6 @@ tablegen(Checkers.inc add_custom_target(ClangSACheckers DEPENDS Checkers.inc) -# So 'Checkers.inc' can be included from the cmake build directory. -# FIXME: Someone more familiar with cmake should enable this for all of LLVM. -set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -I ${CMAKE_CURRENT_BINARY_DIR}") - set(LLVM_USED_LIBS clangBasic clangAST) add_clang_library(clangStaticAnalyzerCheckers |