Re: [AD] END_OF_MAIN, again

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


MSVC was throwing warning because I used AL_FUNC to declare _mangled_main and __install_allegro which add _declspec(dllimport), I switch to extern and it works fine. I also found more elegant way to force linker to include WinMain. I added new function with WinMain called _force_main_linking and in alwin.h define install_allegro to be (_force_main_linking() ? install_allegro : install_allegro). This solves problem about install_allegro not being inline.

Attachment: alwin.h.diff
Description: Binary data

Attachment: wmain.c
Description: Binary data



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/