Bug 802343 - Port |Bug 557000 - Correctly set GCC_VERSION on mingw| and |Bug 797793 - Disable format warnings on mingw| to comm-central r=Callek
authorIan Neal <iann_cvs@blueyonder.co.uk>
Mon, 29 Oct 2012 18:24:06 +0000
changeset 14136 aab3a6beb9625390fbcd9324378ed2d62d3a6231
parent 14135 d8491065a5085b48b630d0ec2d00826694610236
child 14137 852d3e76c665f5a249a590ec4b5d07cc582818ac
push id804
push userbugzilla@standard8.plus.com
push dateMon, 07 Jan 2013 21:31:35 +0000
treeherdercomm-beta@9fdc5c67cdb1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersCallek
bugs802343, 557000, 797793
Bug 802343 - Port |Bug 557000 - Correctly set GCC_VERSION on mingw| and |Bug 797793 - Disable format warnings on mingw| to comm-central r=Callek
configure.in
--- a/configure.in
+++ b/configure.in
@@ -1852,16 +1852,22 @@ ia64*-hpux*)
         RCFLAGS='-O coff --use-temp-file'
         # mingw doesn't require kernel32, user32, and advapi32 explicitly
         LIBS="$LIBS -luuid -lgdi32 -lwinmm -lwsock32"
         MOZ_FIX_LINK_PATHS=
         DYNAMIC_XPCOM_LIBS='-L$(LIBXUL_DIST)/lib -lxpcom -lxpcom_core -lmozalloc'
         XPCOM_FROZEN_LDOPTS='-L$(LIBXUL_DIST)/lib -lxpcom -lmozalloc'
         DLL_PREFIX=
         IMPORT_LIB_SUFFIX=dll.a
+        GCC_VERSION=`$CC -v 2>&1 | awk '/^gcc version/ { print $3 }'`
+
+        # We use mix of both POSIX and Win32 printf format across the tree,
+        # so format warnings are useless on mingw.
+        MOZ_C_SUPPORTS_WARNING(-Wno-, format, ac_c_has_wno_format)
+        MOZ_CXX_SUPPORTS_WARNING(-Wno-, format, ac_cxx_has_wno_format)
     else
         TARGET_COMPILER_ABI=msvc
         HOST_CC='$(CC)'
         HOST_CXX='$(CXX)'
         HOST_LD='$(LD)'
         if test "$AS_BIN"; then
             AS="$(basename "$AS_BIN")"
         fi