NixOS / nix

Nix, the purely functional package manager
https://nixos.org/
GNU Lesser General Public License v2.1
11.92k stars 1.46k forks source link

Build capability interface #10579

Open roberth opened 4 months ago

roberth commented 4 months ago

Is your feature request related to a problem? Please describe.

Scheduling a derivation involves a comparison between a derivation's scheduling attributes (such as system and requiredFeatures), and the related properties of a "builder" (such as system, extra-platforms, supportedFeatures, mandatoryFeatures).

In #9899 I have done some exploratory coding to work out these concepts a little better.

Problems:

Describe the solution you'd like

  1. Define unambiguous terminology
    • I've renamed "builder" to "build capability" but maybe someone has a better term?
    • We should probably further distinguish between "build capability" and the concrete service or implementation that fulfills that capability, because these are again in a many to many relation.
  2. Define interface in C++.
  3. Define an IPC interface between nix-daemon and build process or build daemon (or whatever we want to call it).

Describe alternatives you've considered

Additional context

Efforts/ideas to add more "systems" which may or may not be the native system.

Priorities

Add :+1: to issues you find important.

nixos-discourse commented 4 months ago

This issue has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/2024-04-22-nix-team-meeting-minutes-140/44016/1