# # Makefile for generating HTML slides from DocBook XML # Created by Dan York (dyork@Lodestar2.com) # # $Id: Makefile,v 1.1 2001/11/05 03:27:42 dyork Exp $ # # It assumes that you will have a directory containing the following: # # - your DocBook XML file # - a CSS file for formatting # - a graphics subdirectory that includes the arrows that will be # used for navigation # # The makefile will then create a subdirectory 'html' for the # regular (non-frames) slides and a subdir 'frames' for the frames versions. # # It also assumes you have xsltproc installed. # # Within the Slides stylesheets, it assumes that you have modified # 'xsl/slides.xsl' to have the correct path to where you have installed # the 'chunk.xsl' stylesheet that is part of the DocBook XSL stylesheets # created by Norman Walsh. # # Additionally, it assumes that you have both Norman's "Slides 1.1" # release as well as his "experimental" version from SourceForge CVS. # In the experimental stylesheets, there is also a 'xsl/frames.xsl' # stylesheet that has some parameters that can be set. # # Version 1.1 of the Slides stylesheets generated both a frames and # nonframes version from the same stylesheet. The experimental stylesheet # has two different XSL files depending upon whether you want frames. # The name of the source XML file SOURCE = docbook-tutorial.xml # The release from SF CVS #HTMLXSL = /usr/share/sgml/docbook/slides-2.1b2/xsl/slides.xsl #FRMXSL = /usr/share/sgml/docbook/slides-2.1b2/xsl/frames.xsl HTMLXSL = ../slides-custom.xsl FRMXSL = ../slides-custom-frames.xsl # Directories in which to build slides HTMLDIR = html FRAMESDIR = frames # Directory where the graphics are kept - copied into HTML and FRAMES DIR GRAPHICSDIR = graphics # The name of the CSS file used for formatting. CSSFILE = slides.css help: @echo @echo "---------------------------------------------------------" @echo "This makefile contains the following targets:" @echo @echo "setup - creates subdirectories for for frames and html" @echo "html - builds with the slides 1.1 stylesheet" @echo "exp - builds with the slides CVS stylesheet" @echo "frames - builds with the frames CVS stylesheet" @echo "clean - removes all the html files" @echo "clean-all - removes the html and frames subdirs" @echo "---------------------------------------------------------" @echo setup: mkdir ${HTMLDIR} mkdir ${FRAMESDIR} cp -r ${GRAPHICSDIR} ${HTMLDIR} cp -r ${GRAPHICSDIR} ${FRAMESDIR} cp ${CSSFILE} ${HTMLDIR} cp ${CSSFILE} ${FRAMESDIR} # The 'force' dependency was thrown in because I couldn't get the darn # thing to build one day... html: force (cd ${HTMLDIR};xsltproc ${HTMLXSL} ../${SOURCE}) frames: force (cd ${FRAMESDIR};xsltproc ${FRMXSL} ../${SOURCE}) clean: @echo @echo -n "Removing all HTML files..." @rm ${FRAMESDIR}/*.html @rm ${HTMLDIR}/*.html @echo " done." @echo clean-all: @echo @echo -n "Removing all subdirectories..." @rm -rf ${FRAMESDIR} @rm -rf ${HTMLDIR} @echo " done." @echo "Run 'make setup' to recreate the directories." @echo force: