Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 1 | DOCUMENT := rockbox-build |
| 2 | LATEX := pdflatex |
| 3 | include LaTeX.Rules |
| 4 | GRAPHIC_FILES:=`find . -name \*.jpg \*.jpeg` |
Dominik Riebeling | 9413c2a | 2006-07-20 18:07:46 +0000 | [diff] [blame] | 5 | HTLATEX := htlatex |
Dominik Riebeling | f15e219 | 2008-12-02 22:33:49 +0000 | [diff] [blame] | 6 | HTOPTS1 := rockbox-html,charset=utf-8,early_ |
Dominik Riebeling | 1244ab6 | 2008-12-16 22:44:22 +0000 | [diff] [blame] | 7 | HTOPTS2 := " -utf8 -cmozhtf" |
Dominik Riebeling | f15e219 | 2008-12-02 22:33:49 +0000 | [diff] [blame] | 8 | HTOPTS3 := "-dhtml/ -cvalidate" |
Rafaël Carré | cdc4245 | 2010-05-30 23:18:06 +0000 | [diff] [blame] | 9 | VERSION=`$(TOOLSDIR)/version.sh $(ROOTDIR)` |
Dominik Riebeling | 19f2456 | 2011-06-19 09:41:13 +0000 | [diff] [blame] | 10 | SPLITHTML ?= 2 |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 11 | |
| 12 | .PHONY: all cleaner buildmanual output |
| 13 | |
Dominik Riebeling | abac739 | 2006-10-23 18:09:38 +0000 | [diff] [blame] | 14 | buildmanual: rockbox-build.tex pdf |
Dominik Riebeling | 3ed5de8 | 2008-08-31 21:18:21 +0000 | [diff] [blame] | 15 | @cp $(OBJDIR)/rockbox-build.pdf $(OBJDIR)/../rockbox-$(MODELNAME)-$(VERSION).pdf |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 16 | |
Dominik Riebeling | 9413c2a | 2006-07-20 18:07:46 +0000 | [diff] [blame] | 17 | buildhtml: rockbox-build.tex |
| 18 | @mkdir -p $(OBJDIR)/html |
Frank Gevaerts | 3d98386 | 2015-01-12 12:18:04 +0100 | [diff] [blame] | 19 | @$(HTLATEX) $(DOCUMENT) "$(HTOPTS1),$(SPLITHTML)" $(HTOPTS2) $(HTOPTS3) </dev/null |
Dominik Riebeling | e9e0cf5 | 2011-06-19 15:43:41 +0000 | [diff] [blame] | 20 | @cp --parent `cat $(OBJDIR)/html/*.html | sed -e '/\.js/!d;s/.*\"\(.*\.js\)\".*/\1/g;/</d' | uniq` $(OBJDIR)/html |
Dominik Riebeling | 1c3c171 | 2006-08-03 00:08:43 +0000 | [diff] [blame] | 21 | @cp --parent `cat $(OBJDIR)/html/*.html | sed -e '/[pj][np]g/!d;s/.*\"\(.*\.[pj][np]g\)\".*/\1/g;/</d'` $(OBJDIR)/html |
Dominik Riebeling | 9413c2a | 2006-07-20 18:07:46 +0000 | [diff] [blame] | 22 | @cp -r $(OBJDIR)/html $(OBJDIR)/../ |
Dominik Riebeling | 19f2456 | 2011-06-19 09:41:13 +0000 | [diff] [blame] | 23 | |
Dominik Riebeling | abac739 | 2006-10-23 18:09:38 +0000 | [diff] [blame] | 24 | buildtxt: buildhtml |
| 25 | @mkdir -p $(OBJDIR)/txt |
| 26 | @(cd $(OBJDIR)/txt; for i in $(OBJDIR)/html/*.html; do \ |
| 27 | links -dump -no-numbering -no-references $$i > `basename $$i html`txt; \ |
| 28 | done) |
| 29 | @cp -r $(OBJDIR)/txt $(OBJDIR)/../ |
Dominik Riebeling | 9413c2a | 2006-07-20 18:07:46 +0000 | [diff] [blame] | 30 | |
| 31 | htmlzip: buildhtml |
Daniel Stenberg | b34c8fc | 2006-07-23 10:37:28 +0000 | [diff] [blame] | 32 | @(cd $(OBJDIR); \ |
| 33 | zip -r $(OBJDIR)/rockbox-manual.zip html; \ |
| 34 | cp $(OBJDIR)/rockbox-manual.zip $(OBJDIR)/../ ) |
Dominik Riebeling | abac739 | 2006-10-23 18:09:38 +0000 | [diff] [blame] | 35 | |
| 36 | txtzip: buildtxt |
| 37 | @(cd $(OBJDIR); \ |
| 38 | zip -r $(OBJDIR)/rockbox-manual-txt.zip txt; \ |
| 39 | cp $(OBJDIR)/rockbox-manual-txt.zip $(OBJDIR)/../ ) |
| 40 | |