This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] elf: Apply attribute_relro to pointers in elf/dl-minimal.c
- From: Joseph Myers <joseph at codesourcery dot com>
- To: Florian Weimer <fweimer at redhat dot com>
- Cc: <libc-alpha at sourceware dot org>, <mjw at fedoraproject dot org>, Patsy Griffin <patsy at redhat dot com>
- Date: Wed, 26 Feb 2020 21:23:49 +0000
- Subject: Re: [PATCH] elf: Apply attribute_relro to pointers in elf/dl-minimal.c
- Ironport-sdr: +qbeX/INqJHDlImaCMIIz96coaBzavSdeyMoxWb2t9tAq/LGKoZsTsS2M2Q+7cPeJrM2wxenaa NU1FGtBHEN+tczbMr/fDMyt9HAnBdXTObrkQnIQ5X0U0q+hXH85ofy6EK9+S/vVGiT7MYQnOmI NBf26UPLf20pYHPGuAkHHv5EMe+3fCDSrKJ6Dc99tQN8OmAQvP6cyk9jj7xKdRLbuOgZj2zzER 9kM9XQFFXEK/8yYnc2NYE5o0M8VlhkM+SpZ2jTqKCIaacQ6Ap+rb6cQp5ug4ryHeysNAs1yHAO Ls0=
- Ironport-sdr: x6KxXubxT/wN8jduUcUsefjVgYE54zjP+03Ut0uwsku8YLY+T475fOp6hB47RwT7PKTLyGwnO6 g7y3z8eszLVQAOYIn2uLZ45mAYWQ0nz7vmhj6jvNnRZVydma3gkZN6L/ezB0nRHC/bxyUC7NUG XZkvVB8+MxJ5qgKVus9TlpjxxnJCP6PpudsXkHQvfZx9JoAFEX4HUFOPlxfNjxfRs5ozVGipJm 5QkYbbT3eNPTMdhGKsm/WN18rzlScHukbuw2nWEQF+jMCY3uTIEcHAB61XHW/ihExcAj+V5mqv 0AE=
- References: <87tv3d2x91.fsf@oldenburg2.str.redhat.com>
This change (commit 758599bc9dcc5764e862bd9e1613c5d1e6efc5d3) breaks the
build for alpha-linux-gnu with GCC and binutils mainline. I get a series
of errors of the form (this is in the "compilers" glibc build):
/scratch/jmyers/glibc/many10/build/compilers/alpha-linux-gnu/glibc/alpha-linux-gnu/elf/librtld.os:
in function `calloc':
/scratch/jmyers/glibc/many10/src/glibc/elf/../include/rtld-malloc.h:44:(.text+0xd98):
relocation truncated to fit: GPREL16 against symbol `__rtld_calloc'
defined in .data.rel.ro section in
/scratch/jmyers/glibc/many10/build/compilers/alpha-linux-gnu/glibc/alpha-linux-gnu/elf/librtld.os
/scratch/jmyers/glibc/many10/build/compilers/alpha-linux-gnu/glibc/alpha-linux-gnu/elf/librtld.os:
in function `malloc':
/scratch/jmyers/glibc/many10/src/glibc/elf/../include/rtld-malloc.h:56:(.text+0x2978):
relocation truncated to fit: GPREL16 against symbol `__rtld_malloc'
defined in .data.rel.ro section in
/scratch/jmyers/glibc/many10/build/compilers/alpha-linux-gnu/glibc/alpha-linux-gnu/elf/librtld.os
https://sourceware.org/ml/libc-testresults/2020-q1/msg00270.html
Reverting to the previous glibc commit, while keeping other components the
same, eliminates that build failure.
I don't know whether the problem lies in GCC, binutils or glibc (but
https://sourceware.org/ml/libc-testresults/2020-q1/msg00271.html shows it
doesn't appear with GCC 9 branch and binutils 2.34 branch).
--
Joseph S. Myers
joseph@codesourcery.com