-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
33 lines (28 loc) · 940 Bytes
/
Makefile
File metadata and controls
33 lines (28 loc) · 940 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
ifeq ($(OS),Windows_NT)
USBFLAGS =
USBLIBS = -lusb
EXE_SUFFIX = .exe
CFLAGS += $(USBFLAGS)
LDFLAGS+= $(USBLIBS)
else
USBFLAGS = `libusb-config --cflags`
USBLIBS = `libusb-config --libs` #-framework CoreFoundation
EXE_SUFFIX =
CFLAGS += $(USBFLAGS) -fPIC
LDFLAGS+= $(USBLIBS)
endif
########################################################################################
CFLAGS+=-ggdb -g3 -O0 -DDEBUG=3 -DMYDEBUG
all: usbasploader$(EXE_SUFFIX)
depclean: deepclean
deepclean: clean
$(RM) *~
clean:
$(RM) *.o
$(RM) usbasploader$(EXE_SUFFIX)
usbhelper.o: usbhelper.c usbasp.h usbhelper.h Makefile
$(CC) -c -o usbhelper.o usbhelper.c $(CFLAGS)
usbasploader.o: usbasploader.c usbasp.h usbhelper.h Makefile
$(CC) -c -o usbasploader.o usbasploader.c $(CFLAGS)
usbasploader$(EXE_SUFFIX): usbasploader.o usbhelper.o usbasp.h usbhelper.h Makefile
$(CC) -o usbasploader$(EXE_SUFFIX) usbasploader.o usbhelper.o $(CFLAGS) $(LDFLAGS)