]> git.ipfire.org Git - thirdparty/glibc.git/commit
x86: Allow undefined _DYNAMIC in static executable
authorH.J. Lu <hjl.tools@gmail.com>
Thu, 28 Sep 2017 22:28:00 +0000 (15:28 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Thu, 28 Sep 2017 22:28:12 +0000 (15:28 -0700)
commit4088d8dd29ce0629eeaa7cceca02414c85d98e05
tree0b807276e1826b3c4522721d076aa81c23c5da8b
parent4d3693ec1cb7d247a217dc1eb7121c658f818dca
x86: Allow undefined _DYNAMIC in static executable

When --enable-static-pie is used to build static PIE, _DYNAMIC is used
to compute the load address of static PIE.  But _DYNAMIC is undefined
when creating static executable.  This patch makes _DYNAMIC weak in PIE
libc.a so that it can be undefined.

* sysdeps/i386/dl-machine.h (elf_machine_load_address): Allow
undefined _DYNAMIC in PIE libc.a.
* sysdeps/x86_64/dl-machine.h (elf_machine_load_address):
Likewse.
ChangeLog
sysdeps/i386/dl-machine.h
sysdeps/x86_64/dl-machine.h