summaryrefslogtreecommitdiffstats
path: root/meta/classes/package_ipk.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'meta/classes/package_ipk.bbclass')
-rw-r--r--meta/classes/package_ipk.bbclass27
1 files changed, 26 insertions, 1 deletions
diff --git a/meta/classes/package_ipk.bbclass b/meta/classes/package_ipk.bbclass
index 2949d1d2e0..9586e06b2e 100644
--- a/meta/classes/package_ipk.bbclass
+++ b/meta/classes/package_ipk.bbclass
@@ -63,7 +63,32 @@ python do_package_ipk () {
63 bb.data.update_data(localdata) 63 bb.data.update_data(localdata)
64 basedir = os.path.join(os.path.dirname(root)) 64 basedir = os.path.join(os.path.dirname(root))
65 arch = localdata.getVar('PACKAGE_ARCH', True) 65 arch = localdata.getVar('PACKAGE_ARCH', True)
66 pkgoutdir = "%s/%s" % (outdir, arch) 66
67 if localdata.getVar('IPK_HIERARCHICAL_FEED') == "1":
68 # Spread packages across subdirectories so each isn't too crowded
69 if pkgname.startswith('lib'):
70 pkg_prefix = 'lib' + pkgname[3]
71 else:
72 pkg_prefix = pkgname[0]
73
74 # Keep -dbg, -dev, -doc, -staticdev, -locale and -locale-* packages
75 # together. These package suffixes are taken from the definitions of
76 # PACKAGES and PACKAGES_DYNAMIC in meta/conf/bitbake.conf
77 if pkgname[-4:] in ('-dbg', '-dev', '-doc'):
78 pkg_subdir = pkgname[:-4]
79 elif pkgname.endswith('-staticdev'):
80 pkg_subdir = pkgname[:-10]
81 elif pkgname.endswith('-locale'):
82 pkg_subdir = pkgname[:-7]
83 elif '-locale-' in pkgname:
84 pkg_subdir = pkgname[:pkgname.find('-locale-')]
85 else:
86 pkg_subdir = pkgname
87
88 pkgoutdir = "%s/%s/%s/%s" % (outdir, arch, pkg_prefix, pkg_subdir)
89 else:
90 pkgoutdir = "%s/%s" % (outdir, arch)
91
67 bb.utils.mkdirhier(pkgoutdir) 92 bb.utils.mkdirhier(pkgoutdir)
68 os.chdir(root) 93 os.chdir(root)
69 cleanupcontrol(root) 94 cleanupcontrol(root)