!ayCRiZriCVtuCUpeLp:nixos.org

Nix Cross Compiling

548 Members
116 Servers

Load older messages


SenderMessageTime
3 Jul 2021
@ius:nltrix.netius I made some changes to patchelf and would like to test it by rebuilding all derivations targeting my cross arch (and only those), is there a way to do this? crossOverlays seems pretty convenient for packages running on the target, but it seems of little use for tools which run on the build machine. A naive overlay runs into a recursion issue due to affecting all derivations.. 18:59:57
@ius:nltrix.netius I tackled similar issues with gcc before, for which checking stdenv.targetPlatfor.isXX seems to work, but can't get it to work for patchelf.. 19:01:15
@ius:nltrix.netius I spent some time reading the nixpkgs manuals, and wonder whether pkgs{Build/Host.Target} would be useful/relevant in any way (but have to admit I don't understand them well enough) 19:02:49
@symphorien:xlumurb.eusymphorien fork nixpkgs and patch the derivation for patchelf with: src = if stdenv.targetPlatform == "foo" then mysource else theoriginalsource ? 19:22:49
@symphorien:xlumurb.eusymphorienhopefully this should not affect non-cross patchelf19:23:41
@ius:nltrix.netiusHmm, I already tried that using an overlay, but ended up forking nixpkgs anyway for the gcc issues I had earlier - let me give that a go to see if it helps19:36:31
@ius:nltrix.netius So I just tried that, doesn't seem to have any effect. In many hours of Googling I also discovered builtins.trace, adding that to print the build/host/target triplet shows it's being evaluated 3 times: {x64, x64, x64}; {x64, x64, x64}; {x64, x64, ppc} 20:22:43
4 Jul 2021
@symphorien:xlumurb.eusymphorien there are more handy functions in lib.debug 14:54:19
@ius:nltrix.netius Ah excellent, at the very least my trace printing is less awkward now (just trace won't eval a sequence), traceSeq does 15:53:23
@ius:nltrix.netius Maybe I need to approach this from the other end and instead of patching patchelf, try to modify the part where stdenv includes it? 16:33:41
@ius:nltrix.netius

Looking into stdenv I notice there are some other peculiarities (although I hardly understand how it works in the first place)

 55     mipsel-linux = stagesLinux;
 56     powerpc-linux = /* stagesLinux */ stagesNative;
 57     powerpc64-linux = stagesLinux;

powerpc is the odd one out for some reason

16:34:42
5 Jul 2021
@qyliss:fairydust.spaceAlyssa Rosssternenseemann: I think I found the commit that changed it...12:29:28
@sternenseemann:systemli.orgsterni (he/him) Alyssa Ross: in llvm? 13:07:08
@qyliss:fairydust.spaceAlyssa Rossyeah13:07:13
@sternenseemann:systemli.orgsterni (he/him)interesting!13:07:20
@qyliss:fairydust.spaceAlyssa RossI'm going to need to find it again now...13:07:30
@sternenseemann:systemli.orgsterni (he/him)I'm intrigued now what the actual cause is because the only explanation that would make sense to me is that the terminfo dependency is new in LLVM 1213:08:11
@qyliss:fairydust.spaceAlyssa Rossnope, it was a cmake refactor13:08:33
@sternenseemann:systemli.orgsterni (he/him)very strange13:08:47
@qyliss:fairydust.spaceAlyssa RossI assume the change to passing absolute path to the linker was accidental13:08:50
@qyliss:fairydust.spaceAlyssa Rosssternenseemann: 3c7bfbd6831b is where it starting trying to link with absolute host ncurses path13:14:33
@qyliss:fairydust.spaceAlyssa RossI haven't determined why it stopped finding ncurses by name though13:15:19
@sternenseemann:systemli.orgsterni (he/him)ah real shame that meta.platforms does only accept system strings13:43:13
@sternenseemann:systemli.orgsterni (he/him) * a real shame that meta.platforms does only accept system strings13:43:17
@sternenseemann:systemli.orgsterni (he/him)we probably want to have the unsupported platform predicate13:47:12
@sternenseemann:systemli.orgsterni (he/him)

Alyssa Ross: ```
ldd /nix/store/28n03fxvzx4ncr52wza16xhfy39rw29k-llvm-aarch64-unknown-linux-gnu-11.1.0-dev/bin/llvm-config-native
linux-vdso.so.1 (0x00007ffcef921000)
libpthread.so.0 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libpthread.so.0 (0x00007f8adf6bf000)
librt.so.1 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/librt.so.1 (0x00007f8adf6b4000)
libdl.so.2 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libdl.so.2 (0x00007f8adf6af000)
libstdc++.so.6 => /nix/store/d9mfvhvksvsx0ar8pmxwhgwd9my045rp-gcc-10.3.0-lib/lib/libstdc++.so.6 (0x00007f8adf4da000)
libm.so.6 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libm.so.6 (0x00007f8adf397000)
libgcc_s.so.1 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libgcc_s.so.1 (0x00007f8adf37b000)
libc.so.6 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libc.so.6 (0x00007f8adf1ba000)
/nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/ld-linux-x86-64.so.2 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib64/ld-linux-x86-64.so.2 (0x00007f8adf6e2000)


so llvm-config-native 11 doesn't link against terminfo at all?!
14:09:42
@sternenseemann:systemli.orgsterni (he/him) *

Alyssa Ross:

ldd /nix/store/28n03fxvzx4ncr52wza16xhfy39rw29k-llvm-aarch64-unknown-linux-gnu-11.1.0-dev/bin/llvm-config-native
linux-vdso.so.1 (0x00007ffcef921000)
libpthread.so.0 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libpthread.so.0 (0x00007f8adf6bf000)
librt.so.1 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/librt.so.1 (0x00007f8adf6b4000)
libdl.so.2 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libdl.so.2 (0x00007f8adf6af000)
libstdc++.so.6 => /nix/store/d9mfvhvksvsx0ar8pmxwhgwd9my045rp-gcc-10.3.0-lib/lib/libstdc++.so.6 (0x00007f8adf4da000)
libm.so.6 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libm.so.6 (0x00007f8adf397000)
libgcc_s.so.1 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libgcc_s.so.1 (0x00007f8adf37b000)
libc.so.6 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libc.so.6 (0x00007f8adf1ba000)
/nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/ld-linux-x86-64.so.2 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib64/ld-linux-x86-64.so.2 (0x00007f8adf6e2000)

so llvm-config-native 11 doesn't link against terminfo at all?!

14:09:51
@sternenseemann:systemli.orgsterni (he/him) *

Alyssa Ross:

ldd /nix/store/28n03fxvzx4ncr52wza16xhfy39rw29k-llvm-aarch64-unknown-linux-gnu-11.1.0-dev/bin/llvm-config-native
linux-vdso.so.1 (0x00007ffcef921000)
libpthread.so.0 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libpthread.so.0 (0x00007f8adf6bf000)
librt.so.1 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/librt.so.1 (0x00007f8adf6b4000)
libdl.so.2 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libdl.so.2 (0x00007f8adf6af000)
libstdc++.so.6 => /nix/store/d9mfvhvksvsx0ar8pmxwhgwd9my045rp-gcc-10.3.0-lib/lib/libstdc++.so.6 (0x00007f8adf4da000)
libm.so.6 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libm.so.6 (0x00007f8adf397000)
libgcc_s.so.1 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libgcc_s.so.1 (0x00007f8adf37b000)
libc.so.6 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/libc.so.6 (0x00007f8adf1ba000)
/nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib/ld-linux-x86-64.so.2 => /nix/store/adxc893j47gxx3xjw403zdf0liiddvw2-glibc-2.32-48/lib64/ld-linux-x86-64.so.2 (0x00007f8adf6e2000)

so llvm-config-native 11 doesn't link against terminfo at all?!

14:09:59
@qyliss:fairydust.spaceAlyssa Rosshmm, I thought it did when I checked14:21:08
@sternenseemann:systemli.orgsterni (he/him) Alyssa Ross: the non cross compiled one does 14:22:24

There are no newer messages yet.


Back to Room ListRoom Version: 6