Skip to content

Commit

Permalink
Add Alpine's search path for Ninja. (#1545)
Browse files Browse the repository at this point in the history
  • Loading branch information
BillyONeal authored Dec 17, 2024
1 parent 7dbf07e commit f02f06b
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/vcpkg/tools.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,13 @@ namespace vcpkg
virtual StringView tool_data_name() const override { return Tools::NINJA; }
virtual std::vector<StringView> system_exe_stems() const override { return {Tools::NINJA}; }
virtual std::array<int, 3> default_min_version() const override { return {3, 5, 1}; }
#if !defined(_WIN32)
virtual void add_system_paths(const ReadOnlyFilesystem&, std::vector<Path>& out_candidate_paths) const override
{
// This is where Ninja goes by default on Alpine: https://github.com/microsoft/vcpkg/issues/21218
out_candidate_paths.emplace_back("/usr/lib/ninja-build/bin");
}
#endif // ^^^ !defined(_WIN32)

virtual ExpectedL<std::string> get_version(const ToolCache&, MessageSink&, const Path& exe_path) const override
{
Expand Down

0 comments on commit f02f06b

Please sign in to comment.