Author: Haibo Huang Date: 2019-11-05T13:25:38-08:00 New Revision: 6a79e083a0d131e741ac8f48badbb0481491e47f
URL: https://github.com/llvm/llvm-project/commit/6a79e083a0d131e741ac8f48badbb0481491e47f DIFF: https://github.com/llvm/llvm-project/commit/6a79e083a0d131e741ac8f48badbb0481491e47f.diff LOG: [lldb] Add a install target for lldb python on darwin Summary: Similar to D68370 but for darwin framework build. Reviewers: aadsm Subscribers: mgorny, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D69834 Added: Modified: lldb/CMakeLists.txt Removed: ################################################################################ diff --git a/lldb/CMakeLists.txt b/lldb/CMakeLists.txt index 388bcf76e662..128130621ba0 100644 --- a/lldb/CMakeLists.txt +++ b/lldb/CMakeLists.txt @@ -216,18 +216,21 @@ if (NOT LLDB_DISABLE_PYTHON) # Ensure we do the python post-build step when building lldb. add_dependencies(lldb finish_swig) - if(NOT LLDB_BUILD_FRAMEWORK) - # Install the LLDB python module - add_custom_target(lldb-python-scripts) - add_dependencies(lldb-python-scripts finish_swig) - install(DIRECTORY ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${LLDB_PYTHON_RELATIVE_PATH}/ - DESTINATION ${LLDB_PYTHON_RELATIVE_PATH} - COMPONENT lldb-python-scripts) - if (NOT LLVM_ENABLE_IDE) - add_llvm_install_targets(install-lldb-python-scripts - COMPONENT lldb-python-scripts - DEPENDS lldb-python-scripts) - endif() + # Install the LLDB python module + if(LLDB_BUILD_FRAMEWORK) + set(LLDB_PYTHON_INSTALL_PATH ${LLDB_FRAMEWORK_INSTALL_DIR}/LLDB.framework/Resources/Python) + else() + set(LLDB_PYTHON_INSTALL_PATH ${LLDB_PYTHON_RELATIVE_PATH}) + endif() + add_custom_target(lldb-python-scripts) + add_dependencies(lldb-python-scripts finish_swig) + install(DIRECTORY ${lldb_python_build_path}/../ + DESTINATION ${LLDB_PYTHON_INSTALL_PATH} + COMPONENT lldb-python-scripts) + if (NOT LLVM_ENABLE_IDE) + add_llvm_install_targets(install-lldb-python-scripts + COMPONENT lldb-python-scripts + DEPENDS lldb-python-scripts) endif() # Add a Post-Build Event to copy the custom Python DLL to the lldb binaries dir so that Windows can find it when launching _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits