wpa-supplicant: Build .config from fragments
PATCH 1/1 wpa-supplicant: Build .config from fragments
do_configure built wpa_supplicant's .config by sed-ing upstream's defconfig and echoing CONFIG lines onto it, this is both fragile and makes handling anything not covered by PACKAGECONFIG tricky.
wpa_supplicant has no configure script and no kconfig - it's just make, so switch do_configure to build the configuration from a base file and .cfg fragments, which matches what CML1 recipes do (though this isn't CML1).
This should have no functional change; the effective configuration should be identical.
AI-Generated: Claude Opus 5 (Claude Code)
--- .../wpa-supplicant/wpa-supplicant/mbo.cfg | 2 + .../wpa-supplicant/wpa-supplicant/suiteb.cfg | 4 ++ .../wpa-supplicant/tls-gnutls.cfg | 23 ++++++++++ .../wpa-supplicant/tls-openssl.cfg | 7 +++ .../wpa-supplicant/wpa-supplicant/wnm.cfg | 2 + .../wpa-supplicant/wpa-supplicant_2.12.bb | 46 +++++++------------ 6 files changed, 55 insertions(+), 29 deletions(-) create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/mbo.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/suiteb.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/tls-gnutls.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/tls-openssl.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/wnm.cfg
meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/mbo.cfg new file +2 -0
@@ -0,0 +1,2 @@ +# Support Multi Band Operation +CONFIG_MBO=y
meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/suiteb.cfg new file +4 -0
@@ -0,0 +1,4 @@ +# Suite B cryptography support. Not offered by upstream's defconfig; the +# symbols are read directly by wpa_supplicant/Makefile. +CONFIG_SUITEB=y +CONFIG_SUITEB192=y
meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/tls-gnutls.cfg new file +23 -0
@@ -0,0 +1,23 @@ +# Select TLS implementation +# openssl = OpenSSL (default) +# gnutls = GnuTLS +# internal = Internal TLSv1 implementation (experimental) +# linux = Linux kernel AF_ALG and internal TLSv1 implementation (experimental) +# none = Empty template +CONFIG_TLS=gnutls + +# The following need functionality the GnuTLS backend does not provide, so they +# are turned back off here. "undefine" rather than an empty assignment leaves +# exactly the state the previous approach of commenting the lines out produced. + +# Device Provisioning Protocol (DPP) (also known as Wi-Fi Easy Connect) +undefine CONFIG_DPP + +# EAP-pwd (secure authentication using only a password) +undefine CONFIG_EAP_PWD + +# Simultaneous Authentication of Equals (SAE), WPA3-Personal +undefine CONFIG_SAE + +# Opportunistic Wireless Encryption (OWE) +undefine CONFIG_OWE
meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/tls-openssl.cfg new file +7 -0
@@ -0,0 +1,7 @@ +# Select TLS implementation +# openssl = OpenSSL (default) +# gnutls = GnuTLS +# internal = Internal TLSv1 implementation (experimental) +# linux = Linux kernel AF_ALG and internal TLSv1 implementation (experimental) +# none = Empty template +CONFIG_TLS=openssl
meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/wnm.cfg new file +2 -0
@@ -0,0 +1,2 @@ +# Wireless Network Management (IEEE Std 802.11v-2011) +CONFIG_WNM=y
meta/recipes-connectivity/wpa-supplicant/wpa-supplicant_2.12.bb +17 -29
65 lines not on this page · raw message
Quoted 21 lines · Alex Kiernan via lists.openembedded.org
do_configurebuilt wpa_supplicant's .config by sed-ing upstream's defconfig and echoing CONFIG lines onto it, this is both fragile and makes handling anything not covered by PACKAGECONFIG tricky.
wpa_supplicanthas no configure script and no kconfig - it's just make, so switchdo_configureto build the configuration from a base file and .cfg fragments, which matches what CML1 recipes do (though this isn't CML1).This should have no functional change; the effective configuration should be identical.
AI-Generated: Claude Opus 5 (Claude Code)
Signed-off-by Alex Kiernan <[email protected]>---
.../wpa-supplicant/wpa-supplicant/mbo.cfg | 2 + .../wpa-supplicant/wpa-supplicant/suiteb.cfg | 4 ++ .../wpa-supplicant/tls-gnutls.cfg | 23 ++++++++++ .../wpa-supplicant/tls-openssl.cfg | 7 +++ .../wpa-supplicant/wpa-supplicant/wnm.cfg | 2 + .../wpa-supplicant/wpa-supplicant_2.12.bb | 46 +++++++------------
Quoted 6 lines
6 files changed, 55 insertions(+), 29 deletions(-)create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/mbo.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/suiteb.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/tls-gnutls.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/tls-openssl.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/wnm.cfg
I'm not convinced this is an improvement. It takes one relatively readable function and turns it into many different files spread all over and complicates the SRC_URI.
I appreciate it isn't easy to add new entries currently but that could be solved by making this function a standalone function which a bbappend could add to, if the additional PACKAGECONFIG really isn't suitable for core.
So no, I'm not really convinced this is a change for the better :/
Cheers,
Richard
Quoted 30 lines · Richard Purdie
Quoted 14 lines · Alex Kiernan via lists.openembedded.org
do_configurebuilt wpa_supplicant's .config by sed-ing upstream's defconfig and echoing CONFIG lines onto it, this is both fragile and makes handling anything not covered by PACKAGECONFIG tricky.
wpa_supplicanthas no configure script and no kconfig - it's just make, so switchdo_configureto build the configuration from a base file and .cfg fragments, which matches what CML1 recipes do (though this isn't CML1).This should have no functional change; the effective configuration should be identical.
AI-Generated: Claude Opus 5 (Claude Code)
Signed-off-by Alex Kiernan <[email protected]>Quoted 13 lines
--- .../wpa-supplicant/wpa-supplicant/mbo.cfg | 2 + .../wpa-supplicant/wpa-supplicant/suiteb.cfg | 4 ++ .../wpa-supplicant/tls-gnutls.cfg | 23 ++++++++++ .../wpa-supplicant/tls-openssl.cfg | 7 +++ .../wpa-supplicant/wpa-supplicant/wnm.cfg | 2 + .../wpa-supplicant/wpa-supplicant_2.12.bb | 46 +++++++------------ 6 files changed, 55 insertions(+), 29 deletions(-) create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/mbo.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/suiteb.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/tls-gnutls.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/tls-openssl.cfg create mode 100644 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant/wnm.cfg
Quoted 9 lines
I'm not convinced this is an improvement. It takes one relatively readable function and turns it into many different files spread all over and complicates the
SRC_URI.I appreciate it isn't easy to add new entries currently but that could be solved by making this function a standalone function which a bbappend could add to, if the additional PACKAGECONFIG really isn't suitable for core.
Okay, I can do that instead... what really bit me was the need to replace the whole config and then having override the entire do_configure in order to stop it modifying it.
Signature · 1 line
Alex Kiernan