From 04a82866e038c39b0748e378bc29bde21acc774c Mon Sep 17 00:00:00 2001 From: Jose Antonio Ortega Ruiz Date: Tue, 8 Sep 2009 16:35:24 +0200 Subject: codesize latex parameter --- noweb.mk | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/noweb.mk b/noweb.mk index f620752..02e83cb 100644 --- a/noweb.mk +++ b/noweb.mk @@ -29,10 +29,13 @@ NW_LINEFORMAT ?= -L"\# %L \"%F\" %N" NW_MAIN ?= main NW_DOCUMENT_CLASS ?= report NW_CONTENTS ?= contents.tex +NW_CODESIZE ?= smallcode NW_HYPER ?= yes NW_HYPER_OPTIONS ?= "colorlinks=true,linkcolor=blue" -f_notangle = $(NOTANGLE) $(NW_LINEFORMAT) -R$(2) $(1) | $(CPIF) $(2); +f_tabbed = $(if $(subst Makefile,,$(1)),,-t8) +f_notangle = $(NOTANGLE) $(NW_LINEFORMAT) $(call f_tabbed,$(2)) -R$(2) $(1) \ + | $(CPIF) $(2); f_latex = $(1) '\scrollmode \input '"$(2)";\ while grep -s 'Rerun to get cross-references right' $(2).log;\ do $(1) '\scrollmode \input '"$(2)"; done @@ -74,11 +77,14 @@ $(main_tex): $(nw_contents_files) $(main_defs) $(tex_files) \ @echo "\usepackage{noweb}" >> $(main_tex) @echo "\noweboptions{longchunks}" >> $(main_tex) @echo "\noweboptions{externalindex}" >> $(main_tex) + @echo "\noweboptions{$(NW_CODESIZE)}" >> $(main_tex) @if [ ! -z $(NW_LANGUAGES) ]; \ then echo "\usepackage[$(NW_LANGUAGES)]{babel}" >> $(main_tex); fi @echo "\usepackage[utf8]{inputenc}" >> $(main_tex) @for f in $(NW_PACKAGES); do echo "\usepackage{$$f}" >> $(main_tex); \ done + @for f in $(NW_PACKAGES_OPT); do echo "\usepackage$$f" >> $(main_tex); \ + done @if [ "x$(HW_HYPER)" != "xno" ]; \ then echo "\usepackage[$(NW_HYPER_OPTIONS)]{hyperref}" >> $(main_tex); fi @echo "\begin{document}" >> $(main_tex) -- cgit v1.2.3