X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=crt%2Fcrt1.c;h=8fe8ab5d8c3ea005ce9e0eb07e72cadb4747b0ab;hb=2b2c8aafce9d80f9d58652643538f4d58e82b856;hp=e69de29bb2d1d6434b8b29ae775ad8c2e48c5391;hpb=0b44a0315b47dd8eced9f3b7f31580cf14bbfc01;p=musl diff --git a/crt/crt1.c b/crt/crt1.c index e69de29b..8fe8ab5d 100644 --- a/crt/crt1.c +++ b/crt/crt1.c @@ -0,0 +1,19 @@ +#include +#include "libc.h" + +#define START "_start" + +#include "crt_arch.h" + +int main(); +weak void _init(); +weak void _fini(); +int __libc_start_main(int (*)(), int, char **, + void (*)(), void(*)(), void(*)()); + +void _start_c(long *p) +{ + int argc = p[0]; + char **argv = (void *)(p+1); + __libc_start_main(main, argc, argv, _init, _fini, 0); +}