wpa-supplicant 0.7: use madwifi solution from 0.5.x and 0.6.x
authorKoen Kooi <koen@openembedded.org>
Sun, 20 Feb 2011 16:01:12 +0000 (17:01 +0100)
committerKoen Kooi <koen@openembedded.org>
Sun, 20 Feb 2011 16:02:51 +0000 (17:02 +0100)
This makes the package only machine dependant if 'madwifi' is both in machine features and distro features. This avoids having to build an identical wpa-supplicant for every machine which is a significant saving for both machine and distro maintainers.

Fun fact: no in-tree machine has madwifi in machine features.

Signed-off-by: Koen Kooi <koen@openembedded.org>
recipes/wpa-supplicant/wpa-supplicant-0.7.inc

index b4e996a..7649038 100644 (file)
@@ -8,7 +8,7 @@ LIC_FILES_CHKSUM = "file://../COPYING;md5=c54ce9345727175ff66d17b67ff51f58 \
                     file://wpa_supplicant.c;beginline=1;endline=17;md5=acdc5a4b0d6345f21f136eace747260e"
 DEPENDS = "gnutls dbus libnl2 openssl ${@base_contains("COMBINED_FEATURES", "madwifi", "madwifi-ng", "",d)}"
 RRECOMMENDS_${PN} = "wpa-supplicant-passphrase wpa-supplicant-cli"
-INC_PR = "r5"
+INC_PR = "r6"
 
 SRC_URI = "http://hostap.epitest.fi/releases/wpa_supplicant-${PV}.tar.gz \
            file://defconfig \
@@ -81,7 +81,9 @@ do_install () {
        install -m 0644 ${WORKDIR}/99_wpa_supplicant ${D}/etc/default/volatiles
 }
 
-PACKAGE_ARCH = "${MACHINE_ARCH}"
+#we introduce MY_ARCH to get 'armv5te' as arch instead of the misleading 'arm' on armv5te builds
+MY_ARCH := "${PACKAGE_ARCH}"
+PACKAGE_ARCH = "${@base_contains('COMBINED_FEATURES', 'madwifi', '${MACHINE_ARCH}', '${MY_ARCH}', d)}"
 
 pkg_postinst_wpa-supplicant () {
        # can't do this offline