update-alternatives.bbclass: Refactor the implementation

Refactor in order to:
  * Deprecate the old interfaces, but keep them for compatibility
  * Provide a new, interface -- capable of working with split packages
  * Each update-alternative will now set proper "per-file" provides

Note: this adds a warning message when the older deprecated behavior is
used.  The older behavior has been fully tested using oe-core.

(From OE-Core rev: 309117d26de6a87b16406a44a0cefcbaaf7b5d7a)

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Mark Hatle
2012-05-15 11:06:22 -05:00
committed by Richard Purdie
parent f28209d9d3
commit 6ac7e9b598
3 changed files with 293 additions and 71 deletions

View File

@@ -706,10 +706,6 @@ python write_specfile () {
splitrconflicts = strip_multilib(localdata.getVar('RCONFLICTS', True), d) or ""
splitrobsoletes = []
# For now we need to manually supplement RPROVIDES with any update-alternatives links
if pkg == d.getVar("PN", True):
splitrprovides = splitrprovides + " " + (d.getVar('ALTERNATIVE_LINK', True) or '') + " " + (d.getVar('ALTERNATIVE_LINKS', True) or '')
# Gather special src/first package data
if srcname == splitname:
srcrdepends = splitrdepends