When compiling an object produced by cranelift on linux everything works exactly as I expect but when I try to compile it on windows I get an error about a missing entry point. With gcc this is "undefined reference to `WinMain'" and with cl its "LINK : fatal error LNK1561: entry point must be defined". Is there something I need to do to identify the main function as such when generating the ir?
The main function should work if you are linking against libc. WinMain is the entrypoint on Windows when not using libc.
Thanks for the help! I had foolishly failed to export the main function.
Last updated: Nov 22 2024 at 16:03 UTC