aboutsummaryrefslogtreecommitdiff
path: root/toolsrc
diff options
context:
space:
mode:
authorAlexander Karatarakis <alkarata@microsoft.com>2018-04-04 19:28:10 -0700
committerAlexander Karatarakis <alkarata@microsoft.com>2018-04-06 17:24:46 -0700
commit23c2b82535d24a8ef343ce2ca36e5a63d111dcd8 (patch)
treefdb33fecdd37e068006187f2ccf1a255f0ad4660 /toolsrc
parente3099b458b5c11742c1b88c27847801090870f2d (diff)
downloadvcpkg-23c2b82535d24a8ef343ce2ca36e5a63d111dcd8.tar.gz
vcpkg-23c2b82535d24a8ef343ce2ca36e5a63d111dcd8.zip
[vcpkgTools.xml] Add os="windows" to relevant entries
Diffstat (limited to 'toolsrc')
-rw-r--r--toolsrc/src/vcpkg/commands.fetch.cpp9
1 files changed, 2 insertions, 7 deletions
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"###(<archiveRelativePath>([\s\S]*?)</archiveRelativePath>)###")};
static const std::regex URL_REGEX{Strings::format(R"###(<url>([\s\S]*?)</url>)###")};
- std::regex tool_regex{
+ const std::regex tool_regex{
Strings::format(R"###(<tool[\s]+name="%s"[\s]+os="%s">([\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"###(<tool[\s]+name="%s">([\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",