From a0781b6e3a3a150818aa4c9e39e1d1c608e55fc9 Mon Sep 17 00:00:00 2001 From: Stefan Granitz Date: Thu, 13 Jun 2019 17:35:50 +0000 Subject: [PATCH] [CMake] Fix generated Xcode-project ignoring output directory setting for LLDB.framework Other generators honor the `LIBRARY_OUTPUT_DIRECTORY` target property, but apparently Xcode doesn't. So we call `set_output_directory()` as `llvm_add_library()` would do and this works. Note that `LIBRARY_OUTPUT_DIRECTORY` is still necessary, because it's used to store and read the target's absolute build directory (while `LLDB_FRAMEWORK_BUILD_DIR` is relative!). llvm-svn: 363280 --- lldb/cmake/modules/LLDBFramework.cmake | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lldb/cmake/modules/LLDBFramework.cmake b/lldb/cmake/modules/LLDBFramework.cmake index 22b5c068e694d..04f35e1951d2a 100644 --- a/lldb/cmake/modules/LLDBFramework.cmake +++ b/lldb/cmake/modules/LLDBFramework.cmake @@ -26,6 +26,12 @@ set_target_properties(liblldb PROPERTIES MACOSX_FRAMEWORK_INFO_PLIST ${LLDB_SOURCE_DIR}/resources/LLDB-Info.plist.in ) +# Defined in AddLLVM.cmake; handles edge cases for multi-config generators +set_output_directory(liblldb + BINARY_DIR ${framework_target_dir} + LIBRARY_DIR ${framework_target_dir} +) + # Affects the layout of the framework bundle (default is macOS layout). if(IOS) set_target_properties(liblldb PROPERTIES