From e9faaa3129f74c91313e5bbcf658d891bd351319 Mon Sep 17 00:00:00 2001 From: Enrico Tassi Date: Fri, 20 Apr 2018 10:24:01 +0200 Subject: Fix the script that generates the doc --- docs/htmldoc/Makefile | 32 ++++++++++++++------------------ mathcomp/Makefile | 3 ++- 2 files changed, 16 insertions(+), 19 deletions(-) diff --git a/docs/htmldoc/Makefile b/docs/htmldoc/Makefile index d565125..e4ef690 100644 --- a/docs/htmldoc/Makefile +++ b/docs/htmldoc/Makefile @@ -4,29 +4,25 @@ ifeq "$(COQBIN)" "" COQBIN=$(dir $(shell which coqtop))/ endif -SRC=$(shell cd ../mathcomp; ls */*.v | grep -v attic/) -HEAD=$(shell git symbolic-ref HEAD) -ifeq "$(HEAD)" "refs/heads/master" -LAST=$(shell git tag -l --sort=v:refname "mathcomp-*" | tail -n 1) -RELEASED=$(shell git show $(LAST):mathcomp/Make | grep 'v *$$' | cut -d / -f 2 | cut -d . -f 1) -endif +SRC=$(shell grep 'v *$$' ../../mathcomp/Make) all: - $(H) git diff-index --quiet HEAD ||\ + $(H) git diff-index HEAD ||\ (echo error: uncommitted files; exit 1) - $(H) cd ../mathcomp;\ + $(H) cd ../../mathcomp;\ $(COQBIN)/coqdep -R . mathcomp $(SRC) 2>/dev/null |\ - grep -v vio: > ../htmldoc/depend - $(H) cat depend | ./buildlibgraph cytoscape $(RELEASED) > depend.js - $(H) . ../etc/utils/builddoc_lib.sh; \ - cd ../mathcomp; mangle_sources $(SRC) - $(H) make -C ../mathcomp clean - $(H) make -C ../mathcomp -j2 - $(H) cd ../mathcomp; $(COQBIN)/coqdoc -t "Mathematical Components"\ + grep -v vio: > ../docs/htmldoc/depend + $(H) cat depend | ./buildlibgraph cytoscape $(SRC) > depend.js + $(H) . ../../etc/utils/builddoc_lib.sh; \ + cd ../../mathcomp; mangle_sources $(SRC) + $(H) make -C ../../mathcomp clean + $(H) make -C ../../mathcomp -j2 + $(H) cd ../../mathcomp; \ + $(COQBIN)/coqdoc -t "Mathematical Components"\ -g --utf8 -R . mathcomp \ --parse-comments \ - --multi-index $(SRC) -d ../htmldoc/ - $(H) cp ../etc/artwork/coqdoc.css . - $(H) cd ../mathcomp; git checkout $(SRC) + --multi-index $(SRC) -d ../docs/htmldoc/ + $(H) cp ../../etc/artwork/coqdoc.css . + $(H) cd ../../mathcomp; git checkout $(SRC) diff --git a/mathcomp/Makefile b/mathcomp/Makefile index e45d627..07f1869 100644 --- a/mathcomp/Makefile +++ b/mathcomp/Makefile @@ -23,7 +23,8 @@ MAKEFLAGS+=-B -f Makefile.coq $* \ COQDEP='$(COQDEP) -exclude-dir plugin -c' -clean: +clean: + $(H)[ -e Makefile.coq ] || $(call coqmakefile,ssreflect) $(H)MAKEFLAGS="$(OLD_MAKEFLAGS)" $(MAKE) --no-print-directory \ -f Makefile.coq clean $(H)rm -f Makefile.coq -- cgit v1.2.3