From 8db93dc0164ba980317e553a162d6c262d067474 Mon Sep 17 00:00:00 2001 From: Andrew Leech Date: Wed, 30 Mar 2022 16:18:23 +1100 Subject: [PATCH] stm32/Makefile: Allow overriding COPT in Makefile. It can now be set in mpconfigboard.mk (as well as the make command line). --- ports/stm32/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ports/stm32/Makefile b/ports/stm32/Makefile index 3083c99570..fd5688056c 100644 --- a/ports/stm32/Makefile +++ b/ports/stm32/Makefile @@ -106,11 +106,11 @@ LDFLAGS += --gc-sections # Debugging/Optimization ifeq ($(DEBUG), 1) CFLAGS += -g -DPENDSV_DEBUG -COPT = -Og +COPT ?= -Og # Disable text compression in debug builds MICROPY_ROM_TEXT_COMPRESSION = 0 else -COPT += -Os -DNDEBUG +COPT ?= -Os -DNDEBUG endif # Flags for optional C++ source code