-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
67 lines (41 loc) · 870 Bytes
/
Makefile
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
##### Debug #####
DEBUG = -DDEBUG
##### Output #####
TGT = e.exe
##### Sources #####
HDRS = eexe.h
SRCS = eexe.c
RCS = eexe.rc
OBJS = $(SRCS:.c=.obj)
RES = $(RCS:.rc=.res)
LIBS = kernel32.lib user32.lib gdi32.lib advapi32.lib
##### Commands #####
CC = cl -nologo
RC = rc
LD = cl
RM = del
ZIP = zip
##### Flags #####
CFLAGS = -MD -G6 -O2
RCFLAGS =
LDFLAGS = $(CFLAGS)
RFLAGS =
##### Options #####
.SUFFIXES : .exe .obj .c .h .rc .res .lib
##### Precious Rules #####
.c.obj :
$(CC) $(CFLAGS) -c $<
.rc.res :
$(RC) $(RCFLAGS) $<
##### Rules #####
all : $(TGT)
zip : $(TGT)
$(ZIP) -9 $(TGT:.exe=.zip) $(TGT) $(SRCS) $(RCS) $(HDRS) Makefile README.txt
clean :
-$(RM) $(RFLAGS) $(OBJS) $(RES)
distclean : clean
-$(RM) $(RFLAGS) $(TGT)
$(TGT) : $(OBJS) $(RES)
$(LD) $(LDFLAGS) -Fe$(TGT) $(OBJS) $(LIBS) $(RES)
$(OBJS) : $(HDRS)
$(RES) : $(HDRS)