summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalGenerator.cxx
diff options
context:
space:
mode:
authorDavid Cole <david.cole@kitware.com>2007-10-10 15:06:15 (GMT)
committerDavid Cole <david.cole@kitware.com>2007-10-10 15:06:15 (GMT)
commit8e4c7b99e1b73c641308c0177673dac33fe57df1 (patch)
treead00c757835a3ac785fd1b3e78ca3b75c2f1a354 /Source/cmGlobalGenerator.cxx
parentaa9ba5c3efcd32ea631435318f63dc476ac39798 (diff)
downloadCMake-8e4c7b99e1b73c641308c0177673dac33fe57df1.zip
CMake-8e4c7b99e1b73c641308c0177673dac33fe57df1.tar.gz
CMake-8e4c7b99e1b73c641308c0177673dac33fe57df1.tar.bz2
ENH: Finish up the Framework creation code restructuring. Frameworks build and install now. More work needed on the packaging step. See Tests/Framework for example use.
Diffstat (limited to 'Source/cmGlobalGenerator.cxx')
-rw-r--r--Source/cmGlobalGenerator.cxx22
1 files changed, 22 insertions, 0 deletions
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx
index a3b2cf3..b5323e1 100644
--- a/Source/cmGlobalGenerator.cxx
+++ b/Source/cmGlobalGenerator.cxx
@@ -1277,6 +1277,7 @@ cmLocalGenerator* cmGlobalGenerator::FindLocalGenerator(const char* start_dir)
}
+//----------------------------------------------------------------------------
cmTarget* cmGlobalGenerator::FindTarget(const char* project,
const char* name,
bool useImportedTargets)
@@ -1318,6 +1319,27 @@ cmTarget* cmGlobalGenerator::FindTarget(const char* project,
return 0;
}
+//----------------------------------------------------------------------------
+bool cmGlobalGenerator::NameResolvesToFramework(const std::string& libname)
+{
+ if(cmSystemTools::IsPathToFramework(libname.c_str()))
+ {
+ return true;
+ }
+
+ if(cmTarget* tgt = this->FindTarget(0, libname.c_str(), true))
+ {
+ if(tgt->GetType() == cmTarget::SHARED_LIBRARY &&
+ tgt->GetPropertyAsBool("FRAMEWORK"))
+ {
+ return true;
+ }
+ }
+
+ return false;
+}
+
+//----------------------------------------------------------------------------
inline std::string removeQuotes(const std::string& s)
{
if(s[0] == '\"' && s[s.size()-1] == '\"')