To put some context, I trying to make a library, which defines an entry point and would then call a user-defined main for the execution of the actual user-application.