summaryrefslogtreecommitdiff
path: root/meta/classes
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2013-05-14 08:50:33 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-05-14 08:50:37 +0300
commita015881f2207aded601459ba3eebbefb0002b3c5 (patch)
treebfbd8f8b44a0b7d3eb52421a506279d658af1380 /meta/classes
parentcf5e40598ae9a83f22cabedc7b72000beb62703c (diff)
downloadopenembedded-core-a015881f2207aded601459ba3eebbefb0002b3c5.tar.gz
openembedded-core-a015881f2207aded601459ba3eebbefb0002b3c5.tar.bz2
openembedded-core-a015881f2207aded601459ba3eebbefb0002b3c5.zip
package.bbclass: Fix sources contents
http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=c376f1f49cea182a2887945840ab97a20970a373 fixed a valid issue where the sources file was accumulating information and subsequent task runs of do_packacge were not cleaning it. The fix is wrong however since we're removing the file within a loop. This fix removes the file outside the loop ensuring it is not truncated and contains the correct information. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/package.bbclass10
1 files changed, 5 insertions, 5 deletions
diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
index 36b3ae5109..0f2743d106 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -226,7 +226,7 @@ python () {
d.setVar("PACKAGERDEPTASK", "")
}
-def splitdebuginfo(file, debugfile, debugsrcdir, d):
+def splitdebuginfo(file, debugfile, debugsrcdir, sourcefile, d):
# Function to split a single file into two components, one is the stripped
# target system binary, the other contains any debugging information. The
# two files are linked to reference each other.
@@ -240,9 +240,6 @@ def splitdebuginfo(file, debugfile, debugsrcdir, d):
debugedit = d.expand("${STAGING_LIBDIR_NATIVE}/rpm/bin/debugedit")
workdir = d.getVar("WORKDIR", True)
workparentdir = d.getVar("DEBUGSRC_OVERRIDE_PATH", True) or os.path.dirname(os.path.dirname(workdir))
- sourcefile = d.expand("${WORKDIR}/debugsources.list")
-
- bb.utils.remove(sourcefile)
# We ignore kernel modules, we don't generate debug info files.
if file.find("/lib/modules/") != -1 and file.endswith(".ko"):
@@ -721,6 +718,9 @@ python split_and_strip_files () {
debuglibdir = ""
debugsrcdir = "/usr/src/debug"
+ sourcefile = d.expand("${WORKDIR}/debugsources.list")
+ bb.utils.remove(sourcefile)
+
os.chdir(dvar)
# Return type (bits):
@@ -833,7 +833,7 @@ python split_and_strip_files () {
bb.utils.mkdirhier(os.path.dirname(fpath))
#bb.note("Split %s -> %s" % (file, fpath))
# Only store off the hard link reference if we successfully split!
- splitdebuginfo(file, fpath, debugsrcdir, d)
+ splitdebuginfo(file, fpath, debugsrcdir, sourcefile, d)
# Hardlink our debug symbols to the other hardlink copies
for file in hardlinks: