diff options
Diffstat (limited to 'Source/cmQtAutomoc.cxx')
-rw-r--r-- | Source/cmQtAutomoc.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/cmQtAutomoc.cxx b/Source/cmQtAutomoc.cxx index 0103bcc..bb81dd3 100644 --- a/Source/cmQtAutomoc.cxx +++ b/Source/cmQtAutomoc.cxx @@ -663,6 +663,7 @@ void cmQtAutomoc::ParseCppFile(const std::string& absFilename, } else { + std::string fileToMoc = absFilename; if (basename != scannedFileBasename) { bool fail = true; @@ -676,7 +677,7 @@ void cmQtAutomoc::ParseCppFile(const std::string& absFilename, { // this is for KDE4 compatibility: fail = false; - includedMocs[headerToMoc] = currentMoc; + fileToMoc = headerToMoc; std::cerr << "AUTOMOC: warning: " << absFilename << ": The file " "includes the moc file \"" << currentMoc << "\" instead of \"moc_" << basename << ".cpp\". " @@ -703,7 +704,7 @@ void cmQtAutomoc::ParseCppFile(const std::string& absFilename, dotMocIncluded = true; ownDotMocFile = currentMoc; } - includedMocs[absFilename] = currentMoc; + includedMocs[fileToMoc] = currentMoc; } matchOffset += mocIncludeRegExp.end(); } while(mocIncludeRegExp.find(contentsString.c_str() + matchOffset)); |