[vcpkg] Fix warnings on non-Windows
MODIFY
src/vcpkg/base/system.cpp
src/vcpkg/base/system.cpp
@@ -254,7 +254,7 @@ namespace vcpkg::System
Debug::println("system(%s)", cmd_line.c_str());
fflush(nullptr);
int rc = system(cmd_line.c_str());
- Debug::println("system() returned %d", rc);
+ Debug::println("system() returned %d after %d us", rc, static_cast<int>(timer.microseconds()));
return rc;
#endif
}

MODIFY
src/vcpkg/commands.fetch.cpp
src/vcpkg/commands.fetch.cpp
@@ -679,6 +679,7 @@ namespace vcpkg::Commands::Fetch
std::string major_version() const { return version.substr(0, 2); }
};
+#if defined(WIN32)
static std::vector<VisualStudioInstance> get_visual_studio_instances(const VcpkgPaths& paths)
{
const auto& fs = paths.get_filesystem();
@@ -745,6 +746,7 @@ namespace vcpkg::Commands::Fetch
return instances;
}
+#endif
#if defined(_WIN32)
std::vector<Toolset> find_toolset_instances_preferred_first(const VcpkgPaths& paths)

[vcpkg] Fix warnings on non-Windows