Removed -fno-strict-aliasing for OS/2 (not supported by all supported gcc versions).
authorStefan Neis <Stefan.Neis@t-online.de>
Sat, 11 Mar 2006 18:02:38 +0000 (18:02 +0000)
committerStefan Neis <Stefan.Neis@t-online.de>
Sat, 11 Mar 2006 18:02:38 +0000 (18:02 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@38003 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

configure.in

index cd9eb836ca37b55c87fafeb70399068e8b7f55fb..8e51943411b8f692d839139800c9f47df0866d45 100644 (file)
@@ -5147,10 +5147,19 @@ if test "$wxUSE_OPTIMISE" = "no" ; then
     fi
 else
     if test "$GCC" = yes ; then
-        dnl Switch on optimisation but keep strict-aliasing off for now (see
-        dnl -fstrict-aliasing in the gcc manual). When it is switched back on
-        dnl consider using -Wstrict-aliasing=2.
-        OPTIMISE_CFLAGS="-O2 -fno-strict-aliasing"
+        case "${host}" in
+            *-pc-os2_emx | *-pc-os2-emx )
+                dnl Not all of the supported gcc versions understand
+                dnl -fstrict-aliasing and none actually needs it (yet).
+                OPTIMISE_CFLAGS="-O2"
+            ;;
+            *)
+                dnl Switch on optimisation but keep strict-aliasing off for
+                dnl now (see -fstrict-aliasing in the gcc manual). When it is
+                dnl switched back on consider using -Wstrict-aliasing=2.
+                OPTIMISE_CFLAGS="-O2 -fno-strict-aliasing"
+            ;;
+        esac
     else
         OPTIMISE_CFLAGS="-O"
     fi