extender icon indicating copy to clipboard operation
extender copied to clipboard

Add support for "-fdebug-prefix-map" to make debugging easier

Open JCash opened this issue 3 years ago • 0 comments

Instead of having the random job folder as part of the file paths, we can substitute it with either:

  • /tmp/job123456 -> /extender/build/
    • Good for caching, and everyone gets the same paths
    • Still has to setup debug mappings locally
  • /tmp/job123456 -> /path/to/user/project
    • Good for user
    • Our caching will not work across users

From gcc:

" -fdebug-prefix-map=old=new

When compiling files residing in directory old, record debugging information describing them as if the files resided in directory new instead. This can be used to replace a build-time path with an install-time path in the debug info. It can also be used to change an absolute path to a relative path by using . for new. This can give more reproducible builds, which are location independent, but may require an extra command to tell GDB where to find the source files. See also -ffile-prefix-map. "

JCash avatar Feb 14 '23 09:02 JCash