-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathmakefile
More file actions
43 lines (28 loc) · 744 Bytes
/
makefile
File metadata and controls
43 lines (28 loc) · 744 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
34
35
36
37
38
39
40
41
42
# MAKEFILE for C-program film
# OPTIONS
NAME = DFT
INCLUDES = -I.
OUT = \".\"
IN = \".\"
CFLAGS = -O3 $(INCLUDES) -DOUTDIR=$(OUT) -DINDIR=$(IN) #-DNONAME
CC = gcc
LDFLAGS = -lm
# suffix rule: .c needed for .o
.c.o :
$(CC) $(CFLAGS) -c $*.c
#macro definition
DFT = dft.o
# The following commands (second line) produce the files (targets)
# listed on the left of the colon given the prerequisites on the RHS of the first line
DFT: $(DFT)
$(CC) -o $(NAME) $(CFLAGS) $(DFT) $(LDFLAGS)
# rm DFT.o
debug: DFT.c makefile
$(CC) $(CFLAGS) -g -c DFT.c
DFT.o: DFT.c convlv.c numrec.c makefile
$(CC) $(CFLAGS) -c DFT.c
new:
touch *.c
#type "make clean" to execute this command
clean:
rm *.o