Skip to content

lib.systems: remove supported, replace with flakeExposed #168316

Merged
sternenseemann merged 1 commit intoNixOS:masterfrom
sternenseemann:supported-no-hydra
May 23, 2022
Merged

lib.systems: remove supported, replace with flakeExposed #168316
sternenseemann merged 1 commit intoNixOS:masterfrom
sternenseemann:supported-no-hydra

Conversation

@sternenseemann
Copy link
Member

We don't have hardware for mispel, armv7l nor armv6l for the official
Hydra instance and there are negligibly few i686 jobs.

Description of changes
Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 22.05 Release Notes (or backporting 21.11 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

@vcunat
Copy link
Member

vcunat commented Apr 11, 2022

i686 is unclear to me, as the meaning is unclear to me.

@vcunat
Copy link
Member

vcunat commented Apr 11, 2022

BTW, is aarch64-darwin really still not on any of these tiers?

@sternenseemann
Copy link
Member Author

i686 is unclear to me, as the meaning is unclear to me.

From the comment I always interpret it as “binary cache is available”. The problem is that this file is basically only used to determine the systems available via the nixpkgs flake which makes this criterium even more bizarre. I think eventually another list “native stdenv available” should be added gating systems in the flake as that would have any useful impact.

BTW, is aarch64-darwin really still not on any of these tiers?

RFC 0046 still lists it as Tier 7 and as I understand it, there would need to be an RFC to promote it. (That would be a formality of course as it is indeed de facto higher already.)

@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels Apr 11, 2022
@sternenseemann
Copy link
Member Author

sternenseemann commented Apr 11, 2022

Actually, I think just renaming the hydra attribute to nativeStdenvAvailable makes more sense (as it's the only thing it's actually used for). What do you think?

cc @zimbatm

@zimbatm
Copy link
Member

zimbatm commented Apr 17, 2022

I like your idea. Platform tiers and hydra support aren't entirely relevant.

What matters to the flake is that the platform has enough of a stdenv that the packages might build. Given that the list of systems is not extensible from the outside, it's better to be a bit wider here.

@vcunat
Copy link
Member

vcunat commented Apr 17, 2022

FYI, we got native stdenv (if I get what you mean) for a new platform recently: #168199

@zimbatm
Copy link
Member

zimbatm commented Apr 21, 2022

yeah, let's track all of those in a nativeStdenv list and then use that for the flake.

@sternenseemann
Copy link
Member Author

sternenseemann commented Apr 22, 2022

yeah, let's track all of those in a nativeStdenv list and then use that for the flake.

Done in 761ba1a. I used pureStdenv to contrast against the “native stdenv” terminology used for e.g. x86_64-freebsd where an impure OS-provided libc would be used. The attribute now lists all platforms for which we have bootstrap-tools.

Edit: In theory we could compute this lists using builtins.readDir, but it's a little finicky for my taste and I do not know if flake eval would like it.

@sternenseemann sternenseemann changed the title lib.systems.supported: tier3 are not built on Hydra lib.systems.supported: list all available pure stdenvs Apr 22, 2022
@sternenseemann sternenseemann changed the title lib.systems.supported: list all available pure stdenvs lib.systems: remove supported, replace with flakeExposed May 23, 2022
@sternenseemann sternenseemann requested a review from zimbatm May 23, 2022 12:40
Copy link
Member

@zimbatm zimbatm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Since the list only gates the platforms the nixpkgs flake exposes
packages to build on, the `hydra` label made little sense. It was also
only used for this purpose, so the `tier*` attributes were largely
unnecessary.

To reflect the intention more accurately, we expose
`lib.systems.flakeExposed` and use it to gate flake.nix's system list.
@github-actions github-actions bot added 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: changelog This PR adds or changes release notes labels May 23, 2022
@github-actions github-actions bot added the 8.has: documentation This PR adds or changes documentation label May 23, 2022
@sternenseemann sternenseemann merged commit c273870 into NixOS:master May 23, 2022
@sternenseemann sternenseemann deleted the supported-no-hydra branch May 23, 2022 15:08
Sciencentistguy added a commit to Sciencentistguy/nixpkgs-unfree that referenced this pull request May 27, 2022
zimbatm pushed a commit to numtide/nixpkgs-unfree that referenced this pull request May 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: changelog This PR adds or changes release notes 8.has: documentation This PR adds or changes documentation 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants