Line | |
---|
1 | ########################################################################## |
---|
2 | # targets: # |
---|
3 | ########################################################################## |
---|
4 | |
---|
5 | |
---|
6 | ################ |
---|
7 | # object files # |
---|
8 | ################ |
---|
9 | |
---|
10 | OBJ_DIR = |
---|
11 | OBJ = $(OBJ_DIR)bin2to8bin.o |
---|
12 | OBJ2 = $(OBJ_DIR)bin2K7.o |
---|
13 | OBJ3 = $(OBJ_DIR)sincos.o |
---|
14 | |
---|
15 | ################## |
---|
16 | # compiler flags # |
---|
17 | ################## |
---|
18 | |
---|
19 | CC = gcc |
---|
20 | |
---|
21 | WFLAGS = -Wall -W |
---|
22 | |
---|
23 | OFLAGS = -O2 |
---|
24 | |
---|
25 | CFLAGS = $(WFLAGS) $(OFLAGS) |
---|
26 | |
---|
27 | |
---|
28 | ################ |
---|
29 | # target rules # |
---|
30 | ################ |
---|
31 | |
---|
32 | .PHONY: all install clean |
---|
33 | |
---|
34 | all: bin2to8bin bin2K7 sincos |
---|
35 | |
---|
36 | clean: |
---|
37 | rm -f bin2to8bin bin2K7 sincos $(OBJ_DIR)*.o |
---|
38 | |
---|
39 | bin2to8bin: $(OBJ) |
---|
40 | $(CC) -s -o bin2to8bin $(OBJ) |
---|
41 | |
---|
42 | bin2K7: $(OBJ2) |
---|
43 | $(CC) -s -o bin2K7 $(OBJ2) |
---|
44 | |
---|
45 | sincos: $(OBJ3) |
---|
46 | $(CC) -s -o sincos $(OBJ3) |
---|
47 | |
---|
48 | |
---|
49 | $(OBJ_DIR)%.o: %.c |
---|
50 | $(CC) -c $(CFLAGS) -o $@ $< |
---|
51 | |
---|
Note: See
TracBrowser
for help on using the repository browser.