Gentoo Archives: gentoo-commits

From: Mike Frysinger <vapier@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-fs/e2fsprogs/files/, sys-fs/e2fsprogs/
Date: Tue, 29 Mar 2016 00:45:20
Message-Id: 1459212299.90d3156ebcade1197b21c37b5aaaaaf9fc9238eb.vapier@gentoo
1 commit: 90d3156ebcade1197b21c37b5aaaaaf9fc9238eb
2 Author: Mike Frysinger <vapier <AT> gentoo <DOT> org>
3 AuthorDate: Tue Mar 29 00:44:52 2016 +0000
4 Commit: Mike Frysinger <vapier <AT> gentoo <DOT> org>
5 CommitDate: Tue Mar 29 00:44:59 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=90d3156e
7
8 sys-fs/e2fsprogs: fix build w/newer glibc #577946
9
10 sys-fs/e2fsprogs/e2fsprogs-1.42.13.ebuild | 1 +
11 .../files/e2fsprogs-1.42.13-sysmacros.patch | 74 ++++++++++++++++++++++
12 2 files changed, 75 insertions(+)
13
14 diff --git a/sys-fs/e2fsprogs/e2fsprogs-1.42.13.ebuild b/sys-fs/e2fsprogs/e2fsprogs-1.42.13.ebuild
15 index abe315f..34a4047 100644
16 --- a/sys-fs/e2fsprogs/e2fsprogs-1.42.13.ebuild
17 +++ b/sys-fs/e2fsprogs/e2fsprogs-1.42.13.ebuild
18 @@ -39,6 +39,7 @@ src_prepare() {
19 fi
20 epatch "${FILESDIR}"/${PN}-1.42.13-fix-build-cflags.patch #516854
21 epatch "${FILESDIR}"/${PN}-1.42.13-subst-perms.patch #550986
22 + epatch "${FILESDIR}"/${PN}-1.42.13-sysmacros.patch
23
24 # blargh ... trick e2fsprogs into using e2fsprogs-libs
25 rm -rf doc
26
27 diff --git a/sys-fs/e2fsprogs/files/e2fsprogs-1.42.13-sysmacros.patch b/sys-fs/e2fsprogs/files/e2fsprogs-1.42.13-sysmacros.patch
28 new file mode 100644
29 index 0000000..2e4c4e0
30 --- /dev/null
31 +++ b/sys-fs/e2fsprogs/files/e2fsprogs-1.42.13-sysmacros.patch
32 @@ -0,0 +1,74 @@
33 +From 13a12900148e6b778d8532ca76ff38edcec5a45f Mon Sep 17 00:00:00 2001
34 +From: Mike Frysinger <vapier@g.o>
35 +Date: Mon, 28 Mar 2016 20:31:33 -0400
36 +Subject: [PATCH e2fsprogs] include sys/sysmacros.h as needed
37 +
38 +The minor/major/makedev macros are not entirely standard. glibc has had
39 +the definitions in sys/sysmacros.h since the start, and wants to move away
40 +from always defining them implicitly via sys/types.h (as this pollutes the
41 +namespace in violation of POSIX). Other C libraries have already dropped
42 +them. Since the configure script already checks for this header, use that
43 +to pull in the header in files that use these macros.
44 +
45 +Signed-off-by: Mike Frysinger <vapier@g.o>
46 +
47 +--- a/lib/blkid/devname.c
48 ++++ b/lib/blkid/devname.c
49 +@@ -36,6 +36,9 @@
50 + #if HAVE_SYS_MKDEV_H
51 + #include <sys/mkdev.h>
52 + #endif
53 ++#ifdef HAVE_SYS_SYSMACROS_H
54 ++#include <sys/sysmacros.h>
55 ++#endif
56 + #include <time.h>
57 +
58 + #include "blkidP.h"
59 +--- a/lib/blkid/devno.c
60 ++++ b/lib/blkid/devno.c
61 +@@ -31,6 +31,9 @@
62 + #if HAVE_SYS_MKDEV_H
63 + #include <sys/mkdev.h>
64 + #endif
65 ++#ifdef HAVE_SYS_SYSMACROS_H
66 ++#include <sys/sysmacros.h>
67 ++#endif
68 +
69 + #include "blkidP.h"
70 +
71 +--- a/lib/ext2fs/finddev.c
72 ++++ b/lib/ext2fs/finddev.c
73 +@@ -31,6 +31,9 @@
74 + #if HAVE_SYS_MKDEV_H
75 + #include <sys/mkdev.h>
76 + #endif
77 ++#ifdef HAVE_SYS_SYSMACROS_H
78 ++#include <sys/sysmacros.h>
79 ++#endif
80 +
81 + #include "ext2_fs.h"
82 + #include "ext2fs.h"
83 +--- a/lib/ext2fs/ismounted.c
84 ++++ b/lib/ext2fs/ismounted.c
85 +@@ -49,6 +49,9 @@
86 + #endif /* HAVE_GETMNTINFO */
87 + #include <string.h>
88 + #include <sys/stat.h>
89 ++#ifdef HAVE_SYS_SYSMACROS_H
90 ++#include <sys/sysmacros.h>
91 ++#endif
92 +
93 + #include "ext2_fs.h"
94 + #include "ext2fs.h"
95 +--- a/misc/mk_hugefiles.c
96 ++++ b/misc/mk_hugefiles.c
97 +@@ -35,6 +35,9 @@ extern int optind;
98 + #include <sys/ioctl.h>
99 + #include <sys/types.h>
100 + #include <sys/stat.h>
101 ++#ifdef HAVE_SYS_SYSMACROS_H
102 ++#include <sys/sysmacros.h>
103 ++#endif
104 + #include <libgen.h>
105 + #include <limits.h>
106 + #include <blkid/blkid.h>