diff --git a/tools/configure b/tools/configure index b7932be13f..f9ef9803e2 100755 --- a/tools/configure +++ b/tools/configure @@ -111,7 +111,7 @@ simcc () { elif [ "$simver" = "sdl" ]; then # sdl version GCCOPTS="$GCCOPTS `sdl-config --cflags`" - LDOPTS="`sdl-config --libs`" + LDOPTS="`sdl-config --libs` -mconsole" checksoundcard else # x11 version diff --git a/uisimulator/sdl/uisdl.c b/uisimulator/sdl/uisdl.c index 8c9d216f10..d298167df1 100644 --- a/uisimulator/sdl/uisdl.c +++ b/uisimulator/sdl/uisdl.c @@ -187,6 +187,11 @@ int sim_app_main(void *param) return 0; } +#if defined(WIN32) && defined(main) +/* Don't use SDL_main on windows -> no more stdio redirection */ +#undef main +#endif + int main(int argc, char *argv[]) { if (argc >= 1) {