]>
git.proxmox.com Git - wasi-libc.git/blob - libc-bottom-half/crt/crt1-command.c
706ab97e69b0272aa7bd9a57ce095051944f09c9
3 extern void __wasm_call_ctors(void);
4 extern int __main_void(void);
5 extern void __wasm_call_dtors(void);
7 __attribute__((export_name("_start")))
9 // Call `__main_void` which will either be the application's zero-argument
10 // `__main_void` function or a libc routine which obtains the command-line
11 // arguments and calls `__main_argv_argc`.
12 int r
= __main_void();
14 // If main exited successfully, just return, otherwise call `exit`.