GitBucket
4.21.2
Toggle navigation
Snippets
Sign in
Files
Branches
1
Releases
Issues
1
Pull requests
Labels
Priorities
Milestones
Wiki
Forks
nigel.stanger
/
Handbook
Browse code
• Fixed bug with whitespace in LATEX_OPTS variable that caused LaTeX to ignore the options entirely.
master
1 parent
0f39cd6
commit
433fe312b7beca23002bc7aac03980fd9b33d20a
Nigel Stanger
authored
on 25 Feb 2014
Patch
Showing
1 changed file
make-includes/standard_environment.make
Ignore Space
Show notes
View
make-includes/standard_environment.make
################################################################################ # # Specify standard environmental variables. These can be either actual # shell environment variables, or make variables. # ################################################################################ ################################################################################ # # Various environment variables. # # Set DRAFT to "draft" to run LaTeX in draft mode (i.e., make DRAFT=draft xxx). # DRAFT= # # Set PAPER_SIZE to an appropriate LaTeX value to change the paper size # (e.g., make PAPER_SIZE=letterpaper xxx). # ifndef PAPER_SIZE PAPER_SIZE=a4paper endif # # Set FONT_SIZE to an appropriate LaTeX value to change the font size # (e.g., make FONT_SIZE=10pt xxx). # ifndef FONT_SIZE FONT_SIZE=12pt endif # # Specify LaTeX document options (comma-separated list). # We need to add a comma if there is something there already! # ifdef LATEX_OPTS LATEX_OPTS+=, endif LATEX_OPTS+=$(FONT_SIZE),$(PAPER_SIZE),$(DRAFT) # LaTeX doesn't like white space in document class options (it basically stops # when it hits the first occurrence), so we need to strip these out. Unfortunately # this is (as many things) inordinately difficult to do within make, so let's # just drop out to the shell and use tr. Note use of := to avoid recursive # expansion. LATEX_OPTS:=$(shell echo "$(LATEX_OPTS)" | tr -d ' ') # # List of standard "phony" build targets. # TARGETS+=all debug test clean tidy targets
################################################################################ # # Specify standard environmental variables. These can be either actual # shell environment variables, or make variables. # ################################################################################ ################################################################################ # # Various environment variables. # # Set DRAFT to "draft" to run LaTeX in draft mode (i.e., make DRAFT=draft xxx). # DRAFT= # # Set PAPER_SIZE to an appropriate LaTeX value to change the paper size # (e.g., make PAPER_SIZE=letterpaper xxx). # ifndef PAPER_SIZE PAPER_SIZE=a4paper endif # # Set FONT_SIZE to an appropriate LaTeX value to change the font size # (e.g., make FONT_SIZE=10pt xxx). # ifndef FONT_SIZE FONT_SIZE=12pt endif # # Specify LaTeX document options (comma-separated list). # We need to add a comma if there is something there already! # ifdef LATEX_OPTS LATEX_OPTS+=, endif LATEX_OPTS+=$(FONT_SIZE),$(PAPER_SIZE),$(DRAFT) # # List of standard "phony" build targets. # TARGETS+=all debug test clean tidy targets
Show line notes below