mirror of
https://github.com/NixOS/nix.git
synced 2025-11-09 03:56:01 +01:00
Settings::ExternalBuilder::systems make set
Nothing cares about the order, actually.
This commit is contained in:
parent
2308aaf192
commit
b56dd21c31
2 changed files with 4 additions and 5 deletions
|
|
@ -1375,7 +1375,7 @@ public:
|
||||||
|
|
||||||
struct ExternalBuilder
|
struct ExternalBuilder
|
||||||
{
|
{
|
||||||
std::vector<std::string> systems;
|
StringSet systems;
|
||||||
Path program;
|
Path program;
|
||||||
std::vector<std::string> args;
|
std::vector<std::string> args;
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -19,8 +19,7 @@ struct ExternalDerivationBuilder : DerivationBuilderImpl
|
||||||
LocalStore & store, std::unique_ptr<DerivationBuilderCallbacks> & miscMethods, DerivationBuilderParams & params)
|
LocalStore & store, std::unique_ptr<DerivationBuilderCallbacks> & miscMethods, DerivationBuilderParams & params)
|
||||||
{
|
{
|
||||||
for (auto & handler : settings.externalBuilders.get()) {
|
for (auto & handler : settings.externalBuilders.get()) {
|
||||||
for (auto & system : handler.systems)
|
if (handler.systems.contains(params.drv.platform))
|
||||||
if (params.drv.platform == system)
|
|
||||||
return std::make_unique<ExternalDerivationBuilder>(
|
return std::make_unique<ExternalDerivationBuilder>(
|
||||||
store, std::move(miscMethods), std::move(params), handler);
|
store, std::move(miscMethods), std::move(params), handler);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue