aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSergio Martins <iamsergio@gmail.com>2018-09-21 00:21:29 +0100
committerSergio Martins <iamsergio@gmail.com>2018-09-21 00:26:46 +0100
commit35254b62a04f1fb5d00e65fb2224aeb1561b7575 (patch)
tree7608e7816a28302677933cb287690e6a68756025
parent0476be9178919a6e9af14f3dcdf62a8219ee02b8 (diff)
Fix linking when using MSVC
the string replace was transforming the list back into a string fix is simply removing that code as it builds fine without it
-rw-r--r--CMakeLists.txt12
1 files changed, 1 insertions, 11 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 827ef476..8ba12c82 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -70,16 +70,6 @@ endif()
include(ClazySources.cmake)
-if (NOT CLAZY_BUILD_WITH_CLANG)
- if(MSVC)
- string(REPLACE "\\" "/" LLVM_LIBS ${LLVM_LIBS})
- endif()
-
- if(MSVC)
- list(REMOVE_ITEM CLANG_LIBS "-lFrontend")
- endif()
-endif()
-
include_directories(${CMAKE_BINARY_DIR})
include_directories(${CLANG_INCLUDE_DIRS} ${CMAKE_CURRENT_LIST_DIR} ${CMAKE_CURRENT_LIST_DIR}/src)
link_directories("${LLVM_INSTALL_PREFIX}/lib" ${LLVM_LIBRARY_DIRS})
@@ -100,7 +90,7 @@ macro(link_to_llvm name is_standalone)
endforeach()
foreach(llvm_lib ${LLVM_LIBS})
- if(NOT ${is_standalone} AND NOT APPLE AND NOT MINGW)
+ if(NOT ${is_standalone} AND NOT APPLE AND NOT MINGW AND NOT MSVC)
## Don't link against LLVMSupport, causes: CommandLine Error: Option 'view-background' registered more than once!
if (NOT llvm_lib MATCHES ".*LLVMSupport.*")
target_link_libraries(${name} ${llvm_lib})