Skip to content

Commit 41245c8

Browse files
microbit-carlosdpgeorge
authored andcommitted
codal_port/Makefile: Keep C/C++ flags set up by MicroPython lib.
1 parent ef2a57e commit 41245c8

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/codal_port/Makefile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,8 @@ INC += -I$(BUILD)
4545
CWARN = -Wall -Werror
4646
CWARN += -Wpointer-arith -Wuninitialized
4747
CFLAGS_ARCH += -DNRF52833_XXAA
48-
CFLAGS = $(INC) $(CWARN) -std=c99 $(CFLAGS_MOD) $(CFLAGS_ARCH) $(COPT) $(CFLAGS_EXTRA)
48+
CFLAGS += $(INC) $(CWARN) -std=c99 $(CFLAGS_MOD) $(CFLAGS_ARCH) $(COPT) $(CFLAGS_EXTRA)
49+
CXXFLAGS += $(filter-out -std=c99,$(CFLAGS))
4950

5051
# Debugging/Optimization
5152
ifdef DEBUG
@@ -56,7 +57,7 @@ endif
5657

5758
CFLAGS += -g
5859
LDFLAGS_ARCH = -Wl,-map,$@.map
59-
LDFLAGS = $(LDFLAGS_MOD) $(LDFLAGS_ARCH) -lm $(LDFLAGS_EXTRA)
60+
LDFLAGS += $(LDFLAGS_MOD) $(LDFLAGS_ARCH) -lm $(LDFLAGS_EXTRA)
6061

6162
SRC_C += \
6263
drv_display.c \

0 commit comments

Comments
 (0)