diff options
Diffstat (limited to 'macros/latex/contrib/listlbls/Makefile')
-rw-r--r-- | macros/latex/contrib/listlbls/Makefile | 44 |
1 files changed, 23 insertions, 21 deletions
diff --git a/macros/latex/contrib/listlbls/Makefile b/macros/latex/contrib/listlbls/Makefile index 20ecc6f468..64df745ce7 100644 --- a/macros/latex/contrib/listlbls/Makefile +++ b/macros/latex/contrib/listlbls/Makefile @@ -1,13 +1,17 @@ -NAME = listlbls -SHELL = bash -PWD = $(shell pwd) -TEMP := $(shell mktemp -d) -TDIR = $(TEMP)/$(NAME) -VERS = $(shell ltxfileinfo -v $(NAME).dtx) -LOCAL = $(shell kpsewhich --var-value TEXMFLOCAL) -UTREE = $(shell kpsewhich --var-value TEXMFHOME) - -all: $(NAME).pdf README.md README clean +NAME = listlbls +SHELL = bash +PWD = $(shell pwd) +TEMP := $(shell mktemp -d) +TDIR = $(TEMP)/$(NAME) +VERS = $(shell ltxfileinfo -v $(NAME).dtx) +LOCAL = $(shell kpsewhich --var-value TEXMFLOCAL) +UTREE = $(shell kpsewhich --var-value TEXMFHOME) +PREFIX ?= $(LOCAL) +LATEX = xelatex +SUDO = sudo + +all: $(NAME).pdf README.md README + $(MAKE) clean README: README.txt cp README.txt README @@ -17,11 +21,12 @@ README.txt: $(NAME).pdf README.md: $(NAME).pdf $(NAME).pdf: $(NAME).dtx - xelatex -shell-escape -recorder -interaction=batchmode $(NAME).dtx >/dev/null + $(LATEX) -shell-escape -recorder $(NAME).dtx if [ -f $(NAME).glo ]; then makeindex -q -s gglo.ist -o $(NAME).gls $(NAME).glo; fi if [ -f $(NAME).idx ]; then makeindex -q -s gind.ist -o $(NAME).ind $(NAME).idx; fi - xelatex -shell-escape -recorder -interaction=nonstopmode $(NAME).dtx > /dev/null - xelatex -shell-escape -recorder -interaction=nonstopmode $(NAME).dtx > /dev/null + $(LATEX) -shell-escape -recorder -interaction=scrollmode $(NAME).dtx + $(LATEX) -shell-escape -recorder -interaction=scrollmode $(NAME).dtx + $(LATEX) -shell-escape -recorder -interaction=scrollmode $(NAME).dtx clean: rm -f *.fls @@ -31,16 +36,13 @@ distclean: clean rm -f $(NAME).{pdf,sty} README{,.{md,txt}} inst: all - mkdir -p $(UTREE)/{tex,source,doc}/latex/$(NAME) - cp $(NAME).dtx $(UTREE)/source/latex/$(NAME) - cp $(NAME).sty $(UTREE)/tex/latex/$(NAME) - cp $(NAME).pdf $(UTREE)/doc/latex/$(NAME) + $(MAKE) install PREFIX=$(UTREE) SUDO="" install: all - sudo mkdir -p $(LOCAL)/{tex,source,doc}/latex/$(NAME) - sudo cp $(NAME).dtx $(LOCAL)/source/latex/$(NAME) - sudo cp $(NAME).sty $(LOCAL)/tex/latex/$(NAME) - sudo cp $(NAME).pdf $(LOCAL)/doc/latex/$(NAME) + $(SUDO) mkdir -p $(PREFIX)/{tex,source,doc}/latex/$(NAME) + $(SUDO) cp $(NAME).dtx $(PREFIX)/source/latex/$(NAME) + $(SUDO) cp $(NAME).sty $(PREFIX)/tex/latex/$(NAME) + $(SUDO) cp $(NAME).pdf $(PREFIX)/doc/latex/$(NAME) zip: all mkdir $(TDIR) |