Add support for using FOP or XEP as an XSL-FO backend via USE_* make
variables. PassiveTeX is pretty limited and so the other formatters give the stylesheets more functionality to create nice slides.
This commit is contained in:
parent
710862d3d0
commit
30830727e5
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/head/; revision=22239
2 changed files with 18 additions and 3 deletions
|
@ -98,6 +98,8 @@ LATEX_CMD?= ${PREFIX}/bin/latex
|
||||||
PDFTEX_CMD?= ${PREFIX}/bin/pdftex
|
PDFTEX_CMD?= ${PREFIX}/bin/pdftex
|
||||||
JADETEX_CMD?= ${TEX_CMD} "&jadetex"
|
JADETEX_CMD?= ${TEX_CMD} "&jadetex"
|
||||||
PDFJADETEX_CMD?=${PDFTEX_CMD} "&pdfjadetex"
|
PDFJADETEX_CMD?=${PDFTEX_CMD} "&pdfjadetex"
|
||||||
|
FOP_CMD?= ${PREFIX}/share/fop/fop.sh
|
||||||
|
XEP_CMD?= sh ${HOME}/XEP/xep.sh
|
||||||
|
|
||||||
# Image processing (contains code used by the doc.<format>.mk files, so must
|
# Image processing (contains code used by the doc.<format>.mk files, so must
|
||||||
# be listed first).
|
# be listed first).
|
||||||
|
|
|
@ -32,7 +32,7 @@ CSS_SHEET?=
|
||||||
|
|
||||||
SLIDES_XSLDIR= /usr/local/share/xsl/slides/xsl/
|
SLIDES_XSLDIR= /usr/local/share/xsl/slides/xsl/
|
||||||
SLIDES_XSLHTML= ${SLIDES_XSLDIR}xhtml/default.xsl
|
SLIDES_XSLHTML= ${SLIDES_XSLDIR}xhtml/default.xsl
|
||||||
SLIDES_XSLPRINT= ${SLIDES_XSLDIR}fo/plain.xsl
|
SLIDES_XSLPRINT?= ${SLIDES_XSLDIR}fo/plain.xsl
|
||||||
|
|
||||||
# Loop through formats we should build.
|
# Loop through formats we should build.
|
||||||
.for _curformat in ${FORMATS}
|
.for _curformat in ${FORMATS}
|
||||||
|
@ -45,11 +45,16 @@ _docs+= ${DOC}.${_curformat}
|
||||||
CLEANFILES+= ${DOC}.${_curformat}
|
CLEANFILES+= ${DOC}.${_curformat}
|
||||||
|
|
||||||
.if ${_cf} == "pdf"
|
.if ${_cf} == "pdf"
|
||||||
CLEANFILES+= ${DOC}.fo ${DOC}.aux ${DOC}.log ${DOC}.out ${DOC}.pdf texput.log
|
CLEANFILES+= ${DOC}.fo ${DOC}.pdf
|
||||||
|
.if ! defined (USE_FOP) && ! defined (USE_XEP)
|
||||||
|
CLEANFILES+= ${DOC}.aux ${DOC}.log ${DOC}.out texput.log
|
||||||
|
.endif
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.endfor
|
.endfor
|
||||||
|
|
||||||
|
XSLTPROCFLAGS?= --nonet
|
||||||
|
XSLTPROCOPTS= ${XSLTPROCFLAGS}
|
||||||
|
|
||||||
.MAIN: all
|
.MAIN: all
|
||||||
|
|
||||||
|
@ -58,6 +63,14 @@ all: ${_docs}
|
||||||
${DOC}.html: ${SRCS}
|
${DOC}.html: ${SRCS}
|
||||||
${XSLTPROC} ${XSLTPROCOPTS} ${SLIDES_XSLHTML} ${.ALLSRC}
|
${XSLTPROC} ${XSLTPROCOPTS} ${SLIDES_XSLHTML} ${.ALLSRC}
|
||||||
|
|
||||||
${DOC}.pdf: ${SRCS}
|
${DOC}.fo: ${SRCS}
|
||||||
${XSLTPROC} ${XSLTPROCOPTS} ${SLIDES_XSLPRINT} ${.ALLSRC} > ${.TARGET:S/.pdf$/.fo/}
|
${XSLTPROC} ${XSLTPROCOPTS} ${SLIDES_XSLPRINT} ${.ALLSRC} > ${.TARGET:S/.pdf$/.fo/}
|
||||||
|
|
||||||
|
${DOC}.pdf: ${DOC}.fo
|
||||||
|
.if defined(USE_FOP)
|
||||||
|
${FOP_CMD} ${.TARGET:S/.pdf$/.fo/} ${.TARGET}
|
||||||
|
.elif defined(USE_XEP)
|
||||||
|
${XEP_CMD} ${.TARGET:S/.pdf$/.fo/} ${.TARGET}
|
||||||
|
.else
|
||||||
${PDFTEX_CMD} --interaction nonstopmode "&pdfxmltex" ${.TARGET:S/.pdf$/.fo/}
|
${PDFTEX_CMD} --interaction nonstopmode "&pdfxmltex" ${.TARGET:S/.pdf$/.fo/}
|
||||||
|
.endif
|
||||||
|
|
Loading…
Reference in a new issue