force libopencm3 to not use enums

This commit is contained in:
King Kévin 2017-04-03 13:32:50 +02:00
parent aa0a5dd0a9
commit 11149901d0
1 changed files with 2 additions and 2 deletions

View File

@ -92,7 +92,7 @@ CFLAGS += -Wpedantic -Wall -Werror -Wundef -Wextra -Wshadow -Wredundant-decls -W
# add options for better code optimization
CFLAGS += -fno-common -ffunction-sections -fdata-sections
# use variable size enum (opencm3, gcc, and compiler-rt do)
CFLAGS += -fshort-enums
#CFLAGS += -fshort-enums
# use no variable size enum (ELLCC/musl does not)
CFLAGS += -fno-short-enums
# don't use system main definition (the starting point)
@ -195,7 +195,7 @@ $(OPENCM3_LIB)/lib$(STM32F1_LIB).a:
$(info compiling libopencm3 library)
git submodule init
git submodule update
$(Q)$(MAKE) -C $(OPENCM3_DIR)
$(Q)$(MAKE) CFLAGS=-fno-short-enums -C $(OPENCM3_DIR)
flash: $(BINARY).hex
$(info flashing $(<) using SWD)