-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
35 lines (25 loc) · 927 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
CC = gcc
WARNING_FLAGS = -Wall -Wextra
EXE = prodcomm
SCAN_BUILD_DIR = scan-build-out
all: main.o munch1.o munch2.o inputreader.o outputwriter.o Queue.o
$(CC) -o $(EXE) main.o munch1.o munch2.o inputreader.o outputwriter.o Queue.o -lpthread
main.o: main.c munch1.h munch2.h inputreader.h outputwriter.h Queue.h
$(CC) $(WARNING_FLAGS) -c main.c
inputreader.o: inputreader.c inputreader.h Queue.h
$(CC) $(WARNING_FLAGS) -c inputreader.c
munch1.o: munch1.c munch1.h Queue.h
$(CC) $(WARNING_FLAGS) -c munch1.c
munch2.o: munch2.c munch2.h Queue.h
$(CC) $(WARNING_FLAGS) -c munch2.c
outputwriter.o: outputwriter.c outputwriter.h Queue.h
$(CC) $(WARNING_FLAGS) -c outputwriter.c
Queue.o: Queue.c Queue.h
$(CC) $(WARNING_FLAGS) -c Queue.c
clean:
rm $(EXE) *.o
rm -rf $(SCAN_BUILD_DIR)
scan-build: clean
scan-build -o $(SCAN_BUILD_DIR) make
scan-view: scan-build
firefox -new-window $(SCAN_BUILD_DIR)/*/index.html