mirror of
https://git.yoctoproject.org/poky
synced 2026-06-02 01:19:52 +00:00
packaged-staging.bbclass: Set BB_STAMP_WHITELIST with packaged-staging tasks, update package location code to deal with packaged which don't exist, preserve stamp timestamps when copying them
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@4410 311d38ba-8fff-0310-9ca6-ca027cbcb966
This commit is contained in:
@@ -41,6 +41,8 @@ PSTAGE_NATIVEDEPENDS = "\
|
|||||||
stagemanager-native \
|
stagemanager-native \
|
||||||
"
|
"
|
||||||
|
|
||||||
|
BB_STAMP_WHITELIST = "${PSTAGE_NATIVEDEPENDS}"
|
||||||
|
|
||||||
python () {
|
python () {
|
||||||
import bb
|
import bb
|
||||||
pstage_allowed = True
|
pstage_allowed = True
|
||||||
@@ -307,11 +309,10 @@ python do_package_stage () {
|
|||||||
if bb.data.inherits_class('package_ipk', d):
|
if bb.data.inherits_class('package_ipk', d):
|
||||||
srcname = bb.data.expand(pkgname + "_${PV}-" + pr + "_" + arch + ".ipk", d)
|
srcname = bb.data.expand(pkgname + "_${PV}-" + pr + "_" + arch + ".ipk", d)
|
||||||
srcfile = bb.data.expand("${DEPLOY_DIR_IPK}/" + arch + "/" + srcname, d)
|
srcfile = bb.data.expand("${DEPLOY_DIR_IPK}/" + arch + "/" + srcname, d)
|
||||||
if not os.path.exists(srcfile):
|
if os.path.exists(srcfile):
|
||||||
bb.fatal("Package %s does not exist yet it should" % srcfile)
|
destpath = ipkpath + "/" + arch + "/"
|
||||||
destpath = ipkpath + "/" + arch + "/"
|
bb.mkdirhier(destpath)
|
||||||
bb.mkdirhier(destpath)
|
bb.copyfile(srcfile, destpath + srcname)
|
||||||
bb.copyfile(srcfile, destpath + srcname)
|
|
||||||
|
|
||||||
if bb.data.inherits_class('package_deb', d):
|
if bb.data.inherits_class('package_deb', d):
|
||||||
if arch == 'all':
|
if arch == 'all':
|
||||||
@@ -319,11 +320,10 @@ python do_package_stage () {
|
|||||||
else:
|
else:
|
||||||
srcname = bb.data.expand(pkgname + "_${PV}-" + pr + "_${DPKG_ARCH}.deb", d)
|
srcname = bb.data.expand(pkgname + "_${PV}-" + pr + "_${DPKG_ARCH}.deb", d)
|
||||||
srcfile = bb.data.expand("${DEPLOY_DIR_DEB}/" + arch + "/" + srcname, d)
|
srcfile = bb.data.expand("${DEPLOY_DIR_DEB}/" + arch + "/" + srcname, d)
|
||||||
if not os.path.exists(srcfile):
|
if os.path.exists(srcfile):
|
||||||
bb.fatal("Package %s does not exist yet it should" % srcfile)
|
destpath = debpath + "/" + arch + "/"
|
||||||
destpath = debpath + "/" + arch + "/"
|
bb.mkdirhier(destpath)
|
||||||
bb.mkdirhier(destpath)
|
bb.copyfile(srcfile, destpath + srcname)
|
||||||
bb.copyfile(srcfile, destpath + srcname)
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Handle stamps/ files
|
# Handle stamps/ files
|
||||||
@@ -333,7 +333,7 @@ python do_package_stage () {
|
|||||||
bb.mkdirhier(destdir)
|
bb.mkdirhier(destdir)
|
||||||
# We need to include the package_stage stamp in the staging package so create one
|
# We need to include the package_stage stamp in the staging package so create one
|
||||||
bb.build.make_stamp("do_package_stage", d)
|
bb.build.make_stamp("do_package_stage", d)
|
||||||
os.system("cp %s.do_* %s/" % (stampfn, destdir))
|
os.system("cp -dpR %s.do_* %s/" % (stampfn, destdir))
|
||||||
|
|
||||||
bb.build.exec_func("staging_helper", d)
|
bb.build.exec_func("staging_helper", d)
|
||||||
bb.build.exec_func("staging_packager", d)
|
bb.build.exec_func("staging_packager", d)
|
||||||
|
|||||||
Reference in New Issue
Block a user