all: $(T:%=run-%) html
@echo "Run 'make plot' to generate graphs"
-TEST_FLAGS = -P -t all -l all
+TEST_FLAGS = -P -t all -l all $(if $(UPDATE),-u)
$(T:%=run-%):run-%:
./$* $(TEST_FLAGS)
PLOT_SCRIPTS=$(shell find results -name plot.sh)
define plot_template
-plot: $1/$(notdir $1).png
-$1/$(notdir $1).png: $1/plot.sh $(notdir $1).sh lib.sh $(wildcard $1/*.txt)
+plot: $1/graph.png
+$1/graph.png: $1/plot.sh $(notdir $1).sh lib.sh $(wildcard $1/*.txt)
$1/plot.sh -X
endef