summaryrefslogtreecommitdiffstats
path: root/meta
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-22 17:14:04 +0100
commit437d0c2122f6685d3b6531dd4daf33c232941803 (patch)
treef122ea6f472b620dac5b68453ce5dd241cea72ee /meta
parent8824d9ef7ac974b20cca6fa0947fe1d46badf18a (diff)
downloadpoky-437d0c2122f6685d3b6531dd4daf33c232941803.tar.gz
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. (From OE-Core master rev: a015881f2207aded601459ba3eebbefb0002b3c5) (From OE-Core rev: f897550222003ccea8f18c136a7b9ced5acb0ed3) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-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 2bc31eefe2..affa34e808 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -226,7 +226,7 @@ python () {
226 d.setVar("PACKAGERDEPTASK", "") 226 d.setVar("PACKAGERDEPTASK", "")
227} 227}
228 228
229def splitdebuginfo(file, debugfile, debugsrcdir, d): 229def splitdebuginfo(file, debugfile, debugsrcdir, sourcefile, d):
230 # Function to split a single file into two components, one is the stripped 230 # Function to split a single file into two components, one is the stripped
231 # target system binary, the other contains any debugging information. The 231 # target system binary, the other contains any debugging information. The
232 # two files are linked to reference each other. 232 # two files are linked to reference each other.
@@ -240,9 +240,6 @@ def splitdebuginfo(file, debugfile, debugsrcdir, d):
240 debugedit = d.expand("${STAGING_LIBDIR_NATIVE}/rpm/bin/debugedit") 240 debugedit = d.expand("${STAGING_LIBDIR_NATIVE}/rpm/bin/debugedit")
241 workdir = d.getVar("WORKDIR", True) 241 workdir = d.getVar("WORKDIR", True)
242 workparentdir = d.getVar("DEBUGSRC_OVERRIDE_PATH", True) or os.path.dirname(os.path.dirname(workdir)) 242 workparentdir = d.getVar("DEBUGSRC_OVERRIDE_PATH", True) or os.path.dirname(os.path.dirname(workdir))
243 sourcefile = d.expand("${WORKDIR}/debugsources.list")
244
245 bb.utils.remove(sourcefile)
246 243
247 # We ignore kernel modules, we don't generate debug info files. 244 # We ignore kernel modules, we don't generate debug info files.
248 if file.find("/lib/modules/") != -1 and file.endswith(".ko"): 245 if file.find("/lib/modules/") != -1 and file.endswith(".ko"):
@@ -721,6 +718,9 @@ python split_and_strip_files () {
721 debuglibdir = "" 718 debuglibdir = ""
722 debugsrcdir = "/usr/src/debug" 719 debugsrcdir = "/usr/src/debug"
723 720
721 sourcefile = d.expand("${WORKDIR}/debugsources.list")
722 bb.utils.remove(sourcefile)
723
724 os.chdir(dvar) 724 os.chdir(dvar)
725 725
726 # Return type (bits): 726 # Return type (bits):
@@ -832,7 +832,7 @@ python split_and_strip_files () {
832 bb.utils.mkdirhier(os.path.dirname(fpath)) 832 bb.utils.mkdirhier(os.path.dirname(fpath))
833 #bb.note("Split %s -> %s" % (file, fpath)) 833 #bb.note("Split %s -> %s" % (file, fpath))
834 # Only store off the hard link reference if we successfully split! 834 # Only store off the hard link reference if we successfully split!
835 splitdebuginfo(file, fpath, debugsrcdir, d) 835 splitdebuginfo(file, fpath, debugsrcdir, sourcefile, d)
836 836
837 # Hardlink our debug symbols to the other hardlink copies 837 # Hardlink our debug symbols to the other hardlink copies
838 for file in hardlinks: 838 for file in hardlinks: