diff options
author | rsesek@chromium.org <rsesek@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2014-07-25 18:18:59 +0000 |
---|---|---|
committer | rsesek@chromium.org <rsesek@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2014-07-25 18:18:59 +0000 |
commit | e2fffff1a4de7b9d335ea49632502015e02eac7d (patch) | |
tree | 7e51a0f076ba6d9b3bc282e5181754eda22ebca6 /src/common | |
parent | Add GYP build for the src/tools directory on Mac and Linux. (diff) | |
download | breakpad-e2fffff1a4de7b9d335ea49632502015e02eac7d.tar.xz |
In Mac dump_syms, allow reading debug data out of both the Mach-O file and the dSYM.
This adds a new |-g <dSYM path>| flag to dump_syms, to specify the dSYM path for
the target Mach-O argument. The UUIDs and architectures of the two paths must
match in order to dump symbols for this "split module."
This reason for this is that for x86_64 binaries on OS X, the CFI data is stored
in the __TEXT,__eh_frame segment of the Mach-O file, and the data is not copied
into the dSYM by dsymutil. Therefore, just dumping the dSYM doesn't yield CFI
data for x86_64 files, and both the dSYM and the Mach-O file must be dumped in
order to produce a complete Breakpad symbol file. For i386 binaries, the CFI data
is stored in the __DWARF,__debug_frame segment, which is part of the dSYM, so
this isn't necessary.
BUG=https://code.google.com/p/chromium/issues/detail?id=393594
R=mark@chromium.org
Review URL: https://breakpad.appspot.com/6704002
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1359 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/common')
-rw-r--r-- | src/common/module.cc | 2 | ||||
-rw-r--r-- | src/common/module.h | 7 |
2 files changed, 7 insertions, 2 deletions
diff --git a/src/common/module.cc b/src/common/module.cc index 2d2e4efc..244fc988 100644 --- a/src/common/module.cc +++ b/src/common/module.cc @@ -155,7 +155,7 @@ void Module::GetFiles(vector<File *> *vec) { vec->push_back(it->second); } -void Module::GetStackFrameEntries(vector<StackFrameEntry *> *vec) { +void Module::GetStackFrameEntries(vector<StackFrameEntry *> *vec) const { *vec = stack_frame_entries_; } diff --git a/src/common/module.h b/src/common/module.h index 398bc315..440298f0 100644 --- a/src/common/module.h +++ b/src/common/module.h @@ -247,7 +247,7 @@ class Module { // effectively a copy of the stack frame entry list, this is mostly // useful for testing; other uses should probably get // a more appropriate interface.) - void GetStackFrameEntries(vector<StackFrameEntry *> *vec); + void GetStackFrameEntries(vector<StackFrameEntry *> *vec) const; // Find those files in this module that are actually referred to by // functions' line number data, and assign them source id numbers. @@ -270,6 +270,11 @@ class Module { // established by SetLoadAddress. bool Write(std::ostream &stream, SymbolData symbol_data); + string name() const { return name_; } + string os() const { return os_; } + string architecture() const { return architecture_; } + string identifier() const { return id_; } + private: // Report an error that has occurred writing the symbol file, using // errno to find the appropriate cause. Return false. |