X-Git-Url: http://rtime.felk.cvut.cz/gitweb/can-benchmark.git/blobdiff_plain/0facbaa1d87d74135e8af6008b26f3e03ed8b386..48bc9235892fd71da18c5a00b26804e93de18c72:/gw-tests/Makefile diff --git a/gw-tests/Makefile b/gw-tests/Makefile index d496337..c042d2f 100644 --- a/gw-tests/Makefile +++ b/gw-tests/Makefile @@ -1,19 +1,35 @@ T=$(filter-out lib.sh,$(wildcard *.sh)) -.PHONY: $(T) +.PHONY: $(T:%=run-%) -all: $(T) html +all: $(T:%=run-%) html @echo "Run 'make plot' to generate graphs" -TEST_FLAGS = -P +TEST_FLAGS = -P -t all -$(T):%: - ./$@ $(TEST_FLAGS) +$(T:%=run-%):run-%: + ./$* $(TEST_FLAGS) -.PHONY: plot -plot: - $(MAKE) TEST_FLAGS="-p -X" +.PHONY: plot plotall + +PLOT_SCRIPTS=$(shell find results -name plot.sh) + +define plot_template +plot: $1/thumb +$1/thumb: $1/plot.sh $(notdir $1).sh $(wildcard $1/*.txt) + $1/plot.sh -X +endef + +define plotall_template +plotall: plot-$1 +.PHONY: plot-$1 +plot-$1: + $1/plot.sh -X +endef + +$(foreach result_dir,$(PLOT_SCRIPTS:%/plot.sh=%),$(eval $(call plot_template,$(result_dir)))) +$(foreach result_dir,$(PLOT_SCRIPTS:%/plot.sh=%),$(eval $(call plotall_template,$(result_dir)))) .PHONY: html html: - ./genhtml.py results + ./genhtml/genhtml.py results