Added GCC check in windows.mak and win32 part of sdl.mak and also did silence of gcc 4.6 in win32 specific video.c (no whatsnew)

This commit is contained in:
Miodrag Milanovic 2011-12-15 08:17:18 +00:00
parent e97020e394
commit f23a3ef001
3 changed files with 11 additions and 0 deletions

View File

@ -398,6 +398,11 @@ endif
# Static linking
LDFLAGS += -static-libgcc
TEST_GCC = $(shell gcc --version)
ifeq ($(findstring 4.4,$(TEST_GCC)),)
#if we use new tools
LDFLAGS += -static-libstdc++
endif
LIBS += -lSDL.dll
LIBS += -luser32 -lgdi32 -lddraw -ldsound -ldxguid -lwinmm -ladvapi32 -lcomctl32 -lshlwapi

View File

@ -397,6 +397,7 @@ static BOOL CALLBACK monitor_enum_callback(HMONITOR handle, HDC dc, LPRECT rect,
info.cbSize = sizeof(info);
result = GetMonitorInfo(handle, (LPMONITORINFO)&info);
assert(result);
result++; // to silence gcc 4.6
// allocate a new monitor info
monitor = global_alloc_clear(sdl_monitor_info);

View File

@ -246,6 +246,11 @@ endif
# ensure we statically link the gcc runtime lib
LDFLAGS += -static-libgcc
TEST_GCC = $(shell gcc --version)
ifeq ($(findstring 4.4,$(TEST_GCC)),)
#if we use new tools
LDFLAGS += -static-libstdc++
endif
# add the windows libraries
LIBS += -luser32 -lgdi32 -ldsound -ldxguid -lwinmm -ladvapi32 -lcomctl32 -lshlwapi -ldinput8 -lwsock32