!ayCRiZriCVtuCUpeLp:nixos.org

Nix Cross Compiling

576 Members
128 Servers

Load older messages


SenderMessageTime
14 Feb 2025
@artturin:matrix.orgArtturin Change the variable name or put it in the callPackage overrides 19:18:36
@artturin:matrix.orgArtturin callPackage ./file.nix { <here> 19:18:47
@artturin:matrix.orgArtturin * callPackage ./file.nix { <here> } 19:18:49
@rosssmyth:matrix.org@rosssmyth:matrix.org

It still errors with infinite recursion. I have it setup as

highPower = with armPkgs;
  callPackage ./default.nix {
    stdenv = with pkgs;
      overrideCC stdenv (buildPackages.wrapCC (stdenv.cc
        // {
          stdenv.cc.targetPlatform =
            stdenv.cc.targetPlatform
            // {
              gcc =
                stdenv.cc.targetPlatform.gcc
                // {
                  arch = "arv6m";
                  cpu = "cortex-m0";
                  thumb = true;
                };
            };
        }));
  };
20:04:05
@rosssmyth:matrix.org@rosssmyth:matrix.orgoh wait20:04:14
@rosssmyth:matrix.org@rosssmyth:matrix.orgI think I see the error20:04:26
@rosssmyth:matrix.org@rosssmyth:matrix.org *

It still errors with infinite recursion. I have it setup as

highPower = with armPkgs;
  callPackage ./default.nix {
    stdenv = 
      overrideCC stdenv (buildPackages.wrapCC (stdenv.cc
        // {
          stdenv.cc.targetPlatform =
            stdenv.cc.targetPlatform
            // {
              gcc =
                stdenv.cc.targetPlatform.gcc
                // {
                  arch = "arv6m";
                  cpu = "cortex-m0";
                  thumb = true;
                };
            };
        }));
  };
20:05:06
@rosssmyth:matrix.org@rosssmyth:matrix.orgNo, I don't20:06:35
@artturin:matrix.orgArtturinLook through the trace20:17:09
@alexfmpe:matrix.orgalexfmpe
In reply to @emilazy:matrix.org
fwiw still personally happy to mentor bringing iOS support up to date in line with my previous statements about how it should work :P
I remember, it's just taking longer than I expected to get through pkgsCross.ghcjs so not enough budget yet for iOS
20:26:24
@alexfmpe:matrix.orgalexfmpeThere's also the, heh, cross cutting concern of template haskell20:27:09
@rosssmyth:matrix.org@rosssmyth:matrix.orgThat still ends up building it in ARM mode. Oh well.20:44:36
@lucassong:matrix.orglucassong joined the room.20:53:29
@lucassong:matrix.orglucassonghello20:53:47
15 Feb 2025
@alexfmpe:matrix.orgalexfmpe hmm the types.h errors are gone in staging-next, someone must have fixed something in between 00:45:47
@alexfmpe:matrix.orgalexfmpe though android-ndk-toolchain fails from the recent noBrokenSymlinks 00:46:23
@alexfmpe:matrix.orgalexfmpe * though android-ndk-toolchain still fails from the recent noBrokenSymlinks 00:57:01
@alexfmpe:matrix.orgalexfmpe ah yeah no false alarm, I was building the wrong thing, the types.h and other errors are present in staging(-next) 01:06:05
@alexfmpe:matrix.orgalexfmpefixed this one at least: https://github.com/NixOS/nixpkgs/pull/38218201:23:07
@benjb83:matrix.orgBenjB83 joined the room.10:14:34
@benjb83:matrix.orgBenjB83 changed their display name from Benjamín Buske to BenjB83.10:43:28
16 Feb 2025
@kristijan.zic:matrix.orgKristijanZic joined the room.01:07:04
@jake:hillion.co.ukJake Hillion joined the room.18:26:31
17 Feb 2025
@axman6:matrix.orgAxman6 If you're building on a x86_64-linux system and you build pkgs.pkgsCross.gnu64.foo is there a difference between what it builds and what pkgs.foo? are there any checks that a cross compile isn't actually a cross compile? 06:11:55
@axman6:matrix.orgAxman6Just wondering if there's anything that checks if buildPlatform and hostPlatform are the same and uses the top level definitions06:12:42
@k900:0upti.meK900No, there isn't07:21:10
@alexfmpe:matrix.orgalexfmpe
$ nix-build -A hello
/nix/store/p09fxxwkdj69hk4mgddk4r3nassiryzc-hello-2.12.1
$ nix-build -A pkgsCross.gnu64.hello
/nix/store/p09fxxwkdj69hk4mgddk4r3nassiryzc-hello-2.12.1
16:06:50
@alexfmpe:matrix.orgalexfmpe there are some things that check whether you're doing cross, but not for the purpose of picking a different attribute path 16:08:28
@alexfmpe:matrix.orgalexfmpeI think it's mostly about whether test suites can be run normally, or maybe configuring cross compilers 16:09:34
@alexfmpe:matrix.orgalexfmpea good deal of cross is just proper build time vs run time separation16:09:54

Show newer messages


Back to Room ListRoom Version: 6