File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -19,15 +19,21 @@ OBJCOPY = $(GCC_BIN)arm-none-eabi-objcopy
19
19
OBJDUMP = $(GCC_BIN)arm-none-eabi-objdump
20
20
SIZE = $(GCC_BIN)arm-none-eabi-size
21
21
22
- CPU = -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=softfp
22
+ CPU = -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=$(FLOAT_ABI)
23
23
CC_FLAGS = $(CPU) -c -g -fno-common -fmessage-length=0 -Wall -fno-exceptions -ffunction-sections -fdata-sections
24
24
CC_FLAGS += -MMD -MP
25
25
CC_SYMBOLS = {% for s in symbols %}-D{{s}} {% endfor %}
26
26
27
- LD_FLAGS = -mcpu=cortex-m4 -mthumb -Wl,--gc-sections --specs=nano.specs -u _printf_float -u _scanf_float
27
+ LD_FLAGS = $(CPU) -Wl,--gc-sections --specs=nano.specs -u _printf_float -u _scanf_float
28
28
LD_FLAGS += -Wl,-Map=$(PROJECT).map,--cref
29
29
LD_SYS_LIBS = -lstdc++ -lsupc++ -lm -lc -lgcc -lnosys
30
30
31
+ ifeq ($(SOFTFP),1)
32
+ FLOAT_ABI = softfp
33
+ else
34
+ FLOAT_ABI = hard
35
+ endif
36
+
31
37
ifeq ($(DEBUG), 1)
32
38
CC_FLAGS += -DDEBUG -O0
33
39
else
You can’t perform that action at this time.
0 commit comments