summaryrefslogtreecommitdiffstats
path: root/meta/classes/package.bbclass
diff options
context:
space:
mode:
authorRuss Dill <russ.dill@nikolamotor.com>2022-04-20 09:03:29 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-04-21 20:40:23 +0100
commit493145c6f1bc92ab2b7a23e181641b09df87c9ff (patch)
treed1ca3856ab964a3da5f10a891865e95ccc77f991 /meta/classes/package.bbclass
parentf099e0467599b18f162bc101d2de2fcc3a75b2ec (diff)
downloadopenembedded-core-493145c6f1bc92ab2b7a23e181641b09df87c9ff.tar.gz
package.bbclass: Prevent perform_packagecopy from removing /sysroot-only
The files in /sysroot-only are intended to make it into the recipes sysroot output, but not into the package. However, if do_package is run before do_populate_sysroot, the files are removed. Use a smaller hammer to avoid copying the files into the package so they are still around when do_populate_sysroot runs. Signed-off-by: Russ Dill <russ.dill@nikolamotor.com> Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Diffstat (limited to 'meta/classes/package.bbclass')
-rw-r--r--meta/classes/package.bbclass8
1 files changed, 1 insertions, 7 deletions
diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
index e71daafe94..44fbc32df6 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -422,7 +422,6 @@ def splitstaticdebuginfo(file, dvar, dv, d):
# return a mapping of files:debugsources
import stat
- import shutil
src = file[len(dvar):]
dest = dv["staticlibdir"] + os.path.dirname(src) + dv["staticdir"] + "/" + os.path.basename(src) + dv["staticappend"]
@@ -807,15 +806,10 @@ python perform_packagecopy () {
dest = d.getVar('D')
dvar = d.getVar('PKGD')
- # Remove ${D}/sysroot-only if present
- sysroot_only = os.path.join(dest, 'sysroot-only')
- if cpath.exists(sysroot_only) and cpath.isdir(sysroot_only):
- shutil.rmtree(sysroot_only)
-
# Start by package population by taking a copy of the installed
# files to operate on
# Preserve sparse files and hard links
- cmd = 'tar -cf - -C %s -p -S . | tar -xf - -C %s' % (dest, dvar)
+ cmd = 'tar --exclude=./sysroot-only -cf - -C %s -p -S . | tar -xf - -C %s' % (dest, dvar)
subprocess.check_output(cmd, shell=True, stderr=subprocess.STDOUT)
# replace RPATHs for the nativesdk binaries, to make them relocatable