27 lines
655 B
Makefile
27 lines
655 B
Makefile
|
# Generate HTMLs from the Coq source files
|
||
|
|
||
|
# Directory containing source (Coq) files
|
||
|
source := ./src
|
||
|
|
||
|
# Directory containing pdf files
|
||
|
output := ./html
|
||
|
|
||
|
# All Coq files in src/ are considered sources
|
||
|
sources := $(wildcard $(source)/*.v)
|
||
|
|
||
|
# Convert the list of source files (Coq files in directory .)
|
||
|
# into a list of output files (HTMLs in directory ./html).
|
||
|
objects := $(patsubst %.v,%.html,$(subst $(source),$(output),$(sources)))
|
||
|
|
||
|
all: $(objects)
|
||
|
|
||
|
# Recipe for converting a Coq file into HTML using coqdoc
|
||
|
$(output)/%.html: $(source)/%.v
|
||
|
coqc $<
|
||
|
coqdoc --html --no-index -d ./html/ $<
|
||
|
|
||
|
.PHONY : clean
|
||
|
|
||
|
clean:
|
||
|
rm -f $(output)/*.html $(output)/*.css
|