Bazel: debug info embeds absolute paths into the sandbox
@walkingeyerobot is already working on this.
Since Nov 9, 2022.
Assessment
This issue has not been assessed yet.
Description
If you build with -g or -gseparate-dwarf, the generated symbols will contain absolute paths into Bazel's sandbox directory. Those directories don't exist beyond the lifetime of an individual compile action, so the resulting debug symbols aren't useful. For example, you won't be able to debug using Chrome Developer Tools.
The way that Bazel toolchains usually address this is one of the following:
- Execute the compile action in an environment that sets
$PWDto/proc/self/cwd. This is what the default Bazel cc toolchain does on linux. - Set an appropriate
-fdebug-prefix-mapflag in a compiler wrapper script. This is what the default Bazel cc toolchain does on macOS.
- Dominant language
- Python
- Stars
- 3.7k
- Forks
- 822
- Avg merge
- 2d 6h
- Merged PRs (30d)
- 4
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from emscripten-core/emsdk
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
emscripten-core/emsdk#1734 · 1 comment ·
-
emscripten-core/emsdk#1732 · 3 comments · 1 assignee ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
emscripten-core/emsdk#1714 · 5 comments ·
-
Bootstrap LLVM build Open
Difficulty 5/5 Over a week Newbie friendliness 35/100
emscripten-core/emsdk#1713 · 4 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
emscripten-core/emsdk#1689 ·
All issues in emscripten-core/emsdk
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100