mirror of
https://git.yoctoproject.org/poky
synced 2026-01-29 21:08:42 +01:00
lib/oe/package: replace in place PN-locale-* packages in PACKAGES
split_locales() removes PN-locale from PACKAGES and adds PN-locale-* to the end. As the PN-locale package typically appears before PN base package, it may result in paths not installed in PN-locale-* packages if already catched by PN. Now insert PN-locale-* exactly where PN-locale was existing in list to avoid such an issue. (From OE-Core rev: 108bc167ed0d43505af3140947a0ab79c89f0a7b) Signed-off-by: Jonathan GUILLOT <jonathan@joggee.fr> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
8f855f1e84
commit
c381ca7243
@@ -647,8 +647,11 @@ def split_locales(d):
|
||||
dvar = d.getVar('PKGD')
|
||||
pn = d.getVar('LOCALEBASEPN')
|
||||
|
||||
if pn + '-locale' in packages:
|
||||
packages.remove(pn + '-locale')
|
||||
try:
|
||||
locale_index = packages.index(pn + '-locale')
|
||||
packages.pop(locale_index)
|
||||
except ValueError:
|
||||
locale_index = len(packages)
|
||||
|
||||
localedir = os.path.join(dvar + datadir, 'locale')
|
||||
|
||||
@@ -665,7 +668,8 @@ def split_locales(d):
|
||||
for l in sorted(locales):
|
||||
ln = legitimize_package_name(l)
|
||||
pkg = pn + '-locale-' + ln
|
||||
packages.append(pkg)
|
||||
packages.insert(locale_index, pkg)
|
||||
locale_index += 1
|
||||
d.setVar('FILES:' + pkg, os.path.join(datadir, 'locale', l))
|
||||
d.setVar('RRECOMMENDS:' + pkg, '%svirtual-locale-%s' % (mlprefix, ln))
|
||||
d.setVar('RPROVIDES:' + pkg, '%s-locale %s%s-translation' % (pn, mlprefix, ln))
|
||||
|
||||
Reference in New Issue
Block a user