Bug 1075758 - Update the local patch to suppress various clang warnings in ICU. r=glandium
authorJeff Walden <jwalden@mit.edu>
Fri, 12 Jun 2015 14:25:23 -0700
changeset 282383 80841ebc9acaa84a19a944e1f5b74c8d435d51f4
parent 282382 cbcc5ea79885e44d23d3053a29cdc8beb492a134
child 282384 b8ff9ab0b32dce4a05701a176ef7a1a45d8e796c
push id5067
push userraliiev@mozilla.com
push dateMon, 21 Sep 2015 14:04:52 +0000
treeherdermozilla-beta@14221ffe5b2f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersglandium
bugs1075758
milestone42.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1075758 - Update the local patch to suppress various clang warnings in ICU. r=glandium
intl/icu-patches/suppress-warnings.diff
intl/icu/source/acinclude.m4
intl/icu/source/configure
intl/update-icu.sh
--- a/intl/icu-patches/suppress-warnings.diff
+++ b/intl/icu-patches/suppress-warnings.diff
@@ -1,12 +1,12 @@
 diff --git a/intl/icu/source/acinclude.m4 b/intl/icu/source/acinclude.m4
 --- a/intl/icu/source/acinclude.m4
 +++ b/intl/icu/source/acinclude.m4
-@@ -466,30 +466,36 @@ AC_DEFUN([AC_CHECK_STRICT_COMPILE],
+@@ -473,30 +473,36 @@ AC_DEFUN([AC_CHECK_STRICT_COMPILE],
              *)
                  # Do not use -ansi. It limits us to C90, and it breaks some platforms.
                  # We use -std=c99 to disable the gnu99 defaults and its associated warnings
                  CFLAGS="$CFLAGS -std=c99"
                  ;;
              esac
              
              CFLAGS="$CFLAGS -Wall -pedantic -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings"
@@ -15,38 +15,38 @@ diff --git a/intl/icu/source/acinclude.m
 +            CFLAGS="$CFLAGS -Wno-sign-compare -Wno-unused"
          else
              case "${host}" in
              *-*-cygwin)
                  if test "`$CC /help 2>&1 | head -c9`" = "Microsoft"
                  then
                      CFLAGS="$CFLAGS /W4"
                  fi ;;
-             *-*-mingw32|*-*-mingw64)
+             *-*-mingw*)
                  CFLAGS="$CFLAGS -W4" ;;
              esac
          fi
          if test "$GXX" = yes
          then
              CXXFLAGS="$CXXFLAGS -W -Wall -pedantic -Wpointer-arith -Wwrite-strings -Wno-long-long"
 +
 +            # Suppress clang C++ warnings:
 +            CXXFLAGS="$CXXFLAGS -Wno-unused -Wno-unused-parameter"
          else
              case "${host}" in
              *-*-cygwin)
                  if test "`$CXX /help 2>&1 | head -c9`" = "Microsoft"
                  then
                      CXXFLAGS="$CXXFLAGS /W4"
                  fi ;;
-             *-*-mingw32|*-*-mingw64)
+             *-*-mingw*)
 diff --git a/intl/icu/source/configure b/intl/icu/source/configure
 --- a/intl/icu/source/configure
 +++ b/intl/icu/source/configure
-@@ -4089,30 +4089,36 @@ fi
+@@ -4319,30 +4319,36 @@ fi
              *)
                  # Do not use -ansi. It limits us to C90, and it breaks some platforms.
                  # We use -std=c99 to disable the gnu99 defaults and its associated warnings
                  CFLAGS="$CFLAGS -std=c99"
                  ;;
              esac
  
              CFLAGS="$CFLAGS -Wall -pedantic -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings"
@@ -55,26 +55,26 @@ diff --git a/intl/icu/source/configure b
 +            CFLAGS="$CFLAGS -Wno-sign-compare -Wno-unused"
          else
              case "${host}" in
              *-*-cygwin)
                  if test "`$CC /help 2>&1 | head -c9`" = "Microsoft"
                  then
                      CFLAGS="$CFLAGS /W4"
                  fi ;;
-             *-*-mingw32|*-*-mingw64)
+             *-*-mingw*)
                  CFLAGS="$CFLAGS -W4" ;;
              esac
          fi
          if test "$GXX" = yes
          then
              CXXFLAGS="$CXXFLAGS -W -Wall -pedantic -Wpointer-arith -Wwrite-strings -Wno-long-long"
 +
 +            # Suppress clang C++ warnings:
 +            CXXFLAGS="$CXXFLAGS -Wno-unused -Wno-unused-parameter"
          else
              case "${host}" in
              *-*-cygwin)
                  if test "`$CXX /help 2>&1 | head -c9`" = "Microsoft"
                  then
                      CXXFLAGS="$CXXFLAGS /W4"
                  fi ;;
-             *-*-mingw32|*-*-mingw64)
+             *-*-mingw*)
--- a/intl/icu/source/acinclude.m4
+++ b/intl/icu/source/acinclude.m4
@@ -473,30 +473,36 @@ AC_DEFUN([AC_CHECK_STRICT_COMPILE],
             *)
                 # Do not use -ansi. It limits us to C90, and it breaks some platforms.
                 # We use -std=c99 to disable the gnu99 defaults and its associated warnings
                 CFLAGS="$CFLAGS -std=c99"
                 ;;
             esac
             
             CFLAGS="$CFLAGS -Wall -pedantic -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings"
+
+            # Suppress clang C warnings:
+            CFLAGS="$CFLAGS -Wno-sign-compare -Wno-unused"
         else
             case "${host}" in
             *-*-cygwin)
                 if test "`$CC /help 2>&1 | head -c9`" = "Microsoft"
                 then
                     CFLAGS="$CFLAGS /W4"
                 fi ;;
             *-*-mingw*)
                 CFLAGS="$CFLAGS -W4" ;;
             esac
         fi
         if test "$GXX" = yes
         then
             CXXFLAGS="$CXXFLAGS -W -Wall -pedantic -Wpointer-arith -Wwrite-strings -Wno-long-long"
+
+            # Suppress clang C++ warnings:
+            CXXFLAGS="$CXXFLAGS -Wno-unused -Wno-unused-parameter"
         else
             case "${host}" in
             *-*-cygwin)
                 if test "`$CXX /help 2>&1 | head -c9`" = "Microsoft"
                 then
                     CXXFLAGS="$CXXFLAGS /W4"
                 fi ;;
             *-*-mingw*)
--- a/intl/icu/source/configure
+++ b/intl/icu/source/configure
@@ -4319,30 +4319,36 @@ fi
             *)
                 # Do not use -ansi. It limits us to C90, and it breaks some platforms.
                 # We use -std=c99 to disable the gnu99 defaults and its associated warnings
                 CFLAGS="$CFLAGS -std=c99"
                 ;;
             esac
 
             CFLAGS="$CFLAGS -Wall -pedantic -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings"
+
+            # Suppress clang C warnings:
+            CFLAGS="$CFLAGS -Wno-sign-compare -Wno-unused"
         else
             case "${host}" in
             *-*-cygwin)
                 if test "`$CC /help 2>&1 | head -c9`" = "Microsoft"
                 then
                     CFLAGS="$CFLAGS /W4"
                 fi ;;
             *-*-mingw*)
                 CFLAGS="$CFLAGS -W4" ;;
             esac
         fi
         if test "$GXX" = yes
         then
             CXXFLAGS="$CXXFLAGS -W -Wall -pedantic -Wpointer-arith -Wwrite-strings -Wno-long-long"
+
+            # Suppress clang C++ warnings:
+            CXXFLAGS="$CXXFLAGS -Wno-unused -Wno-unused-parameter"
         else
             case "${host}" in
             *-*-cygwin)
                 if test "`$CXX /help 2>&1 | head -c9`" = "Microsoft"
                 then
                     CXXFLAGS="$CXXFLAGS /W4"
                 fi ;;
             *-*-mingw*)
--- a/intl/update-icu.sh
+++ b/intl/update-icu.sh
@@ -46,15 +46,15 @@ rm ${icu_dir}/source/data/translit/*
 # Record `svn info`, eliding the line that changes every time the entire ICU
 # repository (not just the path within it we care about) receives a commit.
 # (This ensures that if ICU modifications are performed properly, it's always
 # possible to run the command at the top of this script and make no changes to
 # the tree.)
 svn info $1 | grep -v '^Revision: [[:digit:]]\+$' > ${icu_dir}/SVN-INFO
 
 patch -d ${icu_dir}/../../ -p1 < ${icu_dir}/../icu-patches/bug-915735
+patch -d ${icu_dir}/../../ -p1 < ${icu_dir}/../icu-patches/suppress-warnings.diff
 
 exit 0
 
-patch -d ${icu_dir}/../../ -p1 < ${icu_dir}/../icu-patches/suppress-warnings.diff
 patch -d ${icu_dir}/../../ -p1 < ${icu_dir}/../icu-patches/clang-cl.diff
 
 hg addremove ${icu_dir}