| 3 Jul 2021 |
ius | 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 | 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 | 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 | fork nixpkgs and patch the derivation for patchelf with: src = if stdenv.targetPlatform == "foo" then mysource else theoriginalsource ? | 19:22:49 |
symphorien | hopefully this should not affect non-cross patchelf | 19:23:41 |
ius | Hmm, 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 helps | 19:36:31 |
ius | 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 | there are more handy functions in lib.debug | 14:54:19 |
ius | 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 | 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 | 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 |
Alyssa Ross | sternenseemann: I think I found the commit that changed it... | 12:29:28 |
sterni (he/him) | Alyssa Ross: in llvm? | 13:07:08 |
Alyssa Ross | yeah | 13:07:13 |
sterni (he/him) | interesting! | 13:07:20 |
Alyssa Ross | I'm going to need to find it again now... | 13:07:30 |
sterni (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 12 | 13:08:11 |
Alyssa Ross | nope, it was a cmake refactor | 13:08:33 |
sterni (he/him) | very strange | 13:08:47 |
Alyssa Ross | I assume the change to passing absolute path to the linker was accidental | 13:08:50 |
Alyssa Ross | sternenseemann: 3c7bfbd6831b is where it starting trying to link with absolute host ncurses path | 13:14:33 |
Alyssa Ross | I haven't determined why it stopped finding ncurses by name though | 13:15:19 |
sterni (he/him) | ah real shame that meta.platforms does only accept system strings | 13:43:13 |
sterni (he/him) | * a real shame that meta.platforms does only accept system strings | 13:43:17 |
sterni (he/him) | we probably want to have the unsupported platform predicate | 13:47:12 |
sterni (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 |
sterni (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 |
sterni (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 |
Alyssa Ross | hmm, I thought it did when I checked | 14:21:08 |
sterni (he/him) | Alyssa Ross: the non cross compiled one does | 14:22:24 |