Implement -Dbuiltin_cling=Off

Cling needs to be built and installed as part of llvm/clang and
then we need to specify paths as we do for builtin_clang=Off.
This commit is contained in:
Vassil Vassilev 2020-09-10 07:09:53 +00:00 committed by jenkins
parent 45002e650d
commit cad5c25c17
2 changed files with 4 additions and 29 deletions

View File

@ -330,6 +330,8 @@ macro(set_cling_windows_version_resource_properties name)
endif()
endmacro()
include_directories(BEFORE ${LLVM_INCLUDE_DIRS} ${CLANG_INCLUDE_DIRS})
macro(add_cling_library name)
cmake_parse_arguments(ARG
"SHARED"
@ -447,28 +449,6 @@ endmacro(add_cling_executable)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
option(ROOT_CLASSIC "Building as part of the ROOT (classic)." OFF)
if(DEFINED ROOT_BINARY_DIR)
# Building as part of ROOT (CMake)
include_directories(BEFORE
${CMAKE_BINARY_DIR}/interpreter/llvm/src/tools/clang/include
${CMAKE_SOURCE_DIR}/interpreter/llvm/src/tools/clang/include
)
elseif(ROOT_CLASSIC)
# Building as part of ROOT (classic)
include_directories(BEFORE
${CMAKE_CURRENT_BINARY_DIR}/../llvm/obj/tools/clang/include
${CMAKE_CURRENT_SOURCE_DIR}/../llvm/src/tools/clang/include
)
else()
# and this when building Cling standalone:
include_directories(BEFORE
${CMAKE_CURRENT_BINARY_DIR}/../clang/include
${CMAKE_CURRENT_SOURCE_DIR}/../clang/include
)
endif()
include_directories(BEFORE
${CMAKE_CURRENT_BINARY_DIR}/include
${CMAKE_CURRENT_SOURCE_DIR}/include

View File

@ -6,7 +6,8 @@
# LICENSE.TXT for details.
#------------------------------------------------------------------------------
set(CLING_DEPEND_LIBS
set(LIBS
clingUtils
clangCodeGen
clangDriver
clangFrontend
@ -20,11 +21,6 @@ set(CLING_DEPEND_LIBS
clangAST
clangBasic
clangLex
CACHE STRING "Dependency Clang libraries for Cling"
)
set(LIBS
clingUtils
)
set(LLVM_LINK_COMPONENTS
@ -103,7 +99,6 @@ add_cling_library(clingInterpreter OBJECT
${CLING_DEPENDS}
LINK_LIBS
${CLING_DEPEND_LIBS}
${LIBS}
${CMAKE_DL_LIBS}
)