commit:     4d46c2c6ded34dc86725c3350376de2038f63e69
Author:     Ben Kohler <bkohler <AT> gentoo <DOT> org>
AuthorDate: Tue Sep  8 20:54:34 2020 +0000
Commit:     Ben Kohler <bkohler <AT> gentoo <DOT> org>
CommitDate: Tue Sep  8 20:54:53 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4d46c2c6

net-wireless/iwd: copy all recent changes to 9999

Package-Manager: Portage-3.0.6, Repoman-3.0.1
Signed-off-by: Ben Kohler <bkohler <AT> gentoo.org>

 net-wireless/iwd/iwd-9999.ebuild | 39 +++++++++++++++++++++++++++++++--------
 1 file changed, 31 insertions(+), 8 deletions(-)

diff --git a/net-wireless/iwd/iwd-9999.ebuild b/net-wireless/iwd/iwd-9999.ebuild
index 55d9df110e1..604e376346d 100644
--- a/net-wireless/iwd/iwd-9999.ebuild
+++ b/net-wireless/iwd/iwd-9999.ebuild
@@ -21,19 +21,30 @@ 
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"
+IUSE="+client +crda +monitor ofono wired cpu_flags_x86_aes cpu_flags_x86_ssse3
+standalone systemd"
 
-COMMON_DEPEND="sys-apps/dbus
-       client? ( sys-libs/readline:0= )"
+COMMON_DEPEND="
+       sys-apps/dbus
+       client? ( sys-libs/readline:0= )
+"
 
-[[ -z "${ELL_REQ}" ]] || COMMON_DEPEND+=" >=dev-libs/ell-${ELL_REQ}"
+[[ -z "${ELL_REQ}" ]] || COMMON_DEPEND+=" ~dev-libs/ell-${ELL_REQ}"
 
-RDEPEND="${COMMON_DEPEND}
+RDEPEND="
+       ${COMMON_DEPEND}
        net-wireless/wireless-regdb
-       crda? ( net-wireless/crda )"
+       crda? ( net-wireless/crda )
+       standalone? (
+               systemd? ( sys-apps/systemd )
+               !systemd? ( virtual/resolvconf )
+       )
+"
 
-DEPEND="${COMMON_DEPEND}
-       virtual/pkgconfig"
+DEPEND="
+       ${COMMON_DEPEND}
+       virtual/pkgconfig
+"
 
 [[ ${PV} == *9999* ]] && DEPEND+=" dev-python/docutils"
 
@@ -91,6 +102,10 @@ pkg_setup() {
        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
@@ -151,4 +166,12 @@ src_install() {
                exeinto /usr/share/iwd/scripts/
                doexe test/*
        fi
+
+       if use standalone ; then
+               dodir /etc/iwd
+               echo "[General]" > ${ED}/etc/iwd/main.conf
+               echo "EnableNetworkConfiguration=true" >> 
"${ED}"/etc/iwd/main.conf
+               echo "NameResolvingService=$(usex systemd systemd resolvconf)" 
>> "${ED}"/etc/iwd/main.conf
+               echo "rc_provide=\"net\"" > ${ED}/etc/conf.d/iwd
+       fi
 }

Reply via email to