forked from MIT-DB-Class/simple-db-hw
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
52 lines (40 loc) · 1.52 KB
/
Copy pathMakefile
File metadata and controls
52 lines (40 loc) · 1.52 KB
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
Lab1=TupleTest,TupleDescTest,CatalogTest,HeapPageIdTest,RecordIDTest,HeapPageReadTest,HeapFileReadTest,systemtest.ScanTest
Lab2=PredicateTest,JoinPredicateTest,FilterTest,JoinTest,systemtest.FilterTest,systemtest.JoinTest,IntegerAggregatorTest,StringAggregatorTest,AggregateTest,systemtest.AggregateTest,HeapPageWriteTest,HeapFileWriteTest,BufferPoolWriteTest,InsertTest,systemtest.InsertTest,systemtest.DeleteTest,systemtest.EvictionTest
Lab3=IntHistogramTest,TableStatsTest,JoinOptimizerTest,JoinOptimizerTest,systemtest.QueryTest
Lab4=LockingTest,DeadlockTest,TransactionTest,systemtest.TransactionTest,systemtest.AbortEvictionTest
#echo "make test ARGS=InsertTest"
ifdef L1
ARGS=$(Lab1)
endif
ifdef L2
ARGS=$(Lab2)
endif
ifdef L3
ARGS=$(Lab3)
endif
ifdef L4
ARGS=$(Lab4)
endif
.PHONY: build
build: clean
./mvnw compile
.PHONY: test
test: clean
./mvnw clean test -Dtest=$(ARGS)
.PHONY: convert-l1
convert-l1:
./mvnw exec:java -D"exec.mainClass"="simpledb.SimpleDb" -Dexec.args="convert simple_data.txt 3"
.PHONY: convert-l2
convert-l2:
./mvnw exec:java -D"exec.mainClass"="simpledb.SimpleDb" -Dexec.args='convert data/lab2.txt 2 "int,int"'
mv data/lab2.dat data/data.dat
.PHONY: catalog
catalog: build convert-l2
echo "select d.f1, d.f2 from data d;"
./mvnw exec:java -D"exec.mainClass"="simpledb.SimpleDb" -Dexec.args='parser data/catalog.txt'
.PHONY: clean
clean:
./mvnw clean
.PHONY: install
install:
./mvnw install:install-file -Dfile=lib/zql.jar -DgroupId=org.gibello -DartifactId=zql-parser -Dversion=0.0.1 -Dpackaging=jar