author | Mike Hommey <mh+mozilla@glandium.org> |
Thu, 06 Dec 2012 17:06:48 +0100 | |
changeset 115163 | 3bb2d53dde34ab8eb2823fc6c1b4b0a938a556c0 |
parent 115162 | 251478307d97c1c04f6d058293f95d1dfe083794 |
child 115164 | 7e5fee8e5ba03ad9083e55d8ffd7e195250dddc6 |
push id | 23975 |
push user | mh@glandium.org |
push date | Thu, 06 Dec 2012 16:07:53 +0000 |
treeherder | mozilla-central@3bb2d53dde34 [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | ted |
bugs | 818903 |
milestone | 20.0a1 |
first release with | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
last release without | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
--- a/toolkit/crashreporter/tools/symbolstore.py +++ b/toolkit/crashreporter/tools/symbolstore.py @@ -606,27 +606,31 @@ class Dumper_Linux(Dumper): command in PATH.""" if not Dumper.ShouldProcess(self, file): return False if file.endswith(".so") or os.access(file, os.X_OK): return self.RunFileCommand(file).startswith("ELF") return False def CopyDebug(self, file, debug_file, guid): + import zlib, struct, hashlib # We want to strip out the debug info, and add a # .gnu_debuglink section to the object, so the debugger can # actually load our debug info later. file_dbg = file + ".dbg" - if subprocess.call([self.objcopy, '--only-keep-debug', file, file_dbg]) == 0 and \ - subprocess.call([self.objcopy, '--add-gnu-debuglink=%s' % file_dbg, file]) == 0: + if subprocess.call([self.objcopy, '--only-keep-debug', file, file_dbg], stdout=sys.stderr) == 0 and \ + subprocess.call([self.objcopy, '--add-gnu-debuglink=%s' % file_dbg, file], stdout=sys.stderr) == 0: rel_path = os.path.join(debug_file, guid, debug_file + ".dbg") full_path = os.path.normpath(os.path.join(self.symbol_path, rel_path)) + # Temporary debug information + print >>sys.stderr, read_output('objdump', '-j', '.gnu_debuglink', '-s', file) + print >>sys.stderr, "%s crc: %08x" % (file_dbg, 0xffffffff & zlib.crc32(open(file_dbg).read())) shutil.move(file_dbg, full_path) # gzip the shipped debug files os.system("gzip %s" % full_path) print rel_path + ".gz" else: if os.path.isfile(file_dbg): os.unlink(file_dbg)