diff options
author | Aidan MacDonald <amachronic@protonmail.com> | 2022-05-16 14:33:26 +0100 |
---|---|---|
committer | Aidan MacDonald <amachronic@protonmail.com> | 2022-05-22 07:16:11 -0400 |
commit | 981e9728390b401404c36241e2ce6bd4cfcb723d (patch) | |
tree | b68a7eaf7bf53dcd0dea8b29324c1e303bbb48f7 /lib/mipsunwinder/mipsunwinder.make | |
parent | cade488b089667f1252220d6b613c6795f960852 (diff) | |
download | rockbox-981e9728390b401404c36241e2ce6bd4cfcb723d.tar.gz rockbox-981e9728390b401404c36241e2ce6bd4cfcb723d.zip |
mips: add native backtrace implementation
Should make debugging crashes on native MIPS targets far easier.
This is by no means a 100% complete or robust implementation but
it seems to handle the vast majority of functions.
Change-Id: Id5f430270e02b5092b79026b6876675c784aa649
Diffstat (limited to 'lib/mipsunwinder/mipsunwinder.make')
-rw-r--r-- | lib/mipsunwinder/mipsunwinder.make | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/lib/mipsunwinder/mipsunwinder.make b/lib/mipsunwinder/mipsunwinder.make new file mode 100644 index 0000000000..ddd1ce078f --- /dev/null +++ b/lib/mipsunwinder/mipsunwinder.make | |||
@@ -0,0 +1,23 @@ | |||
1 | # __________ __ ___. | ||
2 | # Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
3 | # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
4 | # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
5 | # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
6 | # \/ \/ \/ \/ \/ | ||
7 | # | ||
8 | |||
9 | MIPSUNWINDERLIB_DIR = $(ROOTDIR)/lib/mipsunwinder | ||
10 | MIPSUNWINDERLIB_SRC = $(call preprocess, $(MIPSUNWINDERLIB_DIR)/SOURCES) | ||
11 | MIPSUNWINDERLIB_OBJ := $(call c2obj, $(MIPSUNWINDERLIB_SRC)) | ||
12 | |||
13 | OTHER_SRC += $(MIPSUNWINDERLIB_SRC) | ||
14 | |||
15 | MIPSUNWINDERLIB = $(BUILDDIR)/lib/libmipsunwinder.a | ||
16 | CORE_LIBS += $(MIPSUNWINDERLIB) | ||
17 | |||
18 | INCLUDES += -I$(MIPSUNWINDERLIB_DIR) | ||
19 | DEFINES += -DBACKTRACE_MIPSUNWINDER | ||
20 | |||
21 | $(MIPSUNWINDERLIB): $(MIPSUNWINDERLIB_OBJ) | ||
22 | $(SILENT)$(shell rm -f $@) | ||
23 | $(call PRINTS,AR $(@F))$(AR) rcs $@ $^ >/dev/null | ||