summaryrefslogtreecommitdiffstats
path: root/Source/cmQtAutoGenerators.h
diff options
context:
space:
mode:
authorSebastian Holtermann <sebholt@xwmw.org>2017-08-26 11:59:57 (GMT)
committerSebastian Holtermann <sebholt@xwmw.org>2017-09-07 15:53:18 (GMT)
commitd1e5eb849704f73d646f64105d44807f3de50e48 (patch)
tree2246c9fd4e76d5f6eecdf42372d7c28adfc19b0a /Source/cmQtAutoGenerators.h
parent25ac91a715ee5f21fd169c47d55e02234c00915f (diff)
downloadCMake-d1e5eb849704f73d646f64105d44807f3de50e48.zip
CMake-d1e5eb849704f73d646f64105d44807f3de50e48.tar.gz
CMake-d1e5eb849704f73d646f64105d44807f3de50e48.tar.bz2
Autogen: Iterate source files only once
This is a large commit that serves multiple purposes - Iterate source files only once and store all extracted information in a cmQtAutogenDigest class that can be reused. This is brings speed improvements because several properties are only evaluated once. More that that it helps to avoid duplication of code with non trivial files property checks. - Fix the Visual Studio generator to use PRE_BUILD when possible. - Convert `for( ... )` loops to C++11 range base loops where possible (cmQtAutogen*.cxx only). - String concatenation optimizations.
Diffstat (limited to 'Source/cmQtAutoGenerators.h')
-rw-r--r--Source/cmQtAutoGenerators.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/Source/cmQtAutoGenerators.h b/Source/cmQtAutoGenerators.h
index 5cb3d9f..5421408 100644
--- a/Source/cmQtAutoGenerators.h
+++ b/Source/cmQtAutoGenerators.h
@@ -6,6 +6,7 @@
#include "cmConfigure.h" // IWYU pragma: keep
#include "cmFilePathChecksum.h"
+#include "cmQtAutoGen.h"
#include "cmsys/RegularExpression.hxx"
#include <map>
@@ -142,11 +143,11 @@ private:
std::string ChecksumedPath(const std::string& sourceFile,
const std::string& basePrefix,
const std::string& baseSuffix) const;
- bool MakeParentDirectory(const char* logPrefix,
+ bool MakeParentDirectory(cmQtAutoGen::GeneratorType genType,
const std::string& filename) const;
bool FileDiffers(const std::string& filename, const std::string& content);
- bool FileWrite(const char* logPrefix, const std::string& filename,
- const std::string& content);
+ bool FileWrite(cmQtAutoGen::GeneratorType genType,
+ const std::string& filename, const std::string& content);
bool RunCommand(const std::vector<std::string>& command, std::string& output,
bool verbose = true) const;