Removes low-level hacks to call a code before the main function. It simplifies the logic and allows to not follow that way for 64-bits.
The patch isn't the cleanest one rather the simplest. Ideally we need to refactor the mess inside main.cpp and use proper scopes.