make plot creates only missing graphs
authorMichal Sojka <sojkam1@fel.cvut.cz>
Thu, 9 Dec 2010 13:01:30 +0000 (14:01 +0100)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Thu, 9 Dec 2010 13:01:30 +0000 (14:01 +0100)
make plotall recreates everything

gw-tests/Makefile
gw-tests/lib.sh

index ac9760f..2ede079 100644 (file)
@@ -10,9 +10,18 @@ TEST_FLAGS = -P -t all
 $(T):%:
        ./$@ $(TEST_FLAGS)
 
-.PHONY: plot
-plot:
-       find results -name plot.sh -exec '{}' -X ';'
+.PHONY: plot plotall
+PLOT_SCRIPTS=$(shell find results -name plot.sh)
+THUMBS=$(PLOT_SCRIPTS:%/plot.sh=%/thumb)
+plot: $(THUMBS)
+%/thumb: %/plot.sh
+       $*/plot.sh -X
+
+plotall: $(PLOT_SCRIPTS:%=run-%)
+run-%: %
+       $* -X
+
+
 
 .PHONY: html
 html:
index 4c4274d..5108f8d 100644 (file)
@@ -121,8 +121,8 @@ _run() {
        mkdir -p $dir
        script=$(echo $dir | sed -e 's/[^/]*/../g')/${test}.sh
        cd $dir
-       echo "Working directory: $dir"
        if [[ ! "$OPT_PLOT_ONLY" ]]; then
+           echo "Working directory: $dir"
            _measure
        fi
        if [[ ! "$OPT_PLOT_DISABLE" ]]; then