1 |
commit: 87f87c28f18c7cdd396f4e2e68dfaee778506eb8 |
2 |
Author: Sam James <sam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Aug 30 02:34:24 2021 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Aug 30 02:34:24 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=87f87c28 |
7 |
|
8 |
sys-process/procps: add stop-gap musl patch for now |
9 |
|
10 |
Conditionally apply a patch from ::musl for building on |
11 |
musl (to facilitate stage building). |
12 |
|
13 |
A different (better) approach was taken upstream and will |
14 |
result in a --disable-w configure option in the next release, |
15 |
but we're not there yet. |
16 |
|
17 |
Closes: https://bugs.gentoo.org/794997 |
18 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
19 |
|
20 |
.../procps/files/procps-3.3.17-musl-fix.patch | 78 ++++++++++++++++++++++ |
21 |
sys-process/procps/procps-3.3.17-r1.ebuild | 8 +++ |
22 |
2 files changed, 86 insertions(+) |
23 |
|
24 |
diff --git a/sys-process/procps/files/procps-3.3.17-musl-fix.patch b/sys-process/procps/files/procps-3.3.17-musl-fix.patch |
25 |
new file mode 100644 |
26 |
index 00000000000..4402354c21e |
27 |
--- /dev/null |
28 |
+++ b/sys-process/procps/files/procps-3.3.17-musl-fix.patch |
29 |
@@ -0,0 +1,78 @@ |
30 |
+Temporary stopgap patch (a different solution was used upstream |
31 |
+in the next release, should be in the next after 3.3.17 -- we'll need to |
32 |
+add --disable-w instead). |
33 |
+ |
34 |
+https://bugs.gentoo.org/794997 |
35 |
+ |
36 |
+From 7bfe2b7c12b33aabca71491360c433d2d3f7bbf4 Mon Sep 17 00:00:00 2001 |
37 |
+From: Alexander Kanavin <alex.kanavin@×××××.com> |
38 |
+Date: Wed, 24 Feb 2021 21:14:31 +0000 |
39 |
+Subject: [PATCH 1/2] w.c: correct musl builds |
40 |
+ |
41 |
+No need to redefine UT_ stuff to something that does not exist. |
42 |
+ |
43 |
+UT_ is already provided in musl but via utmp.h header, so include |
44 |
+it always. |
45 |
+ |
46 |
+Signed-off-by: Alexander Kanavin <alex.kanavin@×××××.com> |
47 |
+--- |
48 |
+ w.c | 9 +-------- |
49 |
+ 1 file changed, 1 insertion(+), 8 deletions(-) |
50 |
+ |
51 |
+diff --git a/w.c b/w.c |
52 |
+index 9d07ac9e..d10639b8 100644 |
53 |
+--- a/w.c |
54 |
++++ b/w.c |
55 |
+@@ -57,9 +57,8 @@ |
56 |
+ #include <unistd.h> |
57 |
+ #ifdef HAVE_UTMPX_H |
58 |
+ # include <utmpx.h> |
59 |
+-#else |
60 |
+-# include <utmp.h> |
61 |
+ #endif |
62 |
++#include <utmp.h> |
63 |
+ #include <arpa/inet.h> |
64 |
+ |
65 |
+ static int ignoreuser = 0; /* for '-u' */ |
66 |
+@@ -72,12 +71,6 @@ typedef struct utmpx utmp_t; |
67 |
+ typedef struct utmp utmp_t; |
68 |
+ #endif |
69 |
+ |
70 |
+-#if !defined(UT_HOSTSIZE) || defined(__UT_HOSTSIZE) |
71 |
+-# define UT_HOSTSIZE __UT_HOSTSIZE |
72 |
+-# define UT_LINESIZE __UT_LINESIZE |
73 |
+-# define UT_NAMESIZE __UT_NAMESIZE |
74 |
+-#endif |
75 |
+- |
76 |
+ #ifdef W_SHOWFROM |
77 |
+ # define FROM_STRING "on" |
78 |
+ #else |
79 |
+-- |
80 |
+GitLab |
81 |
+ |
82 |
+ |
83 |
+From 145165aba6c659f3f0f3567a323a3e6170408ea6 Mon Sep 17 00:00:00 2001 |
84 |
+From: Alexander Kanavin <alex.kanavin@×××××.com> |
85 |
+Date: Wed, 24 Feb 2021 21:16:14 +0000 |
86 |
+Subject: [PATCH 2/2] proc/escape.c: add missing include |
87 |
+ |
88 |
+Signed-off-by: Alexander Kanavin <alex.kanavin@×××××.com> |
89 |
+--- |
90 |
+ proc/escape.c | 1 + |
91 |
+ 1 file changed, 1 insertion(+) |
92 |
+ |
93 |
+diff --git a/proc/escape.c b/proc/escape.c |
94 |
+index 2e8fb7dd..e1f4612d 100644 |
95 |
+--- a/proc/escape.c |
96 |
++++ b/proc/escape.c |
97 |
+@@ -21,6 +21,7 @@ |
98 |
+ #include <sys/types.h> |
99 |
+ #include <string.h> |
100 |
+ #include <limits.h> |
101 |
++#include <langinfo.h> |
102 |
+ #include "procps.h" |
103 |
+ #include "escape.h" |
104 |
+ #include "readproc.h" |
105 |
+-- |
106 |
+GitLab |
107 |
+ |
108 |
|
109 |
diff --git a/sys-process/procps/procps-3.3.17-r1.ebuild b/sys-process/procps/procps-3.3.17-r1.ebuild |
110 |
index 77bbf988516..2fa54d22f40 100644 |
111 |
--- a/sys-process/procps/procps-3.3.17-r1.ebuild |
112 |
+++ b/sys-process/procps/procps-3.3.17-r1.ebuild |
113 |
@@ -42,6 +42,14 @@ PATCHES=( |
114 |
"${FILESDIR}"/${PN}-3.3.12-proc-tests.patch # 583036 |
115 |
) |
116 |
|
117 |
+src_prepare() { |
118 |
+ default |
119 |
+ |
120 |
+ # Please drop this after 3.3.17 and instead use --disable-w on musl. |
121 |
+ # bug #794997 |
122 |
+ use elibc_musl && eapply "${FILESDIR}"/${PN}-3.3.17-musl-fix.patch |
123 |
+} |
124 |
+ |
125 |
multilib_src_configure() { |
126 |
# http://www.freelists.org/post/procps/PATCH-enable-transparent-large-file-support |
127 |
append-lfs-flags #471102 |