From a13b2f0c92d1cd5322ed0cb839a4bba5b1ab6aa7 Mon Sep 17 00:00:00 2001 From: Alexander Karatarakis Date: Fri, 3 Feb 2017 18:10:29 -0800 Subject: build_package() modified to return the result of the build --- toolsrc/include/PostBuildLint.h | 2 +- toolsrc/include/vcpkg_Commands.h | 11 ++++++++++- 2 files changed, 11 insertions(+), 2 deletions(-) (limited to 'toolsrc/include') diff --git a/toolsrc/include/PostBuildLint.h b/toolsrc/include/PostBuildLint.h index 215a237aa..73c8ec54b 100644 --- a/toolsrc/include/PostBuildLint.h +++ b/toolsrc/include/PostBuildLint.h @@ -4,5 +4,5 @@ namespace vcpkg::PostBuildLint { - void perform_all_checks(const package_spec& spec, const vcpkg_paths& paths); + size_t perform_all_checks(const package_spec& spec, const vcpkg_paths& paths); } diff --git a/toolsrc/include/vcpkg_Commands.h b/toolsrc/include/vcpkg_Commands.h index 8d772b255..ef300ac12 100644 --- a/toolsrc/include/vcpkg_Commands.h +++ b/toolsrc/include/vcpkg_Commands.h @@ -11,7 +11,16 @@ namespace vcpkg::Commands namespace Build { - void build_package(const SourceParagraph& source_paragraph, const package_spec& spec, const vcpkg_paths& paths, const fs::path& port_dir); + enum class BuildResult + { + BUILD_NOT_STARTED = 0, + SUCCESS, + CASCADED_DUE_TO_MISSING_DEPENDENCIES, + BUILD_FAILED, + POST_BUILD_CHECKS_FAILED, + }; + + BuildResult build_package(const SourceParagraph& source_paragraph, const package_spec& spec, const vcpkg_paths& paths, const fs::path& port_dir); void perform_and_exit(const vcpkg_cmd_arguments& args, const vcpkg_paths& paths, const triplet& default_target_triplet); } -- cgit v1.2.3