llvm.org GIT mirror llvm / 674e504
[CMake] Add LLVM_EXTERNALIZE_DEBUGINFO_OUTPUT_DIR for custom dSYM target directory on Darwin Summary: When using `LLVM_EXTERNALIZE_DEBUGINFO` in LLDB, the default dSYM location for the shared library in LLDB.framework is inside the framework bundle. With `LLVM_EXTERNALIZE_DEBUGINFO_OUTPUT_DIR` we can easily fix that. I consider it a useful feature to be able to set a global output directory for external debug info (rather then having a target-specific one). Only implemented for Darwin so far. Reviewers: beanz, aprantl Reviewed By: aprantl Subscribers: mgorny, aprantl, #lldb, lldb-commits, llvm-commits Differential Revision: https://reviews.llvm.org/D55114 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@348118 91177308-0d34-0410-b5e6-96231b3b80d8 Stefan Granitz 10 months ago
1 changed file(s) with 8 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
15961596 endif()
15971597 endif()
15981598
1599 if(LLVM_EXTERNALIZE_DEBUGINFO_OUTPUT_DIR)
1600 if(APPLE)
1601 set(output_name "$.dSYM")
1602 set(output_path "-o=${LLVM_EXTERNALIZE_DEBUGINFO_OUTPUT_DIR}/${output_name}")
1603 endif()
1604 endif()
1605
15991606 if(APPLE)
16001607 if(CMAKE_CXX_FLAGS MATCHES "-flto"
16011608 OR CMAKE_CXX_FLAGS_${uppercase_CMAKE_BUILD_TYPE} MATCHES "-flto")
16081615 set(CMAKE_DSYMUTIL xcrun dsymutil)
16091616 endif()
16101617 add_custom_command(TARGET ${name} POST_BUILD
1611 COMMAND ${CMAKE_DSYMUTIL} $
1618 COMMAND ${CMAKE_DSYMUTIL} ${output_path} $
16121619 ${strip_command}
16131620 )
16141621 else()