PPC startup code
Geoff Keating
geoffk@geoffk.org
Sat Mar 15 23:01:00 GMT 2003
> From: Paul Mackerras <paulus@samba.org>
> Date: Sat, 15 Mar 2003 13:50:11 +1100 (EST)
> Maybe what we can do instead is to have the PPC __libc_start_main call
> the generic one. Something like this:
>
> #define __libc_start_main __generic_libc_start_main
> #include <sysdeps/generic/libc-start.c>
>
> __libc_start_main(...)
> {
> /* detect static binaries, do all that stuff */
> if (*stack_on_entry == 0) {
> argc = *(int *)stack_on_entry;
> argv = (char **)(stack_on_entry + 4);
> }
> __generic_libc_start_main(...)
> }
>
> Thoughts?
That would make sense. It'd remove the duplicated code without
encountering any of the problems I mentioned.
--
- Geoffrey Keating <geoffk@geoffk.org>
More information about the Libc-alpha
mailing list