X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=tests%2FMakefile;h=ce0399b2e0ca7a8cf078696e148550426ac39bea;hb=94ed9ea85989c086a0d2ba11d48aef9d1e2e8951;hp=b5ff710a4074914ef7424ea5f027396c2cc5cb4e;hpb=9cbd07cbe591828ca8a5dc7f7f67848b71f0afc4;p=pintos-anon diff --git a/tests/Makefile b/tests/Makefile index b5ff710..ce0399b 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -21,15 +21,16 @@ cd $@/src && $(MAKE) clean $(SUBMAKEFLAGS) endef define run-tests -cd $@/src/$(PROJECT) && make check +cd $@/src/$(PROJECT) && $(MAKE) check endef define run-tests-grade -cd $@/src/$(PROJECT) && make check && make grade +cd $@/src/$(PROJECT) && $(MAKE) check +cd $@/src/$(PROJECT) && $(MAKE) grade && grep -q PERFECT build/grade endef define compile -cd $@/src/$(PROJECT) && make +cd $@/src/$(PROJECT) && $(MAKE) endef define clean @@ -53,6 +54,9 @@ userprog vm filesys:: $(compile) $(clean) +FAST_SIM := $(if $(shell which qemu),--qemu) +export PINTOSOPTS + p1: PROJECT = threads p1:: $(mk-sandbox) @@ -61,6 +65,7 @@ p1:: $(clean) p2: PROJECT = userprog +p2: PINTOSOPTS = $(FAST_SIM) p2:: $(mk-sandbox) $(apply-patch) < ../solutions/p2.patch @@ -68,6 +73,7 @@ p2:: $(clean) p3: PROJECT = vm +p3: PINTOSOPTS = $(FAST_SIM) p3:: $(mk-sandbox) $(apply-patch) < ../solutions/p3.patch @@ -75,6 +81,7 @@ p3:: $(clean) p4: PROJECT = filesys +p4: PINTOSOPTS = $(FAST_SIM) p4:: $(mk-sandbox) $(apply-patch) < ../solutions/p4.patch