diff options
author | Sebastian Holtermann <sebholt@xwmw.org> | 2016-12-27 18:03:14 (GMT) |
---|---|---|
committer | Sebastian Holtermann <sebholt@xwmw.org> | 2017-01-10 11:49:14 (GMT) |
commit | d51cc88e844c78c01c1616e6a2fb102c0682dd00 (patch) | |
tree | bef37f17d1d42e53026d15b373974735b5176776 | |
parent | cf1d5a9cdba49a2e9f08879d756ae118b22bfc6a (diff) | |
download | CMake-d51cc88e844c78c01c1616e6a2fb102c0682dd00.zip CMake-d51cc88e844c78c01c1616e6a2fb102c0682dd00.tar.gz CMake-d51cc88e844c78c01c1616e6a2fb102c0682dd00.tar.bz2 |
AUTOGEN: Generators: Split config headers/sources into vector
-rw-r--r-- | Source/cmQtAutoGenerators.cxx | 23 | ||||
-rw-r--r-- | Source/cmQtAutoGenerators.h | 4 |
2 files changed, 12 insertions, 15 deletions
diff --git a/Source/cmQtAutoGenerators.cxx b/Source/cmQtAutoGenerators.cxx index f2f1505..5a370fe 100644 --- a/Source/cmQtAutoGenerators.cxx +++ b/Source/cmQtAutoGenerators.cxx @@ -221,8 +221,10 @@ bool cmQtAutoGenerators::ReadAutogenInfoFile( this->RccExecutable = makefile->GetSafeDefinition("AM_QT_RCC_EXECUTABLE"); // - File Lists - this->Sources = makefile->GetSafeDefinition("AM_SOURCES"); - this->Headers = makefile->GetSafeDefinition("AM_HEADERS"); + cmSystemTools::ExpandListArgument(makefile->GetSafeDefinition("AM_SOURCES"), + this->Sources); + cmSystemTools::ExpandListArgument(makefile->GetSafeDefinition("AM_HEADERS"), + this->Headers); // - Moc this->SkipMoc = makefile->GetSafeDefinition("AM_SKIP_MOC"); @@ -501,9 +503,6 @@ bool cmQtAutoGenerators::RunAutogen(cmMakefile* makefile) // collect all headers which may need to be mocced std::set<std::string> headerFiles; - std::vector<std::string> sourceFiles; - cmSystemTools::ExpandListArgument(this->Sources, sourceFiles); - const std::vector<std::string>& headerExtensions = makefile->GetCMakeInstance()->GetHeaderExtensions(); @@ -512,13 +511,13 @@ bool cmQtAutoGenerators::RunAutogen(cmMakefile* makefile) std::vector<std::string> uicSkipped; cmSystemTools::ExpandListArgument(this->SkipUic, uicSkipped); - for (std::vector<std::string>::const_iterator it = sourceFiles.begin(); - it != sourceFiles.end(); ++it) { - const bool skipUic = - std::find(uicSkipped.begin(), uicSkipped.end(), *it) != uicSkipped.end(); + for (std::vector<std::string>::const_iterator it = this->Sources.begin(); + it != this->Sources.end(); ++it) { + const std::string& absFilename = *it; + const bool skipUic = std::find(uicSkipped.begin(), uicSkipped.end(), + absFilename) != uicSkipped.end(); std::map<std::string, std::vector<std::string> >& uiFiles = skipUic ? skippedUis : includedUis; - const std::string& absFilename = *it; if (this->Verbose) { std::ostringstream err; err << "AUTOGEN: Checking " << absFilename << std::endl; @@ -551,9 +550,7 @@ bool cmQtAutoGenerators::RunAutogen(cmMakefile* makefile) } } - std::vector<std::string> headerFilesVec; - cmSystemTools::ExpandListArgument(this->Headers, headerFilesVec); - headerFiles.insert(headerFilesVec.begin(), headerFilesVec.end()); + headerFiles.insert(this->Headers.begin(), this->Headers.end()); // key = moc source filepath, value = moc output filename std::map<std::string, std::string> notIncludedMocs; diff --git a/Source/cmQtAutoGenerators.h b/Source/cmQtAutoGenerators.h index c6fe3b6..bffdee2 100644 --- a/Source/cmQtAutoGenerators.h +++ b/Source/cmQtAutoGenerators.h @@ -116,8 +116,8 @@ private: std::string UicExecutable; std::string RccExecutable; // - File lists - std::string Sources; - std::string Headers; + std::vector<std::string> Sources; + std::vector<std::string> Headers; // - Moc std::string SkipMoc; std::string MocCompileDefinitionsStr; |