llvm.org GIT mirror llvm / fdc6308
[CMake] LLVMSupport should be responsible to provide system_libs. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@201077 91177308-0d34-0410-b5e6-96231b3b80d8 NAKAMURA Takumi 5 years ago
6 changed file(s) with 2 addition(s) and 28 deletion(s). Raw diff Collapse all Expand all
237237
238238 llvm_config(${name} ${ARG_LINK_COMPONENTS} ${LLVM_LINK_COMPONENTS})
239239
240 # Ensure that the system libraries always comes last on the
241 # list. Without this, linking the unit tests on MinGW fails.
242 link_system_libs( ${name} )
243
244240 if(LLVM_COMMON_DEPENDS)
245241 add_dependencies(${name} ${LLVM_COMMON_DEPENDS})
246242 endif()
329325 if( LLVM_COMMON_DEPENDS )
330326 add_dependencies( ${name} ${LLVM_COMMON_DEPENDS} )
331327 endif( LLVM_COMMON_DEPENDS )
332 link_system_libs( ${name} )
333328 endmacro(add_llvm_executable name)
334329
335330
116116 endif()
117117
118118 if( MINGW )
119 target_link_libraries(${target} imagehlp psapi shell32)
120119 if(CMAKE_SIZEOF_VOID_P MATCHES "8")
121120 set_target_properties(${target} PROPERTIES LINK_FLAGS -Wl,--stack,16777216)
122121 endif(CMAKE_SIZEOF_VOID_P MATCHES "8")
123122 endif( MINGW )
124 if( LLVM_ENABLE_THREADS AND HAVE_LIBPTHREAD AND NOT BEOS )
125 target_link_libraries(${target} pthread)
126 endif()
127
128123 if (${project} STREQUAL LLVM AND NOT LLVM_INSTALL_TOOLCHAIN_ONLY)
129124 install(TARGETS ${target}
130125 EXPORT LLVMExports
116116 Windows/TimeValue.inc
117117 Windows/Watchdog.inc
118118 )
119
120 link_system_libs(LLVMSupport)
22 )
33
44 target_link_libraries(FileCheck LLVMSupport)
5 if( MINGW )
6 target_link_libraries(FileCheck imagehlp psapi shell32)
7 endif( MINGW )
8 if( LLVM_ENABLE_THREADS AND HAVE_LIBPTHREAD )
9 target_link_libraries(FileCheck pthread)
10 endif()
22 )
33
44 target_link_libraries(FileUpdate LLVMSupport)
5 if( MINGW )
6 target_link_libraries(FileUpdate imagehlp psapi shell32)
7 endif( MINGW )
8 if( LLVM_ENABLE_THREADS AND HAVE_LIBPTHREAD )
9 target_link_libraries(FileUpdate pthread)
10 endif()
22 )
33
44 target_link_libraries(not LLVMSupport)
5 if( MINGW )
6 target_link_libraries(not imagehlp psapi shell32)
7 endif( MINGW )
8 if( LLVM_ENABLE_THREADS AND HAVE_LIBPTHREAD )
9 target_link_libraries(not pthread)
10 endif()