From 23c2b82535d24a8ef343ce2ca36e5a63d111dcd8 Mon Sep 17 00:00:00 2001 From: Alexander Karatarakis Date: Wed, 4 Apr 2018 19:28:10 -0700 Subject: [vcpkgTools.xml] Add os="windows" to relevant entries --- toolsrc/src/vcpkg/commands.fetch.cpp | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'toolsrc/src') diff --git a/toolsrc/src/vcpkg/commands.fetch.cpp b/toolsrc/src/vcpkg/commands.fetch.cpp index 95c47e2db..cfb1b6c2a 100644 --- a/toolsrc/src/vcpkg/commands.fetch.cpp +++ b/toolsrc/src/vcpkg/commands.fetch.cpp @@ -78,16 +78,11 @@ namespace vcpkg::Commands::Fetch Strings::format(R"###(([\s\S]*?))###")}; static const std::regex URL_REGEX{Strings::format(R"###(([\s\S]*?))###")}; - std::regex tool_regex{ + const std::regex tool_regex{ Strings::format(R"###(([\s\S]*?)<\/tool>)###", tool, OS_STRING)}; std::smatch match_tool; - bool has_match_tool = std::regex_search(XML.cbegin(), XML.cend(), match_tool, tool_regex); - if (!has_match_tool && OS_STRING == "windows") // Legacy support. Change introduced in vcpkg v0.0.107. - { - tool_regex = Strings::format(R"###(([\s\S]*?)<\/tool>)###", tool); - has_match_tool = std::regex_search(XML.cbegin(), XML.cend(), match_tool, tool_regex); - } + const bool has_match_tool = std::regex_search(XML.cbegin(), XML.cend(), match_tool, tool_regex); Checks::check_exit(VCPKG_LINE_INFO, has_match_tool, "Could not find entry for tool [%s] in %s", -- cgit v1.2.3