Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

__original_main no longer in WASI #58

Open
guregu opened this issue Sep 18, 2022 · 3 comments
Open

__original_main no longer in WASI #58

guregu opened this issue Sep 18, 2022 · 3 comments

Comments

@guregu
Copy link

guregu commented Sep 18, 2022

As of WASI SDK 16, __original_main is no longer added, breaking this:

wizer/include/wizer.h

Lines 87 to 90 in 65e345f

/* `main()`. This may change in the future; when it does, we will */ \
/* coordinate with the WASI-SDK toolchain to implement this entry */ \
/* point in an alternate way. */ \
__original_main(); \

https://github.com/WebAssembly/wasi-sdk/releases/tag/wasi-sdk-16
I am not sure what issue #295 is referring to there.

@srenatus
Copy link

WebAssembly/wasi-libc#295

@Zzzode
Copy link

Zzzode commented Sep 19, 2022

Replace __origin_main() with __main_argc_argv() manually could be a workaround?

@guregu
Copy link
Author

guregu commented Oct 6, 2022

Thanks @Zzzode, adding this seems to work:

#ifndef __original_main
#define __original_main __main_argc_argv
#endif

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants