summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefileExecutableTargetGenerator.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2006-03-03 17:58:48 (GMT)
committerBrad King <brad.king@kitware.com>2006-03-03 17:58:48 (GMT)
commit93c95f1cc5207d043b4bfaa617a611d1dffc7016 (patch)
tree2fffa0b6b63b2cdf104d6425e213b076c7a84450 /Source/cmMakefileExecutableTargetGenerator.cxx
parentea8c278cd63010f00d12ded3cdde316c5188cd01 (diff)
downloadCMake-93c95f1cc5207d043b4bfaa617a611d1dffc7016.zip
CMake-93c95f1cc5207d043b4bfaa617a611d1dffc7016.tar.gz
CMake-93c95f1cc5207d043b4bfaa617a611d1dffc7016.tar.bz2
BUG: Fixed installation of MacOSX Bundle executables and the corresponding install_name remapping support. Extended the BundleTest test to check that this all works. Part of these fixes required changing the signature of AppendDirectoryForConfig in all generators. It now accepts prefix and suffix strings to deal with whether leading or trailing slashes should be included with the configuration subdirectory.
Diffstat (limited to 'Source/cmMakefileExecutableTargetGenerator.cxx')
-rw-r--r--Source/cmMakefileExecutableTargetGenerator.cxx13
1 files changed, 8 insertions, 5 deletions
diff --git a/Source/cmMakefileExecutableTargetGenerator.cxx b/Source/cmMakefileExecutableTargetGenerator.cxx
index b763349..73b1e59 100644
--- a/Source/cmMakefileExecutableTargetGenerator.cxx
+++ b/Source/cmMakefileExecutableTargetGenerator.cxx
@@ -109,7 +109,7 @@ void cmMakefileExecutableTargetGenerator::WriteExecutableRule(bool relink)
if(this->Target->GetPropertyAsBool("MACOSX_BUNDLE"))
{
// Make bundle directories
- outpath += this->Target->GetName();
+ outpath += targetName;
outpath += ".app/Contents/MacOS/";
std::string f1 =
this->Makefile->GetModulesFile("MacOSXBundleInfo.plist.in");
@@ -127,14 +127,17 @@ void cmMakefileExecutableTargetGenerator::WriteExecutableRule(bool relink)
{
macdir += "/";
}
- macdir += this->Target->GetName();
+ macdir += targetName;
macdir += ".app/Contents/";
+
+ // Configure the Info.plist file. Note that it needs the executable name
+ // to be set.
std::string f2 = macdir + "Info.plist";
macdir += "MacOS";
cmSystemTools::MakeDirectory(macdir.c_str());
- this->Makefile->AddDefinition("MACOSX_BUNDLE_EXECUTABLE_NAME", this->Target->GetName());
- this->Makefile->ConfigureFile(f1.c_str(), f2.c_str(),
- false, false, false);
+ this->Makefile->AddDefinition("MACOSX_BUNDLE_EXECUTABLE_NAME",
+ targetName.c_str());
+ this->Makefile->ConfigureFile(f1.c_str(), f2.c_str(), false, false, false);
}
#endif
if(relink)