diff options
author | Khem Raj <raj.khem@gmail.com> | 2016-12-18 22:39:52 -0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-12-19 15:03:43 +0000 |
commit | 32643ed355c94035d6fabbd0cd9e4c6f3b18ab56 (patch) | |
tree | d8eab07ce6b2dacaa2603ed7b5c276f948645956 /meta/recipes-extended/mdadm | |
parent | 5e501f8e3ecf14f31da3cca5ab762af5ddc81964 (diff) | |
download | openembedded-core-32643ed355c94035d6fabbd0cd9e4c6f3b18ab56.tar.gz openembedded-core-32643ed355c94035d6fabbd0cd9e4c6f3b18ab56.tar.bz2 openembedded-core-32643ed355c94035d6fabbd0cd9e4c6f3b18ab56.zip |
mdadm: Fix build with glibc 2.25
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta/recipes-extended/mdadm')
-rw-r--r-- | meta/recipes-extended/mdadm/files/0001-include-sys-sysmacros.h-for-major-minor-defintions.patch | 48 | ||||
-rw-r--r-- | meta/recipes-extended/mdadm/mdadm_3.4.bb | 1 |
2 files changed, 49 insertions, 0 deletions
diff --git a/meta/recipes-extended/mdadm/files/0001-include-sys-sysmacros.h-for-major-minor-defintions.patch b/meta/recipes-extended/mdadm/files/0001-include-sys-sysmacros.h-for-major-minor-defintions.patch new file mode 100644 index 0000000000..acd64ada22 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-include-sys-sysmacros.h-for-major-minor-defintions.patch @@ -0,0 +1,48 @@ +From 943616e5dffb79f307e4bd9b249d316212998750 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Sun, 18 Dec 2016 08:30:51 +0000 +Subject: [PATCH] include <sys/sysmacros.h> for major/minor defintions + +glibc 2.25 is warning about it if applications depend on +sys/types.h for these macros, it expects to be included +from <sys/sysmacros.h> + +Fixes +| Grow.c:3534:13: error: In the GNU C Library, "minor" is defined +| by <sys/sysmacros.h>. For historical compatibility, it is +| currently defined by <sys/types.h> as well, but we plan to +| remove this soon. To use "minor", include <sys/sysmacros.h> +| directly. If you did not intend to use a system-defined macro +| "minor", you should undefine it after including <sys/types.h>. [-Werror] +| Query.c: In function 'Query': +| Query.c:105:13: error: In the GNU C Library, "makedev" is defined +| by <sys/sysmacros.h>. For historical compatibility, it is +| currently defined by <sys/types.h> as well, but we plan to +| remove this soon. To use "makedev", include <sys/sysmacros.h> +| directly. If you did not intend to use a system-defined macro +| "makedev", you should undefine it after including <sys/types.h>. [-Werror] +| makedev((unsigned)disc.major,(unsigned)disc.minor) == stb.st_rdev) +| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- +Upstream-Status: Pending + + mdadm.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/mdadm.h b/mdadm.h +index 8c8f4d1..3ce13b5 100755 +--- a/mdadm.h ++++ b/mdadm.h +@@ -34,6 +34,7 @@ extern __off64_t lseek64 __P ((int __fd, __off64_t __offset, int __whence)); + #endif + + #include <sys/types.h> ++#include <sys/sysmacros.h> + #include <sys/stat.h> + #include <stdint.h> + #include <stdlib.h> +-- +1.9.1 + diff --git a/meta/recipes-extended/mdadm/mdadm_3.4.bb b/meta/recipes-extended/mdadm/mdadm_3.4.bb index d34b885076..7bf15b51be 100644 --- a/meta/recipes-extended/mdadm/mdadm_3.4.bb +++ b/meta/recipes-extended/mdadm/mdadm_3.4.bb @@ -21,6 +21,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/raid/mdadm/${BPN}-${PV}.tar.xz \ file://run-ptest \ file://0001-raid6check-Fix-if-else-indentation.patch \ file://0001-mdadm.h-Undefine-dprintf-before-redefining.patch \ + file://0001-include-sys-sysmacros.h-for-major-minor-defintions.patch \ " SRC_URI[md5sum] = "04b8b21f637540350f8517c7e68d3c63" SRC_URI[sha256sum] = "27d0be4627d38a12ddcd1c1c3721d649d4e89e1093914497e22b57245cda8808" |