[oe] modprobe: invalid lines in etc/modutils/hostap_cs.conf?

Martin Dietze di at fh-wedel.de
Fri Apr 24 11:31:28 UTC 2009


On Fri, April 24, 2009, Martin Dietze wrote:

> On Fri, April 24, 2009, Marcin Juszkiewicz wrote:
> 
> > That was done for 2.6 kernel.
> 
> ... which means that we could actually make this configuration
> file kernel version dependent and provide none or a different
> version of it for 2.4 kernels? Actually in my case the file

How about this patch?

> ---------- SNIP ----------

diff --git a/recipes/hostap/hostap-conf_1.0.bb b/recipes/hostap/hostap-conf_1.0.bb
index e0909dd..b13eb1d 100644
--- a/recipes/hostap/hostap-conf_1.0.bb
+++ b/recipes/hostap/hostap-conf_1.0.bb
@@ -7,20 +7,23 @@ PACKAGE_ARCH = "all"
 PR = "r9"

 SRC_URI = "file://hostap_cs.conf \
-           file://hostap_cs.modalias \
            file://hostap_cs.conf-upstream"

+SRC_URI_append = '${@base_conditional("KERNEL_MAJOR_VERSION", "2.6", " file://hostap_cs.modalias  ", "",d)}'
+
 do_compile() {
 }

 do_install() {
         install -d ${D}${sysconfdir}/pcmcia
-        install -d ${D}${sysconfdir}/modutils

         install -m 0644 ${WORKDIR}/hostap_cs.conf-upstream ${D}${sysconfdir}/pcmcia/hostap_cs.conf
        cat ${WORKDIR}/hostap_cs.conf >>${D}${sysconfdir}/pcmcia/hostap_cs.conf

-       install -m 0644 ${WORKDIR}/hostap_cs.modalias ${D}${sysconfdir}/modutils/hostap_cs.conf
+        if [ -r ${WORKDIR}/hostap_cs.modalias ]; then
+               install -d ${D}${sysconfdir}/modutils
+               install -m 0644 ${WORKDIR}/hostap_cs.modalias ${D}${sysconfdir}/modutils/hostap_cs.conf
+       fi
 }

 pkg_postinst () {

> ---------- SNIP ----------

Cheers,

Martin

-- 
----------- / http://herbert.the-little-red-haired-girl.org / -------------
=+= 
Wie verhindert man, dass einem die Geige gestohlen wird?
Man legt sie in einen Bratschenkasten...




More information about the Openembedded-devel mailing list