2015-03-09 02:39:42 +00:00
|
|
|
OUTFILE = blackmagic_upgrade
|
2012-01-18 07:45:18 +00:00
|
|
|
|
|
|
|
CC = $(CROSS_COMPILE)gcc
|
|
|
|
|
2015-03-11 04:58:37 +00:00
|
|
|
CFLAGS = -Wall -Wextra -std=gnu99 -O0 -g -MD -mno-ms-bitfields
|
2012-01-18 07:45:18 +00:00
|
|
|
LDFLAGS = -lusb
|
|
|
|
|
|
|
|
OBJ = bindata.o \
|
|
|
|
dfu.o \
|
|
|
|
stm32mem.o \
|
|
|
|
main.o
|
|
|
|
|
2015-03-09 02:39:42 +00:00
|
|
|
all: $(OUTFILE)
|
2012-01-18 07:45:18 +00:00
|
|
|
|
2015-03-09 02:39:42 +00:00
|
|
|
$(OUTFILE) $(OUTFILE).exe: $(OBJ)
|
2012-01-18 07:45:18 +00:00
|
|
|
$(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS)
|
|
|
|
|
|
|
|
.PHONY: clean
|
|
|
|
clean:
|
2015-03-09 02:39:42 +00:00
|
|
|
-rm -rf $(OUTFILE) $(OUTFILE).exe *.d *.o
|
2012-01-18 07:45:18 +00:00
|
|
|
|
|
|
|
-include *.d
|
|
|
|
|