summaryrefslogtreecommitdiffstats
path: root/meta/classes/packagefeed-stability.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'meta/classes/packagefeed-stability.bbclass')
-rw-r--r--meta/classes/packagefeed-stability.bbclass14
1 files changed, 7 insertions, 7 deletions
diff --git a/meta/classes/packagefeed-stability.bbclass b/meta/classes/packagefeed-stability.bbclass
index aa01def74d..3a128073d0 100644
--- a/meta/classes/packagefeed-stability.bbclass
+++ b/meta/classes/packagefeed-stability.bbclass
@@ -31,7 +31,7 @@ python() {
31 # This assumes that the package_write task is called package_write_<pkgtype> 31 # This assumes that the package_write task is called package_write_<pkgtype>
32 # and that the directory in which packages should be written is 32 # and that the directory in which packages should be written is
33 # pointed to by the variable DEPLOY_DIR_<PKGTYPE> 33 # pointed to by the variable DEPLOY_DIR_<PKGTYPE>
34 for pkgclass in (d.getVar('PACKAGE_CLASSES', True) or '').split(): 34 for pkgclass in (d.getVar('PACKAGE_CLASSES') or '').split():
35 if pkgclass.startswith('package_'): 35 if pkgclass.startswith('package_'):
36 pkgtype = pkgclass.split('_', 1)[1] 36 pkgtype = pkgclass.split('_', 1)[1]
37 pkgwritefunc = 'do_package_write_%s' % pkgtype 37 pkgwritefunc = 'do_package_write_%s' % pkgtype
@@ -71,7 +71,7 @@ python() {
71# This isn't the real task function - it's a template that we use in the 71# This isn't the real task function - it's a template that we use in the
72# anonymous python code above 72# anonymous python code above
73fakeroot python do_package_compare () { 73fakeroot python do_package_compare () {
74 currenttask = d.getVar('BB_CURRENTTASK', True) 74 currenttask = d.getVar('BB_CURRENTTASK')
75 pkgtype = currenttask.rsplit('_', 1)[1] 75 pkgtype = currenttask.rsplit('_', 1)[1]
76 package_compare_impl(pkgtype, d) 76 package_compare_impl(pkgtype, d)
77} 77}
@@ -83,12 +83,12 @@ def package_compare_impl(pkgtype, d):
83 import subprocess 83 import subprocess
84 import oe.sstatesig 84 import oe.sstatesig
85 85
86 pn = d.getVar('PN', True) 86 pn = d.getVar('PN')
87 deploydir = d.getVar('DEPLOY_DIR_%s' % pkgtype.upper(), True) 87 deploydir = d.getVar('DEPLOY_DIR_%s' % pkgtype.upper(), True)
88 prepath = deploydir + '-prediff/' 88 prepath = deploydir + '-prediff/'
89 89
90 # Find out PKGR values are 90 # Find out PKGR values are
91 pkgdatadir = d.getVar('PKGDATA_DIR', True) 91 pkgdatadir = d.getVar('PKGDATA_DIR')
92 packages = [] 92 packages = []
93 try: 93 try:
94 with open(os.path.join(pkgdatadir, pn), 'r') as f: 94 with open(os.path.join(pkgdatadir, pn), 'r') as f:
@@ -138,7 +138,7 @@ def package_compare_impl(pkgtype, d):
138 files = [] 138 files = []
139 docopy = False 139 docopy = False
140 manifest, _ = oe.sstatesig.sstate_get_manifest_filename(pkgwritetask, d) 140 manifest, _ = oe.sstatesig.sstate_get_manifest_filename(pkgwritetask, d)
141 mlprefix = d.getVar('MLPREFIX', True) 141 mlprefix = d.getVar('MLPREFIX')
142 # Copy recipe's all packages if one of the packages are different to make 142 # Copy recipe's all packages if one of the packages are different to make
143 # they have the same PR. 143 # they have the same PR.
144 with open(manifest, 'r') as f: 144 with open(manifest, 'r') as f:
@@ -215,7 +215,7 @@ def package_compare_impl(pkgtype, d):
215 # multilib), they're identical in theory, but sstate.bbclass 215 # multilib), they're identical in theory, but sstate.bbclass
216 # copies it again, so keep align with that. 216 # copies it again, so keep align with that.
217 if os.path.exists(destpath) and pkgtype == 'rpm' \ 217 if os.path.exists(destpath) and pkgtype == 'rpm' \
218 and d.getVar('PACKAGE_ARCH', True) == 'all': 218 and d.getVar('PACKAGE_ARCH') == 'all':
219 os.unlink(destpath) 219 os.unlink(destpath)
220 if (os.stat(srcpath).st_dev == os.stat(destdir).st_dev): 220 if (os.stat(srcpath).st_dev == os.stat(destdir).st_dev):
221 # Use a hard link to save space 221 # Use a hard link to save space
@@ -229,7 +229,7 @@ def package_compare_impl(pkgtype, d):
229do_cleansstate[postfuncs] += "pfs_cleanpkgs" 229do_cleansstate[postfuncs] += "pfs_cleanpkgs"
230python pfs_cleanpkgs () { 230python pfs_cleanpkgs () {
231 import errno 231 import errno
232 for pkgclass in (d.getVar('PACKAGE_CLASSES', True) or '').split(): 232 for pkgclass in (d.getVar('PACKAGE_CLASSES') or '').split():
233 if pkgclass.startswith('package_'): 233 if pkgclass.startswith('package_'):
234 pkgtype = pkgclass.split('_', 1)[1] 234 pkgtype = pkgclass.split('_', 1)[1]
235 deploydir = d.getVar('DEPLOY_DIR_%s' % pkgtype.upper(), True) 235 deploydir = d.getVar('DEPLOY_DIR_%s' % pkgtype.upper(), True)