public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Rick Farina" <zerochaos@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-wireless/wireless-regdb/
Date: Sat, 19 Aug 2023 16:52:32 +0000 (UTC)	[thread overview]
Message-ID: <1692463942.2e25da30bafda0031bea4e6ea884e8f50ac9ff67.zerochaos@gentoo> (raw)

commit:     2e25da30bafda0031bea4e6ea884e8f50ac9ff67
Author:     Rick Farina <zerochaos <AT> gentoo <DOT> org>
AuthorDate: Sat Aug 19 16:38:42 2023 +0000
Commit:     Rick Farina <zerochaos <AT> gentoo <DOT> org>
CommitDate: Sat Aug 19 16:52:22 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2e25da30

net-wireless/wireless-regdb: make crda optional

Linux has now supported loading regulatory information without CRDA
since kernel 4.15.  After significant discussion negril, sam, and I have
agreed upon a set of checks to ensure users are getting working regulatory
information with or without crda, and have made crda optional.  All packages
that can cause radio emission must depend directly on wireless-regdb.

Primary discussion location
https://github.com/gentoo/gentoo/pull/31514

Signed-off-by: Rick Farina <zerochaos <AT> gentoo.org>

 .../wireless-regdb-20230503-r1.ebuild              | 36 ++++++++++++----------
 1 file changed, 20 insertions(+), 16 deletions(-)

diff --git a/net-wireless/wireless-regdb/wireless-regdb-20230503-r1.ebuild b/net-wireless/wireless-regdb/wireless-regdb-20230503-r1.ebuild
index 48c69e75e76d..cf490e5d7dd3 100644
--- a/net-wireless/wireless-regdb/wireless-regdb-20230503-r1.ebuild
+++ b/net-wireless/wireless-regdb/wireless-regdb-20230503-r1.ebuild
@@ -22,22 +22,25 @@ REQUIRED_USE="kernel_linux"
 
 pkg_pretend() {
 	if kernel_is -ge 4 15; then
-		if linux_config_exists && linux_chkconfig_builtin CFG80211 &&
-			[[ $(linux_chkconfig_string EXTRA_FIRMWARE) != *regulatory.db* ]]
-		then
-			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."
-		fi
-		if linux_config_exists && ! linux_chkconfig_present CFG80211; then
-			ewarn "REGULARTORY DOMAIN PROBLEM:"
-			ewarn "  With CONFIG_CFG80211 unset the wireless dirvers won't be able to load the regulatory.db"
-			ewarn "  which this ebuild installs.  Please set CONFIG_CFG80211=m."
+		if linux_config_exists; then
+			if linux_chkconfig_builtin CFG80211 &&
+				[[ $(linux_chkconfig_string EXTRA_FIRMWARE) != *regulatory.db* ]]; then
+				ewarn "REGULATORY DOMAIN PROBLEM:"
+				ewarn "  With CONFIG_CFG80211=y (built-in), the driver(s) 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."
+			fi
+			if ! linux_chkconfig_present CFG80211; then
+				ewarn "REGULARTORY DOMAIN PROBLEM:"
+				ewarn "  With CONFIG_CFG80211 unset, the driver(s) won't be able to load the regulatory.db from"
+				ewarn "  /lib/firmware, resulting in broken regulatory domain support. Please set CONFIG_CFG80211=m."
+			fi
 		fi
 
-		has_version net-wireless/crda && \
+		if has_version net-wireless/crda || use crda; then
 			ewarn "Starting from kernel version 4.15 net-wireless/crda is no longer needed."
+			ewarn "The crda USE flag will be removed on or after Feb 01, 2024"
+		fi
 
 		CONFIG_CHECK="EXPERT ~!CFG80211_CRDA_SUPPORT"
 		WARNING_CFG80211_CRDA_SUPPORT="You can safely disable CFG80211_CRDA_SUPPORT"
@@ -51,7 +54,8 @@ please enable CFG80211_CRDA_SUPPORT for proper regulatory domain support"
 }
 
 src_compile() {
-	einfo "Recompiling regulatory.bin from db.txt would break CRDA verify. Installing unmodified binary version."
+	einfo "Recompiling regulatory database(s) from db.txt would break signature verification."
+	einfo "Installing unmodified binary version."
 }
 
 src_install() {
@@ -63,13 +67,13 @@ src_install() {
 
 		insinto /etc/wireless-regdb/pubkeys
 		doins sforshee.key.pub.pem
-		doman -i18n= regulatory.bin.5
 	fi
 	# install the files the kernel needs unconditionally,
 	# they are small and kernels get upgraded
 	insinto /lib/firmware
 	doins regulatory.db regulatory.db.p7s
 
-	doman -i18n= regulatory.db.5
+	# regulatory.db.5 is a reference to regulatory.bin.5 so you need both unconditionally
+	doman -i18n= regulatory.db.5 regulatory.bin.5
 	dodoc README db.txt
 }


             reply	other threads:[~2023-08-19 16:52 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-19 16:52 Rick Farina [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-04-26  2:14 [gentoo-commits] repo/gentoo:master commit in: net-wireless/wireless-regdb/ Sam James
2025-03-20  0:07 Sam James
2025-03-20  0:06 Sam James
2024-12-01 12:42 Sam James
2024-12-01 11:51 Sam James
2024-10-02 20:52 Sam James
2024-05-09  0:38 Rick Farina
2024-01-21  9:42 David Seifert
2023-08-23 20:27 Rick Farina
2023-08-19 20:58 Rick Farina
2023-08-19 16:52 Rick Farina
2023-08-19 16:52 Rick Farina
2023-08-19 16:52 Rick Farina
2023-06-17 15:13 Sam James
2023-03-19 23:10 Sam James
2022-06-06 16:56 Rick Farina
2022-06-06 16:56 Rick Farina
2022-05-05 23:48 WANG Xuerui
2022-04-08 16:48 Rick Farina
2022-04-04 14:56 Rick Farina
2022-04-04 14:56 Rick Farina
2021-10-04 20:40 Sam James
2021-05-18 15:52 Rick Farina
2021-05-18 15:52 Rick Farina
2021-05-18 15:52 Rick Farina
2021-02-27  3:56 Sam James
2021-02-26 15:56 Rick Farina
2021-02-12 10:33 Sam James
2021-02-03  9:56 Tony Vroon
2020-08-14 18:19 Rick Farina
2019-06-04  2:14 Rick Farina
2019-05-23  6:39 Aaron Bauman
2019-03-01 22:07 Rick Farina
2018-10-25  3:39 Richard Farina
2018-09-07 19:20 Richard Farina
2018-05-31 15:19 Richard Farina
2018-05-10 16:42 Richard Farina
2018-01-29  9:55 Tony Vroon
2018-01-26 18:05 Richard Farina
2017-03-08 22:46 Richard Farina
2016-06-10 15:46 Richard Farina
2016-05-02 22:18 Richard Farina
2016-02-08 22:47 Richard Farina
2015-10-22 17:00 Richard Farina
2015-09-30 17:30 Richard Farina

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1692463942.2e25da30bafda0031bea4e6ea884e8f50ac9ff67.zerochaos@gentoo \
    --to=zerochaos@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox