X-Git-Url: https://git.distorted.org.uk/~mdw/sod/blobdiff_plain/ddfe426573957fa52102832a51582bb134ee7b42..b20e5e2658691754756e99829e578f8e2df3aaa9:/doc/Makefile.am diff --git a/doc/Makefile.am b/doc/Makefile.am index 1037032..6647f48 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -7,7 +7,7 @@ ###----- Licensing notice --------------------------------------------------- ### -### This file is part of the Sensble Object Design, an object system for C. +### This file is part of the Sensible Object Design, an object system for C. ### ### SOD is free software; you can redistribute it and/or modify ### it under the terms of the GNU General Public License as published by @@ -31,6 +31,28 @@ TEX_FILES = CLEANFILES += *.aux *.out *.log *.toc *.ind *.idx *.ilg EXTRA_DIST += $(TEX_FILES) +TEXFLAGS = --interaction=batchmode \ + --output-directory=$(abs_builddir) +BIBTEXFLAGS = --terse +MAKEINDEXFLAGS = -q + +V_LATEX = $(V_LATEX_@AM_V@) +V_LATEX_ = $(V_LATEX_@AM_DEFAULT_V@) +V_LATEX_0 = @echo " LATEX $@"; + +V_BIBTEX = $(V_BIBTEX_@AM_V@) +V_BIBTEX_ = $(V_BIBTEX_@AM_DEFAULT_V@) +V_BIBTEX_0 = @echo " BIBTEX $@"; + +V_MAKEINDEX = $(V_MAKEINDEX_@AM_V@) +V_MAKEINDEX_ = $(V_MAKEINDEX_@AM_DEFAULT_V@) +V_MAKEINDEX_0 = @echo " MAKEIDX $@"; + +run_pdflatex = $(V_LATEX)cd $(srcdir) && \ + $(PDFLATEX) $(TEXFLAGS) \ + --jobname=$(basename $1) \ + '\def\pkgversion{$(VERSION)}\input{$1}' + ###-------------------------------------------------------------------------- ### The manual. @@ -40,10 +62,14 @@ TEX_FILES += sod.tex ## Main document styling and definitions. TEX_FILES += sod.sty +## The introduction. +TEX_FILES += intro.tex + ## Tutorial. TEX_FILES += tutorial.tex ## Reference. +TEX_FILES += refintro.tex TEX_FILES += concepts.tex ##TEX_FILES += cmdline.tex TEX_FILES += syntax.tex @@ -65,12 +91,16 @@ TEX_FILES += cutting-room-floor.tex ## Building the output documents. MAINTAINERCLEANFILES += sod.pdf -EXTRA_DIST += sod.pdf + +if HAVE_LATEX doc_DATA += sod.pdf +EXTRA_DIST += sod.pdf sod.pdf: $(TEX_FILES) - cd $(srcdir) && pdflatex --output-directory=$(abs_builddir) sod.tex - cd $(srcdir) && pdflatex --output-directory=$(abs_builddir) sod.tex - makeindex sod.idx - cd $(srcdir) && pdflatex --output-directory=$(abs_builddir) sod.tex + $(call run_pdflatex,sod.tex) + $(V_BIBTEX)$(BIBTEX) $(BIBTEXFLAGS) sod.aux + $(call run_pdflatex,sod.tex) + $(V_MAKEINDEX)$(MAKEINDEX) $(MAKEINDEXFLAGS) sod.idx + $(call run_pdflatex,sod.tex) +endif ###----- That's all, folks --------------------------------------------------