1 |
commit: d9be9452dc264ba3a32ed16ae97707167df383d4 |
2 |
Author: Sam James <sam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Sep 13 14:32:09 2022 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Sep 13 14:32:09 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d9be9452 |
7 |
|
8 |
net-misc/radvd: update EAPI 7 -> 8; fix runtime w/ musl (and build w/ Clang 15) |
9 |
|
10 |
Bug: https://github.com/radvd-project/radvd/issues/158 |
11 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
12 |
|
13 |
net-misc/radvd/files/radvd-2.19-musl-include.patch | 28 +++++++++ |
14 |
net-misc/radvd/radvd-2.19-r3.ebuild | 69 ++++++++++++++++++++++ |
15 |
2 files changed, 97 insertions(+) |
16 |
|
17 |
diff --git a/net-misc/radvd/files/radvd-2.19-musl-include.patch b/net-misc/radvd/files/radvd-2.19-musl-include.patch |
18 |
new file mode 100644 |
19 |
index 000000000000..cba7666f8129 |
20 |
--- /dev/null |
21 |
+++ b/net-misc/radvd/files/radvd-2.19-musl-include.patch |
22 |
@@ -0,0 +1,28 @@ |
23 |
+https://github.com/radvd-project/radvd/commit/06689f8c06f44c7e87f7ff1d814428f88375b53f |
24 |
+https://github.com/radvd-project/radvd/pull/161 |
25 |
+https://github.com/radvd-project/radvd/issues/158 |
26 |
+ |
27 |
+From: Jonathan Davies <jpds@××××××××××.com> |
28 |
+Date: Thu, 25 Nov 2021 15:29:18 +0000 |
29 |
+Subject: [PATCH] Reverts the include.h change in |
30 |
+ 46883f8a1a02fe42040dd8e48aec0ed871545d4d |
31 |
+ |
32 |
+Closes: #158 |
33 |
+ |
34 |
+Signed-off-by: Jonathan Davies <jpds@××××××××××.com> |
35 |
+--- a/includes.h |
36 |
++++ b/includes.h |
37 |
+@@ -76,12 +76,7 @@ |
38 |
+ #include <sys/sysctl.h> |
39 |
+ #endif |
40 |
+ |
41 |
+-#if !defined(__GLIBC__) && defined(linux) |
42 |
+-#include <linux/if.h> |
43 |
+-#define IF_NAMESIZE IFNAMSIZ |
44 |
+-#else |
45 |
+ #include <net/if.h> |
46 |
+-#endif |
47 |
+ |
48 |
+ #ifdef HAVE_NET_IF_DL_H |
49 |
+ #include <net/if_dl.h> |
50 |
+ |
51 |
|
52 |
diff --git a/net-misc/radvd/radvd-2.19-r3.ebuild b/net-misc/radvd/radvd-2.19-r3.ebuild |
53 |
new file mode 100644 |
54 |
index 000000000000..e5bb868d1b38 |
55 |
--- /dev/null |
56 |
+++ b/net-misc/radvd/radvd-2.19-r3.ebuild |
57 |
@@ -0,0 +1,69 @@ |
58 |
+# Copyright 1999-2022 Gentoo Authors |
59 |
+# Distributed under the terms of the GNU General Public License v2 |
60 |
+ |
61 |
+EAPI=8 |
62 |
+ |
63 |
+inherit readme.gentoo-r1 systemd toolchain-funcs |
64 |
+ |
65 |
+DESCRIPTION="Linux IPv6 Router Advertisement Daemon" |
66 |
+HOMEPAGE="https://v6web.litech.org/radvd/" |
67 |
+SRC_URI="https://v6web.litech.org/radvd/dist/${P}.tar.xz" |
68 |
+ |
69 |
+LICENSE="BSD" |
70 |
+SLOT="0" |
71 |
+KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~riscv ~sparc ~x86" |
72 |
+IUSE="selinux test" |
73 |
+RESTRICT="!test? ( test )" |
74 |
+ |
75 |
+BDEPEND="virtual/pkgconfig" |
76 |
+CDEPEND="dev-libs/libdaemon" |
77 |
+DEPEND=" |
78 |
+ ${CDEPEND} |
79 |
+ sys-devel/bison |
80 |
+ sys-devel/flex |
81 |
+ test? ( dev-libs/check ) |
82 |
+" |
83 |
+RDEPEND=" |
84 |
+ ${CDEPEND} |
85 |
+ acct-group/radvd |
86 |
+ acct-user/radvd |
87 |
+ selinux? ( sec-policy/selinux-radvd ) |
88 |
+" |
89 |
+ |
90 |
+DOCS=( CHANGES README TODO radvd.conf.example ) |
91 |
+ |
92 |
+PATCHES=( |
93 |
+ "${FILESDIR}"/${P}-musl-include.patch |
94 |
+) |
95 |
+ |
96 |
+src_configure() { |
97 |
+ econf --with-pidfile=/run/radvd/radvd.pid \ |
98 |
+ --with-systemdsystemunitdir=no \ |
99 |
+ $(use_with test check) |
100 |
+} |
101 |
+ |
102 |
+src_compile() { |
103 |
+ emake AR="$(tc-getAR)" |
104 |
+} |
105 |
+ |
106 |
+src_install() { |
107 |
+ default |
108 |
+ |
109 |
+ docinto html |
110 |
+ dodoc INTRO.html |
111 |
+ |
112 |
+ newinitd "${FILESDIR}"/${PN}-2.15.init ${PN} |
113 |
+ newconfd "${FILESDIR}"/${PN}.conf ${PN} |
114 |
+ |
115 |
+ systemd_dounit "${FILESDIR}"/${PN}.service |
116 |
+ |
117 |
+ readme.gentoo_create_doc |
118 |
+} |
119 |
+ |
120 |
+DISABLE_AUTOFORMATTING=1 |
121 |
+DOC_CONTENTS="Please create a configuration file ${ROOT}/etc/radvd.conf. |
122 |
+See ${ROOT}/usr/share/doc/${PF} for an example. |
123 |
+ |
124 |
+grsecurity users should allow a specific group to read /proc |
125 |
+and add the radvd user to that group, otherwise radvd may |
126 |
+segfault on startup." |