Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarification or example for README bullet #198

Open
frostmourne8 opened this issue Mar 19, 2020 · 2 comments
Open

Clarification or example for README bullet #198

frostmourne8 opened this issue Mar 19, 2020 · 2 comments

Comments

@frostmourne8
Copy link

There is a bullet in the README that drew me to this crate: "Generate Breakpad symbol files from Mach, ELF and PDBs" which would be perfect for something I am trying to accomplish. I am having trouble figuring out how to perform this generation though. Any chance someone could offer clarification and/or update the README with a more detailed explanation?

@jan-auer
Copy link
Member

We never implemented a full dump_syms equivalent, but only the CFI part of it. To do that, you'll want to use AsciiCfiWriter.

To write FUNC and PUBLIC records, you would roughly have to do the following:

  • Open an Object from the input file.
  • Get the debug_session and generate FUNC records for all functions returned by functions. Skip inlinees, since Breakpad doesn't support that.
  • Iterate through symbols and emit missing ones as PUBLIC record.
  • You can have a look at this function for an example of how to iterate functions and symbols to emit those in order.

It makes sense to add a dump_syms example program to showcase this. I'll leave this issue open for that.

You might also want to have a look at Mozilla's dump_syms which is a more complete implementation that's partially based on symbolic.

@vaind
Copy link
Collaborator

vaind commented Feb 17, 2023

I'd vote for closing this as out-of-scope, considering dump_syms existence.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants