mirror of
https://github.com/mmueller41/genode.git
synced 2026-01-21 20:42:56 +01:00
use /depot as depot directory in debug info
By using GCC's --debug-prefix-map argument, we can make sure that debug archives always refer to source files at /depot. With this change, GDB can be pointed to the correct source-file location by using the `set substitute-path /depot /path/to/local/depot`. Fixes #5260
This commit is contained in:
committed by
Norman Feske
parent
d44ec53cd3
commit
b5c9107465
@@ -124,6 +124,12 @@ endif
|
||||
CC_OPT += -fprofile-arcs -ftest-coverage -fprofile-dir=$(PROFILE_DIR)
|
||||
endif
|
||||
|
||||
ifneq ($(findstring /depot/,$(CURDIR)),)
|
||||
DEBUG_PREFIX = $(shell echo $(CURDIR) | \
|
||||
sed -e 's|/depot/.*$$|/depot/|')
|
||||
CC_OPT += -fdebug-prefix-map=$(DEBUG_PREFIX)=/depot/
|
||||
endif
|
||||
|
||||
#
|
||||
# Enable the undefined behavior sanitizer if requested
|
||||
#
|
||||
|
||||
Reference in New Issue
Block a user