From 966be439e07131c3ff84175c1a9e3b6336908d8e Mon Sep 17 00:00:00 2001 From: Sebastian Holtermann Date: Sat, 31 Dec 2016 11:51:39 +0100 Subject: AUTOGEN: Generators: Be verbose about skipping files --- Source/cmQtAutoGenerators.cxx | 61 ++++++++++++++++++++++++++++++------------- 1 file changed, 43 insertions(+), 18 deletions(-) diff --git a/Source/cmQtAutoGenerators.cxx b/Source/cmQtAutoGenerators.cxx index c162c87..b323609 100644 --- a/Source/cmQtAutoGenerators.cxx +++ b/Source/cmQtAutoGenerators.cxx @@ -607,11 +607,20 @@ void cmQtAutoGenerators::ParseContentForUic( const std::string& absFilename, const std::string& contentsString, std::map >& includedUis) { - if (this->UicExecutable.empty() || - ListContains(this->SkipUic, absFilename)) { + if (this->UicExecutable.empty()) { + return; + } + // Check skip list + if (ListContains(this->SkipUic, absFilename)) { + if (this->Verbose) { + std::ostringstream err; + err << "AUTOUIC: Skipping " << absFilename << "\n"; + this->LogInfo(err.str()); + } return; } + // Process if (this->Verbose) { std::ostringstream err; err << "AUTOUIC: Checking " << absFilename << "\n"; @@ -641,11 +650,20 @@ bool cmQtAutoGenerators::ParseContentForMoc( const std::vector& headerExtensions, std::map& includedMocs, bool relaxed) { - if (this->MocExecutable.empty() || - ListContains(this->SkipMoc, absFilename)) { + if (this->MocExecutable.empty()) { + return true; + } + // Check skip list + if (ListContains(this->SkipMoc, absFilename)) { + if (this->Verbose) { + std::ostringstream err; + err << "AUTOMOC: Skipping " << absFilename << "\n"; + this->LogInfo(err.str()); + } return true; } + // Process if (this->Verbose) { std::ostringstream err; err << "AUTOMOC: Checking " << absFilename << "\n"; @@ -872,21 +890,28 @@ void cmQtAutoGenerators::ParseHeaders( // Parse header content for MOC if (!this->MocExecutable.empty() && - !ListContains(this->SkipMoc, headerName) && (includedMocs.find(headerName) == includedMocs.end())) { - - if (this->Verbose) { - std::ostringstream err; - err << "AUTOMOC: Checking " << headerName << "\n"; - this->LogInfo(err.str()); - } - - std::string macroName; - if (this->requiresMocing(contents, macroName)) { - notIncludedMocs[headerName] = fpathCheckSum.getPart(headerName) + - "/moc_" + - cmsys::SystemTools::GetFilenameWithoutLastExtension(headerName) + - ".cpp"; + if (ListContains(this->SkipMoc, headerName)) { + // Skip + if (this->Verbose) { + std::ostringstream err; + err << "AUTOMOC: Skipping " << headerName << "\n"; + this->LogInfo(err.str()); + } + } else { + // Process + if (this->Verbose) { + std::ostringstream err; + err << "AUTOMOC: Checking " << headerName << "\n"; + this->LogInfo(err.str()); + } + std::string macroName; + if (this->requiresMocing(contents, macroName)) { + notIncludedMocs[headerName] = fpathCheckSum.getPart(headerName) + + "/moc_" + + cmsys::SystemTools::GetFilenameWithoutLastExtension(headerName) + + ".cpp"; + } } } -- cgit v0.12