Patchwork [WIP,08/20] telepathy-mission-control: Add PACKAGECONFIG for upower and connectivity

login
register
mail settings
Submitter Martin Jansa
Date Aug. 29, 2013, 4:02 p.m.
Message ID <ec8f1bdec56b09ad884f0c19fb5e4eea256e846e.1377792006.git.Martin.Jansa@gmail.com>
Download mbox | patch
Permalink /patch/57021/
State Accepted
Commit 8268ce9997e77a4ef6aa990ca7566cf3ed14c746
Headers show

Comments

Martin Jansa - Aug. 29, 2013, 4:02 p.m.
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
---
 .../telepathy/telepathy-mission-control_5.15.0.bb                 | 8 ++++++++
 1 file changed, 8 insertions(+)
Ross Burton - Sept. 2, 2013, 5:10 p.m.
On 29 August 2013 17:02, Martin Jansa <martin.jansa@gmail.com> wrote:
> +PACKAGECONFIG[connman] = "--with-connectivity=connman,,connman"
> +PACKAGECONFIG[nm] = "--with-connectivity=nm,,networkmanager"

Were those meant to be runtime dependencies?  At least for connman a
build dependency doesn't make any sense (no headers).

Ross
Martin Jansa - Sept. 3, 2013, 6:08 p.m.
On Mon, Sep 02, 2013 at 06:10:33PM +0100, Burton, Ross wrote:
> On 29 August 2013 17:02, Martin Jansa <martin.jansa@gmail.com> wrote:
> > +PACKAGECONFIG[connman] = "--with-connectivity=connman,,connman"
> > +PACKAGECONFIG[nm] = "--with-connectivity=nm,,networkmanager"
> 
> Were those meant to be runtime dependencies?  At least for connman a
> build dependency doesn't make any sense (no headers).

It is using pkg-config in build time to enable support for it:
http://cgit.collabora.com/git/user/cassidy/telepathy-mission-control/tree/configure.ac?h=offline-38366#n330

and it has to conditionally link with them (otherwise test-dependencies
script wouldn't detect it).
Ross Burton - Sept. 3, 2013, 6:51 p.m.
On 3 September 2013 19:08, Martin Jansa <martin.jansa@gmail.com> wrote:
> It is using pkg-config in build time to enable support for it:
> http://cgit.collabora.com/git/user/cassidy/telepathy-mission-control/tree/configure.ac?h=offline-38366#n330
>
> and it has to conditionally link with them (otherwise test-dependencies
> script wouldn't detect it).

Ah, so mission-control is Doing It Wrong - that .pc file is for
connman plugins.  I'll harass upstream but I do wonder what the script
is detecting as there isn't anything like a libconnman.so to link
against.

Ross
Ross Burton - Sept. 3, 2013, 6:57 p.m.
On 3 September 2013 19:51, Burton, Ross <ross.burton@intel.com> wrote:
> Ah, so mission-control is Doing It Wrong - that .pc file is for
> connman plugins.  I'll harass upstream but I do wonder what the script
> is detecting as there isn't anything like a libconnman.so to link
> against.

So upstream has already fixed this by deleting all of the code and
using GLib instead.  A worthy approach, and when they release we can
ditch the PACKAGECONFIGs.

Ross

Patch

diff --git a/meta/recipes-connectivity/telepathy/telepathy-mission-control_5.15.0.bb b/meta/recipes-connectivity/telepathy/telepathy-mission-control_5.15.0.bb
index b2736ca..ba80cc1 100644
--- a/meta/recipes-connectivity/telepathy/telepathy-mission-control_5.15.0.bb
+++ b/meta/recipes-connectivity/telepathy/telepathy-mission-control_5.15.0.bb
@@ -12,6 +12,14 @@  SRC_URI[sha256sum] = "88800d1b5f385e94b34721319ff4fe65c493632954d7229b36e57af5b4
 
 inherit autotools pkgconfig pythonnative
 
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[upower] = "--enable-upower,--disable-upower,upower"
+
+# to select connman or nm you need to use "connectivity" and "connman" or "nm", default is to disable both
+PACKAGECONFIG[connectvity] = ",--with-connectivity=no"
+PACKAGECONFIG[connman] = "--with-connectivity=connman,,connman"
+PACKAGECONFIG[nm] = "--with-connectivity=nm,,networkmanager"
+
 PACKAGES =+ " \
 	libmissioncontrol \
 	libmissioncontrol-config \