Patchwork [1/3] connman: respect the 3g feature and enable/disable ofono support

login
register
mail settings
Submitter Ross Burton
Date June 7, 2012, 2:19 p.m.
Message ID <5afc9f367cc3224e82bbe59fe9bda14f504b45c0.1339078729.git.ross.burton@intel.com>
Download mbox | patch
Permalink /patch/29379/
State New
Headers show

Comments

Ross Burton - June 7, 2012, 2:19 p.m.
[YOCTO #2357]

Signed-off-by: Ross Burton <ross.burton@intel.com>
---
 meta/recipes-connectivity/connman/connman.inc |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
Martin Jansa - June 7, 2012, 2:32 p.m.
On Thu, Jun 07, 2012 at 03:19:36PM +0100, Ross Burton wrote:
> [YOCTO #2357]
> 
> Signed-off-by: Ross Burton <ross.burton@intel.com>
> ---
>  meta/recipes-connectivity/connman/connman.inc |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/meta/recipes-connectivity/connman/connman.inc b/meta/recipes-connectivity/connman/connman.inc
> index f2da8d9..58e3f56 100644
> --- a/meta/recipes-connectivity/connman/connman.inc
> +++ b/meta/recipes-connectivity/connman/connman.inc
> @@ -17,7 +17,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \
>  DEPENDS  = "dbus glib-2.0 ppp iptables gnutls \
>              ${@base_contains('DISTRO_FEATURES', 'bluetooth','bluez4', '', d)} \
>              ${@base_contains('DISTRO_FEATURES', 'wifi','wpa-supplicant', '', d)} \
> -            ofono \
> +            ${@base_contains('DISTRO_FEATURES', '3g','ofono', '', d)} \
>              "
>  
>  TIST = "--enable-tist"
> @@ -34,7 +34,7 @@ EXTRA_OECONF += "\
>      ${@base_contains('DISTRO_FEATURES', 'wifi','--enable-wifi ${TIST}', '--disable-wifi', d)} \
>      ${@base_contains('DISTRO_FEATURES', 'bluetooth','--enable-bluetooth ${TIST}', '--disable-bluetooth', d)} \
>      --enable-dnsproxy \
> -    --enable-ofono \
> +    ${@base_contains('DISTRO_FEATURES', '3g', '', '--disable-ofono', d)} \
>      --enable-tools \
>      --enable-test \
>      --disable-polkit \

Why not use PACKAGECONFIG for all those?

Cheers,
Koen Kooi - June 7, 2012, 2:33 p.m.
Op 7 jun. 2012, om 16:19 heeft Ross Burton het volgende geschreven:

> [YOCTO #2357]
> 
> Signed-off-by: Ross Burton <ross.burton@intel.com>
> ---
> meta/recipes-connectivity/connman/connman.inc |    4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/meta/recipes-connectivity/connman/connman.inc b/meta/recipes-connectivity/connman/connman.inc
> index f2da8d9..58e3f56 100644
> --- a/meta/recipes-connectivity/connman/connman.inc
> +++ b/meta/recipes-connectivity/connman/connman.inc
> @@ -17,7 +17,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \
> DEPENDS  = "dbus glib-2.0 ppp iptables gnutls \
>             ${@base_contains('DISTRO_FEATURES', 'bluetooth','bluez4', '', d)} \
>             ${@base_contains('DISTRO_FEATURES', 'wifi','wpa-supplicant', '', d)} \
> -            ofono \
> +            ${@base_contains('DISTRO_FEATURES', '3g','ofono', '', d)} \
>             "
> 
> TIST = "--enable-tist"
> @@ -34,7 +34,7 @@ EXTRA_OECONF += "\
>     ${@base_contains('DISTRO_FEATURES', 'wifi','--enable-wifi ${TIST}', '--disable-wifi', d)} \
>     ${@base_contains('DISTRO_FEATURES', 'bluetooth','--enable-bluetooth ${TIST}', '--disable-bluetooth', d)} \
>     --enable-dnsproxy \
> -    --enable-ofono \
> +    ${@base_contains('DISTRO_FEATURES', '3g', '', '--disable-ofono', d)} \
>     --enable-tools \
>     --enable-test \
>     --disable-polkit \

This one is missing a PR bump
Ross Burton - June 7, 2012, 2:46 p.m.
On 7 June 2012 15:33, Koen Kooi <koen@dominion.thruhere.net> wrote:
> This one is missing a PR bump

Whoops, fixed and re-pushed.

Ross
Ross Burton - June 7, 2012, 2:46 p.m.
On 7 June 2012 15:32, Martin Jansa <martin.jansa@gmail.com> wrote:
> Why not use PACKAGECONFIG for all those?

Because this is the first time I've encountered it.  :)  Is there any
documentation on it, or a comprehensive example?

Ross
Martin Jansa - June 8, 2012, 12:08 a.m.
On Thu, Jun 07, 2012 at 03:46:54PM +0100, Burton, Ross wrote:
> On 7 June 2012 15:32, Martin Jansa <martin.jansa@gmail.com> wrote:
> > Why not use PACKAGECONFIG for all those?
> 
> Because this is the first time I've encountered it.  :)  Is there any
> documentation on it, or a comprehensive example?

Git log shows e.g.
http://git.openembedded.org/openembedded-core/commit/?id=7a58911f6951abd56db9ebb37f8d6284d91fa514

and git grep PACKAGECONFIG will show couple of examples

Cheers,
Ross Burton - June 11, 2012, 3:17 p.m.
On 8 June 2012 01:08, Martin Jansa <martin.jansa@gmail.com> wrote:
>> Because this is the first time I've encountered it.  :)  Is there any
>> documentation on it, or a comprehensive example?
>
> Git log shows e.g.
> http://git.openembedded.org/openembedded-core/commit/?id=7a58911f6951abd56db9ebb37f8d6284d91fa514
>
> and git grep PACKAGECONFIG will show couple of examples

So,  the basic theory is that you set PACKAGECONFIG to the list of
enabled options, i.e. connman would have wifi, bluetooth, 3G.  This
would be set using base_contains(DISTRO_FEATURES...).

Then, you have a PACKAGECONFIG[foo] for each option that defines the
configure flags and build/runtime depends.

Neat.

Ross

Patch

diff --git a/meta/recipes-connectivity/connman/connman.inc b/meta/recipes-connectivity/connman/connman.inc
index f2da8d9..58e3f56 100644
--- a/meta/recipes-connectivity/connman/connman.inc
+++ b/meta/recipes-connectivity/connman/connman.inc
@@ -17,7 +17,7 @@  LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \
 DEPENDS  = "dbus glib-2.0 ppp iptables gnutls \
             ${@base_contains('DISTRO_FEATURES', 'bluetooth','bluez4', '', d)} \
             ${@base_contains('DISTRO_FEATURES', 'wifi','wpa-supplicant', '', d)} \
-            ofono \
+            ${@base_contains('DISTRO_FEATURES', '3g','ofono', '', d)} \
             "
 
 TIST = "--enable-tist"
@@ -34,7 +34,7 @@  EXTRA_OECONF += "\
     ${@base_contains('DISTRO_FEATURES', 'wifi','--enable-wifi ${TIST}', '--disable-wifi', d)} \
     ${@base_contains('DISTRO_FEATURES', 'bluetooth','--enable-bluetooth ${TIST}', '--disable-bluetooth', d)} \
     --enable-dnsproxy \
-    --enable-ofono \
+    ${@base_contains('DISTRO_FEATURES', '3g', '', '--disable-ofono', d)} \
     --enable-tools \
     --enable-test \
     --disable-polkit \