]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
[AArch64] Use hidden __GI__dl_argv in rtld startup code
authorSzabolcs Nagy <szabolcs.nagy@arm.com>
Wed, 21 Jun 2017 12:47:07 +0000 (13:47 +0100)
committerSzabolcs Nagy <szabolcs.nagy@arm.com>
Wed, 21 Jun 2017 13:54:11 +0000 (14:54 +0100)
We rely on the symbol being locally defined so using extern symbol
is not correct and the linker may complain about the relocations.

ChangeLog
sysdeps/aarch64/dl-machine.h

index 2cd20ad38d219321306bf927f6b1cdd581ee97ea..7371bcbd83cb6e249620afc216538c2175cef0b8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2017-06-21  Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+       * sysdeps/aarch64/dl-machine.h (RTLD_START_1): Change _dl_argv to the
+       hidden __GI__dl_argv symbol.
+
 2017-06-21  Florian Weimer  <fweimer@redhat.com>
 
        * sysdeps/posix/getaddrinfo.c (gaih_inet): Call __inet_pton_length
index 02fab04f4009842dce5f3f6f10a8bc55fe227cd4..60472036f5731da425640af23f70c2f3ecc37bd9 100644 (file)
@@ -194,8 +194,8 @@ _dl_start_user:                                                             \n\
        cmp     " PTR "0, #0                                            \n\
        bne     1b                                                      \n\
        // Update _dl_argv                                              \n\
-       adrp    x3, _dl_argv                                            \n\
-       str     " PTR "2, [x3, #:lo12:_dl_argv]                         \n\
+       adrp    x3, __GI__dl_argv                                       \n\
+       str     " PTR "2, [x3, #:lo12:__GI__dl_argv]                    \n\
 .L_done_stack_adjust:                                                  \n\
        // compute envp                                                 \n\
        add     " PTR "3, " PTR "2, " PTR "1, lsl #" PTR_SIZE_LOG "     \n\