From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) by sourceware.org (Postfix) with ESMTP id 422F93858C62 for ; Sat, 29 Jul 2023 18:34:49 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 422F93858C62 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gentoo.org From: "Andreas K. Huettel" To: libc-alpha@sourceware.org, vapier@gentoo.org Subject: build failure on ia64 (+ patch), "relocation truncated to fit: GPREL22 against `.text'" Date: Sat, 29 Jul 2023 20:34:35 +0200 Message-ID: <4817905.GXAFRqVoOG@pinacolada> Organization: Gentoo Linux MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart1857047.tdWV9SEqCh"; micalg="pgp-sha512"; protocol="application/pgp-signature" X-Spam-Status: No, score=-9.6 required=5.0 tests=BAYES_00,GIT_PATCH_0,JMQ_SPF_NEUTRAL,KAM_DMARC_STATUS,SPF_HELO_PASS,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: --nextPart1857047.tdWV9SEqCh Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-1"; protected-headers="v1" From: "Andreas K. Huettel" To: libc-alpha@sourceware.org, vapier@gentoo.org Date: Sat, 29 Jul 2023 20:34:35 +0200 Message-ID: <4817905.GXAFRqVoOG@pinacolada> Organization: Gentoo Linux MIME-Version: 1.0 When testing a manual build on ia64 we ran (on two different Gentoo machine= s) into https://bugs.gentoo.org/723268 https://sourceware.org/pipermail/libc-alpha/2020-May/114028.html gcc -o /home/dilfridge/glibc_build/support/test-run-command -nostdlib -nost= artfiles -static /home/dilfridge/glibc_build/csu/crt1.o /home/dilfridg= e/glibc_build/csu/crti.o `gcc --print-file-name=3Dcrtbegin.o` /home/dilfri= dge/glibc_build/support/test-run-command.o /home/dilfridge/glibc_build/elf/= static-stubs.o /home/dilfridge/glibc_build/support/libsupport_nonshared.a = =2DWl,--start-group /home/dilfridge/glibc_build/libc.a -lgcc -Wl,--end-gro= up `gcc --print-file-name=3Dcrtend.o` /home/dilfridge/glibc_build/csu/crtn= =2Eo /usr/lib/gcc/ia64-unknown-linux-gnu/13/../../../../ia64-unknown-linux-gnu/b= in/ld: warning: -z relro ignored /home/dilfridge/glibc_build/libc.a(dl-support.o): in function `_dl_aux_init= ': /home/dilfridge/glibc/elf/dl-support.c:239:(.text+0x51): relocation truncat= ed to fit: GPREL22 against `.text' /home/dilfridge/glibc_build/libc.a(dl-support.o): in function `setup_vdso': /home/dilfridge/glibc/elf/setup-vdso.h:108:(.text+0xea2): relocation trunca= ted to fit: GPREL22 against `.text' collect2: error: ld returned 1 exit status make[2]: *** [../Rules:290: /home/dilfridge/glibc_build/support/test-run-co= mmand] Error 1 make[2]: *** Waiting for unfinished jobs.... make[2]: Leaving directory '/home/dilfridge/glibc/support' make[1]: *** [Makefile:484: support/others] Error 2 make[1]: Leaving directory '/home/dilfridge/glibc' make: *** [Makefile:9: all] Error 2 Turns out we have a fix for this in our Gentoo patchset since glibc-2.31, p= asted below. Since this fixes a clear build failure, is localized to sysdeps/unix/sysv/l= inux/ia64, and there are no positive test results without it anywhere, I'd like to pul= l it in for 2.38. Any objections? =46rom ed428afb4c6353692fba6cedaa2f9db7bc9fb551 Mon Sep 17 00:00:00 2001 =46rom: Sergei Trofimovich Date: Sat, 11 Jul 2020 20:06:51 +0300 Subject: [PATCH 4/9] Fix miscompilation on ia64's gcc-10 MIME-Version: 1.0 Content-Type: text/plain; charset=3DUTF-8 Content-Transfer-Encoding: 8bit Bug: https://bugs.gentoo.org/723268 Signed-off-by: Andreas K. H=FCttel =2D-- sysdeps/unix/sysv/linux/ia64/dl-sysdep.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sysdeps/unix/sysv/linux/ia64/dl-sysdep.h b/sysdeps/unix/sysv/l= inux/ia64/dl-sysdep.h index 3e4d5da820..eb7681b704 100644 =2D-- a/sysdeps/unix/sysv/linux/ia64/dl-sysdep.h +++ b/sysdeps/unix/sysv/linux/ia64/dl-sysdep.h @@ -32,7 +32,9 @@ #ifndef __ASSEMBLER__ /* Don't declare this as a function---we want it's entry-point, not it's function descriptor... */ =2Dextern int _dl_sysinfo_break attribute_hidden; +/* Use section ".text" to force far GPREL64 relocation instead of + GPREL22 . */ +extern int _dl_sysinfo_break attribute_hidden __attribute__((section(".tex= t"))); # define DL_SYSINFO_DEFAULT ((uintptr_t) &_dl_sysinfo_break) # define DL_SYSINFO_IMPLEMENTATION \ asm (".text\n\t" \ =2D-=20 2.39.3 =2D-=20 Andreas K. H=FCttel dilfridge@gentoo.org Gentoo Linux developer (council, toolchain, base-system, perl, libreoffice) --nextPart1857047.tdWV9SEqCh Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. Content-Transfer-Encoding: 7Bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQKTBAABCgB9FiEE/Rnm0xsZLuTcY+rT3CsWIV7VQSoFAmTFW7tfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldEZE MTlFNkQzMUIxOTJFRTREQzYzRUFEM0RDMkIxNjIxNUVENTQxMkEACgkQ3CsWIV7V QSrnjw/+NqPIi7q5M04YuGW//i3jbjTvlZ/sfjDPSZYqMcxTKFVZkfIC3zfhHeU3 7tyHKBnP754Tt2L/rIXjztoEBVOJCf1DBqQR8ygNcgdJftwCl+reAFS5k2xxXqGh MwoAcShBvobTU58IhtXw12R6T3QUJtMiCamMBAihhMy94gsMZKr7WgeA0edzFEgJ RtcLBbv9SU838KuaRCiKcA74wJZo1V32UIPu/tiiYsAVpZmXgN5pbNbVWhCfIkx5 P78iv892srGY3NyR1kNRzYPTfvDPBadCa1RfTAdydoG4HnRqp7K/K3K5jopYmGvt DczvspwF2UdHyo6oVdyeIK2C2h3VbDowGmAkRicTmxDP/gEk1HdsDAsSGZ3GGsfC 40fJ7/AEA+xJ59owqDggBdOearG6hueITnOAd2/muXC7g9Tm1+o8WNwKhO7fntD2 u757owzYAuGcyFVpA4qPX/KWkB+fRibaWevK5A9wjbN3/xW9tkrXmJNRjoiasE70 7AFgosZbafpbxHRPzr7OGtPnReu+51tekZQxYKJlHZLw1PhbhueT9SLuoNhMgrTP OjmWa1V/3grjV8f0RK7rXpF+r5uV3/bZz0gcp5uv+VJLCAdPQYJk8yW30Qv1BMzc 0Jk5cQHWDgmrkRrT1mHTp45xOegouhw9PffdxlKoJNV4fs0UXmI= =S3um -----END PGP SIGNATURE----- --nextPart1857047.tdWV9SEqCh--