-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
41 lines (31 loc) · 908 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
#
# Propositional Inference
# Informatics 2D
# Assignment 1
# 2016-2017
#
# Makefile
#
OBJS = Prop.o Inf2d.o Main/SatParser.o
INTERS = Prop.hi Inf2d.hi Main/SatParser.hi
SOURCE = Prop.hs Inf2d.hs Main/SatParser.hs
CC = ghc
FLAGS = -package parsec -package random -iMain -c
OFLAGS = -package parsec -package random -iMain
%.o: %.hs
$(CC) $(FLAGS) $<
%.hi: %.hs
$(CC) $(FLAGS) $<
walksat: $(OBJS) $(INTERS) Main/WalkSat.o Main/WalkSat.hi
$(CC) $(OFLAGS) $(OBJS) Main/WalkSat.o -o walksat
dpll: $(OBJS) $(INTERS) Main/Dpll.o Main/Dpll.hi
$(CC) $(OFLAGS) $(OBJS) Main/Dpll.o -o dpll
dpllv2: $(OBJS) $(INTERS) Main/Dpllv2.o Main/Dpllv2.hi
$(CC) $(OFLAGS) $(OBJS) Main/Dpllv2.o -o dpllv2
all: walksat dpll dpllv2
clean:
rm -f $(OBJS) $(INTERS) Main/WalkSat.o Main/WalkSat.hi Main/Dpll.o Main/Dpll.hi Main/Dpllv2.o Main/Dpllv2.hi
cleanall: clean
rm -f walksat dpll dpllv2
count:
wc $(SOURCE)