!ayCRiZriCVtuCUpeLp:nixos.org

Nix Cross Compiling

533 Members
110 Servers

Load older messages


SenderMessageTime
7 Oct 2025
@alexfmpe:matrix.orgalexfmpe something like canExecuteHostOnBuild = buildPlatform.canExecute hostPlatform || hostPlatform.emulatorAvailable buildPlatform; 01:54:42
@dramforever:matrix.orgdramforever no that would break stuff with doCheck = true; written without regard for cross 01:57:45
@dramforever:matrix.orgdramforeveri'm not sure what it should be like to work around this though01:58:19
@alexfmpe:matrix.orgalexfmpeyeah this looks kinda wrong01:58:32
@alexfmpe:matrix.orgalexfmpeit's saying "there can be no testing without buildPlatform.canExecute"01:58:51
@dramforever:matrix.orgdramforeveryou can make up your own phase01:59:12
@dramforever:matrix.orgdramforever preInstallPhases would go next to where checkPhase would be 02:01:20
@alexfmpe:matrix.orgalexfmpefeels a bit weird to throw check in a new phase when it's cross02:15:33
@alexfmpe:matrix.orgalexfmpebut I don't see a way around that without adding some sort of doCheckCross to mkDerivation or special-casing haskell in make-derivation02:16:17
@qyliss:fairydust.spaceAlyssa Rossemulators should only be used where they're absolutely necessary, imo. they have large closures and often diverge from actual platform behaviour so provide dubious value.12:53:29
@quadradical:federated.nexusQuadRadical (Ping) left the room.15:47:32
@alexfmpe:matrix.orgalexfmpeI don't disagree with the issues but realistically what's the alternative?20:22:23
@alexfmpe:matrix.orgalexfmpeeveryone owning one machine of each?20:22:49
@alexfmpe:matrix.orgalexfmpeIIUC even the linux-builder runs inside qemu20:23:03
@dramforever:matrix.orgdramforeveryou can write integration tests in passthru-tests that call qemu if you want20:25:16
@dramforever:matrix.orgdramforever* you can write integration tests in passthru.tests that call qemu if you want20:25:21
@dramforever:matrix.orgdramforeverthat's easier to work with20:25:35
@dramforever:matrix.orgdramforeverand i don't understand what this is referring to ...?20:26:49
@dramforever:matrix.orgdramforeverlike, the whole thing is it's not saying that there can be no testing without canExecute, it's saying that there can be no checkPhase without canExecute20:28:10
@dramforever:matrix.orgdramforeverand sadly realistically you can't expect make check to generally work with an emulator20:30:31
@dramforever:matrix.orgdramforever at one point even coreutils couldn't pass tests in qemu user, i went and dig up and fixed it in qemu so that's not a problem now but there's a lot of cursed stuff going on 20:31:57
@alexfmpe:matrix.orgalexfmpeoh I just meant that if I want to run host tests without having access to host, best I can do is emulation, inside or outside the derivation20:40:31
@alexfmpe:matrix.orgalexfmpehuh that's interesting TIL so ofborg CI runs these? that sounds like a pretty decent compromise20:41:04
8 Oct 2025
@gsaurel:laas.frnim65s

nix build -L nixpkgs#pkgsCross.aarch64-multiplatform.ruby fail with

/nix/store/fxzmz6h2m0l74kxglsl5q4zcncw19035-aarch64-unknown-linux-gnu-binutils-2.44/bin/aarch64-unknown-linux-gnu-ld: 
yjit/target/release/libyjit.a(yjit.1fllkjkj80qowi7xzzkaw1xy8.rcgu.o): 
error adding symbols: file in wrong format

I tried some env.CARGO_BUILD_TARGET = stdenv.hostPlatform.rust.rustcTarget; but it's not helping. Maybe I'm not putting that in the correct place.
Any clue ?

14:02:16
@k900:0upti.meK900IIRC their build system explicitly says somewhere that cross is unsupported for Rust bits14:03:18
@k900:0upti.meK900At least that's what we found last time someone ran into this14:03:27
@gsaurel:laas.frnim65sworkaround wfm in https://github.com/NixOS/nixpkgs/pull/449938 :)14:22:04
9 Oct 2025
@nullcube:matrix.org@nullcube:matrix.org left the room.10:36:39
10 Oct 2025
@wolstars:matrix.orgBoas Hermansson joined the room.09:26:02
11 Oct 2025
@anders:sorby.xyzAnders joined the room.11:20:40

Show newer messages


Back to Room ListRoom Version: 6