Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Yann E. MORIN <yann.morin.1998@free.fr>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 1/1] freerdp: fix wayland client dependency chain failure
Date: Mon, 20 Nov 2017 22:14:45 +0100	[thread overview]
Message-ID: <20171120211445.GA2867@scaer> (raw)
In-Reply-To: <20171120084757.04cf0411@windsurf>

Thomas, Adam, All,

On 2017-11-20 08:47 +0100, Thomas Petazzoni spake thusly:
> On Sun, 19 Nov 2017 16:48:52 -0500, Adam Duskett wrote:
> > If the wayland client is selected, freerdp depends on libxkbcommon without
> > depending on it in the mk file.
> > 
> > Fixes:
> > http://autobuild.buildroot.net/results/dc3/dc3e11f7076a8355f3d2f9cb49c6325dcf7084bd
> > Signed-off-by: Adam Duskett <Adamduskett@outlook.com>
> > ---
> >  package/freerdp/freerdp.mk | 4 ++++
> >  1 file changed, 4 insertions(+)
> > 
> > diff --git a/package/freerdp/freerdp.mk b/package/freerdp/freerdp.mk
> > index 69a89a190c..29c35164c3 100644
> > --- a/package/freerdp/freerdp.mk
> > +++ b/package/freerdp/freerdp.mk
> > @@ -207,6 +207,10 @@ else
> >  FREERDP_CONF_OPTS += -DWITH_WAYLAND=OFF
> >  endif
> >  
> > +ifeq ($(BR2_PACKAGE_FREERDP_CLIENT_WL),y)
> > +FREERDP_DEPENDENCIES += libxkbcommon
> > +endif
> 
> https://git.buildroot.org/buildroot/commit/?id=c2824fba2f2f4df6c1e0273fa546a203d1e6d5ac
> already makes libxkbcommon a dependency of freerdp when wayland is
> enabled. Isn't this sufficient ?

I think the current code might indeed not be correct, but that the patch
is not correct either...

The issue with FreeRDP, as much as I can remember, is the way it builds
the clients: either clients are enabled ot they are not. But once you
enable clients, it will look for dependencies of each client, and build
those whose dependencies are met.

So, if you have X11 and wayland libs around, then FreeRDP will biuld
both clients, even if you are only interested in one and not both.

The situation where you want only (say) the wayland client and not the
X11 one is if you are running a wayland system, with XWayland to run
legacy X11 apps ontop of this, and only want to use FreeRDP as a wayland
client.

So we have code in freerdp.mk to get rid of the unneeded client(s).

But now, the select and dependency on libxbcommon are under two slightly
different conditions:

  - the select is only when the wayland client is enabled,
  - the dependency is when the wayland package is enabled.

Now, if the wayland client is disabled, but the walyand package is
enabled, then nothing from FreeRDP selects libxbkcommon, but it ends up
in the dependency chain of FreeRDP nonetheless.

I think a better patch would be something like:

diff --git a/package/freerdp/freerdp.mk b/package/freerdp/freerdp.mk
index 69a89a190c..0ceef576a8 100644
--- a/package/freerdp/freerdp.mk
+++ b/package/freerdp/freerdp.mk
@@ -198,7 +198,7 @@ else
 FREERDP_CONF_OPTS += -DWITH_XV=OFF
 endif
 
-ifeq ($(BR2_PACKAGE_WAYLAND),y)
+ifeq ($(BR2_PACKAGE_FREERDP_CLIENT_WL),y)
 FREERDP_DEPENDENCIES += wayland libxkbcommon
 FREERDP_CONF_OPTS += \
 	-DWITH_WAYLAND=ON \

TBH, I'm a bit under the weather those days, so Adam, I'd be gratefull
if you were to check the above, please.

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'

  reply	other threads:[~2017-11-20 21:14 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-19 21:48 [Buildroot] [PATCH 1/1] freerdp: fix wayland client dependency chain failure Adam Duskett
2017-11-20  7:47 ` Thomas Petazzoni
2017-11-20 21:14   ` Yann E. MORIN [this message]
2017-11-25 17:16     ` Adam Duskett

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171120211445.GA2867@scaer \
    --to=yann.morin.1998@free.fr \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox