]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
x86-64: Check PIC instead of SHARED in start.S
authorH.J. Lu <hjl.tools@gmail.com>
Wed, 2 Aug 2017 17:27:14 +0000 (10:27 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Wed, 2 Aug 2017 17:27:34 +0000 (10:27 -0700)
Since start.o may be compiled as PIC, we should check PIC instead of
SHARED.

* sysdeps/x86_64/start.S (_start): Check PIC instead of SHARED.

ChangeLog
sysdeps/x86_64/start.S

index b3be5a7d19fd58beb9ea6f5790444a089a7c1a26..061895483484c9ed8771a6a0ebd40e5e481311c2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2017-08-02  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * sysdeps/x86_64/start.S (_start): Check PIC instead of SHARED.
+
 2017-08-02  H.J. Lu  <hongjiu.lu@intel.com>
 
        * sysdeps/i386/i686/multiarch/memcmp-sse4.S: Check PIC instead
index 62a00eaeaa006ae19d51f9ed6323689cdfb82d76..9edd17b60cd54ec9eef11c76ab02322dcb5d057a 100644 (file)
@@ -96,7 +96,7 @@ ENTRY (_start)
           which grow downwards).  */
        pushq %rsp
 
-#ifdef SHARED
+#ifdef PIC
        /* Pass address of our own entry points to .fini and .init.  */
        mov __libc_csu_fini@GOTPCREL(%rip), %R8_LP
        mov __libc_csu_init@GOTPCREL(%rip), %RCX_LP