This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Why is _dl_relocate_static_pie linked into crt1.o?


On 07/05/2018 04:23 PM, Carlos O'Donell wrote:
On 07/05/2018 10:20 AM, Florian Weimer wrote:
On 07/05/2018 04:12 PM, Andreas Schwab wrote:
On Jul 05 2018, Florian Weimer <fweimer@redhat.com> wrote:

Note that this is about the stub function in csu/,

Isn't that built with stack projector automatically?  It certainly is
for me.

Not for me:

gcc static-reloc.c -c -std=gnu11 -fgnu89-inline  -O2 -Wall -Werror -Wp,-D_GLIBCXX_ASSERTIONS -Wundef -Wwrite-strings -fasynchronous-unwind-tables -fcf-protection -fmerge-all-constants -frounding-math -fstack-clash-protection -fstack-protector-strong -g -m64 -mtune=generic -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wstrict-prototypes -Wold-style-definition -fno-math-errno   -fpie -fno-stack-protector -DSTACK_PROTECTOR_LEVEL=0 -ftls-model=initial-exec […]

That's due to this in csu/Makefile:

CFLAGS-.o += $(no-stack-protector)
CFLAGS-.op += $(no-stack-protector)
CFLAGS-.os += $(no-stack-protector)

Can we fix this with a subsequent CFLAGS-static-reloc.o override?

I mainly care about the .os file.  With the override, I get this:

-fPIC -fno-stack-protector -DSTACK_PROTECTOR_LEVEL=0 -fstack-protector-strong

So the macro definition is wrong, but for an empty file, this doesn't really matter.

I'm hesitant to make any major changes now that we are in slushy freeze
fro the release.

Well, see my message to Szabolcs: This stuff is currently broken anyway (on arm, don't know about m68k).

Thanks,
Florian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]