[yocto] so how does PACKAGECONFIG really work?

Martin Jansa martin.jansa at gmail.com
Sat Nov 2 11:16:38 PDT 2013


On Sat, Nov 02, 2013 at 01:15:04PM -0400, Robert P. J. Day wrote:
> 
>   most of the way thru the variable glossary and this one confuses me.
> from here:
> 
> http://www.yoctoproject.org/docs/latest/ref-manual/ref-manual.html#var-PACKAGECONFIG
> 
> we have:
> 
> "This variable provides a means of enabling or disabling features of a
> recipe on a per-recipe basis. PACKAGECONFIG blocks are defined in
> recipes when you specify features and then arguments that define
> feature behaviors. Here is the basic block structure:
> 
>      PACKAGECONFIG ??= "f1 f2 f3 ..."
>      PACKAGECONFIG[f1] = "--with-f1,--without-f1,build-deps-f1,rt-deps-f1"
>      PACKAGECONFIG[f2] = "--with-f2,--without-f2,build-deps-f2,rt-deps-f2"
>      PACKAGECONFIG[f3] = "--with-f3,--without-f3,build-deps-f3,rt-deps-f3"
> 
> which *seems* to suggest that you must first set PACKAGECONFIG to the
> list of features, but i see numerous examples that don't seem to obey
> that condition.

Not all features, but *enabled* features.

>  from meta-oe/recipes-extended, this looks good:
> 
> gnuplot/gnuplot.inc:PACKAGECONFIG ??= "cairo"
> gnuplot/gnuplot.inc:PACKAGECONFIG[cairo] = "--with-cairo,--without-cairo,cairo pango"
> 
>  this looks like it's missing a reference to "ftdi":
> 
> lcdproc/lcdproc5.inc:PACKAGECONFIG ??= "usb"
> lcdproc/lcdproc5.inc:PACKAGECONFIG[usb] = "--enable-libusb,--disable-libusb,virtual/libusb0"
> lcdproc/lcdproc5.inc:PACKAGECONFIG[ftdi] = "--enable-libftdi,--disable-libftdi,libftdi"

It's quite simple, usb is by default enabled, ftdi is by default
disabled.

If you want to enable ftdi in your .bbappend or through local.conf you
need to add ftdi to PACKAGECONFIG variable.

>  and this looks, well, totally wrong (at least according to the
> explanation in the manual):
> 
> collectd/collectd_5.2.2.bb:PACKAGECONFIG ??= ""
> collectd/collectd_5.2.2.bb:PACKAGECONFIG[snmp] = "--enable-snmp,--disable-snmp --with-libnetsnmp=no,net-snmp"
> collectd/collectd_5.2.2.bb:PACKAGECONFIG[libmemcached] = "--with-libmemcached,--without-libmemcached,libmemcached"
> collectd/collectd_5.2.2.bb:PACKAGECONFIG[iptables] = "--enable-iptables,--disable-iptables,iptables"
> collectd/collectd_5.2.2.bb:PACKAGECONFIG[postgresql] = "--enable-postgresql,--disable-postgresql,postgresql"
> collectd/collectd_5.2.2.bb:PACKAGECONFIG[dbi] = "--enable-dbi,--disable-dbi,libdbi"
> collectd/collectd_5.2.2.bb:PACKAGECONFIG[modbus] = "--enable-modbus,--disable-modbus,libmodbus"
> collectd/collectd_5.2.2.bb:PACKAGECONFIG[libowcapi] = "--with-libowcapi,--without-libowcapi,owfs"
> collectd/collectd_5.2.2.bb:PACKAGECONFIG[sensors] = "--enable-sensors,--disable-sensors,lmsensors"
> 
>  so ... clarification? oh, and while i'm here, it's easy enough to use
> the "bb" utility to print PACKAGECONFIG:
> 
> $ bb show -r gnuplot PACKAGECONFIG
> Parsing recipes..done.
> PACKAGECONFIG="cairo"
> $
> 
> but is there a way to display the value of PACKAGECONFIG[cairo]? "bb"
> doesn't seem prepared to do something like that.
> 
> rday
> 
> -- 
> 
> ========================================================================
> Robert P. J. Day                                 Ottawa, Ontario, CANADA
>                         http://crashcourse.ca
> 
> Twitter:                                       http://twitter.com/rpjday
> LinkedIn:                               http://ca.linkedin.com/in/rpjday
> ========================================================================
> _______________________________________________
> yocto mailing list
> yocto at yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa at gmail.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20131102/48acc018/attachment.pgp>


More information about the yocto mailing list