diff --git a/cpu/Makefile.include.cortexm_common b/cpu/Makefile.include.cortexm_common index c58fcfbe4b5496b060650d43d6a8f04a88a3a40e..2c118460ffdbb673e893039198955348d96b0564 100644 --- a/cpu/Makefile.include.cortexm_common +++ b/cpu/Makefile.include.cortexm_common @@ -29,7 +29,9 @@ export INCLUDES += -I$(RIOTCPU)/$(CPU)/include # Explicitly tell the linker to link the startup code. # Without this the interrupt vectors will not be linked correctly! +ifeq ($(COMMON_STARTUP),) export UNDEF += $(BINDIR)cpu/startup.o +endif # CPU depends on the cortex-m common module, so include it: include $(RIOTCPU)/cortexm_common/Makefile.include