All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Ross Burton <ross.burton@intel.com>,
	 openembedded-core@lists.openembedded.org
Subject: Re: [PATCH 3/3] gtk-icon-cache: clean up DEPENDS
Date: Mon, 01 Apr 2019 11:44:48 +0100	[thread overview]
Message-ID: <b8022f1a28c2bf5c32ddcbb498bf9a3ede0dc181.camel@linuxfoundation.org> (raw)
In-Reply-To: <20190329142905.20123-3-ross.burton@intel.com>

On Fri, 2019-03-29 at 14:29 +0000, Ross Burton wrote:
> Instead of using DEPENDS += use _append to ensure that these additions can't get
> overwritten.
> 
> Also use gtk+3-native instead gtk-icon-utils-native as that recipe no longer
> exists and is provided by gtk+3-native for compatibility.
> 
> Signed-off-by: Ross Burton <ross.burton@intel.com>
> ---
>  meta/classes/gtk-icon-cache.bbclass | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/meta/classes/gtk-icon-cache.bbclass b/meta/classes/gtk-icon-cache.bbclass
> index d87167aec09..3572f62ebb6 100644
> --- a/meta/classes/gtk-icon-cache.bbclass
> +++ b/meta/classes/gtk-icon-cache.bbclass
> @@ -1,8 +1,8 @@
>  FILES_${PN} += "${datadir}/icons/hicolor"
>  
> -DEPENDS += "${@['hicolor-icon-theme', '']['${BPN}' == 'hicolor-icon-theme']} gtk-icon-utils-native"
> +DEPENDS_append = " ${@['hicolor-icon-theme', '']['${BPN}' == 'hicolor-icon-theme']} gtk+3-native"

I don't mind the changes themselves but I do have a bit of an issue
with changing to use DEPENDS_append.

In general recipes should be doing DEPENDS += "xxx", unless its at the
start of the recipe before any inherits (and even then += is fine).

_append is much harder to override and whilst it can be needed (e.g.
the hoops base.bbclass has to jump through), I'd much prefer to
encourage people to use +=.

I appreciate its a style thing and there is no "right" answer but its
one do have a fairly strong preference over, mainly for the
overridability. Our _append/_remove/_prepend operators are operators of
last resort to me.

Cheers,

Richard





      reply	other threads:[~2019-04-01 10:44 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-29 14:29 [PATCH 1/3] Revert "gtk+3: add librsvg to DEPENDS" Ross Burton
2019-03-29 14:29 ` [PATCH 2/3] adwaita-icon-theme: depend on librsvg Ross Burton
2019-03-29 14:29 ` [PATCH 3/3] gtk-icon-cache: clean up DEPENDS Ross Burton
2019-04-01 10:44   ` Richard Purdie [this message]

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=b8022f1a28c2bf5c32ddcbb498bf9a3ede0dc181.camel@linuxfoundation.org \
    --to=richard.purdie@linuxfoundation.org \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=ross.burton@intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.