# Original Makefile by Norm Walsh # modifications by Franz J. Kurfess for KM book, 317 material # W05: further modifications for 484 class # Set the SLIDESBASE variable to the name of the file (without extension) # The other settings may have to be adapted to reflect the locations # of the DocBook and XML tools # Set up directories and files for documents SLIDESBASE=1-Intro SLIDESFILE=$(SLIDESBASE).xml SLIDESHTML=$(SLIDESBASE).html # Set up directories and files for Web pages WEBROOT = ../../W05/www INDEXFILE = index.html WEBFILES = $(SLIDESBASE).html $(SLIDESBASE).pdf # sample-pdf.txt sample-HTML.txt PUBDIR = $(WEBROOT)/Slides/$(SLIDESBASE) HTMLFILES = *.html WEBSERVER = falcon.csc.calpoly.edu # Set up DocBook directories and tools DBROOT = /Users/Shared/DocBook DBSLIDESHOME=$(DBROOT)/lib/docbook/slides # Set up XLM Tools XSLTPROC=java -jar $(DBROOT)/lib/saxon/saxon.jar # XSLTPROC=java -jar $(DBROOT)/lib/fop/xalan.sh # FOPPROC=java -cp $(DBROOT)/lib/saxon/saxon-fop.jar FOPPROC=$(DBROOT)/lib/fop/fop.sh -c /Users/fkurfess/lib/DocBook/FJK-Stuff/FOP/userconfig.xml -xsl $(DBSLIDESHOME)/xsl/fo/plain-local.xsl #FOPPROC=$(DBROOT)/lib/fop/fop.sh -c /Users/fkurfess/lib/DocBook/FJK-Stuff/FOP/userconfig.xml -xsl ../xsl/fo/plain.xsl # FOPPROC=java -cp $(DBROOT)/lib/fop/lib/fop.jar;java -cp $(DBROOT)/lib/fop/lib/xerces.jar org.apache.fop.apps.CommandLine XSLT=$(XSLTPROC) $(SLIDESFILE) # Set up helper tools RS = rsync -avzu RSEXCLUDES = --exclude *~ --exclude Makefile* # Make targets and dependencies default: frames-fjk all: frames-fjk onefile pdf publish # uses frames for navigation (my preference for the actual presentation) # generates one file for each slide, which is awful for printing frames-fjk: $(SLIDESBASE).xml $(XSLT) $(DBSLIDESHOME)/xsl/xhtml/frames.xsl overlay=1 multiframe=0 dynamic.toc=0 active.toc=0 # all slides in one single html file (easier to print) onefile: $(SLIDESBASE).xml $(XSLT) $(DBSLIDESHOME)/xsl/xhtml/Slides-One-File/onefile-local.xsl > $(SLIDESBASE).html #dhtml: # uses dynamic html for easier navigation # $(XSLT) $(DBSLIDESHOME)/xsl/dhtml/DHTML-Slides/slides.xsl > $(SLIDESBASE).dhtml dhtml: # use local ../xsl/slides.xsl file $(XSLT) ../xsl/slides.xsl > $(SLIDESBASE)-D.html # needed for the generation of a PDF file # not needed anymore, pdf generated directly from XML below #fo: # @echo -n " Generating $(SLIDESBASE).fo " # rm -f *.html && $(XSLT) $(DBSLIDESHOME)/xsl/fo/plain-local.xsl > $(SLIDESBASE).fo # @echo -n " Generating $(SLIDESBASE).pdf " # $(FOPPROC) $(SLIDESBASE).fo -pdf $(SLIDESBASE).pdf # @echo -n "Done." # generate PDF file pdf: @echo -n " Generating $(SLIDESBASE).pdf " # $(FOPPROC) $(SLIDESBASE).fo $(SLIDESBASE).pdf $(FOPPROC) -xml $(SLIDESBASE).xml -pdf $(SLIDESBASE).pdf @echo -n "Done." htmlclean: rm -rf ./*html publish: $(PUBDIR) # $(WEBFILES) $(INDEXFILE) $(HTMLFILES) # @echo "Synching current directory and Web_Site Directory $(PUBDIR)" # @$(RS) $(RSEXCLUDES) ./. $(PUBDIR) @echo "Copying $(WEBFILES) to $(PUBDIR)" # @rm -f $(INDEXFILE); ln -sf $(SLIDESBASE).html $(INDEXFILE) @cp $(WEBFILES) $(PUBDIR) # @cd $(PUBDIR); \ # rm -f $(INDEXFILE); \ # ln -s $(SLIDESBASE).html $(INDEXFILE); @ls -l $(PUBDIR) @echo "done." # Still needs to be tested ... #falcon: publish # @echo "Copying $(WEBFILES) to $(WEBSERVER)" # @rs-317-www $(PUBDIR): @echo "Creating $(PUBDIR)..." @mkdir $(PUBDIR) @echo " $(PUBDIR) created" @ls -l $(PUBDIR)/* # @cd $(PUBDIR)/ @echo -n " Creating symlinks to resource directories" @ln -s ../xsl/plain . @ln -s ../xsl/resources . # @ ls -l * @echo "done."