!ayCRiZriCVtuCUpeLp:nixos.org

Nix Cross Compiling

577 Members
124 Servers

You have reached the beginning of time (for this room).


SenderMessageTime
25 Nov 2025
@ebnull:matrix.orgeb

Can't automatically pick the packages to get from the cache and which to cross-compile.

Could I introspect the cache somehow (outside of nix, ahead of time) and add a nixpkgs overlay based on pname to select between ( native | cross ), hoping that the hashes will then match?

18:43:18
@ebnull:matrix.orgeb

You can however make a second native nixpkgs instance to pick packages from, you could even overlay them.

If I do set up binfmt emulation, and I'm using a stable nixos branch that hydra has cached, and not building custom packages, should I expect a 99% cache hit rate, and then the last bit is essentially making the sdcard images which I'd need to do locally?

18:44:51
@ebnull:matrix.orgeb(also I haven't said this yet - thank you for your help!)18:45:24
@artturin:matrix.orgArtturinnix-forecast for a specific installable status https://github.com/getchoo/nix-forecast hydra-check for general status https://github.com/nix-community/hydra-check18:46:20
@artturin:matrix.orgArtturinCould probably make something with those18:46:29
@artturin:matrix.orgArtturin The pkgs instance of a config can be accessed like this nixosConfigurations.ArtDesktop.pkgs.hello 18:48:06
@ebnull:matrix.orgeb

nix-forecast

Very nice, looks like something that will be very useful for a/b comparisons. Thanks for the pointer!

hydra-check

Good to know, but probably more useful for those actively hacking on nixpkgs

18:49:03
@artturin:matrix.orgArtturinaarch64-linux is pretty well supported so I guess so18:51:17
@artturin:matrix.orgArtturinhttps://hydra.nixos.org/job/nixos/trunk-combined/tested#tabs-constituents18:51:24

Show newer messages


Back to Room ListRoom Version: 6