[cfe-commits] r128483 - /cfe/trunk/CMakeLists.txt

Oscar Fuentes ofv at wanadoo.es
Tue Mar 29 13:51:00 PDT 2011


Author: ofv
Date: Tue Mar 29 15:51:00 2011
New Revision: 128483

URL: http://llvm.org/viewvc/llvm-project?rev=128483&view=rev
Log:
CMake: removed some unnecesary conditionals from add_clang_library.

Modified:
    cfe/trunk/CMakeLists.txt

Modified: cfe/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/CMakeLists.txt?rev=128483&r1=128482&r2=128483&view=diff
==============================================================================
--- cfe/trunk/CMakeLists.txt (original)
+++ cfe/trunk/CMakeLists.txt Tue Mar 29 15:51:00 2011
@@ -171,21 +171,12 @@
   if( LLVM_COMMON_DEPENDS )
     add_dependencies( ${name} ${LLVM_COMMON_DEPENDS} )
   endif( LLVM_COMMON_DEPENDS )
-  if( LLVM_USED_LIBS )
-    foreach(lib ${LLVM_USED_LIBS})
-      target_link_libraries( ${name} ${lib} )
-    endforeach(lib)
-  endif( LLVM_USED_LIBS )
-  if( LLVM_LINK_COMPONENTS )
-    llvm_config(${name} ${LLVM_LINK_COMPONENTS})
-  endif( LLVM_LINK_COMPONENTS )
-  if (LLVM_COMMON_LIBS)
-    target_link_libraries(${name} ${LLVM_COMMON_LIBS})
-  endif()
-  get_system_libs(llvm_system_libs)
-  if( llvm_system_libs )
-    target_link_libraries(${name} ${llvm_system_libs})
-  endif()
+
+  target_link_libraries( ${name} ${LLVM_USED_LIBS} )
+  llvm_config( ${name} ${LLVM_LINK_COMPONENTS} )
+  target_link_libraries( ${name} ${LLVM_COMMON_LIBS} )
+  link_system_libs( ${name} )
+
   add_dependencies(${name} ClangDiagnosticCommon)
   if(MSVC)
     get_target_property(cflag ${name} COMPILE_FLAGS)





More information about the cfe-commits mailing list