#### macro definitions all: devdoc.pdf PDFLATEX=pdflatex LATEX2HTML=latex2html htmldocoptions_all=-local_icons \ -html_version 4.0,math \ -no_math \ -scalable_fonts \ -accent_images textrm \ -t "eisfair Entwickler-Dokumentation $*" \ -split +1 \ -short_index \ -link 4 \ -toc_depth 4 \ -noinfo \ -noaccent_images \ -mkdir \ -dir=$(outputdir)/$* htmldocoptions= -local_icons \ -html_version 4.0,math \ -no_math \ -scalable_fonts \ -accent_images textrm \ -t "eisfair Entwickler-Dokumentation $*" \ -split 0 \ -link 4 \ -no_info \ -mkdir \ -dir=$(outputdir)/$* outputdir=$(CURDIR)/output tmpvar= .PHONY: clean all devdoc.pdf: *.tex if ! $(PDFLATEX) -file-line-error-style -interaction=errorstopmode \ devdoc.tex; then \ grep -e '.*[[:alnum:]]*.tex:[0-9]\+:' devdoc.log ;\ rm -f devdoc.pdf ; \ false; \ fi makeindex devdoc.idx $(PDFLATEX) devdoc.tex $(PDFLATEX) devdoc.tex devdoc.html: *.tex $(LATEX2HTML) $(htmldocoptions_all) devdoc.tex clean: rm -f *.aux *.toc *.ind *.out *.log *.idx *~ *.ilg distclean: rm -f *.aux *.toc *.pdf *.ps *.ind *.out *.log *.idx *~ *.ilg rm -rf $(outputdir) %.html: $(outputdir)/%.tex $(LATEX2HTML) $(htmldocoptions) $^ %.txt: %.html sed -e 's/ä/ae/g' -e 's/ö/oe/g' -e 's/ü/ue/g' -e 's/Ä/Ae/g' -e 's/Ö/Oe/g' -e 's/Ü/Ue/g' -e 's/ß/ss/g' output/$*/$*.html > $(outputdir)/$*/$*.tmp ; \ lynx -dump -force_html $(outputdir)/$*/$*.tmp > $(outputdir)/$*/$*.txt ; \ rm $(outputdir)/$*/$*.tmp %.pdf: $(outputdir)/%.tex $(PDFLATEX) $^ if [ -e $*.idx ]; then makeindex $*.idx; fi $(PDFLATEX) $^ $(PDFLATEX) $^ mv $(CURDIR)/$*.pdf $(outputdir) $(outputdir)/%.tex: $(outputdir) %.tex (echo "\documentclass[twoside=false,index=totoc]{scrbook}"; \ echo "\usepackage{devdoc}"; \ echo "\makeindex"; \ echo "\begin{document}"; \ echo "\input{$*}"; \ echo "\end{document}") > $(outputdir)/$*.tex $(outputdir): if [ ! -d $(outputdir) ];then mkdir $(outputdir);fi -include ../config.txt public: clean devdoc.pdf devdoc.html if [ ! -f ../config.txt ]; then \ echo "inBerlinUser=" > ../config.txt; \ echo "Config file '../config.txt' created. Modify it according to your account"; \ elif [ -z "${inBerlinUser}" ]; then \ echo "Please insert your account name into '../config.txt'!"; \ else \ scp devdoc.pdf $(outputdir)/*.html $(outputdir)/*.jpg $(outputdir)/*.png ${inBerlinUser}@kudu.in-berlin.de:~/devdoc ; \ fi