[llvm-commits] [llvm] r78975 - in /llvm/trunk/tools: CMakeLists.txt llvm-config/CMakeLists.txt

Oscar Fuentes ofv at wanadoo.es
Thu Aug 13 18:55:06 PDT 2009


Author: ofv
Date: Thu Aug 13 20:55:05 2009
New Revision: 78975

URL: http://llvm.org/viewvc/llvm-project?rev=78975&view=rev
Log:
CMake: build llvm-config before the other tools.

Modified:
    llvm/trunk/tools/CMakeLists.txt
    llvm/trunk/tools/llvm-config/CMakeLists.txt

Modified: llvm/trunk/tools/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/CMakeLists.txt?rev=78975&r1=78974&r2=78975&view=diff

==============================================================================
--- llvm/trunk/tools/CMakeLists.txt (original)
+++ llvm/trunk/tools/CMakeLists.txt Thu Aug 13 20:55:05 2009
@@ -3,7 +3,12 @@
 # in parallel builds.  Please retain this ordering.
 
 if( NOT MSVC )
- add_subdirectory(llvm-config)
+  # It is useful to build llvm-config before the other tools, so we
+  # have a fresh LibDeps.txt for regenerating the hard-coded library
+  # dependencies. llvm-config/CMakeLists.txt takes care of this but we
+  # must keep llvm-config as the first entry on the list of tools to
+  # be built.
+  add_subdirectory(llvm-config)
 endif()
 
 add_subdirectory(opt)

Modified: llvm/trunk/tools/llvm-config/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-config/CMakeLists.txt?rev=78975&r1=78974&r2=78975&view=diff

==============================================================================
--- llvm/trunk/tools/llvm-config/CMakeLists.txt (original)
+++ llvm/trunk/tools/llvm-config/CMakeLists.txt Thu Aug 13 20:55:05 2009
@@ -113,6 +113,12 @@
 
 add_dependencies(llvm-config.target ${llvm_lib_targets})
 
+# Make sure that llvm-config builds before the llvm tools, so we have
+# LibDeps.txt and can use it for updating the hard-coded library
+# dependencies on cmake/modules/LLVMLibDeps.cmake when the tools'
+# build fail due to outdated dependencies:
+set(LLVM_COMMON_DEPENDS ${LLVM_COMMON_DEPENDS} llvm-config.target)
+
 install(FILES ${LLVM_CONFIG}
   PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE
   WORLD_READ WORLD_EXECUTE





More information about the llvm-commits mailing list