From c93ee967cd688bc6d43c795b48e988075655a67f Mon Sep 17 00:00:00 2001 From: Sergey Bugaev Date: Wed, 17 May 2023 22:14:35 +0300 Subject: hurd: Also make it possible to call strlen very early strlen, which is another ifunc-selected function, is invoked during early static executable startup if the argv arrives from the exec server. Make it not crash. Checked on x86_64-gnu: statically linked executables launched after the exec server is up now start up successfully. Signed-off-by: Sergey Bugaev Message-Id: <20230517191436.73636-10-bugaevc@gmail.com> --- sysdeps/mach/hurd/x86_64/static-start.S | 3 +++ 1 file changed, 3 insertions(+) (limited to 'sysdeps/mach') diff --git a/sysdeps/mach/hurd/x86_64/static-start.S b/sysdeps/mach/hurd/x86_64/static-start.S index cc8e2410ea..0fed375cdf 100644 --- a/sysdeps/mach/hurd/x86_64/static-start.S +++ b/sysdeps/mach/hurd/x86_64/static-start.S @@ -22,6 +22,9 @@ _start: leaq __memcpy_sse2_unaligned(%rip), %rax movq %rax, memcpy@GOTPCREL(%rip) + leaq __strlen_sse2(%rip), %rax + movq %rax, strlen@GOTPCREL(%rip) + call _hurd_stack_setup xorq %rdx, %rdx jmp _start1 -- cgit v1.2.1