diff mbox series

[RESEND] wpa-supplicant: add support for building without DBus

Message ID x1Pa.1711219993562897943.5Sfr@lists.openembedded.org
State New
Headers show
Series [RESEND] wpa-supplicant: add support for building without DBus | expand

Commit Message

Alibek Omarov March 23, 2024, 6:53 p.m. UTC
Useful on highly resource constrained embedded systems where DBus is an extra
dependency. Tested to build with and without ` dbus ` in PACKAGECONFIG.

DBus interface is left enabled by default to preserve old behavior.

Signed-off-by: Alibek Omarov < a1ba.omarov@gmail.com >
---
.../wpa-supplicant/ wpa-suppli cant_2.10.bb ( http://wpa-supplicant_2.10.bb ) | 21 +++++++++++++------
1 file changed, 15 insertions(+), 6 deletions(-)

-DEPENDS = " dbus libnl"
+DEPENDS = "libnl"

SRC_URI = " http://w1.fi/releases/wpa_sup plicant-${PV}.tar.gz ( http://w1.fi/releases/wpa_supplicant-$%7BPV%7D.tar.gz ) \
file://wpa-supplicant.sh \
@@ -25,9 +25,10 @@ S = "${WORKDIR}/wpa_supplicant-${P V}"

inherit pkgconfig systemd

-PACKAGECONFIG ?= "openssl"
+PACKAGECONFIG ?= "openssl dbus "
PACKAGECONFIG[gnutls] = ",,gnutls libgcrypt"
PACKAGECONFIG[openssl] = ",,openssl"
+PACKAGECONFIG[ dbus ] = ",, dbus "

CVE_PRODUCT = "wpa_supplicant"

@@ -46,6 +47,12 @@ do_configure () {
-e 's/\(^CONFIG_SAE=\)/#\1/' wpa_supplicant/.config
fi

+       if [ "${@bb.utils.contains('PACKAGE CONFIG',' dbus ','true','false', d)}"
= "false" ]; then
+               sed -i -e 's/\(^CONFIG_CTRL_IFACE_DBUS_N EW=\)/#\1/' \
+                       -e 's/\(^CONFIG_CTRL_IFACE_DBUS_I NTRO=\)/#\1/'
wpa_supplicant/.config
+       fi
+
+
# For rebuild
rm -f wpa_supplicant/*.d wpa_supplicant/ dbus /*.d
}
@@ -72,10 +79,12 @@ do_install () {
install -m 755 ${WORKDIR}/wpa-supplicant.sh
${D}${sysconfdir}/network/if-p re-up.d/wpa-supplicant
ln -sf ../if-pre-up.d/wpa-supplicant
${D}${sysconfdir}/network/if-p ost-down.d/wpa-supplicant

-       install -d ${D}/${sysconfdir}/ dbus -1/syst em.d
-       install -m 644
${S}/wpa_supplicant/ dbus / dbus - wpa_supplicant.conf
${D}/${sysconfdir}/ dbus -1/syst em.d
-       install -d ${D}/${datadir}/ dbus -1/system- services
-       install -m 644 ${S}/wpa_supplicant/ dbus /*.ser vice
${D}/${datadir}/ dbus -1/system- services
+       if ${@bb.utils.contains('PACKAGEC ONFIG',' dbus ','true','false', d)}; then
+               install -d ${D}/${sysconfdir}/ dbus -1/syst em.d
+               install -m 644
${S}/wpa_supplicant/ dbus / dbus - wpa_supplicant.conf
${D}/${sysconfdir}/ dbus -1/syst em.d
+               install -d ${D}/${datadir}/ dbus -1/system- services
+               install -m 644 ${S}/wpa_supplicant/ dbus /*.ser vice
${D}/${datadir}/ dbus -1/system- services
+       fi

if ${@bb.utils.contains('DISTRO_F EATURES','systemd','true','fal se',d)};
then
install -d ${D}/${systemd_system_unitdir}
--
2.34.1

Comments

patchtest@automation.yoctoproject.org March 23, 2024, 7:04 p.m. UTC | #1
Thank you for your submission. Patchtest identified one
or more issues with the patch. Please see the log below for
more information:

---
Testing patch /home/patchtest/share/mboxes/RESEND-wpa-supplicant-add-support-for-building-without-DBus.patch

FAIL: test mbox format: Series has malformed diff lines. Create the series again using git-format-patch and ensure it applies using git am (test_mbox.TestMbox.test_mbox_format)

PASS: test Signed-off-by presence (test_mbox.TestMbox.test_signed_off_by_presence)
PASS: test author valid (test_mbox.TestMbox.test_author_valid)
PASS: test commit message presence (test_mbox.TestMbox.test_commit_message_presence)
PASS: test max line length (test_metadata.TestMetadata.test_max_line_length)
PASS: test non-AUH upgrade (test_mbox.TestMbox.test_non_auh_upgrade)
PASS: test shortlog format (test_mbox.TestMbox.test_shortlog_format)
PASS: test shortlog length (test_mbox.TestMbox.test_shortlog_length)
PASS: test target mailing list (test_mbox.TestMbox.test_target_mailing_list)

SKIP: pretest pylint: Python-unidiff parse error (test_python_pylint.PyLint.pretest_pylint)
SKIP: pretest src uri left files: Patch cannot be merged (test_metadata.TestMetadata.pretest_src_uri_left_files)
SKIP: test CVE check ignore: No modified recipes or older target branch, skipping test (test_metadata.TestMetadata.test_cve_check_ignore)
SKIP: test CVE tag format: Parse error Unexpected hunk found: @@ -25,9 +25,10 @@ S = "${WORKDIR}/wpa_supplicant-${P V}"
SKIP: test Signed-off-by presence: Parse error Unexpected hunk found: @@ -25,9 +25,10 @@ S = "${WORKDIR}/wpa_supplicant-${P V}"
SKIP: test Upstream-Status presence: Parse error Unexpected hunk found: @@ -25,9 +25,10 @@ S = "${WORKDIR}/wpa_supplicant-${P V}"
SKIP: test bugzilla entry format: No bug ID found (test_mbox.TestMbox.test_bugzilla_entry_format)
SKIP: test lic files chksum modified not mentioned: No modified recipes, skipping test (test_metadata.TestMetadata.test_lic_files_chksum_modified_not_mentioned)
SKIP: test lic files chksum presence: No added recipes, skipping test (test_metadata.TestMetadata.test_lic_files_chksum_presence)
SKIP: test license presence: No added recipes, skipping test (test_metadata.TestMetadata.test_license_presence)
SKIP: test pylint: Python-unidiff parse error (test_python_pylint.PyLint.test_pylint)
SKIP: test series merge on head: Merge test is disabled for now (test_mbox.TestMbox.test_series_merge_on_head)
SKIP: test src uri left files: Patch cannot be merged (test_metadata.TestMetadata.test_src_uri_left_files)
SKIP: test summary presence: No added recipes, skipping test (test_metadata.TestMetadata.test_summary_presence)

---

Please address the issues identified and
submit a new revision of the patch, or alternatively, reply to this
email with an explanation of why the patch should be accepted. If you
believe these results are due to an error in patchtest, please submit a
bug at https://bugzilla.yoctoproject.org/ (use the 'Patchtest' category
under 'Yocto Project Subprojects'). For more information on specific
failures, see: https://wiki.yoctoproject.org/wiki/Patchtest. Thank
you!
diff mbox series

Patch

diff --git a/meta/recipes-connectivity/wp
a-supplicant/ wpa-supplicant_2. 10.bb ( http://wpa-supplicant_2.10.bb )
b/meta/recipes-connectivity/wp a-supplicant/ wpa-supplicant_2. 10.bb ( http://wpa-supplicant_2.10.bb )
index 46604045da..dec904b12d 100644
--- a/meta/recipes-connectivity/wp a-supplicant/ wpa-supplicant_2. 10.bb ( http://wpa-supplicant_2.10.bb )
+++ b/meta/recipes-connectivity/wp a-supplicant/ wpa-supplicant_2. 10.bb ( http://wpa-supplicant_2.10.bb )
@@ -8,7 +8,7 @@  LIC_FILES_CHKSUM =
"file://COPYING;md5=5ebcb90236 d1ad640558c3d3cd3035df \

file://README;beginline=1;endl ine=56;md5=e3d2f6c2948991e37c1 ca4960de84747
\

file://wpa_supplicant/wpa_supp licant.c;beginline=1;endline= 12;md5=76306a95306fee9a976b0ac 1be70f705"