Skip to content

Commit 53169e5

Browse files
committed
F4: Fix linker script lookup. Specify some startup defines.
Assuming we're going generally F405 all the way for the F4. We don't clear the heap (yet?).
1 parent 5f4f945 commit 53169e5

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

flight/PiOS/STM32F4xx/library_chibios.mk

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,19 @@ PIOS_DEVLIB := $(dir $(lastword $(MAKEFILE_LIST)))
1010
#
1111
# Linker script depending on STM32 type
1212
#
13-
ifneq "$(findstring STM32F40_41xxx,$(STM32_TYPE))" ""
13+
ifneq "$(findstring STM32F405xx,$(STM32_TYPE))" ""
1414
LINKER_SCRIPTS_APP = $(PIOS_DEVLIB)/sections_chibios.ld
1515
else ifneq "$(findstring STM32F446xx,$(STM32_TYPE))" ""
1616
LINKER_SCRIPTS_APP = $(PIOS_DEVLIB)/sections_chibios_STM32F446xx.ld
1717
else
1818
$(error No linker script found for $(STM32_TYPE))
1919
endif
2020

21+
#
22+
# ChibiOS settings
23+
#
24+
CDEFS += -DCRT1_AREAS_NUMBER=0
25+
ADEFS += -DCRT0_INIT_RAM_AREAS=FALSE
2126

2227
#
2328
# Compiler options implied by the F4xx

0 commit comments

Comments
 (0)