2009-06-27 18:38:11 +03:00
PROJECT = office-server
2009-10-22 09:13:30 +03:00
TOPLEVEL_DOC = index.txt
HTMLPAGE = $( TOPLEVEL_DOC:.txt= .html)
docdir = /usr/local/share/doc/$( PROJECT)
DESTDIR =
2009-06-27 18:38:11 +03:00
A2X = a2x
INSTALL = install
INSTALL_DATA = $( INSTALL) -m 644
.PHONY : all install clean
2009-10-22 09:13:30 +03:00
all : $( HTMLPAGE )
2009-06-27 18:38:11 +03:00
%.html : %.txt
2009-10-22 09:13:30 +03:00
$( A2X) -d book -f xhtml -a lang = ru \
--icons -r /etc/asciidoc/ -r ./ \
--xsltproc-opts= '--stringparam toc.max.depth 2' \
$<
chunked : $( TOPLEVEL_DOC )
$( A2X) -d book -f chunked -a lang = ru \
--icons -r /etc/asciidoc/ -r ./ \
--xsltproc-opts= '--stringparam toc.max.depth 2' \
$<
pdf : $( TOPLEVEL_DOC )
$( A2X) --fop --fop-opts= '-c fop.xconf' -d book -f pdf -a lang = ru \
--xsltproc-opts= '--stringparam toc.max.depth 2' \
--xsltproc-opts= '--stringparam title.font.family "Liberation Sans"' \
--xsltproc-opts= '--stringparam body.font.family "Liberation Sans"' \
--xsltproc-opts= '--stringparam monospace.font.family "Liberation Mono"' \
$<
install : all
$( INSTALL_DATA) -D $( HTMLPAGE) $( DESTDIR) $( docdir) /$( HTMLPAGE)
2009-06-27 18:38:11 +03:00
$( INSTALL) -d $( DESTDIR) $( docdir) /images/icons
2009-10-22 09:13:30 +03:00
$( INSTALL_DATA) -D docbook-xsl.css $( DESTDIR) $( docdir) /
$( INSTALL_DATA) -D images/*.png $( DESTDIR) $( docdir) /images/
$( INSTALL_DATA) -D images/icons/* $( DESTDIR) $( docdir) /images/icons/
2009-06-27 18:38:11 +03:00
clean :
2009-10-22 09:13:30 +03:00
$( RM) -r index.xml $( HTMLPAGE) docbook-xsl.css images index.chunked index.fo index.pdf *~