summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2009-09-23 18:10:08 (GMT)
committerBrad King <brad.king@kitware.com>2009-09-23 18:10:08 (GMT)
commitbd33da9fccf209f9f7f23b00db4b7305caab32a0 (patch)
tree2f70d5e94c8aa469e5a29db0762c6864320ee917
parent8ffc8147e07b67e484b235760ea5c6f0b8b21756 (diff)
downloadCMake-bd33da9fccf209f9f7f23b00db4b7305caab32a0.zip
CMake-bd33da9fccf209f9f7f23b00db4b7305caab32a0.tar.gz
CMake-bd33da9fccf209f9f7f23b00db4b7305caab32a0.tar.bz2
Add Xcode SYMROOT setting for custom targets
Xcode 1.5 writes helper scripts at the projectDirPath location for targets that do not set SYMROOT. We now add SYMROOT to custom targets so that all targets set it. This prevents Xcode 1.5 from touching the source directory now that we always set projectDirPath. See issue #8481.
-rw-r--r--Source/cmGlobalXCodeGenerator.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx
index e695749..2603c0d 100644
--- a/Source/cmGlobalXCodeGenerator.cxx
+++ b/Source/cmGlobalXCodeGenerator.cxx
@@ -1531,19 +1531,20 @@ void cmGlobalXCodeGenerator::CreateBuildSettings(cmTarget& target,
this->CreateString(pnbase.c_str()));
// Set attributes to specify the proper name for the target.
+ std::string pndir = this->CurrentMakefile->GetCurrentOutputDirectory();
if(target.GetType() == cmTarget::STATIC_LIBRARY ||
target.GetType() == cmTarget::SHARED_LIBRARY ||
target.GetType() == cmTarget::MODULE_LIBRARY ||
target.GetType() == cmTarget::EXECUTABLE)
{
- std::string pndir = target.GetDirectory();
- buildSettings->AddAttribute("SYMROOT",
- this->CreateString(pndir.c_str()));
+ pndir = target.GetDirectory();
buildSettings->AddAttribute("EXECUTABLE_PREFIX",
this->CreateString(pnprefix.c_str()));
buildSettings->AddAttribute("EXECUTABLE_SUFFIX",
this->CreateString(pnsuffix.c_str()));
}
+ buildSettings->AddAttribute("SYMROOT",
+ this->CreateString(pndir.c_str()));
// Handle settings for each target type.
switch(target.GetType())