NixOS / hydra

Hydra, the Nix-based continuous build system
http://nixos.org/hydra
GNU General Public License v3.0
1.1k stars 291 forks source link

align `system` retrieval with `nix-build` #1303

Open DavHau opened 9 months ago

DavHau commented 9 months ago

Read the system from the instantiated derivation instead of getting it from the eval time drv attrs.

This is better in terms of correctness as it derives the system through a derivations string context, instead of relying on builder implementations to set the system attribute correctly.

This derivation for example did not build with hydra before while it builds fine with the nix repl:

:b { name="hello"; type="derivation"; drvPath = hello.drvPath; }