diff options
author | Brad King <brad.king@kitware.com> | 2019-01-29 14:19:31 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2019-01-29 14:19:39 (GMT) |
commit | 9620cb935a49e7b4955f5b1d0ffa2e93b4327591 (patch) | |
tree | d0e011b3649793502929e4e0597b6d636fdc57ec /Source/cmGlobalVisualStudio7Generator.cxx | |
parent | 60c06620a690f0cbeeaa3fba762e19cd031669ca (diff) | |
parent | 66801f4d40227c46904ad54848bd1da959604cbf (diff) | |
download | CMake-9620cb935a49e7b4955f5b1d0ffa2e93b4327591.zip CMake-9620cb935a49e7b4955f5b1d0ffa2e93b4327591.tar.gz CMake-9620cb935a49e7b4955f5b1d0ffa2e93b4327591.tar.bz2 |
Merge topic 'add_consistent_verbose_build_flag'
66801f4d40 cmake: Add tests for verbose output to --build mode
439fe2e253 cmake: Add options for verbose output to --build mode
638667efa2 cmake: cmcmd.cxx fix "The arguments are" comments
3ca4402966 ctest: Fix --build-and-test without --build-target on Xcode
cb6c233ecc cmake: Add -hideShellScriptEnvironment xcodebuild option
1a45266cb5 cmGlobalGenerator: Add a class that represent the build command
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2708
Diffstat (limited to 'Source/cmGlobalVisualStudio7Generator.cxx')
-rw-r--r-- | Source/cmGlobalVisualStudio7Generator.cxx | 34 |
1 files changed, 12 insertions, 22 deletions
diff --git a/Source/cmGlobalVisualStudio7Generator.cxx b/Source/cmGlobalVisualStudio7Generator.cxx index c267a7b..d457f60 100644 --- a/Source/cmGlobalVisualStudio7Generator.cxx +++ b/Source/cmGlobalVisualStudio7Generator.cxx @@ -191,7 +191,7 @@ const char* cmGlobalVisualStudio7Generator::ExternalProjectType( return "8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942"; } void cmGlobalVisualStudio7Generator::GenerateBuildCommand( - std::vector<std::string>& makeCommand, const std::string& makeProgram, + GeneratedMakeCommand& makeCommand, const std::string& makeProgram, const std::string& projectName, const std::string& /*projectDir*/, const std::string& targetName, const std::string& config, bool /*fast*/, int /*jobs*/, bool /*verbose*/, std::vector<std::string> const& makeOptions) @@ -209,35 +209,25 @@ void cmGlobalVisualStudio7Generator::GenerateBuildCommand( makeProgramSelected = this->GetDevEnvCommand(); } - makeCommand.push_back(makeProgramSelected); + // Workaround to convince VCExpress.exe to produce output. + makeCommand.RequiresOutputForward = + (makeProgramLower.find("vcexpress") != std::string::npos); - makeCommand.push_back(std::string(projectName) + ".sln"); + makeCommand.add(makeProgramSelected); + + makeCommand.add(std::string(projectName) + ".sln"); std::string realTarget = targetName; bool clean = false; if (realTarget == "clean") { clean = true; realTarget = "ALL_BUILD"; } - if (clean) { - makeCommand.push_back("/clean"); - } else { - makeCommand.push_back("/build"); - } - - if (!config.empty()) { - makeCommand.push_back(config); - } else { - makeCommand.push_back("Debug"); - } - makeCommand.push_back("/project"); - if (!realTarget.empty()) { - makeCommand.push_back(realTarget); - } else { - makeCommand.push_back("ALL_BUILD"); - } - makeCommand.insert(makeCommand.end(), makeOptions.begin(), - makeOptions.end()); + makeCommand.add((clean ? "/clean" : "/build")); + makeCommand.add((config.empty() ? "Debug" : config)); + makeCommand.add("/project"); + makeCommand.add((realTarget.empty() ? "ALL_BUILD" : realTarget)); + makeCommand.add(makeOptions.begin(), makeOptions.end()); } ///! Create a local generator appropriate to this Global Generator |