diff options
Diffstat (limited to 'manual/Makefile')
-rw-r--r-- | manual/Makefile | 45 |
1 files changed, 22 insertions, 23 deletions
diff --git a/manual/Makefile b/manual/Makefile index 5c18cb96db..4fa647f44a 100644 --- a/manual/Makefile +++ b/manual/Makefile @@ -2,37 +2,36 @@ DOCNAME = ardour_manual # Default values, only set if not set in book Makefile -XMLFILE ?= tmp/xml/$(DOCNAME).xml -XSLFILE ?= tmp/xsl/html.xsl -CSSFILE ?= tmp/$(DOCNAME).css -XMLTO ?= xmlto -XSLTPROC ?= xsltproc -PWD = $(shell pwd) - -xml:: clean - -@mkdir tmp - # copy all the necessary files to the build directory - -@cp -rf xml tmp/xml - -@cp -rf xsl tmp/xsl - -@cp -rf images tmp/images - -.PHONY : xml - -html:: xml - # generate html - LANG=en_US.UTF-8 $(XMLTO) -x $(XSLFILE) -o tmp/ html $(XMLFILE) - # copy css file to html directory - -@cp -f css/$(DOCNAME).css $(CSSFILE) +OUTDIR ?= tmp +XMLFILE ?= xml/$(DOCNAME).xml +XSLFILE ?= xsl/html.xsl +CSSFILE ?= $(DOCNAME).css +XSLTPROC ?= xsltproc +#PWD = $(shell pwd) + +# xsltproc -output option gives I/O errors because??, so +# just move the html to the output directory +html:: clean + # creating output directory + -@mkdir $(OUTDIR) + # generating html + LANG=en_US.UTF-8 $(XSLTPROC) -xinclude $(XSLFILE) $(XMLFILE) + # copy html files to output directory + -@mv *.html $(OUTDIR) + # copy css file to output directory + -@cp css/$(CSSFILE) $(OUTDIR)/$(CSSFILE) + # copy the image files to the output directory + -@cp -r images $(OUTDIR)/images .PHONY : html -test:: xml +test:: xmllint --noout --postvalid --xinclude $(XMLFILE) .PHONY : test clean:: - @rm -rf tmp + @rm -rf $(OUTDIR) .PHONY : clean |