#include <stdio.h>int main( int argc, char** argv ){printf("Hello, World!\n");return (0);}
Mike.--
You received this message because you are subscribed to the Google Groups "Native-Client-Discuss" group.
To post to this group, send email to native-cli...@googlegroups.com.
To unsubscribe from this group, send email to native-client-di...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/native-client-discuss?hl=en.
- main() is already taken by NaCl, so after the file is compiled objcopy is used to rename main to something else.
main() isn't reserved by NaCl, by the way. In the SDK, main() is just a convenience function that calls PpapiPluginMain() (see src/untrusted/irt_stub/plugin_main_irt.c in the NaCl source tree). If you provide your own main(), it will just override the version that is provided by libppapi.a/libppapi.so.I didn't dig into it too much, but I initially just tried to override main() and it caused the plugin to crash.
That will put main() in the wrong thread...Actually that's a question: Will the PPAPI callbacks, functions, etc. happen/work in whatever thread PpapiPluginMain() is called from? Or is there some other reason it has to be in the "main" thread?
That will put main() in the wrong thread...Actually that's a question: Will the PPAPI callbacks, functions, etc. happen/work in whatever thread PpapiPluginMain() is called from?