Skip to content

How to read Source Link JSON data from PDBs #723

Closed
@gregwb

Description

@gregwb

Is there a supported way for retrieving Source Link URLs from PDB files?

For writing tools that use Source Link data, there's a useful SourceLinkMap for parsing the JSON, but how can the JSON be read from a PDB in the first place?

I note that the symreader-converter project has code for reading Source Link data, but from my experimentation, I believe the APIs used there do not support PDBs for native C++ projects. I would like in particular to be able to read Source Link data embedded in native PDBs by the C++ linker.

From this comment it appears at a pinch I may be able to use pdbstr.exe to extract streams sourcelink$1, sourcelink$2, ... etc. But I was hoping for a more convenient API than a command-line tool.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions