Windows build fixes, hopefully last part.
authorNico Weber <nicolasweber@gmx.de>
Sun, 29 Dec 2013 06:56:28 +0000 (06:56 +0000)
committerNico Weber <nicolasweber@gmx.de>
Sun, 29 Dec 2013 06:56:28 +0000 (06:56 +0000)
r198153 fixed the msvs bot problem, but broke a msysgit bot. This change
hopefully makes both variants happy.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@198156 91177308-0d34-0410-b5e6-96231b3b80d8

cmake/modules/AddLLVM.cmake

index 404bc38a6ab7e23a44d8b8cb22fd49c02ce76886..0933a02a015b3272eea2c25d97e3a824b4116683 100644 (file)
@@ -44,8 +44,13 @@ function(add_llvm_symbol_exports target_name export_file)
       DEPENDS ${export_file}
       VERBATIM
       COMMENT "Creating export file for ${target_name}")
-    set_property(TARGET ${target_name} APPEND_STRING PROPERTY
-                 LINK_FLAGS "/DEF:${CMAKE_CURRENT_BINARY_DIR}/symbol.def")
+    if(CYGWIN)
+      set_property(TARGET ${target_name} APPEND_STRING PROPERTY
+                   LINK_FLAGS "${CMAKE_CURRENT_BINARY_DIR}/symbol.def")
+    else()
+      set_property(TARGET ${target_name} APPEND_STRING PROPERTY
+                   LINK_FLAGS "/DEF:${CMAKE_CURRENT_BINARY_DIR}/symbol.def")
+    endif()
   endif()
 
   add_custom_target(${target_name}_exports DEPENDS ${native_export_file})