From 62161c85f3b57dbe89965a7b5e93333d8d5fdf1b Mon Sep 17 00:00:00 2001 From: Michael Lauer Date: Sat, 1 May 2004 11:18:04 +0000 Subject: eliminate local do_split in favour of version in package.oeclass - patch courtesy pb_. BKrev: 4093876cRv4MY7SX-FsyKyGvcNL3tA --- glibc/glibc_cvs.oe | 33 +-------------------------------- 1 file changed, 1 insertion(+), 32 deletions(-) diff --git a/glibc/glibc_cvs.oe b/glibc/glibc_cvs.oe index a64d35bf48..efb1ec9f70 100644 --- a/glibc/glibc_cvs.oe +++ b/glibc/glibc_cvs.oe @@ -190,37 +190,6 @@ do_install() { python package_do_split_gconvs () { import os - def do_split(root, pattern, format, description, postinst): - dvar = oe.data.getVar('D', d, 1) - if not dvar: - oe.error("D not defined") - return - - packages = oe.data.getVar('PACKAGES', d, 1).split() - if not packages: - # might be glibc-initial - return - - if postinst: - postinst = '#!/bin/sh\n' + postinst - objs = os.listdir(dvar + root) - mainpkg = oe.data.getVar('PKG_' + packages[0], d) or packages[0] - for o in objs: - import re - m = re.match(pattern, o) - if not m: - continue - on = m.group(1).lower().replace('_', '+').replace('@', '+') - pkg = format % on - packages.append(pkg) - oe.data.setVar('FILES_' + pkg, os.path.join(root, o), d) - oe.data.setVar('RDEPENDS_' + pkg, mainpkg, d) - oe.data.setVar('DESCRIPTION_' + pkg, description % on, d) - if postinst: - oe.data.setVar('pkg_postinst_' + pkg, postinst, d) - - oe.data.setVar('PACKAGES', ' '.join(packages), d) - if (oe.data.getVar('PACKAGE_NO_GCONV', d, 1) == '1'): oe.note("package requested not splitting gconvs") return @@ -232,7 +201,7 @@ python package_do_split_gconvs () { gconv_libdir = os.path.join(libdir, "gconv") - do_split(gconv_libdir, '^(.*)\.so$', 'glibc-gconv-%s', 'gconv module for character set %s', None) + do_split_packages(d, gconv_libdir, file_regex='^(.*)\.so$', output_pattern='glibc-gconv-%s', description='gconv module for character set %s') oe.data.setVar('PACKAGES', oe.data.getVar('PACKAGES', d) + ' glibc-gconv', d) } -- cgit v1.2.3