diff options
-rw-r--r-- | Makefile | 2 | ||||
-rwxr-xr-x | configure | 49 |
2 files changed, 29 insertions, 22 deletions
@@ -24,7 +24,7 @@ CXXFLAGS:= -Wall $(CXXFLAGS) # Turn off some annoying and not-so-useful warnings CXXFLAGS+= -Wno-long-long -Wno-multichar -Wno-unknown-pragmas -Wno-reorder # Enable even more warnings... -CXXFLAGS+= -pedantic -Wpointer-arith -Wcast-qual -Wcast-align +CXXFLAGS+= -Wpointer-arith -Wcast-qual -Wcast-align CXXFLAGS+= -Wshadow -Wimplicit -Wnon-virtual-dtor -Wwrite-strings # Disable RTTI and exceptions, and enabled checking of pointers returned by "new" @@ -973,27 +973,6 @@ if test "$cxx_verc_fail" = yes ; then fi # -# Do CXXFLAGS now we know the compiler version -# -if test "$_cxx_major" -ge "3" ; then - case $_host_os in - mingw* | cygwin* | dreamcast) - CXXFLAGS="$CXXFLAGS -W -Wno-unused-parameter" - ;; - *) - CXXFLAGS="$CXXFLAGS -ansi -W -Wno-unused-parameter" - ;; - esac - add_line_to_config_mk 'HAVE_GCC3 = 1' -fi; - -if test "$_cxx_major" -ge "4" && test "$_cxx_minor" -ge "3" ; then - CXXFLAGS="$CXXFLAGS -Wno-parentheses -Wno-empty-body" -else - CXXFLAGS="$CXXFLAGS -Wconversion" -fi; - -# # Check for endianness # echo_n "Checking endianness... " @@ -1755,6 +1734,34 @@ case $_backend in esac # +# Do CXXFLAGS now we know the compiler version +# +if test "$_cxx_major" -ge "3" ; then + case $_host_os in + mingw* | cygwin* | dreamcast) + CXXFLAGS="$CXXFLAGS -W -Wno-unused-parameter" + ;; + *) + CXXFLAGS="$CXXFLAGS -ansi -W -Wno-unused-parameter" + ;; + esac + add_line_to_config_mk 'HAVE_GCC3 = 1' +fi; + +if test "$_cxx_major" -ge "4" && test "$_cxx_minor" -ge "3" ; then + CXXFLAGS="$CXXFLAGS -Wno-parentheses -Wno-empty-body" +else + CXXFLAGS="$CXXFLAGS -Wconversion" +fi; + +# Some platforms use certain GNU extensions in header files +case $_host_os in +*) + CXXFLAGS="$CXXFLAGS -pedantic" + ;; +esac + +# # Engine selection # _engines_built_static="" |