Globally configurable stack checks, R10 is always fixed

This commit is contained in:
Pavel Kirienko
2015-01-21 14:54:24 +01:00
committed by Lorenz Meier
parent c9eae96cf6
commit 2ebd7099de
3 changed files with 13 additions and 12 deletions
+6
View File
@@ -62,8 +62,14 @@ ARCHCPUFLAGS = -mcpu=cortex-m4 \
# enable precise stack overflow tracking
ENABLE_STACK_CHECKS ?= 0
ifneq ($(ENABLE_STACK_CHECKS),0)
$(info Stack checks enabled)
INSTRUMENTATIONDEFINES = -finstrument-functions \
-ffixed-r10
else
INSTRUMENTATIONDEFINES = -ffixed-r10
endif
# pull in *just* libm from the toolchain ... this is grody
LIBM = "${shell $(CC) $(ARCHCPUFLAGS) -print-file-name=libm.a}"