• Bug#1102299: patchelf: FTBFS on mips64el

    From Chris Hofstaedtler@21:1/5 to Chris Hofstaedtler on Sat Apr 19 18:20:01 2025
    On Sat, Apr 19, 2025 at 01:27:21PM +0200, Chris Hofstaedtler wrote:
    On Sat, Apr 19, 2025 at 12:45:08AM -0400, Sergio Durigan Junior wrote:
    On Monday, April 07 2025, Graham Inggs wrote:
    The recent upload of patchelf 0.18.0-1.2 FTBFS on mips64el [1]. I've copied what I hope is the relevant part of the log below.

    Thanks, Graham.

    I tried reproducing the issue but apparently it's gone. I've given back the build, hopefully it will succeed this time. I'll check back
    tomorrow.

    Didn't help: https://buildd.debian.org/status/logs.php?pkg=patchelf&ver=0.18.0-1.2&arch=mips64el
    https://buildd.debian.org/status/fetch.php?pkg=patchelf&arch=mips64el&ver=0.18.0-1.2&stamp=1745055768&raw=0

    One of the commits added in -1.2 is:

    $ head fix-replace-add-needed-armhf.patch
    From 1c443aa1c7b8c8bcafde796f2e41e4abce3793e1 Mon Sep 17 00:00:00 2001
    From: matoro <matoro@users.noreply.github.com>
    Date: Sat, 4 Nov 2023 20:01:22 -0400
    Subject: [PATCH] Fix page size on Alpha

    Upstream meanwhile reverted it: https://github.com/NixOS/patchelf/pull/541/commits/a9d3f085ffdc1730c722998ef95a632e2f76dc8f

    Unfortunately, reproducing the build failure does not seem possible
    on eberlin.d.o.

    Chris

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Sergio Durigan Junior@21:1/5 to All on Sat Apr 19 23:50:01 2025
    Control: forwarded -1 https://github.com/NixOS/patchelf/issues/594

    On Saturday, April 19 2025, I wrote:

    On Saturday, April 19 2025, I wrote:

    I'll keep debugging it.

    And so I did.

    First of all, I've just uploaded patchelf 0.18.0-1.4 which will skip the failing test on mips64el, since I haven't been able to find a proper
    fix. But I think I have a few clues about what might be happening, and
    I'll report an upstream bug to let them know.

    If we look at the build logs for the FTBFS, we see the following
    excerpt:

    --8<---------------cut here---------------start------------->8---
    shifting new PT_LOAD segment by 65536 bytes to work around a Linux kernel bug rewriting section '.note.gnu.build-id' from offset 0x2a8 (size 36) to offset 0x60000 (size 36)
    rewriting section '.interp' from offset 0x2cc (size 15) to offset 0x60028 (size 15)
    rewriting section '.MIPS.abiflags' from offset 0x2e0 (size 24) to offset 0x60038 (size 24)
    rewriting section '.MIPS.xhash' from offset 0x2f8 (size 22228) to offset 0x60050 (size 22228)
    rewriting section '.dynstr' from offset 0x119e8 (size 11085) to offset 0x65728 (size 51978)
    --8<---------------cut here---------------end--------------->8---

    Note the presence of the .MIPS.xhash section.

    Meanwhile, on eberlin, we see:

    --8<---------------cut here---------------start------------->8---
    rewriting section '.MIPS.abiflags' from offset 0x200 (size 24) to offset 0x60000 (size 24)
    rewriting section '.MIPS.options' from offset 0x218 (size 200) to offset 0x60018 (size 200)
    rewriting section '.dynamic' from offset 0x308 (size 480) to offset 0x600e0 (size 496)
    rewriting section '.dynstr' from offset 0xf078 (size 10978) to offset 0x602d0 (size 10992)
    --8<---------------cut here---------------end--------------->8---

    Note the absence of .MIPS.xhash.

    This pointed me to something that either glibc or Linux might be doing
    here. Both systems are running the same glibc version (2.47-1), but
    while the official builder is running Linux 6.1.0-33-loongson, eberlin
    is running Linux 4.19.0-21-loongson-3.

    I believe this extra section might be confusing patchelf, but I wasn't
    able to debug further because I couldn't find another mips64el machine
    with a recent Linux. I could use QEMU for it, but this would take even
    longer and unfortunately I don't have much time now.

    Anyway, the build should now pass and the package. I have also
    submitted an upstream issue here:

    https://github.com/NixOS/patchelf/issues/594

    Let's hope they have more luck when tackling this issue.

    Cheers,

    --
    Sergio
    GPG key ID: 237A 54B1 0287 28BF 00EF 31F4 D0EB 7628 65FC 5E36
    Please send encrypted e-mail if possible
    https://sergiodj.net/

    --=-=-Content-Type: application/pgp-signature; name="signature.asc"

    -----BEGIN PGP SIGNATURE-----

    iQIzBAEBCgAdFiEEI3pUsQKHKL8A7zH00Ot2KGX8XjYFAmgEGPEACgkQ0Ot2KGX8 XjYl0Q//b/4Zp4h2u2iuHPUccuFDCcpgshVgOi2TgECHh3SoH+hQR1n3iU3TzaS6 WO2g3ch+mUzlVf83l/xPtuF8Ely02RGPZJywx7jjEvW17ipBL1I3HKy7jwrUOevp yCbPRFCvxuDPJdsBchSKurkd3xhWWjacRWaar01fr15x0z1ZOHxSPgonGdp9gm3z SAU0iYoFh8pSs4W5IZVIYXPZfZHc2+hEbeg8qYDts9KgZSe7vKQT7GOOPG+l4vhP rJA5XJ4sp/740jbl1fDTfmFjq7Ug4AYdJiqSUhKB1diR8Ac2zwcGEGmEeoPYztWG 1wXlyupBqDrj/4wgfJ6TodHgJm52vriopcwsyEBFGRFFFIDOzB0f7UoZsUzwnKk/ uu/hTprCl0AuI2V17l83Ch0obw+VA0DccqbGpDdpjhwVTTd8g10KWeZZ5JTkKMRC iUeLaIzmmuQxytqAC+cZcc5bEF4ntKSMkp/GA6bVCP5kElyMhS7GpvXfW/v9xTCs baD/97jghF2FTz6oqqoRkV4EpzRad7UMIQqBRMa/Wl7Ro0JfR3o1HkFypvaJ2Fw6 4XwkV27n15Ros9x2htDpAVb1DuxMr7jxHGvGc4G7vA4x58OfifrZ7IRNHBak1LE8 cA2AKR0qFSQzyLJJ6CJsmtA/RJVZuEtuOF1vqcxIOJ+c8gqdXI