[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
On 13 Apr 2009, at 8:58 , Elias Pschernig wrote:
I don't think there should be a problem. The "main" function already
was inside
main.m - so basically instead of the END_OF_MAIN() macro the OSX
port now has this:
Yes, but it shouldn't by in the dylib, which I think it might be right
now. We need something like liballeg-main.a (or liballeg-main.dylib?)
Hmm... evil plan here: maybe we can treat "magic main" as an addon in
some sense?
Having thought this, I think I like this idea.
The only problem is Windows where there simply is no "main"
function, instead
the program entry point is WinMain.
That's the other thing I wanted to look at: merging in the patches
that were posted to make it possible to use a regular main() in Windows.
At least that's how it is in A4. Someone said there's a compiler
switch to make
mingw recognize a "main" function
From what I recall, MinGW actually works with either of them just
fine. It's only MSVC that needs a switch (or #pragma) to use a normal
main() instead of WinMain().
- but the question is, do we want to force
such a compiler switch,
I would, but we possibly want to allow users to disable it.
and can it also work with other compilers?
Good question. Apart from MSVC and MinGW, what compilers do we
currently care about? Someone should check these.
Evert