Ticket #3035: rough_epub_makefile.patch
File rough_epub_makefile.patch, 1.3 KB (added by , 13 years ago) |
---|
-
Makefile
old new 5 5 ROOT_ID = 6 6 PDF_OUTPUT = LFS-BOOK.pdf 7 7 NOCHUNKS_OUTPUT = LFS-BOOK.html 8 EPUB_OUTPUT = LFS-BOOK.epub 8 9 SHELL = /bin/bash 9 10 10 11 ifdef V … … 59 60 fi; 60 61 $(Q)fop $(RENDERTMP)/lfs-pdf.fo $(BASEDIR)/$(PDF_OUTPUT) 61 62 63 epub: validate 64 @echo "Generating HTML/XML for EPUB..." 65 $(Q)if [ ! -e $(BASEDIR) ]; then \ 66 mkdir -p $(BASEDIR); \ 67 fi; 68 $(Q)mkdir -p $(RENDERTMP)/lfs-epub 69 $(Q)xsltproc --nonet --output $(RENDERTMP)/lfs-epub/ \ 70 stylesheets/lfs-xsl/docbook-xsl-1.76.1/epub/docbook.xsl \ 71 $(RENDERTMP)/lfs-full.xml &>/dev/null 72 73 @echo "Generating EPUB file..." 74 $(Q)echo "application/epub+zip" > $(RENDERTMP)/lfs-epub-mimetype 75 $(Q)zip -0Xq $(BASEDIR)/$(EPUB_OUTPUT) $(RENDERTMP)/lfs-epub-mimetype 76 $(Q)zip -Xr9Dq $(BASEDIR)/$(EPUB_OUTPUT) $(RENDERTMP)/lfs-epub/* 77 62 78 nochunks: validate profile-html 63 79 @echo "Generating non chunked XHTML file..." 64 80 $(Q)xsltproc --nonet -stringparam rootid "$(ROOT_ID)" \ … … 80 96 $(Q)[ -d $(RENDERTMP) ] || mkdir -p $(RENDERTMP) 81 97 $(Q)rm -f $(RENDERTMP)/lfs-{full,html,pdf}.xml 82 98 $(Q)rm -f $(RENDERTMP)/lfs-pdf.fo 99 $(Q)rm -rf $(RENDERTMP)/lfs-epub* 83 100 84 101 validate: tmpdir 85 102 @echo "Processing bootscripts..."