diff options
author | Mitch Bradley <wmb@firmworks.com> | 2020-02-09 09:49:45 -1000 |
---|---|---|
committer | Mitch Bradley <wmb@firmworks.com> | 2020-02-09 09:56:15 -1000 |
commit | 815214ee7e65f21214d17b9f1f3f307d3ab5d33b (patch) | |
tree | 72c57de20f1305d89394fdbfc0ddbabc5d9a2649 | |
parent | e6f2c482579bef88b92d570822c6fdf912633016 (diff) | |
download | cforth-815214ee7e65f21214d17b9f1f3f307d3ab5d33b.tar.gz |
arm-stm32f103 - fixed build problems
-rw-r--r-- | build/arm-stm32f103/Makefile | 10 | ||||
-rw-r--r-- | src/platform/arm-stm32f103/extend.c (renamed from src/platform/arm-stm32f103/textend.c) | 0 | ||||
-rw-r--r-- | src/platform/arm-stm32f103/stm32_flash.ld | 6 | ||||
-rw-r--r-- | src/platform/arm-stm32f103/targets.mk | 6 |
4 files changed, 16 insertions, 6 deletions
diff --git a/build/arm-stm32f103/Makefile b/build/arm-stm32f103/Makefile index 3cce6cd..353c90b 100644 --- a/build/arm-stm32f103/Makefile +++ b/build/arm-stm32f103/Makefile @@ -20,11 +20,11 @@ include $(TOPDIR)/src/app/$(MYNAME)/targets.mk ifeq ("$(wildcard $(STMLIB))","") - $(info You need the STM Standard Peripheral Library) - $(info Get it from http://www.st.com/content/st_com/en/products/embedded-software/mcus-embedded-software/stm32-embedded-software/stm32-standard-peripheral-libraries/stsw-stm32054.html) - $(info Get it from https://my.st.com/content/ccc/resource/technical/software/firmware/48/ab/e5/17/0d/79/43/74/stsw-stm32054.zip/files/stsw-stm32054.zip/_jcr_content/translations/en.stsw-stm32054.zip) - $(info Unpack it into the parent directory of the cforth/ tree) - $(error ) + $(info You need the STM Standard Peripheral Library) + $(info Get it from http://www.st.com/content/st_com/en/products/embedded-software/mcus-embedded-software/stm32-embedded-software/stm32-standard-peripheral-libraries/stsw-stm32054.html) + $(info Get it from https://my.st.com/content/ccc/resource/technical/software/firmware/48/ab/e5/17/0d/79/43/74/stsw-stm32054.zip/files/stsw-stm32054.zip/_jcr_content/translations/en.stsw-stm32054.zip) + $(info Unpack it into the parent directory of the cforth/ tree) + $(error ) endif diff --git a/src/platform/arm-stm32f103/textend.c b/src/platform/arm-stm32f103/extend.c index dbc1592..dbc1592 100644 --- a/src/platform/arm-stm32f103/textend.c +++ b/src/platform/arm-stm32f103/extend.c diff --git a/src/platform/arm-stm32f103/stm32_flash.ld b/src/platform/arm-stm32f103/stm32_flash.ld index dda2b0c..6689f2f 100644 --- a/src/platform/arm-stm32f103/stm32_flash.ld +++ b/src/platform/arm-stm32f103/stm32_flash.ld @@ -61,6 +61,12 @@ SECTIONS /* XXX _exit = .; */ } >FLASH + .ARM.exidx : + { + *(.ARM.exidx*) + *(.gnu.linkonce.armexidx.*) + } >FLASH + /* used by the startup to initialize data */ _sidata = .; diff --git a/src/platform/arm-stm32f103/targets.mk b/src/platform/arm-stm32f103/targets.mk index e905ed7..5110ae2 100644 --- a/src/platform/arm-stm32f103/targets.mk +++ b/src/platform/arm-stm32f103/targets.mk @@ -27,9 +27,13 @@ CFLAGS += -m32 -march=i386 TCFLAGS += -Os +# Use thumb instruction set to save a little space +TCFLAGS += -mthumb + # Omit unreachable functions from output TCFLAGS += -ffunction-sections -fdata-sections +TCFLAGS += -ffunction-sections -fdata-sections TLFLAGS += --gc-sections # VPATH += $(SRC)/cpu/arm @@ -80,7 +84,7 @@ PLAT_OBJS += $(EXTEND_OBJS) # Object files for the Forth system and application-specific extensions -FORTH_OBJS = tembed.o ttextend.o +FORTH_OBJS = tembed.o textend.o # Recipe for linking the final image |