summaryrefslogtreecommitdiffstats
path: root/Source/cmProjectCommand.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmProjectCommand.cxx')
-rw-r--r--Source/cmProjectCommand.cxx18
1 files changed, 18 insertions, 0 deletions
diff --git a/Source/cmProjectCommand.cxx b/Source/cmProjectCommand.cxx
index 6e3b6af..4c1abcf 100644
--- a/Source/cmProjectCommand.cxx
+++ b/Source/cmProjectCommand.cxx
@@ -77,6 +77,24 @@ bool cmProjectCommand
languages.push_back("CXX");
}
this->Makefile->EnableLanguage(languages, false);
+ std::string extraInclude = "CMAKE_PROJECT_" + args[0] + "_INCLUDE";
+ const char* include = this->Makefile->GetDefinition(extraInclude.c_str());
+ if(include)
+ {
+ std::string fullFilePath;
+ bool readit =
+ this->Makefile->ReadListFile( this->Makefile->GetCurrentListFile(),
+ include);
+ if(!readit && !cmSystemTools::GetFatalErrorOccured())
+ {
+ std::string m =
+ "could not find load file:\n"
+ " ";
+ m += include;
+ this->SetError(m.c_str());
+ return false;
+ }
+ }
return true;
}