diff options
Diffstat (limited to 'meta/classes/packageinfo.bbclass')
-rw-r--r-- | meta/classes/packageinfo.bbclass | 34 |
1 files changed, 8 insertions, 26 deletions
diff --git a/meta/classes/packageinfo.bbclass b/meta/classes/packageinfo.bbclass index 26cce604ae..bd7b249bb4 100644 --- a/meta/classes/packageinfo.bbclass +++ b/meta/classes/packageinfo.bbclass | |||
@@ -14,32 +14,14 @@ python packageinfo_handler () { | |||
14 | for root, dirs, files in os.walk(pkgdata_dir): | 14 | for root, dirs, files in os.walk(pkgdata_dir): |
15 | for pkgname in files: | 15 | for pkgname in files: |
16 | if pkgname.endswith('.packaged'): | 16 | if pkgname.endswith('.packaged'): |
17 | continue | 17 | pkgname = pkgname[:-9] |
18 | sdata = oe.packagedata.read_pkgdatafile(root + pkgname) | 18 | pkgdatafile = root + pkgname |
19 | sdata['PKG'] = pkgname | 19 | try: |
20 | pkgrename = sdata['PKG_%s' % pkgname] | 20 | sdata = oe.packagedata.read_pkgdatafile(pkgdatafile) |
21 | pkgv = sdata['PKGV'].replace('-', '+') | 21 | sdata['PKG'] = pkgname |
22 | pkgr = sdata['PKGR'] | 22 | pkginfolist.append(sdata) |
23 | # We found there are some renaming issue with certain architecture. | 23 | except Exception as e: |
24 | # For example, armv7a-vfp-neon, it will use armv7a in the rpm file. This is the workaround for it. | 24 | bb.warn("Failed to read pkgdata file %s: %s: %s" % (pkgdatafile, e.__class__, str(e))) |
25 | arch_tmp = arch.split('-')[0] | ||
26 | if os.path.exists(deploy_dir + '/' + arch + '/' + \ | ||
27 | pkgname + '-' + pkgv + '-' + pkgr + '.' + arch + '.' + packaging) or \ | ||
28 | os.path.exists(deploy_dir + '/' + arch + '/' + \ | ||
29 | pkgname + '-' + pkgv + '-' + pkgr + '.' + arch_tmp + '.' + packaging) or \ | ||
30 | os.path.exists(deploy_dir + '/' + arch + '/' + \ | ||
31 | pkgrename + '-' + pkgv + '-' + pkgr + '.' + arch + '.' + packaging) or \ | ||
32 | os.path.exists(deploy_dir + '/' + arch + '/' + \ | ||
33 | pkgrename + '-' + pkgv + '-' + pkgr + '.' + arch_tmp + '.' + packaging) or \ | ||
34 | os.path.exists(deploy_dir + '/' + arch + '/' + \ | ||
35 | pkgname + '_' + pkgv + '-' + pkgr + '_' + arch + '.' + packaging) or \ | ||
36 | os.path.exists(deploy_dir + '/' + arch + '/' + \ | ||
37 | pkgname + '_' + pkgv + '-' + pkgr + '_' + arch_tmp + '.' + packaging) or \ | ||
38 | os.path.exists(deploy_dir + '/' + arch + '/' + \ | ||
39 | pkgrename + '_' + pkgv + '-' + pkgr + '_' + arch + '.' + packaging) or \ | ||
40 | os.path.exists(deploy_dir + '/' + arch + '/' + \ | ||
41 | pkgrename + '_' + pkgv + '-' + pkgr + '_' + arch_tmp + '.' + packaging): | ||
42 | pkginfolist.append(sdata) | ||
43 | bb.event.fire(bb.event.PackageInfo(pkginfolist), e.data) | 25 | bb.event.fire(bb.event.PackageInfo(pkginfolist), e.data) |
44 | } | 26 | } |
45 | 27 | ||