[compiler-rt] r220517 - Do not set linker flags for MSVC; they are not the same thing as compiler flags. Note, this is already done in the add_compiler_rt_test test_suite function.
Aaron Ballman
aaron at aaronballman.com
Thu Oct 23 14:58:36 PDT 2014
Author: aaronballman
Date: Thu Oct 23 16:58:36 2014
New Revision: 220517
URL: http://llvm.org/viewvc/llvm-project?rev=220517&view=rev
Log:
Do not set linker flags for MSVC; they are not the same thing as compiler flags. Note, this is already done in the add_compiler_rt_test test_suite function.
Modified:
compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake
Modified: compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake?rev=220517&r1=220516&r2=220517&view=diff
==============================================================================
--- compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake (original)
+++ compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake Thu Oct 23 16:58:36 2014
@@ -52,8 +52,12 @@ macro(add_compiler_rt_runtime name arch
# Setup compile flags and definitions.
set_target_compile_flags(${name}
${TARGET_${arch}_CFLAGS} ${LIB_CFLAGS})
- set_target_link_flags(${name}
- ${TARGET_${arch}_CFLAGS} ${LIB_CFLAGS})
+ if (NOT MSVC)
+ # We do not want any custom link flags set on MSVC; especially not the
+ # compiler flags, as with other compilers.
+ set_target_link_flags(${name}
+ ${TARGET_${arch}_CFLAGS} ${LIB_CFLAGS})
+ endif()
set_property(TARGET ${name} APPEND PROPERTY
COMPILE_DEFINITIONS ${LIB_DEFS})
# Setup correct output directory in the build tree.
More information about the llvm-commits
mailing list