mirror of
https://git.yoctoproject.org/poky
synced 2026-04-27 12:32:13 +02:00
update-alternatives.bbclass: Add missing runtime dependency
When using update-alternatives, there should be a runtime dependency on
${VIRTUAL-RUNTIME_update-alternatives}. Without this, it's possible to
get into a situation where the package is not installable.
(If VIRTUAL-RUNTIME_update-alternatives is not defined, no requirement
is added.)
(From OE-Core rev: 8a4c5765fb56d17c3d82ff6db47863e934c9fcbe)
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
d3154aa9f8
commit
1d61099065
@@ -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
|
||||
provider = d.getVar('VIRTUAL-RUNTIME_update-alternatives', True)
|
||||
if provider:
|
||||
#bb.note('adding runtime requirement for update-alternatives for %s' % pkg)
|
||||
d.appendVar('RDEPENDS_%s' % pkg, ' ' + d.getVar('MLPREFIX') + provider)
|
||||
|
||||
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'
|
||||
|
||||
Reference in New Issue
Block a user