1 |
commit: 9463c487ae1bf6a960ea83fafcda88b17c90ef06 |
2 |
Author: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Mar 26 21:17:04 2018 +0000 |
4 |
Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Mar 26 21:17:23 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9463c487 |
7 |
|
8 |
sys-apps/systemd: fix build with util-linux-2.32 |
9 |
|
10 |
Closes: https://bugs.gentoo.org/651304 |
11 |
Package-Manager: Portage-2.3.24, Repoman-2.3.6_p81 |
12 |
|
13 |
sys-apps/systemd/files/238-libmount-include.patch | 72 +++++++++++++++++++++++ |
14 |
sys-apps/systemd/systemd-236-r5.ebuild | 1 + |
15 |
sys-apps/systemd/systemd-237-r3.ebuild | 1 + |
16 |
sys-apps/systemd/systemd-238-r1.ebuild | 1 + |
17 |
4 files changed, 75 insertions(+) |
18 |
|
19 |
diff --git a/sys-apps/systemd/files/238-libmount-include.patch b/sys-apps/systemd/files/238-libmount-include.patch |
20 |
new file mode 100644 |
21 |
index 00000000000..6a02dff65e4 |
22 |
--- /dev/null |
23 |
+++ b/sys-apps/systemd/files/238-libmount-include.patch |
24 |
@@ -0,0 +1,72 @@ |
25 |
+From 227b8a762fea1458547be2cdf0e6e4aac0079730 Mon Sep 17 00:00:00 2001 |
26 |
+From: Michael Olbrich <m.olbrich@×××××××××××.de> |
27 |
+Date: Mon, 26 Mar 2018 17:34:53 +0200 |
28 |
+Subject: [PATCH] core: don't include libmount.h in a header file (#8580) |
29 |
+ |
30 |
+linux/fs.h sys/mount.h, libmount.h and missing.h all include MS_* |
31 |
+definitions. |
32 |
+ |
33 |
+To avoid problems, only one of linux/fs.h, sys/mount.h and libmount.h |
34 |
+should be included. And missing.h must be included last. |
35 |
+ |
36 |
+Without this, building systemd may fail with: |
37 |
+ |
38 |
+In file included from [...]/libmount/libmount.h:31:0, |
39 |
+ from ../systemd-238/src/core/manager.h:23, |
40 |
+ from ../systemd-238/src/core/emergency-action.h:37, |
41 |
+ from ../systemd-238/src/core/unit.h:34, |
42 |
+ from ../systemd-238/src/core/dbus-timer.h:25, |
43 |
+ from ../systemd-238/src/core/timer.c:26: |
44 |
+[...]/sys/mount.h:57:2: error: expected identifier before numeric constant |
45 |
+--- |
46 |
+ src/core/dbus-execute.c | 1 + |
47 |
+ src/core/manager.h | 3 ++- |
48 |
+ src/core/mount.c | 2 ++ |
49 |
+ 3 files changed, 5 insertions(+), 1 deletion(-) |
50 |
+ |
51 |
+diff --git a/src/core/dbus-execute.c b/src/core/dbus-execute.c |
52 |
+index 7344623ebf6..c342093bca4 100644 |
53 |
+--- a/src/core/dbus-execute.c |
54 |
++++ b/src/core/dbus-execute.c |
55 |
+@@ -18,6 +18,7 @@ |
56 |
+ along with systemd; If not, see <http://www.gnu.org/licenses/>. |
57 |
+ ***/ |
58 |
+ |
59 |
++#include <sys/mount.h> |
60 |
+ #include <sys/prctl.h> |
61 |
+ #include <stdio_ext.h> |
62 |
+ |
63 |
+diff --git a/src/core/manager.h b/src/core/manager.h |
64 |
+index 28c5da225b1..e09e0cdf5e9 100644 |
65 |
+--- a/src/core/manager.h |
66 |
++++ b/src/core/manager.h |
67 |
+@@ -20,7 +20,6 @@ |
68 |
+ along with systemd; If not, see <http://www.gnu.org/licenses/>. |
69 |
+ ***/ |
70 |
+ |
71 |
+-#include <libmount.h> |
72 |
+ #include <stdbool.h> |
73 |
+ #include <stdio.h> |
74 |
+ |
75 |
+@@ -34,6 +33,8 @@ |
76 |
+ #include "list.h" |
77 |
+ #include "ratelimit.h" |
78 |
+ |
79 |
++struct libmnt_monitor; |
80 |
++ |
81 |
+ /* Enforce upper limit how many names we allow */ |
82 |
+ #define MANAGER_MAX_NAMES 131072 /* 128K */ |
83 |
+ |
84 |
+diff --git a/src/core/mount.c b/src/core/mount.c |
85 |
+index 0e755da5c02..0154ebda5d6 100644 |
86 |
+--- a/src/core/mount.c |
87 |
++++ b/src/core/mount.c |
88 |
+@@ -23,6 +23,8 @@ |
89 |
+ #include <stdio.h> |
90 |
+ #include <sys/epoll.h> |
91 |
+ |
92 |
++#include <libmount.h> |
93 |
++ |
94 |
+ #include "sd-messages.h" |
95 |
+ |
96 |
+ #include "alloc-util.h" |
97 |
|
98 |
diff --git a/sys-apps/systemd/systemd-236-r5.ebuild b/sys-apps/systemd/systemd-236-r5.ebuild |
99 |
index ed62d0a6f44..aed2113e91a 100644 |
100 |
--- a/sys-apps/systemd/systemd-236-r5.ebuild |
101 |
+++ b/sys-apps/systemd/systemd-236-r5.ebuild |
102 |
@@ -148,6 +148,7 @@ src_unpack() { |
103 |
|
104 |
src_prepare() { |
105 |
local PATCHES=( |
106 |
+ "${FILESDIR}/238-libmount-include.patch" |
107 |
) |
108 |
|
109 |
[[ -d "${WORKDIR}"/patches ]] && PATCHES+=( "${WORKDIR}"/patches ) |
110 |
|
111 |
diff --git a/sys-apps/systemd/systemd-237-r3.ebuild b/sys-apps/systemd/systemd-237-r3.ebuild |
112 |
index 466126ca683..d0254ee71db 100644 |
113 |
--- a/sys-apps/systemd/systemd-237-r3.ebuild |
114 |
+++ b/sys-apps/systemd/systemd-237-r3.ebuild |
115 |
@@ -150,6 +150,7 @@ src_unpack() { |
116 |
src_prepare() { |
117 |
local PATCHES=( |
118 |
"${FILESDIR}/237-0001-networkctl-display-type.patch" |
119 |
+ "${FILESDIR}/238-libmount-include.patch" |
120 |
) |
121 |
|
122 |
[[ -d "${WORKDIR}"/patches ]] && PATCHES+=( "${WORKDIR}"/patches ) |
123 |
|
124 |
diff --git a/sys-apps/systemd/systemd-238-r1.ebuild b/sys-apps/systemd/systemd-238-r1.ebuild |
125 |
index 2898aa322ed..2903bb82e51 100644 |
126 |
--- a/sys-apps/systemd/systemd-238-r1.ebuild |
127 |
+++ b/sys-apps/systemd/systemd-238-r1.ebuild |
128 |
@@ -150,6 +150,7 @@ src_prepare() { |
129 |
local PATCHES=( |
130 |
"${FILESDIR}/238-0001-sd-bus-do-not-try-to-close-already-closed-fd-8392.patch" |
131 |
"${FILESDIR}/238-0002-core-do-not-free-heap-allocated-strings-8391.patch" |
132 |
+ "${FILESDIR}/238-libmount-include.patch" |
133 |
) |
134 |
|
135 |
[[ -d "${WORKDIR}"/patches ]] && PATCHES+=( "${WORKDIR}"/patches ) |