mirror of
git://git.musl-libc.org/musl
synced 2024-12-14 02:35:17 +00:00
9b95fd0944
this cleans up what had become widespread direct inline use of "GNU C"
style attributes directly in the source, and lowers the barrier to
increased use of hidden visibility, which will be useful to recovering
some of the efficiency lost when the protected visibility hack was
dropped in commit dc2f368e56
, especially
on archs where the PLT ABI is costly.
15 lines
355 B
C
15 lines
355 B
C
#define START "_start"
|
|
#define _dlstart_c _start_c
|
|
#include "../ldso/dlstart.c"
|
|
|
|
int main();
|
|
weak void _init();
|
|
weak void _fini();
|
|
_Noreturn int __libc_start_main(int (*)(), int, char **,
|
|
void (*)(), void(*)(), void(*)());
|
|
|
|
hidden _Noreturn void __dls2(unsigned char *base, size_t *sp)
|
|
{
|
|
__libc_start_main(main, *sp, (void *)(sp+1), _init, _fini, 0);
|
|
}
|