Hi Marcus,
applied, tested and pushed.
best regards
Waldemar
Marcus Hähnel wrote,
Hello devs,
The _start symbol does not necessarily have to be on the first page of the application. But the __ehdr_start symbol is
always at address zero for PIE binaries.
So now we know how it works ;)
Best regards,
--
+++++++++++++++++++
Register now for our workshop "Get to know L4Re in 3 days" on April 8-10. Learn to design and deploy secure system
architectures for your product with L4Re: https://www.kernkonzept.com/workshop-getting-started-with-l4re/
+++++++++++++++++++
Kernkonzept GmbH
Sitz: Dresden
HRB 31129
Geschäftsführer: Dr.-Ing. Michael Hohmuth
From 6bff37e29b34740e2ff0d2b6b8ab57e54c0580ed Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jan=20Kl=C3=B6tzke?= jan.kloetzke@kernkonzept.com
Date: Wed, 19 Mar 2025 08:04:44 +0100
Subject: [PATCH] Use __ehdr_start as known zero link address symbol
The _start symbol does not necessarily have to be on the first page of
the application. But the __ehdr_start symbol is always at address zero
for PIE binaries.
libc/sysdeps/linux/aarch64/crt1.S | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libc/sysdeps/linux/aarch64/crt1.S b/libc/sysdeps/linux/aarch64/crt1.S
index e9f946894..965d3265d 100644
--- a/libc/sysdeps/linux/aarch64/crt1.S
+++ b/libc/sysdeps/linux/aarch64/crt1.S
@@ -52,8 +52,8 @@ _start:
/* Save off the atexit pointer */
mov x19, x0
- /* Calculate load address... idk how this works, but it does */
- adrp x0, _start
--
2.47.1
devel mailing list -- devel@uclibc-ng.org
To unsubscribe send an email to devel-leave@uclibc-ng.org