Last active
March 5, 2019 23:37
-
-
Save vfrico/ef4e4a6d08b2ff187b52011054187830 to your computer and use it in GitHub Desktop.
Makefile para compilar un projecto en LaTeX
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MAIN_LATEX=latex_file | |
BUILD_DIR=build/ | |
LATEXMK_OPTS="-output-directory=$(BUILD_DIR)" | |
PDFLATEX_OPTS="--output-directory=$(BUILD_DIR)" | |
TEX_ENGINE=-pdflatex="pdflatex $(PDFLATEX_OPTS)" | |
# TEX_ENGINE=-xelatex | |
all: latex | |
mkbuilddir: | |
mkdir -p $(BUILD_DIR) | |
latex: | |
latexmk -pdf -shell-escape $(LATEXMK_OPTS) $(TEX_ENGINE) $(MAIN_LATEX).tex | |
ln -sf build/$(MAIN_LATEX).pdf $(MAIN_LATEX).pdf | |
clean: | |
latexmk $(LATEXMK_OPTS) -c $(MAIN_LATEX).tex | |
rm -f *~ | |
rm -f *.run.xml | |
rm -f $(MAIN_LATEX).bbl |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment