Generate xeplist on Docker build

This commit is contained in:
Jonas Wielicki 2017-08-23 13:26:36 +02:00
parent 609a081f27
commit aea6f78a1a
2 changed files with 8 additions and 1 deletions

View File

@ -4,10 +4,11 @@
FROM xmppxsf/xeps-base:latest FROM xmppxsf/xeps-base:latest
ARG NCORES=1 ARG NCORES=1
ARG TARGETS="html inbox-html inbox-xml pdf" ARG TARGETS="html inbox-html inbox-xml pdf xeplist"
COPY *.xml xep.* *.css *.xsl *.js *.xsl Makefile /src/ COPY *.xml xep.* *.css *.xsl *.js *.xsl Makefile /src/
COPY resources/*.pdf /src/resources/ COPY resources/*.pdf /src/resources/
COPY tools/*.py /src/tools/
COPY inbox/*.xml inbox/*.ent inbox/*.dtd /src/inbox/ COPY inbox/*.xml inbox/*.ent inbox/*.dtd /src/inbox/
WORKDIR /src WORKDIR /src

View File

@ -53,6 +53,9 @@ $(OUTDIR)/inbox/%: build/inbox
build/inbox: build/inbox:
mkdir -p build/inbox mkdir -p build/inbox
.PHONY: xeplist
xeplist: $(OUTDIR)/xeplist.xml
.PHONY: html .PHONY: html
html: $(xep_htmls) html: $(xep_htmls)
@ -86,6 +89,9 @@ xep-%.pdf: $(OUTDIR)/xep-%.pdf ;
$(all_xep_xmls): $(OUTDIR)/%.xml: %.xml $(all_xep_xmls): $(OUTDIR)/%.xml: %.xml
cp $< $@ cp $< $@
$(OUTDIR)/xeplist.xml: $(wildcard *.xml) $(wildcard inbox/*.xml)
./tools/extract-metadata.py > $@
$(EXAMPLESDIR)/%.xml: xep-%.xml $(XMLDEPS) examples.xsl $(EXAMPLESDIR) $(EXAMPLESDIR)/%.xml: xep-%.xml $(XMLDEPS) examples.xsl $(EXAMPLESDIR)
xsltproc --path $(CURDIR) examples.xsl "$<" > "$@" && echo "Finished building $@" xsltproc --path $(CURDIR) examples.xsl "$<" > "$@" && echo "Finished building $@"