diff options
Diffstat (limited to 'tmk_core/chibios.mk')
-rw-r--r-- | tmk_core/chibios.mk | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/tmk_core/chibios.mk b/tmk_core/chibios.mk index f9e52aed2..73c01c7b4 100644 --- a/tmk_core/chibios.mk +++ b/tmk_core/chibios.mk @@ -110,6 +110,8 @@ else ifneq ("$(wildcard $(KEYBOARD_PATH_1)/ld/$(MCU_LDSCRIPT).ld)","") LDSCRIPT = $(KEYBOARD_PATH_1)/ld/$(MCU_LDSCRIPT).ld else ifneq ("$(wildcard $(TOP_DIR)/drivers/boards/ld/$(MCU_LDSCRIPT).ld)","") LDSCRIPT = $(TOP_DIR)/drivers/boards/ld/$(MCU_LDSCRIPT).ld +else ifneq ("$(wildcard $(STARTUPLD_CONTRIB)/$(MCU_LDSCRIPT).ld)","") + LDSCRIPT = $(STARTUPLD_CONTRIB)/$(MCU_LDSCRIPT).ld else LDSCRIPT = $(STARTUPLD)/$(MCU_LDSCRIPT).ld endif @@ -120,17 +122,18 @@ CHIBISRC = $(STARTUPSRC) \ $(OSALSRC) \ $(HALSRC) \ $(PLATFORMSRC) \ + $(PLATFORMSRC_CONTRIB) \ $(BOARDSRC) \ - $(STREAMSSRC) \ - $(STARTUPASM) \ - $(PORTASM) \ - $(OSALASM) + $(STREAMSSRC) + +# Ensure the ASM files are not subjected to LTO -- it'll strip out interrupt handlers otherwise. +QUANTUM_LIB_SRC += $(STARTUPASM) $(PORTASM) $(OSALASM) CHIBISRC := $(patsubst $(TOP_DIR)/%,%,$(CHIBISRC)) -EXTRAINCDIRS += $(CHIBIOS)/os/license \ +EXTRAINCDIRS += $(CHIBIOS)/os/license $(CHIBIOS)/os/oslib/include \ $(STARTUPINC) $(KERNINC) $(PORTINC) $(OSALINC) \ - $(HALINC) $(PLATFORMINC) $(BOARDINC) $(TESTINC) \ + $(HALINC) $(PLATFORMINC) $(PLATFORMINC_CONTRIB) $(BOARDINC) $(TESTINC) \ $(STREAMSINC) $(CHIBIOS)/os/various $(COMMON_VPATH) # @@ -179,6 +182,9 @@ LDFLAGS += -Wl,--script=$(LDSCRIPT)$(LDSYMBOLS) OPT_DEFS += -DPROTOCOL_CHIBIOS +# Workaround to stop ChibiOS from complaining about new GCC -- it's been fixed for 7/8/9 already +OPT_DEFS += -DPORT_IGNORE_GCC_VERSION_CHECK=1 + MCUFLAGS = -mcpu=$(MCU) # FPU options default (Cortex-M4 and Cortex-M7 single precision). |