summaryrefslogtreecommitdiff
path: root/meta/classes
diff options
context:
space:
mode:
authorChris Larson <chris_larson@mentor.com>2011-06-02 13:31:59 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-08-12 17:11:22 +0100
commit521cab0239352e3b4316183c20e63cc06f5ae92b (patch)
tree19464e14b00d461dae2bd7d13a2ee24ac2ec133f /meta/classes
parent47664bb8309f5d791d7aa040a38c7324cb4f14e6 (diff)
downloadopenembedded-core-521cab0239352e3b4316183c20e63cc06f5ae92b.tar.gz
openembedded-core-521cab0239352e3b4316183c20e63cc06f5ae92b.tar.bz2
openembedded-core-521cab0239352e3b4316183c20e63cc06f5ae92b.tar.xz
openembedded-core-521cab0239352e3b4316183c20e63cc06f5ae92b.zip
package: allow setting a section for locale packages
Signed-off-by: Chris Larson <chris_larson@mentor.com>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/package.bbclass5
1 files changed, 5 insertions, 0 deletions
diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
index 0a954ef97..100f465d9 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -44,6 +44,8 @@ inherit prserv
PKGD = "${WORKDIR}/package"
PKGDEST = "${WORKDIR}/packages-split"
+LOCALE_SECTION ?= ''
+
# rpm is used for the per-file dependency identification
PACKAGE_DEPENDS += "rpm-native"
@@ -401,6 +403,7 @@ python package_do_split_locales() {
summary = bb.data.getVar('SUMMARY', d, True) or pn
description = bb.data.getVar('DESCRIPTION', d, True) or ""
+ locale_section = bb.data.getVar('LOCALE_SECTION', d, True)
for l in locales:
ln = legitimize_package_name(l)
pkg = pn + '-locale-' + ln
@@ -410,6 +413,8 @@ python package_do_split_locales() {
bb.data.setVar('RPROVIDES_' + pkg, '%s-locale %s-translation' % (pn, ln), d)
bb.data.setVar('SUMMARY_' + pkg, '%s - %s translations' % (summary, l), d)
bb.data.setVar('DESCRIPTION_' + pkg, '%s This package contains language translation files for the %s locale.' % (description, l), d)
+ if locale_section:
+ bb.data.setVar('SECTION_' + pkg, locale_section, d)
bb.data.setVar('PACKAGES', ' '.join(packages), d)