From d1f714b72da1674f6f784a8a1b2a6179f103b723 Mon Sep 17 00:00:00 2001 From: Julian Büning Date: Fri, 26 Jul 2019 15:43:03 +0200 Subject: CMake: fix LLVM_DEFINITIONS with find_package() --- cmake/find_llvm.cmake | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'cmake') diff --git a/cmake/find_llvm.cmake b/cmake/find_llvm.cmake index 874bd1ae..8527221a 100644 --- a/cmake/find_llvm.cmake +++ b/cmake/find_llvm.cmake @@ -33,8 +33,14 @@ if (USE_CMAKE_FIND_PACKAGE_LLVM) llvm_map_components_to_libnames(${output_var} ${ARGN}) set(${output_var} ${${output_var}} PARENT_SCOPE) endfunction() + # HACK: This information is not exported so just pretend its OFF for now. set(LLVM_ENABLE_VISIBILITY_INLINES_HIDDEN OFF) + + # make LLVM_DEFINITIONS into proper list + set(_new_llvm_definitions "${LLVM_DEFINITIONS}") + string(REPLACE " " ";" LLVM_DEFINITIONS "${_new_llvm_definitions}") + unset(_new_llvm_definitions) else() # Use the llvm-config binary to get the information needed. # Try to detect it in the user's environment. The user can force a particular -- cgit 1.4.1