1 ##############################################################################
5 # Purpose: Makefile for the clsql documentation
6 # Programer: Kevin M. Rosenberg
7 # Date Started: Mar 2002
11 # This file, part of CLSQL, is Copyright (c) 2002-2003 by Kevin M. Rosenberg
13 # CLSQL users are granted the rights to distribute and use this software
14 # as governed by the terms of the Lisp Lesser GNU Public License
15 # (http://opensource.franz.com/preamble.html), also known as the LLGPL.
16 ##############################################################################
18 DOCFILE_BASE_DEFAULT
:=clsql
19 DOCFILE_EXT_DEFAULT
:=xml
22 # Standard docfile processing
24 DEBIAN
=$(shell expr
"`cat /etc/issue 2> /dev/null`" : '.*Debian.*')
25 SUSE
=$(shell expr
"`cat /etc/issue 2> /dev/null`" : '.*SuSE.*')
26 SUSE91
=$(shell expr
"`cat /etc/issue 2> /dev/null`" : '.*SuSE Linux 9.1.*')
27 REDHAT
=$(shell expr
"`cat /etc/issue 2> /dev/null`" : '.*Red Hat.*')
28 MANDRAKE
=$(shell expr
"`cat /etc/issue 2> /dev/null`" : '.*Mandrake.*')
29 DARWIN
=$(shell expr
"`uname -a`" : '.*Darwin.*')
57 DOCFILE_BASE
=${DOCFILE_BASE_DEFAULT}
61 DOCFILE_EXT
=${DOCFILE_EXT_DEFAULT}
64 DOCFILE
:=${DOCFILE_BASE}.
${DOCFILE_EXT}
65 FOFILE
:=${DOCFILE_BASE}.fo
66 PDFFILE
:=${DOCFILE_BASE}.pdf
67 PSFILE
:=${DOCFILE_BASE}.ps
68 DVIFILE
:=${DOCFILE_BASE}.
dvi
69 TXTFILE
:=${DOCFILE_BASE}.txt
70 HTMLFILE
:=${DOCFILE_BASE}.html
71 TMPFILES
:=${DOCFILE_BASE}.aux
${DOCFILE_BASE}.out
${DOCFILE_BASE}.log
72 DOCFILES
:=$(shell echo
*.xml
*.xsl
)
78 CATALOG
:=`pwd`/catalog-
${OS}.xml
79 CHECK
:=XML_CATALOG_FILES
="$(CATALOG)" xmllint
--noout
--xinclude
--postvalid
$(DOCFILE
) || exit
1
92 @echo
"Operating system detected: ${OS}"
98 html.
tar.gz
: $(DOCFILES
) Makefile
101 @XML_CATALOG_FILES
="$(CATALOG)" $(XSLTPROC
) --stringparam chunker.output.encoding UTF-8 \
102 --xinclude
--output html
/ html_chunk.xsl
$(DOCFILE
)
103 @GZIP
='-9' tar czf html.
tar.gz html
108 ${FOFILE}: $(DOCFILES
) Makefile
109 @XML_CATALOG_FILES
="$(CATALOG)" xsltproc
--xinclude
--stringparam fop1.extensions
1 --output
$(FOFILE
) fo.xsl
$(DOCFILE
)
114 ${PDFFILE}: ${DOCFILES} Makefile
116 @fop
$(FOFILE
) -pdf
$(PDFFILE
) > /dev
/null
124 ${PSFILE}: ${DOCFILES} Makefile
126 @fop
$(FOFILE
) -ps
$(PSFILE
) > /dev
/null
132 ${TXTFILE}: ${FOFILE}
133 @XML_CATALOG_FILES
="$(CATALOG)" xsltproc
--xinclude
--output
${HTMLFILE} html.xsl
$(DOCFILE
)
134 lynx
-dump
${HTMLFILE} > ${TXTFILE}
138 @
rm -f
*~
*.bak
*.orig \
#*\# .\#* texput.log
139 @
rm -rf html
${PSFILE} ${HTMLFILE}
140 @
rm -f
${TMPFILES} ${FOFILE}
141 @
rm -f
${DVIFILE} ${TXTFILE}