summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Kohler <bkohler@gentoo.org>2021-08-23 09:09:11 -0500
committerBen Kohler <bkohler@gentoo.org>2021-08-23 09:31:33 -0500
commit01388a7d944b57d042b104c42d3c0967937c1a83 (patch)
treed8a589a8536d6827450e274feff50c1d4440dc01 /net-wireless
parentdev-libs/ell: bump to 0.43 (diff)
downloadgentoo-01388a7d944b57d042b104c42d3c0967937c1a83.tar.gz
gentoo-01388a7d944b57d042b104c42d3c0967937c1a83.tar.bz2
gentoo-01388a7d944b57d042b104c42d3c0967937c1a83.zip
net-wireless/iwd: bump to 1.17
Includes one extra commit from upstream to fix tests. Package-Manager: Portage-3.0.22, Repoman-3.0.3 Signed-off-by: Ben Kohler <bkohler@gentoo.org>
Diffstat (limited to 'net-wireless')
-rw-r--r--net-wireless/iwd/Manifest1
-rw-r--r--net-wireless/iwd/files/iwd-1.17-fix-tests.patch35
-rw-r--r--net-wireless/iwd/iwd-1.17.ebuild185
3 files changed, 221 insertions, 0 deletions
diff --git a/net-wireless/iwd/Manifest b/net-wireless/iwd/Manifest
index 572d903cf8ae..0582bb4f3411 100644
--- a/net-wireless/iwd/Manifest
+++ b/net-wireless/iwd/Manifest
@@ -1,3 +1,4 @@
DIST iwd-1.14.tar.xz 933764 BLAKE2B edc6a925872afb6b98f5bbe16fc1cb6b8459a1aff33ec1f9e2d6bd45e605e34debaffa3048b6506cd3e8006c57d6efc9ae341f73050668454ad85fe7e6b4f256 SHA512 bff9b5a744e8eb4e285f28d976e9335d2c85b57fc1eb023c3aa9442e451523b3b9f080d2c02fc5432735c398857b64d115ed2929dd4bb910925cbf18df0b0874
DIST iwd-1.15.tar.xz 940724 BLAKE2B 6dae8a71e15136bcc9d8bb44cc6b152848207d89af2f447f48e834a3feda72a0a018dd1db3cb3a0e92c834cb2a19d8f9e4a9c900d91f96df378772d220205d65 SHA512 71e1f5f1b9d4e09a158b9bf801cee8af5ed8a19a3e80ad677e28ccab29ae10a79ebb7dbeaed60dd24283b6a40dbda8c212400b6d5ac659ed6056588a8663f0d4
DIST iwd-1.16.tar.xz 949692 BLAKE2B 6063f0fe79cfe61f68fd2d1acc4c67cd9b907bcf728da072b5845a60c6032db472428fa5ea7f203d840a7934c58fcb73d23805c5f3d4336a7ebb795575233260 SHA512 4cbf548421f7f5be6e73cea29802cf5757aece92fa2ce36257a608346bca0280338130915a974c895d3b865e0621a3ffe22228487d2552e407dacdd7d7eb9109
+DIST iwd-1.17.tar.xz 954428 BLAKE2B 2758b7c82afa94a90d2cb067e6ef63699e99e92101e35174d6976eee11a6057ce4d2324eda103a07f102a4d07d274d7f78888a5929928adcaefebe450b00298e SHA512 1dd04959a82c6a96b273479d604c989e246dea557190e3c936a21eea3041c3370c4c29b963171664e5e11fc43d0daf2ab5b62f325edc96f62a5a47259a733ed1
diff --git a/net-wireless/iwd/files/iwd-1.17-fix-tests.patch b/net-wireless/iwd/files/iwd-1.17-fix-tests.patch
new file mode 100644
index 000000000000..cf3de4c1d38f
--- /dev/null
+++ b/net-wireless/iwd/files/iwd-1.17-fix-tests.patch
@@ -0,0 +1,35 @@
+From ed10b00afa3f4c087b46d7ba0b60a47bd05d8b39 Mon Sep 17 00:00:00 2001
+From: Denis Kenzior <denkenz@gmail.com>
+Date: Mon, 23 Aug 2021 08:51:35 -0500
+Subject: unit: Fix eapol IP Allocation test failure
+
+This test was failing due to a change introduced in commit
+5c9de0cf23f9 which changed handshake state storage of IPs from host
+order to network byte order. Update the test to set IPs in network
+byte-order.
+
+Fixes: 5c9de0cf23f9 ("eapol: Store IP address in network byte order")
+---
+ unit/test-eapol.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/unit/test-eapol.c b/unit/test-eapol.c
+index b6a6adcb..470e0e9f 100644
+--- a/unit/test-eapol.c
++++ b/unit/test-eapol.c
+@@ -3802,9 +3802,9 @@ static void eapol_ap_sta_handshake_ip_alloc_ok_test(const void *data)
+ handshake_state_set_ssid(s.ap_hs, (void *) ssid, strlen(ssid));
+ handshake_state_set_pmk(s.ap_hs, psk, 32);
+ s.ap_hs->support_ip_allocation = true;
+- s.ap_hs->client_ip_addr = 0x01020304;
+- s.ap_hs->subnet_mask = 0xffff0000;
+- s.ap_hs->go_ip_addr = 0x01020305;
++ s.ap_hs->client_ip_addr = L_CPU_TO_BE32(0x01020304);
++ s.ap_hs->subnet_mask = L_CPU_TO_BE32(0xffff0000);
++ s.ap_hs->go_ip_addr = L_CPU_TO_BE32(0x01020305);
+
+ handshake_state_set_authenticator(s.sta_hs, false);
+ handshake_state_set_event_func(s.sta_hs, test_ap_sta_hs_event, &s);
+--
+cgit 1.2.3-1.el7
+
diff --git a/net-wireless/iwd/iwd-1.17.ebuild b/net-wireless/iwd/iwd-1.17.ebuild
new file mode 100644
index 000000000000..91b133c1eb32
--- /dev/null
+++ b/net-wireless/iwd/iwd-1.17.ebuild
@@ -0,0 +1,185 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+inherit flag-o-matic linux-info systemd
+
+#Set this variable to the required external ell version
+ELL_REQ="0.43"
+
+if [[ ${PV} == *9999* ]]; then
+ inherit autotools git-r3
+ IWD_EGIT_REPO_URI="https://git.kernel.org/pub/scm/network/wireless/iwd.git"
+ ELL_EGIT_REPO_URI="https://git.kernel.org/pub/scm/libs/ell/ell.git"
+else
+ SRC_URI="https://www.kernel.org/pub/linux/network/wireless/${P}.tar.xz"
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~riscv ~sparc ~x86"
+ MYRST2MAN="RST2MAN=:"
+fi
+
+DESCRIPTION="Wireless daemon for linux"
+HOMEPAGE="https://git.kernel.org/pub/scm/network/wireless/iwd.git/"
+
+LICENSE="GPL-2"
+SLOT="0"
+IUSE="+client +crda +monitor ofono wired cpu_flags_x86_aes cpu_flags_x86_ssse3
+standalone systemd"
+
+DEPEND="
+ sys-apps/dbus
+ client? ( sys-libs/readline:0= )
+"
+
+[[ -z "${ELL_REQ}" ]] || DEPEND+=" ~dev-libs/ell-${ELL_REQ}"
+
+RDEPEND="
+ ${DEPEND}
+ net-wireless/wireless-regdb
+ crda? ( net-wireless/crda )
+ standalone? (
+ systemd? ( sys-apps/systemd )
+ !systemd? ( virtual/resolvconf )
+ )
+"
+
+BDEPEND="
+ virtual/pkgconfig
+"
+
+[[ ${PV} == *9999* ]] && BDEPEND+=" dev-python/docutils"
+
+PATCHES=( "${FILESDIR}"/iwd-1.17-fix-tests.patch )
+
+pkg_setup() {
+ CONFIG_CHECK="
+ ~ASYMMETRIC_KEY_TYPE
+ ~ASYMMETRIC_PUBLIC_KEY_SUBTYPE
+ ~CFG80211
+ ~CRYPTO_AES
+ ~CRYPTO_CBC
+ ~CRYPTO_CMAC
+ ~CRYPTO_DES
+ ~CRYPTO_ECB
+ ~CRYPTO_HMAC
+ ~CRYPTO_MD4
+ ~CRYPTO_MD5
+ ~CRYPTO_RSA
+ ~CRYPTO_SHA1
+ ~CRYPTO_SHA256
+ ~CRYPTO_SHA512
+ ~CRYPTO_USER_API_HASH
+ ~CRYPTO_USER_API_SKCIPHER
+ ~KEY_DH_OPERATIONS
+ ~PKCS7_MESSAGE_PARSER
+ ~RFKILL
+ ~X509_CERTIFICATE_PARSER
+ "
+ if use crda;then
+ CONFIG_CHECK="${CONFIG_CHECK} ~CFG80211_CRDA_SUPPORT"
+ WARNING_CFG80211_CRDA_SUPPORT="REGULATORY DOMAIN PROBLEM: please enable CFG80211_CRDA_SUPPORT for proper regulatory domain support"
+ fi
+
+ if use amd64;then
+ CONFIG_CHECK="${CONFIG_CHECK} ~CRYPTO_DES3_EDE_X86_64"
+ WARNING_CRYPTO_DES3_EDE_X86_64="CRYPTO_DES3_EDE_X86_64: enable for increased performance"
+ fi
+
+ if use cpu_flags_x86_aes;then
+ CONFIG_CHECK="${CONFIG_CHECK} ~CRYPTO_AES_NI_INTEL"
+ WARNING_CRYPTO_AES_NI_INTEL="CRYPTO_AES_NI_INTEL: enable for increased performance"
+ fi
+
+ if use cpu_flags_x86_ssse3 && use amd64; then
+ CONFIG_CHECK="${CONFIG_CHECK} ~CRYPTO_SHA1_SSSE3 ~CRYPTO_SHA256_SSSE3 ~CRYPTO_SHA512_SSSE3"
+ WARNING_CRYPTO_SHA1_SSSE3="CRYPTO_SHA1_SSSE3: enable for increased performance"
+ WARNING_CRYPTO_SHA256_SSSE3="CRYPTO_SHA256_SSSE3: enable for increased performance"
+ WARNING_CRYPTO_SHA512_SSSE3="CRYPTO_SHA512_SSSE3: enable for increased performance"
+ fi
+
+ if use kernel_linux && kernel_is -ge 4 20; then
+ CONFIG_CHECK="${CONFIG_CHECK} ~PKCS8_PRIVATE_KEY_PARSER"
+ fi
+
+ check_extra_config
+
+ if ! use crda; then
+ if use kernel_linux && kernel_is -lt 4 15; then
+ ewarn "POSSIBLE REGULATORY DOMAIN PROBLEM:"
+ ewarn "Regulatory domain support for kernels older than 4.15 requires crda."
+ fi
+ if linux_config_exists && linux_chkconfig_builtin CFG80211 &&
+ [[ $(linux_chkconfig_string EXTRA_FIRMWARE) != *regulatory.db* ]]
+ then
+ ewarn ""
+ ewarn "REGULATORY DOMAIN PROBLEM:"
+ ewarn "With CONFIG_CFG80211=y (built-in), the driver won't be able to load regulatory.db from"
+ ewarn " /lib/firmware, resulting in broken regulatory domain support. Please set CONFIG_CFG80211=m"
+ ewarn " or add regulatory.db and regulatory.db.p7s to CONFIG_EXTRA_FIRMWARE."
+ ewarn ""
+ fi
+ fi
+}
+
+src_unpack() {
+ if [[ ${PV} == *9999* ]] ; then
+ EGIT_REPO_URI=${IWD_EGIT_REPO_URI} git-r3_src_unpack
+ EGIT_REPO_URI=${ELL_EGIT_REPO_URI} EGIT_CHECKOUT_DIR=${WORKDIR}/ell git-r3_src_unpack
+ else
+ default
+ fi
+}
+
+src_prepare() {
+ default
+ if [[ ${PV} == *9999* ]] ; then
+ eautoreconf
+ fi
+}
+
+src_configure() {
+ append-cflags "-fsigned-char"
+ local myeconfargs=(
+ --sysconfdir="${EPREFIX}"/etc/iwd --localstatedir="${EPREFIX}"/var
+ $(use_enable client)
+ $(use_enable monitor)
+ $(use_enable ofono)
+ $(use_enable wired)
+ --enable-systemd-service
+ --with-systemd-unitdir="$(systemd_get_systemunitdir)"
+ --with-systemd-modloaddir="${EPREFIX}/usr/lib/modules-load.d"
+ --with-systemd-networkdir="$(systemd_get_utildir)/network"
+ )
+ [[ ${PV} == *9999* ]] || myeconfargs+=(--enable-external-ell)
+ econf "${myeconfargs[@]}"
+}
+
+src_compile() {
+ emake ${MYRST2MAN}
+}
+
+src_install() {
+ emake DESTDIR="${D}" ${MYRST2MAN} install
+ keepdir /var/lib/${PN}
+
+ newinitd "${FILESDIR}/iwd.initd-r1" iwd
+
+ if use wired;then
+ newinitd "${FILESDIR}/ead.initd" ead
+ fi
+
+ if [[ ${PV} == *9999* ]] ; then
+ exeinto /usr/share/iwd/scripts/
+ doexe test/*
+ fi
+
+ if use standalone ; then
+ local iwdconf="${ED}/etc/iwd/main.conf"
+ dodir /etc/iwd
+ echo "[General]" > "${iwdconf}"
+ echo "EnableNetworkConfiguration=true" >> "${iwdconf}"
+ echo "[Network]" >> "${iwdconf}"
+ echo "NameResolvingService=$(usex systemd systemd resolvconf)" >> "${iwdconf}"
+ dodir /etc/conf.d
+ echo "rc_provide=\"net\"" > ${ED}/etc/conf.d/iwd
+ fi
+}