1 |
commit: 08966208e5ed1f41923e5207e6cbec70b2cd3cb9 |
2 |
Author: Ben Kohler <bkohler <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Sep 3 16:45:29 2020 +0000 |
4 |
Commit: Ben Kohler <bkohler <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Sep 3 17:37:34 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=08966208 |
7 |
|
8 |
net-wireless/iwd: revbump to test new standalone mode |
9 |
|
10 |
Bug: https://bugs.gentoo.org/727218 |
11 |
|
12 |
Package-Manager: Portage-3.0.5, Repoman-3.0.1 |
13 |
Signed-off-by: Ben Kohler <bkohler <AT> gentoo.org> |
14 |
|
15 |
net-wireless/iwd/iwd-1.8-r2.ebuild | 179 +++++++++++++++++++++++++++++++++++++ |
16 |
net-wireless/iwd/metadata.xml | 2 + |
17 |
2 files changed, 181 insertions(+) |
18 |
|
19 |
diff --git a/net-wireless/iwd/iwd-1.8-r2.ebuild b/net-wireless/iwd/iwd-1.8-r2.ebuild |
20 |
new file mode 100644 |
21 |
index 00000000000..a00b3791b04 |
22 |
--- /dev/null |
23 |
+++ b/net-wireless/iwd/iwd-1.8-r2.ebuild |
24 |
@@ -0,0 +1,179 @@ |
25 |
+# Copyright 1999-2020 Gentoo Authors |
26 |
+# Distributed under the terms of the GNU General Public License v2 |
27 |
+ |
28 |
+EAPI=6 |
29 |
+inherit flag-o-matic linux-info systemd |
30 |
+ |
31 |
+#Set this variable to the required external ell version |
32 |
+ELL_REQ="0.32" |
33 |
+ |
34 |
+if [[ ${PV} == *9999* ]]; then |
35 |
+ inherit autotools git-r3 |
36 |
+ IWD_EGIT_REPO_URI="https://git.kernel.org/pub/scm/network/wireless/iwd.git" |
37 |
+ ELL_EGIT_REPO_URI="https://git.kernel.org/pub/scm/libs/ell/ell.git" |
38 |
+else |
39 |
+ SRC_URI="https://www.kernel.org/pub/linux/network/wireless/${P}.tar.xz" |
40 |
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~sparc ~x86" |
41 |
+fi |
42 |
+ |
43 |
+DESCRIPTION="Wireless daemon for linux" |
44 |
+HOMEPAGE="https://git.kernel.org/pub/scm/network/wireless/iwd.git/" |
45 |
+ |
46 |
+LICENSE="GPL-2" |
47 |
+SLOT="0" |
48 |
+IUSE="+client +crda +monitor ofono wired cpu_flags_x86_aes cpu_flags_x86_ssse3 |
49 |
+standalone systemd" |
50 |
+ |
51 |
+COMMON_DEPEND=" |
52 |
+ sys-apps/dbus |
53 |
+ client? ( sys-libs/readline:0= ) |
54 |
+" |
55 |
+ |
56 |
+[[ -z "${ELL_REQ}" ]] || COMMON_DEPEND+=" >=dev-libs/ell-${ELL_REQ}" |
57 |
+ |
58 |
+RDEPEND=" |
59 |
+ ${COMMON_DEPEND} |
60 |
+ net-wireless/wireless-regdb |
61 |
+ crda? ( net-wireless/crda ) |
62 |
+ standalone? ( |
63 |
+ systemd? ( sys-apps/systemd ) |
64 |
+ !systemd? ( virtual/resolvconf ) |
65 |
+ ) |
66 |
+" |
67 |
+ |
68 |
+DEPEND=" |
69 |
+ ${COMMON_DEPEND} |
70 |
+ virtual/pkgconfig |
71 |
+" |
72 |
+ |
73 |
+[[ ${PV} == *9999* ]] && DEPEND+=" dev-python/docutils" |
74 |
+ |
75 |
+PATCHES=( "${FILESDIR}"/iwd-1.8-eapol-prevent-key-reinstallation.patch ) |
76 |
+ |
77 |
+pkg_setup() { |
78 |
+ CONFIG_CHECK=" |
79 |
+ ~ASYMMETRIC_KEY_TYPE |
80 |
+ ~ASYMMETRIC_PUBLIC_KEY_SUBTYPE |
81 |
+ ~CFG80211 |
82 |
+ ~CRYPTO_AES |
83 |
+ ~CRYPTO_ARC4 |
84 |
+ ~CRYPTO_CBC |
85 |
+ ~CRYPTO_CMAC |
86 |
+ ~CRYPTO_DES |
87 |
+ ~CRYPTO_ECB |
88 |
+ ~CRYPTO_HMAC |
89 |
+ ~CRYPTO_MD4 |
90 |
+ ~CRYPTO_MD5 |
91 |
+ ~CRYPTO_RSA |
92 |
+ ~CRYPTO_SHA1 |
93 |
+ ~CRYPTO_SHA256 |
94 |
+ ~CRYPTO_SHA512 |
95 |
+ ~CRYPTO_USER_API_HASH |
96 |
+ ~CRYPTO_USER_API_SKCIPHER |
97 |
+ ~KEY_DH_OPERATIONS |
98 |
+ ~PKCS7_MESSAGE_PARSER |
99 |
+ ~RFKILL |
100 |
+ ~X509_CERTIFICATE_PARSER |
101 |
+ " |
102 |
+ if use crda;then |
103 |
+ CONFIG_CHECK="${CONFIG_CHECK} ~CFG80211_CRDA_SUPPORT" |
104 |
+ WARNING_CFG80211_CRDA_SUPPORT="REGULATORY DOMAIN PROBLEM: please enable CFG80211_CRDA_SUPPORT for proper regulatory domain support" |
105 |
+ fi |
106 |
+ |
107 |
+ if use amd64;then |
108 |
+ CONFIG_CHECK="${CONFIG_CHECK} ~CRYPTO_DES3_EDE_X86_64" |
109 |
+ WARNING_CRYPTO_DES3_EDE_X86_64="CRYPTO_DES3_EDE_X86_64: enable for increased performance" |
110 |
+ fi |
111 |
+ |
112 |
+ if use cpu_flags_x86_aes;then |
113 |
+ CONFIG_CHECK="${CONFIG_CHECK} ~CRYPTO_AES_NI_INTEL" |
114 |
+ WARNING_CRYPTO_AES_NI_INTEL="CRYPTO_AES_NI_INTEL: enable for increased performance" |
115 |
+ fi |
116 |
+ |
117 |
+ if use cpu_flags_x86_ssse3 && use amd64; then |
118 |
+ CONFIG_CHECK="${CONFIG_CHECK} ~CRYPTO_SHA1_SSSE3 ~CRYPTO_SHA256_SSSE3 ~CRYPTO_SHA512_SSSE3" |
119 |
+ WARNING_CRYPTO_SHA1_SSSE3="CRYPTO_SHA1_SSSE3: enable for increased performance" |
120 |
+ WARNING_CRYPTO_SHA256_SSSE3="CRYPTO_SHA256_SSSE3: enable for increased performance" |
121 |
+ WARNING_CRYPTO_SHA512_SSSE3="CRYPTO_SHA512_SSSE3: enable for increased performance" |
122 |
+ fi |
123 |
+ |
124 |
+ if use kernel_linux && kernel_is -ge 4 20; then |
125 |
+ CONFIG_CHECK="${CONFIG_CHECK} ~PKCS8_PRIVATE_KEY_PARSER" |
126 |
+ fi |
127 |
+ |
128 |
+ check_extra_config |
129 |
+ |
130 |
+ if ! use crda; then |
131 |
+ if use kernel_linux && kernel_is -lt 4 15; then |
132 |
+ ewarn "POSSIBLE REGULATORY DOMAIN PROBLEM:" |
133 |
+ ewarn "Regulatory domain support for kernels older than 4.15 requires crda." |
134 |
+ fi |
135 |
+ if linux_config_exists && linux_chkconfig_builtin CFG80211 && |
136 |
+ [[ $(linux_chkconfig_string EXTRA_FIRMWARE) != *regulatory.db* ]] |
137 |
+ then |
138 |
+ ewarn "" |
139 |
+ ewarn "REGULATORY DOMAIN PROBLEM:" |
140 |
+ ewarn "With CONFIG_CFG80211=y (built-in), the driver won't be able to load regulatory.db from" |
141 |
+ ewarn " /lib/firmware, resulting in broken regulatory domain support. Please set CONFIG_CFG80211=m" |
142 |
+ ewarn " or add regulatory.db and regulatory.db.p7s to CONFIG_EXTRA_FIRMWARE." |
143 |
+ ewarn "" |
144 |
+ fi |
145 |
+ fi |
146 |
+} |
147 |
+ |
148 |
+src_unpack() { |
149 |
+ if [[ ${PV} == *9999* ]] ; then |
150 |
+ EGIT_REPO_URI=${IWD_EGIT_REPO_URI} git-r3_src_unpack |
151 |
+ EGIT_REPO_URI=${ELL_EGIT_REPO_URI} EGIT_CHECKOUT_DIR=${WORKDIR}/ell git-r3_src_unpack |
152 |
+ else |
153 |
+ default |
154 |
+ fi |
155 |
+} |
156 |
+ |
157 |
+src_prepare() { |
158 |
+ default |
159 |
+ if [[ ${PV} == *9999* ]] ; then |
160 |
+ eautoreconf |
161 |
+ fi |
162 |
+} |
163 |
+ |
164 |
+src_configure() { |
165 |
+ append-cflags "-fsigned-char" |
166 |
+ local myeconfargs=( |
167 |
+ --sysconfdir="${EPREFIX}"/etc/iwd --localstatedir="${EPREFIX}"/var |
168 |
+ $(use_enable client) |
169 |
+ $(use_enable monitor) |
170 |
+ $(use_enable ofono) |
171 |
+ $(use_enable wired) |
172 |
+ --enable-systemd-service |
173 |
+ --with-systemd-unitdir="$(systemd_get_systemunitdir)" |
174 |
+ --with-systemd-modloaddir="${EPREFIX}/usr/lib/modules-load.d" |
175 |
+ --with-systemd-networkdir="$(systemd_get_utildir)/network" |
176 |
+ ) |
177 |
+ [[ ${PV} == *9999* ]] || myeconfargs+=(--enable-external-ell) |
178 |
+ econf "${myeconfargs[@]}" |
179 |
+} |
180 |
+ |
181 |
+src_install() { |
182 |
+ default |
183 |
+ keepdir /var/lib/${PN} |
184 |
+ |
185 |
+ newinitd "${FILESDIR}/iwd.initd-r1" iwd |
186 |
+ |
187 |
+ if use wired;then |
188 |
+ newinitd "${FILESDIR}/ead.initd" ead |
189 |
+ fi |
190 |
+ |
191 |
+ if [[ ${PV} == *9999* ]] ; then |
192 |
+ exeinto /usr/share/iwd/scripts/ |
193 |
+ doexe test/* |
194 |
+ fi |
195 |
+ |
196 |
+ if use standalone ; then |
197 |
+ dodir /etc/iwd |
198 |
+ echo "[General]" > ${ED}/etc/iwd/main.conf |
199 |
+ echo "EnableNetworkConfiguration=true" >> "${ED}"/etc/iwd/main.conf |
200 |
+ echo "NameResolvingService=$(usex systemd systemd resolvconf)" >> "${ED}"/etc/iwd/main.conf |
201 |
+ echo "rc_provide=\"net\"" > ${ED}/etc/conf.d/iwd |
202 |
+ fi |
203 |
+} |
204 |
|
205 |
diff --git a/net-wireless/iwd/metadata.xml b/net-wireless/iwd/metadata.xml |
206 |
index b8cd886617b..2b83f954fd8 100644 |
207 |
--- a/net-wireless/iwd/metadata.xml |
208 |
+++ b/net-wireless/iwd/metadata.xml |
209 |
@@ -10,6 +10,8 @@ |
210 |
<flag name='crda'>Use net-wireless/crda for regulatory domain loading instead of in-kernel (4.15+) support</flag> |
211 |
<flag name='monitor'>Enable iwmon monitor tool</flag> |
212 |
<flag name='ofono'>Enable support for oFono SIM authentication</flag> |
213 |
+ <flag name='standalone'>Enable standalone mode with built-in DHCP client and DNS handling"</flag> |
214 |
+ <flag name='systemd'>Use systemd-resolve rather than resolvconf for DNS handling in standalone mode</flag> |
215 |
<flag name='wired'>Enable ethernet authentication daemon</flag> |
216 |
</use> |
217 |
</pkgmetadata> |