[OE-core] [PATCH 03/22] update-alternatives.bbclass: Add missing runtime dependency

Martin Jansa martin.jansa at gmail.com
Tue Dec 4 17:04:32 UTC 2012


On Tue, Dec 04, 2012 at 11:14:35AM -0600, Mark Hatle wrote:
> When using update-alternatives, there should be a runtime dependency on
> update-alternatives.  Without this, it's possible to get into a situation
> where the package is not installable.
> 
> Signed-off-by: Mark Hatle <mark.hatle at windriver.com>
> ---
>  meta/classes/update-alternatives.bbclass |    6 ++++++
>  1 files changed, 6 insertions(+), 0 deletions(-)
> 
> diff --git a/meta/classes/update-alternatives.bbclass b/meta/classes/update-alternatives.bbclass
> index 4e1ff27..e432506 100644
> --- a/meta/classes/update-alternatives.bbclass
> +++ b/meta/classes/update-alternatives.bbclass
> @@ -304,6 +304,12 @@ python populate_packages_prepend () {
>              alt_remove_links += '\tupdate-alternatives --remove  %s %s\n' % (alt_name, alt_target)
>  
>          if alt_setup_links:
> +            # RDEPENDS setup
> +            bb.note('adding runtime requirement for update-alternatives for %s' % pkg)
> +            rdepends = d.getVar('RDEPENDS_%s' % pkg, True) or ""
> +            rdepends += ' ' + d.getVar('MLPREFIX') + 'update-alternatives'
> +            d.setVar("RDEPENDS_%s" % pkg, rdepends)
> +

I guess you should use VIRTUAL-RUNTIME_update-alternatives here

Cheers,

>              bb.note('adding update-alternatives calls to postinst/postrm for %s' % pkg)
>              bb.note('%s' % alt_setup_links)
>              postinst = (d.getVar('pkg_postinst_%s' % pkg, True) or d.getVar('pkg_postinst', True)) or '#!/bin/sh\n'
> -- 
> 1.7.3.4
> 
> 
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core at lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa at gmail.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20121204/fff70f16/attachment-0002.sig>


More information about the Openembedded-core mailing list