coqbooks/Makefile

28 lines
727 B
Makefile
Raw Normal View History

2023-01-04 11:04:31 -05:00
# 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
2023-01-11 10:55:50 -05:00
cd $(source); coqc `basename $<`
2023-01-04 11:04:31 -05:00
coqdoc --html --no-index -d ./html/ $<
2023-01-04 11:11:11 -05:00
scp $@ baruchel@sdf.org:public_html/coqbooks/
2023-01-04 11:04:31 -05:00
.PHONY : clean
clean:
rm -f $(output)/*.html $(output)/*.css