[SDL] sdlmain

Julien Lecomte julien at famille-lecomte.net
Wed Jul 5 10:17:19 PDT 2006


On 05/07/2006 14:46, Torsten Giebl wrote:
>>> I suggest to see how this is done in Allegro:
>>> int main(void) {
>>> allegro_init(); /* more stuff goes here */
>>> ...
>>> return 0; }
>>> END_OF_MAIN()
>>>
>>> END_OF_MAIN is a special macro which is different for different
>>> platforms. See Allegro's headers for more info.
>> Did all missed this message?
>> OK, I explain more.
> 
> That would be an option for SDL1.3 to do it, if all
> the compilers that SDL supports allow this.
> 

That's not a solution, that's a hack. Just like the current one which is 
not required for a mingw host.
Hacks are *evil*.
And so are "#define" (what END_OF_MAIN() would be), well, at least in C++.

I state my case; SDL does *not* need a SDLmain library and/or prototype 
in mingw.




More information about the SDL mailing list