diff options
author | lonkaars <loek@pipeframe.xyz> | 2022-10-29 18:01:56 +0200 |
---|---|---|
committer | lonkaars <loek@pipeframe.xyz> | 2022-10-29 18:01:56 +0200 |
commit | 9e9ea9d07ed2a176d6f6e83b5b100da22d8fca50 (patch) | |
tree | a683bde4664dad75c3b5a1efbd4223a4ab3b40dd /stm32f091/makefile | |
parent | ead710db271795380207141f0add7278ba12ada0 (diff) | |
parent | aae57dc32a843351fb2e17721afcd841bedec0a6 (diff) |
Merge branch 'protocol' into dev
Diffstat (limited to 'stm32f091/makefile')
-rw-r--r-- | stm32f091/makefile | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/stm32f091/makefile b/stm32f091/makefile index 20424c3..dd03761 100644 --- a/stm32f091/makefile +++ b/stm32f091/makefile @@ -4,6 +4,7 @@ OC = arm-none-eabi-objcopy RM = rm -f TARGET = main +HOST=$(strip $(shell uname -o)) include ../shared/shared.mk @@ -13,7 +14,6 @@ SHARED_FLAGS += -Wall SHARED_FLAGS += -Wextra # SHARED_FLAGS += -Wno-register SHARED_FLAGS += -Wa,--defsym,CALL_ARM_SYSTEM_INIT=1 -# SHARED_FLAGS += -I/usr/arm-none-eabi/include/ SHARED_FLAGS += -I./lib/STM32-base-STM32Cube/HAL/STM32F0xx/inc SHARED_FLAGS += -I./lib/STM32-base-STM32Cube/HAL/STM32F0xx/inc/Legacy SHARED_FLAGS += -I./lib/STM32-base-STM32Cube/CMSIS/ARM/inc @@ -22,7 +22,10 @@ SHARED_FLAGS += -I./lib/STM32-base/startup SHARED_FLAGS += -I./lib/FreeRTOS-Kernel/include SHARED_FLAGS += -I./lib/FreeRTOS-Kernel/portable/GCC/ARM_CM0/ SHARED_FLAGS += -I. -SHARED_FLAGS += -O1 +ifeq ($(HOST),GNU/Linux) +SHARED_FLAGS += -I/usr/arm-none-eabi/include/ +endif +# SHARED_FLAGS += -O1 SHARED_FLAGS += -ffunction-sections SHARED_FLAGS += -fdata-sections SHARED_FLAGS += -Wl,--gc-sections @@ -89,7 +92,7 @@ $(TARGET).elf: $(OBJS) $(LD) $(LFLAGS) $^ -o $@ flash: $(TARGET).bin - st-flash write $(TARGET).bin 0x08000000 + st-flash --reset write $(TARGET).bin 0x08000000 compile_commands: clean compiledb make -n |