OSDN Git Service

Disable macro redefined warnings.
authorChristopher Ferris <cferris@google.com>
Thu, 23 Feb 2017 23:36:54 +0000 (15:36 -0800)
committerChristopher Ferris <cferris@google.com>
Fri, 24 Feb 2017 17:36:26 +0000 (09:36 -0800)
The new kernel headers do:

  #define __bitwise __bitwise__

However, the code redefines __bitwise without undef'ing it first.

This is a temporary fix, b/35721782 filed to fix this.

Change-Id: I2c6a64146966f1737835f012d24ccc844570d02b
Test: Builds without warningers/errors.

contrib/Android.bp
debugfs/Android.bp
e2fsck/Android.bp
lib/blkid/Android.bp
lib/e2p/Android.bp
lib/ext2fs/Android.bp
lib/support/Android.bp
misc/Android.bp
resize/Android.bp

index 585a8f1..c2d5cd9 100644 (file)
@@ -10,7 +10,7 @@ cc_binary {
     host_supported: true,
 
     srcs: ["fsstress.c"],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
     system_shared_libs: ["libc"],
 
     target: {
@@ -28,7 +28,7 @@ cc_binary {
     host_supported: true,
 
     srcs: ["add_ext4_encrypt.c"],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
     shared_libs: [
         "libext2fs",
         "libext2_com_err",
index b60b453..013a421 100644 (file)
@@ -34,6 +34,7 @@ cc_defaults {
     cflags: [
         "-W",
         "-Wall",
+        "-Wno-macro-redefined",
         "-fno-strict-aliasing",
         "-DDEBUGFS",
     ],
index 0e1f9b8..1cabe86 100644 (file)
@@ -34,7 +34,7 @@ cc_defaults {
         "readahead.c",
         "extents.c",
     ],
-    cflags: ["-W", "-Wall", "-fno-strict-aliasing"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined", "-fno-strict-aliasing"],
 }
 
 e2fsck_libs = [
index 9a3f276..9b385f9 100644 (file)
@@ -24,6 +24,7 @@ cc_library {
         "-W",
         "-Wall",
         "-fno-strict-aliasing",
+        "-Wno-macro-redefined",
     ],
 
     header_libs: ["libext2-headers"],
index 9c344df..db51670 100644 (file)
@@ -32,6 +32,7 @@ cc_library {
     cflags: [
         "-W",
         "-Wall",
+        "-Wno-macro-redefined",
     ],
 
     header_libs: ["libext2-headers"],
index 73b11a3..df07a9b 100644 (file)
@@ -97,6 +97,7 @@ cc_library {
         "-W",
         "-Wall",
         "-Wno-unused-parameter",
+        "-Wno-macro-redefined",
     ],
     target: {
         host: {
index 11248b4..24414a4 100644 (file)
@@ -25,6 +25,7 @@ cc_library {
     cflags: [
         "-W",
         "-Wall",
+        "-Wno-macro-redefined",
     ],
 
     header_libs: ["libext2-headers"],
index f75c9d1..e36bf93 100644 (file)
@@ -9,7 +9,7 @@ cc_library {
     srcs: [
         "create_inode.c",
     ],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
     shared_libs: [
         "libext2_quota",
         "libext2fs",
@@ -32,7 +32,7 @@ cc_binary {
         "default_profile.c",
         "create_inode.c",
     ],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
     shared_libs: [
         "libext2fs",
         "libext2_blkid",
@@ -58,6 +58,7 @@ cc_defaults {
         "-W",
         "-Wall",
         "-DNO_RECOVERY",
+        "-Wno-macro-redefined",
     ],
     include_dirs: ["external/e2fsprogs/e2fsck"],
 }
@@ -104,7 +105,7 @@ cc_binary {
     host_supported: true,
 
     srcs: ["badblocks.c"],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
     shared_libs: [
         "libext2fs",
         "libext2_com_err",
@@ -123,7 +124,7 @@ cc_binary {
     host_supported: true,
 
     srcs: ["chattr.c"],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
     shared_libs: [
         "libext2_com_err",
         "libext2_e2p",
@@ -137,7 +138,7 @@ cc_binary {
 cc_defaults {
     name: "lsattr-defaults",
     srcs: ["lsattr.c"],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
 }
 
 lsattr_libs = [
@@ -169,7 +170,7 @@ cc_binary {
     name: "blkid",
 
     srcs: ["blkid.c"],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
     shared_libs: [
         "libext2fs",
         "libext2_blkid",
@@ -187,7 +188,7 @@ cc_binary {
     host_supported: true,
 
     srcs: ["e4crypt.c"],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
     shared_libs: [
         "libext2fs",
         "libext2_uuid",
@@ -209,7 +210,7 @@ cc_binary {
     host_supported: true,
 
     srcs: ["e2image.c"],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
     shared_libs: [
         "libext2fs",
         "libext2_blkid",
index 5d8f0e8..6d3d321 100644 (file)
@@ -12,7 +12,7 @@ cc_binary {
         "sim_progress.c",
         "resource_track.c",
     ],
-    cflags: ["-W", "-Wall"],
+    cflags: ["-W", "-Wall", "-Wno-macro-redefined"],
     shared_libs: [
         "libext2fs",
         "libext2_com_err",