Declaration of 'pause' from robotfindskitten has conflicting types for 'pause' from...
[kugel-rb.git] / manual / Makefile
blobde86edef5add4cf2b310a35ef1dea1d927f4d3b8
1 # __________ __ ___.
2 # Open \______ \ ____ ____ | | _\_ |__ _______ ___
3 # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
4 # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
5 # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
6 # \/ \/ \/ \/ \/
7 # $Id$
10 # Needed to build the features list.
11 INCLUDES= $(TARGET_INC) -I$(FIRMDIR)/include -I$(FIRMDIR)/export -I. -I$(BUILDDIR) \
12 -I$(BUILDDIR)/bitmaps -I$(OBJDIR)
14 .PHONY: all buildmanual clean
15 MANFILE := rockbox-build
17 VERSION= `$(TOOLSDIR)/version.sh $(ROOTDIR)`
19 all: manual-pdf
21 features: $(OBJDIR)/features
23 manual-prep: rockbox.tex
24 @if [ "$(OBJDIR)" = "" ]; then echo Run make in you build directory!; false; fi
25 @mkdir -p $(OBJDIR)
26 @find * -type d \! -regex '.*\.svn.*' -exec mkdir -p $(OBJDIR)/{} \;
27 @find * -type f \! -regex '.*\.svn.*' -exec cp {} $(OBJDIR)/{} \;
28 @printf "%s%%" $(VERSION) > $(OBJDIR)/version.tex
29 @perl credits.pl < $(DOCSDIR)/CREDITS > $(OBJDIR)/CREDITS.tex
30 @printf "\\\\newcommand{\\\\platform}{${MANUALDEV}}\n" > $(OBJDIR)/$(MANFILE).tex
31 @printf "\\\\newcommand{\\\\buildversion}{$(VERSION)}\n" >> $(OBJDIR)/$(MANFILE).tex
32 @printf "\\\\input{rockbox.tex}\n" >> $(OBJDIR)/$(MANFILE).tex
33 @mv $(OBJDIR)/Makefile.pdflatex $(OBJDIR)/Makefile
35 $(OBJDIR)/features: $(ROOTDIR)/apps/features.txt
36 $(SILENT)mkdir -p `dirname $@`
37 $(SILENT)cat $< | $(HOSTCC) -DMEMORYSIZE=$(MEMORYSIZE) $(INCLUDES) \
38 $(TARGET) $(DEFINES) $(EXTRA_DEFINES) -E -P -imacros "config.h" -imacros "button.h" - | \
39 grep -v "^\#" | grep -v "^$$" > $@; \
40 for f in `cat $(OBJDIR)/features`; do feat="$$feat\\n\\\\edef\\\\UseOption{\\\\UseOption,$$f}" ; done ; \
41 printf "$$feat" >$(OBJDIR)/features.tex
43 manual-pdf: features manual-prep rockbox.tex
44 $(MAKE) -C $(OBJDIR) buildmanual
46 manual-html: features manual-prep rockbox.tex
47 $(MAKE) -C $(OBJDIR) buildhtml
49 manual-txt: manual-html
50 $(MAKE) -C $(OBJDIR) buildtxt
52 manual-txt-zip: manual-txt
53 $(MAKE) -C $(OBJDIR) txtzip
55 manual-zip: manual-html
56 $(MAKE) -C $(OBJDIR) htmlzip
58 clean:
59 @if [ "$(OBJDIR)" = "" ]; then echo Run make in you build directory!; false; fi
60 @rm -rf $(OBJDIR)/manual $(OBJDIR)/*.pdf
61 @rm -rf $(OBJJDIR)/html $(OBJDIR)/txt