summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefileLibraryTargetGenerator.cxx
diff options
context:
space:
mode:
authorNicolas Despres <nicolas.despres@gmail.com>2012-07-16 14:00:40 (GMT)
committerPeter Kümmel <syntheticpp@gmx.net>2012-07-17 12:03:09 (GMT)
commit7bb56c511eaabf2071cd311b6cf14453651127e4 (patch)
treec9c9d4938652d59af72835c68dcdc1e3f51306da /Source/cmMakefileLibraryTargetGenerator.cxx
parent03bdaf545369d4438a8aece8d3cec603d3a99727 (diff)
downloadCMake-7bb56c511eaabf2071cd311b6cf14453651127e4.zip
CMake-7bb56c511eaabf2071cd311b6cf14453651127e4.tar.gz
CMake-7bb56c511eaabf2071cd311b6cf14453651127e4.tar.bz2
Re-factor CFBundle generation.
Diffstat (limited to 'Source/cmMakefileLibraryTargetGenerator.cxx')
-rw-r--r--Source/cmMakefileLibraryTargetGenerator.cxx29
1 files changed, 2 insertions, 27 deletions
diff --git a/Source/cmMakefileLibraryTargetGenerator.cxx b/Source/cmMakefileLibraryTargetGenerator.cxx
index 4331af6..a655504 100644
--- a/Source/cmMakefileLibraryTargetGenerator.cxx
+++ b/Source/cmMakefileLibraryTargetGenerator.cxx
@@ -28,11 +28,7 @@ cmMakefileLibraryTargetGenerator
cmMakefileTargetGenerator(target),
OSXBundleGenerator(0)
{
- if(this->Target->IsCFBundleOnApple())
- {
- target->SetProperty("PREFIX", "");
- target->SetProperty("SUFFIX", "");
- }
+ cmOSXBundleGenerator::PrepareTargetProperties(this->Target);
this->CustomCommandDriver = OnDepends;
this->Target->GetLibraryNames(
@@ -250,27 +246,6 @@ void cmMakefileLibraryTargetGenerator::WriteFrameworkRules(bool relink)
}
//----------------------------------------------------------------------------
-void
-cmMakefileLibraryTargetGenerator::CreateCFBundle(std::string& targetName,
- std::string& outpath)
-{
- // Compute bundle directory names.
- outpath = this->MacContentDirectory;
- outpath += "MacOS";
- cmSystemTools::MakeDirectory(outpath.c_str());
- this->Makefile->AddCMakeOutputFile(outpath.c_str());
- outpath += "/";
-
- // Configure the Info.plist file. Note that it needs the executable name
- // to be set.
- std::string plist = this->MacContentDirectory + "Info.plist";
- this->LocalGenerator->GenerateAppleInfoPList(this->Target,
- targetName.c_str(),
- plist.c_str());
- this->Makefile->AddCMakeOutputFile(plist.c_str());
-}
-
-//----------------------------------------------------------------------------
void cmMakefileLibraryTargetGenerator::WriteLibraryRules
(const char* linkRuleVar, const char* extraFlags, bool relink)
{
@@ -328,7 +303,7 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules
{
outpath = this->Target->GetDirectory(this->ConfigName);
outpath += "/";
- this->CreateCFBundle(targetName, outpath);
+ this->OSXBundleGenerator->CreateCFBundle(targetName, outpath);
}
else if(relink)
{