summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalXCodeGenerator.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2008-02-14 20:31:08 (GMT)
committerBrad King <brad.king@kitware.com>2008-02-14 20:31:08 (GMT)
commit67f8c0fd104fe6ec1b6c1df2ebce6fdb9b2c811f (patch)
tree6b51fadf24500dea382988525e51e9c0e6d449bb /Source/cmGlobalXCodeGenerator.cxx
parent7b1c305d864977a524e21b7b837a8582eb487d7c (diff)
downloadCMake-67f8c0fd104fe6ec1b6c1df2ebce6fdb9b2c811f.zip
CMake-67f8c0fd104fe6ec1b6c1df2ebce6fdb9b2c811f.tar.gz
CMake-67f8c0fd104fe6ec1b6c1df2ebce6fdb9b2c811f.tar.bz2
ENH: Allow multiple OS X applications bundles to be created in a single build directory. Converted Info.plist files to be generated directly instead of configured with make variables. The MACOSX_BUNDLE_* variables are now properties (and vars for compatibility).
Diffstat (limited to 'Source/cmGlobalXCodeGenerator.cxx')
-rw-r--r--Source/cmGlobalXCodeGenerator.cxx21
1 files changed, 9 insertions, 12 deletions
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx
index c2b0558..de62e8f 100644
--- a/Source/cmGlobalXCodeGenerator.cxx
+++ b/Source/cmGlobalXCodeGenerator.cxx
@@ -1482,18 +1482,15 @@ void cmGlobalXCodeGenerator::CreateBuildSettings(cmTarget& target,
if(target.GetPropertyAsBool("MACOSX_BUNDLE"))
{
productType = "com.apple.product-type.application";
- std::string f1 =
- this->CurrentMakefile->GetModulesFile("MacOSXBundleInfo.plist.in");
- if ( f1.size() == 0 )
- {
- cmSystemTools::Error("could not find Mac OSX bundle template file.");
- }
- std::string f2 = this->CurrentMakefile->GetCurrentOutputDirectory();
- f2 += "/Info.plist";
- this->CurrentMakefile->ConfigureFile(f1.c_str(), f2.c_str(),
- false, false, false);
- std::string path =
- this->ConvertToRelativeForXCode(f2.c_str());
+ std::string plist = this->CurrentMakefile->GetCurrentOutputDirectory();
+ plist += cmake::GetCMakeFilesDirectory();
+ plist += "/";
+ plist += target.GetName();
+ plist += "Info.plist";
+ this->CurrentLocalGenerator
+ ->GenerateAppleInfoPList(&target, productName.c_str(), plist.c_str());
+ std::string path =
+ this->ConvertToRelativeForXCode(plist.c_str());
buildSettings->AddAttribute("INFOPLIST_FILE",
this->CreateString(path.c_str()));