diff options
author | Sebastian Holtermann <sebholt@xwmw.org> | 2016-11-30 11:44:47 (GMT) |
---|---|---|
committer | Sebastian Holtermann <sebholt@xwmw.org> | 2016-12-06 14:59:26 (GMT) |
commit | 273e481e48c855905bde4d91a986c06713df0183 (patch) | |
tree | ee488cb2d67aa2f6e38c5b1e1547f8e49e264c42 | |
parent | 6f024008ce2bdf11bec1ff1174ee68f9a6da6fcb (diff) | |
download | CMake-273e481e48c855905bde4d91a986c06713df0183.zip CMake-273e481e48c855905bde4d91a986c06713df0183.tar.gz CMake-273e481e48c855905bde4d91a986c06713df0183.tar.bz2 |
QtAutogen: Inline single use variable
-rw-r--r-- | Source/cmQtAutoGeneratorInitializer.cxx | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/Source/cmQtAutoGeneratorInitializer.cxx b/Source/cmQtAutoGeneratorInitializer.cxx index 1bdfe32..576b2eb 100644 --- a/Source/cmQtAutoGeneratorInitializer.cxx +++ b/Source/cmQtAutoGeneratorInitializer.cxx @@ -682,13 +682,11 @@ void cmQtAutoGeneratorInitializer::InitializeAutogenTarget( // create a custom target for running generators at buildtime: std::string autogenTargetName = GetAutogenTargetName(target); - std::string targetDir = GetAutogenTargetFilesDir(target); - cmCustomCommandLine currentLine; currentLine.push_back(cmSystemTools::GetCMakeCommand()); currentLine.push_back("-E"); currentLine.push_back("cmake_autogen"); - currentLine.push_back(targetDir); + currentLine.push_back(GetAutogenTargetFilesDir(target)); currentLine.push_back("$<CONFIGURATION>"); cmCustomCommandLines commandLines; @@ -850,8 +848,6 @@ void cmQtAutoGeneratorInitializer::SetupAutoGenerateTarget( "_origin_target_name", cmOutputConverter::EscapeForCMake(target->GetName()).c_str()); - std::string targetDir = GetAutogenTargetFilesDir(target); - const char* qtVersion = makefile->GetDefinition("Qt5Core_VERSION_MAJOR"); if (!qtVersion) { qtVersion = makefile->GetDefinition("QT_VERSION_MAJOR"); @@ -894,7 +890,7 @@ void cmQtAutoGeneratorInitializer::SetupAutoGenerateTarget( std::string inputFile = cmSystemTools::GetCMakeRoot(); inputFile += "/Modules/AutogenInfo.cmake.in"; - std::string outputFile = targetDir; + std::string outputFile = GetAutogenTargetFilesDir(target); outputFile += "/AutogenInfo.cmake"; makefile->ConfigureFile(inputFile.c_str(), outputFile.c_str(), false, true, false); |