diff options
author | Brad King <brad.king@kitware.com> | 2022-10-28 13:52:21 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2022-10-28 13:52:36 (GMT) |
commit | 5d12374b512fe9d69e4cf4eafdad4ea5c441e899 (patch) | |
tree | 01cd6da601fad79665fe11590b8ae8d6f8f6f5fe | |
parent | 37156dc47ab1b3389a2c95ec9d0e4075d9eb889d (diff) | |
parent | 8d5631f0d0cc96850011ebdd05ede2d8de477405 (diff) | |
download | CMake-5d12374b512fe9d69e4cf4eafdad4ea5c441e899.zip CMake-5d12374b512fe9d69e4cf4eafdad4ea5c441e899.tar.gz CMake-5d12374b512fe9d69e4cf4eafdad4ea5c441e899.tar.bz2 |
Merge topic 'xcode-restore-install-path' into release-3.25
8d5631f0d0 Xcode: Revert "Don't set INSTALL_PATH unless target is SHARED_LIBRARY"
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7839
-rw-r--r-- | Source/cmGlobalXCodeGenerator.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx index 6328d29..dd470f8 100644 --- a/Source/cmGlobalXCodeGenerator.cxx +++ b/Source/cmGlobalXCodeGenerator.cxx @@ -2915,8 +2915,8 @@ void cmGlobalXCodeGenerator::CreateBuildSettings(cmGeneratorTarget* gtgt, } // Create the INSTALL_PATH attribute. + std::string install_name_dir; if (gtgt->GetType() == cmStateEnums::SHARED_LIBRARY) { - std::string install_name_dir; // Get the install_name directory for the build tree. install_name_dir = gtgt->GetInstallNameDirForBuildTree(configName); // Xcode doesn't create the correct install_name in some cases. @@ -2938,9 +2938,9 @@ void cmGlobalXCodeGenerator::CreateBuildSettings(cmGeneratorTarget* gtgt, extraLinkOptions += " -install_name "; extraLinkOptions += XCodeEscapePath(install_name); } - buildSettings->AddAttribute("INSTALL_PATH", - this->CreateString(install_name_dir)); } + buildSettings->AddAttribute("INSTALL_PATH", + this->CreateString(install_name_dir)); // Create the LD_RUNPATH_SEARCH_PATHS cmComputeLinkInformation* pcli = gtgt->GetLinkInformation(configName); |