summaryrefslogtreecommitdiff
path: root/config.lib
diff options
context:
space:
mode:
authortruelight <truelight@openttd.org>2007-03-02 00:45:08 +0000
committertruelight <truelight@openttd.org>2007-03-02 00:45:08 +0000
commit89d8f5f7b5376850e8d2f0c1b72253d012ed9bed (patch)
tree1a4ab6631dfa64d27a044f9f0969aa4a6d41cc63 /config.lib
parent322953ad2e6496ae686bab4e2e66529807752ca9 (diff)
downloadopenttd-89d8f5f7b5376850e8d2f0c1b72253d012ed9bed.tar.xz
(svn r8968) -Fix (win32): silent g++ 4.0+ warnings about breaking strict-aliasing
Diffstat (limited to 'config.lib')
-rw-r--r--config.lib3
1 files changed, 3 insertions, 0 deletions
diff --git a/config.lib b/config.lib
index 4f0d501db..56d6c402c 100644
--- a/config.lib
+++ b/config.lib
@@ -671,6 +671,9 @@ make_cflags_and_ldflags() {
if [ "$os" = "CYGWIN" ] || [ "$os" = "MINGW" ]; then
LDFLAGS="$LDFLAGS -Wl,--subsystem,windows"
LIBS="$LIBS -lws2_32 -lwinmm -lgdi32 -ldxguid -lole32"
+ if [ $cc_version -ge 40 ]; then
+ CFLAGS="$CFLAGS -fno-strict-aliasing"
+ fi
fi
if [ "$os" != "CYGWIN" ] && [ "$os" != "FREEBSD" ] && [ "$os" != "MINGW" ] && [ "$os" != "MORPHOS" ] && [ "$os" != "OSX" ] && [ "$os" != "WINCE" ] && [ "$os" != "PSP" ]; then