1 BIN2C = ../../../../src/helper/bin2char.sh
3 CROSS_COMPILE ?= arm-none-eabi-
6 OBJCOPY=$(CROSS_COMPILE)objcopy
7 OBJDUMP=$(CROSS_COMPILE)objdump
10 AFLAGS = -static -nostartfiles -mlittle-endian -Wa,-EL
11 CFLAGS = -c -mthumb -nostdlib -nostartfiles -Os -g -fPIC
13 all: stm32f1x.inc stm32f2x.inc stm32h7x.inc stm32l4x.inc stm32lx.inc
18 $(CC) $(AFLAGS) $< -o $@
20 stm32l4x.elf: stm32l4x.c
21 $(CC) $(CFLAGS) -mcpu=cortex-m0plus -fstack-usage -Wa,-adhln=$(<:.c=.lst) $< -o $@
27 $(OBJCOPY) -Obinary $< $@
33 -rm -f *.elf *.lst *.bin *.inc