[Lldb-commits] [lldb] r212760 - Move the post-build step that creates lldb.py.

Zachary Turner zturner at google.com
Thu Jul 10 13:37:47 PDT 2014


Author: zturner
Date: Thu Jul 10 15:37:47 2014
New Revision: 212760

URL: http://llvm.org/viewvc/llvm-project?rev=212760&view=rev
Log:
Move the post-build step that creates lldb.py.

Being in lldb\source, ${CMAKE_CURRENT_BINARY_DIR} would resolve to
the build\tools\lldb\source directory.  For correct operation, and
parity with the shell script, it needs to resolve to the
build\tools\lldb\scripts directory.

Modified:
    lldb/trunk/scripts/CMakeLists.txt
    lldb/trunk/source/CMakeLists.txt

Modified: lldb/trunk/scripts/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/scripts/CMakeLists.txt?rev=212760&r1=212759&r2=212760&view=diff
==============================================================================
--- lldb/trunk/scripts/CMakeLists.txt (original)
+++ lldb/trunk/scripts/CMakeLists.txt Thu Jul 10 15:37:47 2014
@@ -18,6 +18,14 @@ if ( LLDB_ENABLE_PYTHON_SCRIPTS_SWIG_API
 
 	# Install the LLDB python module on all operating systems
 	install(SCRIPT lldb_python_module.cmake -DCMAKE_INSTALL_PREFIX=\"${CMAKE_INSTALL_PREFIX}\" -DCMAKE_BUILD_DIR=\"${CMAKE_BUILD_DIR}\")
+
+	# Add a Post-Build Event to copy over Python files and create the symlink to liblldb.so for the Python API(hardlink on Windows)
+	add_custom_command( TARGET liblldb
+	  POST_BUILD
+	  DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/finishSwigWrapperClasses.py
+	  DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/Python/finishSwigPythonLLDB.py
+	  COMMAND python ${CMAKE_CURRENT_SOURCE_DIR}/finishSwigWrapperClasses.py -d "--srcRoot=${LLDB_SOURCE_DIR}" "--targetDir=${CMAKE_CURRENT_BINARY_DIR}" "--cfgBldDir=${CMAKE_CURRENT_BINARY_DIR}" "--prefix=${CMAKE_BINARY_DIR}" "--cmakeBuildConfiguration=${CMAKE_CFG_INTDIR}" -m
+	  COMMENT "Python script sym-linking LLDB Python API")
 else ()
 	add_custom_command(
 	  OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/LLDBWrapPython.cpp

Modified: lldb/trunk/source/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/CMakeLists.txt?rev=212760&r1=212759&r2=212760&view=diff
==============================================================================
--- lldb/trunk/source/CMakeLists.txt (original)
+++ lldb/trunk/source/CMakeLists.txt Thu Jul 10 15:37:47 2014
@@ -327,16 +327,6 @@ endif ()
 # FIXME: implement svn/git revision and repository parsing solution on Windows. There is an SVN-only
 #        revision parsing solution in tools/clang/lib/Basic/CMakelists.txt.
 
-if ( LLDB_ENABLE_PYTHON_SCRIPTS_SWIG_API_GENERATION )
-	# Add a Post-Build Event to copy over Python files and create the symlink to liblldb.so for the Python API(hardlink on Windows)
-	if ( NOT LLDB_DISABLE_PYTHON )
-	add_custom_command( TARGET liblldb
-	    POST_BUILD
-	    COMMAND python ${CMAKE_CURRENT_SOURCE_DIR}/../scripts/finishSwigWrapperClasses.py "--srcRoot=${LLDB_SOURCE_DIR}" "--targetDir=${CMAKE_CURRENT_BINARY_DIR}" "--cfgBldDir=${CMAKE_CURRENT_BINARY_DIR}" "--prefix=${CMAKE_BINARY_DIR}" "--cmakeBuildConfiguration=${CMAKE_CFG_INTDIR}" -m
-	    COMMENT "Python script sym-linking LLDB Python API")
-	endif ()
-endif ()
-
 install(TARGETS liblldb
   RUNTIME DESTINATION bin
   LIBRARY DESTINATION lib





More information about the lldb-commits mailing list