Script to automatically load symbols in recordings

It would be nice to have a script that automatically loads the right symbols for recordings.

More often than not the recording is of a stripped binary so loading it results in an unpleasant journey trying to figure out how to load symbols.


The (usually correct) way of doing this is rather counter-intuitive:


set sysroot /
set debug-file-directory /path/to/build
set solib-search-path /path/to/build/lib
uload <your recording>
file /path/to/build/executable



automating the above will render the whole experience much more pleasant.

I think there are some assumptions in there about build system layout on disk which could make implementing a script that is sufficiently generic to be widely useful quite a fiddly undertaking.  Also how would this interoperate when loading a recording from the command line?

udb <your recording>

Perhaps a template (or two templates) would be useful, into which customers could insert the right paths for them (or appropriate logic to construct the paths).

At the risk of moving the goalposts, it would also be good to include some help here for people to identify the version of their binaries from the recording (crack out the exe and inspect its ELF?) so that they can construct an appropriately versioned path.

Perhaps all of this could become a very useful self-documenting not-quite-script in our add-ons repo?

Updated idea status NewDiscussion ongoing