tests/tool-command-line: skip ocamlopt on byte-only configurations

master
Gabriel Scherer 2017-01-19 08:42:12 +01:00
parent 878318123f
commit a48b2cb03b
1 changed files with 19 additions and 5 deletions

View File

@ -17,19 +17,33 @@ BASEDIR=../..
default:
@$(OCAMLOPT) unknown-file 2>&1 | grep "don't know what to do with unknown-file"\
> unknown-file.opt.result || true
$(MAKE) byte
@if $(BYTECODE_ONLY); then $(MAKE) opt-skipped ; else \
$(MAKE) opt; \
fi
byte:
@$(OCAMLC) unknown-file 2>&1 | grep "don't know what to do with unknown-file" \
> unknown-file.byte.result || true
@for file in *.byte.reference; do \
printf " ... testing '$$file':"; \
$(DIFF) $$file `basename $$file reference`result >/dev/null \
&& echo " => passed" || echo " => failed"; \
done
opt:
@$(OCAMLOPT) unknown-file 2>&1 | grep "don't know what to do with unknown-file"\
> unknown-file.opt.result || true
@for file in *.opt.reference; do \
printf " ... testing '$$file':"; \
$(DIFF) $$file `basename $$file reference`result >/dev/null \
&& echo " => passed" || echo " => failed"; \
done
@for file in *.byte.reference; do \
opt-skipped:
@for file in *.opt.reference; do \
printf " ... testing '$$file':"; \
$(DIFF) $$file `basename $$file reference`result >/dev/null \
&& echo " => passed" || echo " => failed"; \
echo " => skipped"; \
done
promote: defaultpromote