X-Git-Url: http://git.tpope.net/?p=latex-mlastyle.git;a=blobdiff_plain;f=Makefile;h=c6fa6c751629dc137a172440a4c1820ffb05d43a;hp=9cbf84bf735bcf327447041e35148d359c3530e4;hb=94e66ed8027650d5105bb5435537564567d032d2;hpb=7a4e4d831c9acaf54624fc8a370535f24e993137 diff --git a/Makefile b/Makefile index 9cbf84b..c6fa6c7 100644 --- a/Makefile +++ b/Makefile @@ -7,33 +7,35 @@ SRCDIR=source/latex/mlastyle #VERSION=`grep '^\\\\def\\\\fileversion' mlastyle.dtx | sed 's/^\\\\def\\\\fileversion{\\(.*\\)\\.\\(.*\\)}/\\1_\\2/'` VERSION=`grep '^%<[a-z]*> *\[[0-9/]* *v' mlastyle.dtx | sed 's/^%<[a-z]*> *\[[0-9/]* *v\([-_.0-9a-z]*\).*/\1/'` LATEX=latex +BIBTEX=bibtex +MAKEINDEX=/usr/bin/makeindex PDFLATEX=pdflatex DVIPS=dvips -MAKEINDEX=/usr/bin/makeindex FAKEROOT=`[ -x /usr/bin/fakeroot ] && echo /usr/bin/fakeroot` .SUFFIXES: .sty .ins .dtx .dvi .ps .pdf .ind .idx .gls .glo .PHONY: clean distclean tar zip install target mlastyle instructions -%.ind: %.idx - $(MAKEINDEX) -s gglo.ist -o $*.gls $*.glo - $(MAKEINDEX) -s gind.ist -o $*.ind $*.idx - [ ! -f $*.bib ] || bibtex $*.aux +%.bbl: %.bib + $(BIBTEX) $*.aux -%.idx: %.dtx +%.bib: %.dtx $(LATEX) $< -%.dvi: %.sty %.dtx %.ind - $(LATEX) $*.dtx - $(LATEX) $*.dtx - %.sty: %.ins %.dtx $(LATEX) $*.ins +%.dvi: %.sty %.dtx %.bbl + $(LATEX) $*.dtx + $(LATEX) $*.dtx + $(MAKEINDEX) -s gglo.ist -o $*.gls $*.glo + $(MAKEINDEX) -s gind.ist -o $*.ind $*.idx + $(LATEX) $*.dtx + %.ps: %.dvi $(DVIPS) -o $@ $< -%.pdf: %.dtx %.ind +%.pdf: %.sty %.dtx %.bbl $(PDFLATEX) $*.dtx $(PDFLATEX) $*.dtx @@ -52,7 +54,8 @@ clean: distclean: clean rm -f mlastyle.sty mlastyle.dvi mlastyle.ps mlastyle.pdf - rm -rf tex doc source bibtex + rm -rf $(LTXDIR)/* $(DOCDIR)/* $(SRCDIR)/* $(BSTDIR)/* + [ ! -d $(LTXDIR) ] || rmdir -p $(LTXDIR) $(DOCDIR) $(SRCDIR) $(BSTDIR) tar: mlastyle.sty mlastyle.dvi clean mkdir mlastyle-$(VERSION)