So trying to compile more complex programs than a hello_world, I'm
seeing segmentation faults on arm, haven't tried other arches. Here's
the backtrace all the failing programs produce. I'll have to try getting
a better backtrace.
(gdb) backtrace
#0 0x2a023248 in _memcpy ()
#1 0x2a0167d8 in __libc_setup_tls ()
#2 0x2a015f64 in __uClibc_init ()
#3 0x2a016194 in __uClibc_main ()
#4 0xbeb50684 in ?? ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
On 7/20/2022 1:35 AM, Yann Sionneau wrote:
I can confirm that with both patches applied
(Lance's patch on GCC and
linted's patch on uClibc-ng) I can build a working hello world for ARM
with -fpie --static-pie.
Btw your GCC patch also applies well to GCC 10.3.0. (Tested with
Buildroot)
Tested-by: Yann Sionneau <yann(a)sionneau.net>
Yann
On 19/07/2022 19:38, Lance Fredrickson wrote:
-static-pie on arm is working well for me. As it
turns out GCC
doesn't currently handle -static-pie with arm, and is not passing the
correct options to the linker. This patch applies onto GCC 12.1 which
fixes that, and I will try to upstream.
https://github.com/lancethepants/gcc/commit/043704d5f827af775cf796b9ec144b7…
One thing that threw me for a while is that the 'file' command in
Debian 10 is apparently too old to know what static-pie is, and
reports it as dynamically linked but without a reference to to the
dynamic linker.
Nice patch! I'm glad to see this feature come to uclibc-ng. I saw you
had a arm64 branch in your repo so would be cool to see that too.
thanks,
Lance
_______________________________________________
devel mailing list -- devel(a)uclibc-ng.org
To unsubscribe send an email to devel-leave(a)uclibc-ng.org
To declare a filtering error, please use the following link :
https://www.security-mail.net/reporter.php?mid=140bd.62d6ec2c.e850f.0&r…
_______________________________________________
devel mailing list -- devel(a)uclibc-ng.org
To unsubscribe send an email to devel-leave(a)uclibc-ng.org