Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Patches and discussions about the oe-core layer
	<openembedded-core@lists.openembedded.org>
Cc: Koen Kooi <koen@dominion.thruhere.net>
Subject: Re: [PATCH] package bbclass: allow per package PRIVATE_LIBS
Date: Thu, 26 Jan 2012 20:51:11 +0000	[thread overview]
Message-ID: <1327611071.19643.405.camel@ted> (raw)
In-Reply-To: <1327597394-31990-1-git-send-email-koen@dominion.thruhere.net>

On Thu, 2012-01-26 at 18:03 +0100, Koen Kooi wrote:
> If a recipe packages multiple versions of shlib (e.g. powervr drivers) we only want the shlib code to pickup $PN, not $PN-foo subpackages.
> This keeps backward compatibility with the global PRIVATE_LIBS usage if no per package PRIVATE_LIBS are set for a given package. In other words: this doesn't break the firefox recipe.
> 
> Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
> ---
>  meta/classes/package.bbclass |    5 ++++-
>  1 files changed, 4 insertions(+), 1 deletions(-)
> 
> diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
> index 45447e3..22a76cf 100644
> --- a/meta/classes/package.bbclass
> +++ b/meta/classes/package.bbclass
> @@ -1246,7 +1246,8 @@ python package_do_shlibs() {
>  				if not this_soname in sonames:
>  					# if library is private (only used by package) then do not build shlib for it
>  					if not private_libs or -1 == private_libs.find(this_soname):
> -						sonames.append(this_soname)
> +						if not private_libs_pkg or -1 == private_libs_pkg.find(this_soname):
> +							sonames.append(this_soname)
>  				if libdir_re.match(root):
>  					needs_ldconfig = True
>  				if snap_symlinks and (file != this_soname):
> @@ -1328,6 +1329,8 @@ python package_do_shlibs() {
>  	shlib_provider = {}
>  	private_libs = d.getVar('PRIVATE_LIBS', True)
>  	for pkg in packages.split():
> +		if not private_libs:
> +			private_libs_pkg = d.getVar('PRIVATE_LIBS_' + pkg, True)

You might as well just put:

                         private_libs = d.getVar('PRIVATE_LIBS_' + pkg, True)

and drop the first bit of the patch.

Cheers,

Richard




  reply	other threads:[~2012-01-26 20:59 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-26 17:03 [PATCH] package bbclass: allow per package PRIVATE_LIBS Koen Kooi
2012-01-26 20:51 ` Richard Purdie [this message]
2012-01-26 23:17   ` Koen Kooi
2012-01-26 23:52     ` Richard Purdie
2012-01-27  9:45       ` Koen Kooi
2012-01-27  9:50         ` Richard Purdie
2012-01-27 11:55           ` Koen Kooi
2012-01-27 13:07             ` Richard Purdie
2012-01-27 14:32               ` Koen Kooi

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=1327611071.19643.405.camel@ted \
    --to=richard.purdie@linuxfoundation.org \
    --cc=koen@dominion.thruhere.net \
    --cc=openembedded-core@lists.openembedded.org \
    /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