diff options
Diffstat (limited to 'toolsrc/src/commands_build.cpp')
| -rw-r--r-- | toolsrc/src/commands_build.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/toolsrc/src/commands_build.cpp b/toolsrc/src/commands_build.cpp index c7db764de..c3ebd7de8 100644 --- a/toolsrc/src/commands_build.cpp +++ b/toolsrc/src/commands_build.cpp @@ -10,7 +10,6 @@ #include "metrics.h" #include "vcpkg_Enums.h" #include "Paragraphs.h" -#include "vcpkg_Util.h" namespace vcpkg::Commands::Build { @@ -150,10 +149,12 @@ namespace vcpkg::Commands::Build if (result == BuildResult::CASCADED_DUE_TO_MISSING_DEPENDENCIES) { std::vector<InstallPlanAction> unmet_dependencies = Dependencies::create_install_plan(paths, { spec }, status_db); - Util::keep_if(unmet_dependencies, [&spec](const InstallPlanAction& p) - { - return (p.spec != spec) && (p.plan_type != InstallPlanType::ALREADY_INSTALLED); - }); + unmet_dependencies.erase( + std::remove_if(unmet_dependencies.begin(), unmet_dependencies.end(), [&spec](const InstallPlanAction& p) + { + return (p.spec == spec) || (p.plan_type == InstallPlanType::ALREADY_INSTALLED); + }), + unmet_dependencies.end()); Checks::check_exit(VCPKG_LINE_INFO, !unmet_dependencies.empty()); System::println(System::Color::error, "The build command requires all dependencies to be already installed."); |
