[llvm-commits] [polly] r153439 - /polly/trunk/CMakeLists.txt

Hongbin Zheng etherzhhb at gmail.com
Mon Mar 26 08:16:29 PDT 2012


Author: ether
Date: Mon Mar 26 10:16:29 2012
New Revision: 153439

URL: http://llvm.org/viewvc/llvm-project?rev=153439&view=rev
Log:
Out-of-tree build: Load the configuration of the installed llvm.

Modified:
    polly/trunk/CMakeLists.txt

Modified: polly/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/CMakeLists.txt?rev=153439&r1=153438&r2=153439&view=diff
==============================================================================
--- polly/trunk/CMakeLists.txt (original)
+++ polly/trunk/CMakeLists.txt Mon Mar 26 10:16:29 2012
@@ -20,23 +20,8 @@
   # Add the llvm header path.
   include_directories(${LLVM_INSTALL_ROOT}/include/)
 
-  # Get the system librarys that will link into LLVM.
-  function(get_system_libs return_var)
-    # Returns in `return_var' a list of system libraries used by LLVM.
-    if( NOT MSVC )
-      if( MINGW )
-        set(system_libs ${system_libs} imagehlp psapi)
-      elseif( CMAKE_HOST_UNIX )
-        if( HAVE_LIBDL )
-          set(system_libs ${system_libs} ${CMAKE_DL_LIBS})
-        endif()
-        if( LLVM_ENABLE_THREADS AND HAVE_LIBPTHREAD )
-          set(system_libs ${system_libs} pthread)
-        endif()
-      endif( MINGW )
-    endif( NOT MSVC )
-    set(${return_var} ${system_libs} PARENT_SCOPE)
-  endfunction(get_system_libs)
+  # Load the configuration of the installed llvm.
+  include(${LLVM_INSTALL_ROOT}/share/llvm/cmake/LLVMConfig.cmake)
 
   # Now set the header paths.
   execute_process(COMMAND "${LLVM_INSTALL_ROOT}/bin/llvm-config" --includedir





More information about the llvm-commits mailing list