From: Mark Wooding Date: Thu, 18 May 2023 21:54:33 +0000 (+0100) Subject: Makefile: Include some custom LaTeX setup. X-Git-Url: https://git.distorted.org.uk/~mdw/mdwtools/commitdiff_plain/9cb5c64cc696cd59cf723021386b254ab8de5b13 Makefile: Include some custom LaTeX setup. And use it to show more error context. --- diff --git a/Makefile b/Makefile index 50a450e..3742eb7 100644 --- a/Makefile +++ b/Makefile @@ -98,6 +98,9 @@ $$(wordlist 2,$$(words $$($3_OUT)),$$($3_OUT)): \ $$(firstword $$($3_OUT)) endef +## LaTeX configuration. +LATEX_INITCMDS = \errorcontextlines=\maxdimen + ###-------------------------------------------------------------------------- ### Project specific definitions. @@ -143,10 +146,10 @@ REALCLEANFILES += $(OUT) define run-latex rm -rf t.$@/ && mkdir t.$@/ && cd t.$@/ && \ TEXINPUTS=..:$$TEXINPUTS && export TEXINPUTS && \ -$1 "\def\indexing{n} \nonstopmode \input $<" $(v_null) && \ -$1 "\def\indexing{y} \nonstopmode \input $<" $(v_null) && \ +$1 "\def\indexing{n} \nonstopmode $(LATEX_INITCMDS) \input $<" $(v_null) && \ +$1 "\def\indexing{y} \nonstopmode $(LATEX_INITCMDS) \input $<" $(v_null) && \ makeindex $(v_quiet) -s gind.ist $*.idx $(v_null) && \ -$1 "\def\indexing{n} \nonstopmode \input $<" $(v_null) && \ +$1 "\def\indexing{n} \nonstopmode $(LATEX_INITCMDS) \input $<" $(v_null) && \ mv $@ $*.log ../ && cd ../ && rm -rf t.$@/ endef CLEANFILES += *.log