summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorConstantin Musca <constantinx.musca@intel.com>2013-01-28 11:01:20 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-01-28 14:49:04 +0000
commit3ba2ce25bdc78f660552d3d16272a551d434c527 (patch)
tree1369d99a1991cf76f069ae1380a15b5f0e856031 /meta
parent30ec3110d91314ae117f3c657e474e7b8395c4ac (diff)
downloadpoky-3ba2ce25bdc78f660552d3d16272a551d434c527.tar.gz
migrate_localcount.bbclass: use PRAUTOINX instead of PN & PV
- we need to use PRAUTOINX (it covers all cases) - it addresses bumped PE issues [YOCTO #3071] (From OE-Core rev: ec81b985bb29a8562366f5343171e68a1f9cc4e9) Signed-off-by: Constantin Musca <constantinx.musca@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/migrate_localcount.bbclass9
1 files changed, 4 insertions, 5 deletions
diff --git a/meta/classes/migrate_localcount.bbclass b/meta/classes/migrate_localcount.bbclass
index 59f14e8a34..3916ad4461 100644
--- a/meta/classes/migrate_localcount.bbclass
+++ b/meta/classes/migrate_localcount.bbclass
@@ -18,14 +18,13 @@ python migrate_localcount_handler () {
18 if not revs or not counts: 18 if not revs or not counts:
19 return 19 return
20 20
21 srcrev = bb.fetch2.get_srcrev(e.data)
22 bpv = pv[:pv.find(srcrev)]
23
24 if len(revs) != len(counts): 21 if len(revs) != len(counts):
25 bb.warn("The number of revs and localcounts don't match in %s" % pn) 22 bb.warn("The number of revs and localcounts don't match in %s" % pn)
26 return 23 return
27 24
28 version = 'AUTOINC-%s-%s' % (pn, bpv) 25 version = e.data.getVar('PRAUTOINX', True)
26 srcrev = bb.fetch2.get_srcrev(e.data)
27 base_ver = 'AUTOINC-%s' % version[:version.find(srcrev)]
29 pkgarch = e.data.getVar('PACKAGE_ARCH', True) 28 pkgarch = e.data.getVar('PACKAGE_ARCH', True)
30 value = max(int(count) for count in counts) 29 value = max(int(count) for count in counts)
31 30
@@ -40,7 +39,7 @@ python migrate_localcount_handler () {
40 flock = bb.utils.lockfile("%s.lock" % df) 39 flock = bb.utils.lockfile("%s.lock" % df)
41 with open(df, 'a') as fd: 40 with open(df, 'a') as fd:
42 fd.write('PRAUTO$%s$%s$%s = "%s"\n' % 41 fd.write('PRAUTO$%s$%s$%s = "%s"\n' %
43 (version, pkgarch, srcrev, str(value))) 42 (base_ver, pkgarch, srcrev, str(value)))
44 bb.utils.unlockfile(flock) 43 bb.utils.unlockfile(flock)
45} 44}
46 45