summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/bigfoot/Makefile
blob: eb4867d5556ed79edd126148a4ecd31c8fccd714 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
TEX=tex
PDFLATEX=pdflatex
DTX=bigfoot.dtx suffix.dtx perpage.dtx
DIST=README COPYING $(DTX) Makefile bigfoot.ins
DOC=$(DTX:.dtx=.pdf)

all: $(DIST) $(DTX:.dtx=.sty) $(DOC)

bigfoot-mk.ins: bigfoot.dtx Makefile
	$(TEX) '\nonstopmode \def\jobname{.ins}\input docstrip ' \
	'\askforoverwritefalse \nopreamble' \
	'\generate{\file{bigfoot-mk.ins}{\from{bigfoot.dtx}{installer,make}}}' \
	'\endbatchfile'

# Not generated by bigfoot-mk.ins in order to allow for hand-editing,
# like putting debug options in
bigfoot.ins: bigfoot.dtx Makefile
	$(TEX) '\nonstopmode \def\jobname{.ins}\input docstrip ' \
	'\askforoverwritefalse \nopreamble' \
	'\generate{\file{bigfoot.ins}{\from{bigfoot.dtx}{installer}}}' \
	'\endbatchfile'

bigfoot.drv bigfoot.sty perpage.drv perpage.sty suffix.drv suffix.sty: bigfoot-mk.ins
	$(TEX) bigfoot-mk.ins

bigfoot.drv bigfoot.sty: bigfoot.dtx
perpage.drv perpage.sty: perpage.dtx
suffix.drv suffix.sty: suffix.dtx

bigfoot.pdf: bigfoot.dtx bigfoot.drv bigfoot.sty perpage.sty suffix.sty
	$(PDFLATEX) '\nonstopmode\input{bigfoot.drv}'
	$(PDFLATEX) '\nonstopmode\input{bigfoot.drv}'
	$(PDFLATEX) '\nonstopmode\input{bigfoot.drv}'

perpage.pdf: perpage.dtx perpage.drv
	$(PDFLATEX) '\nonstopmode\input{perpage.drv}'
	$(PDFLATEX) '\nonstopmode\input{perpage.drv}'
	$(PDFLATEX) '\nonstopmode\input{perpage.drv}'

suffix.pdf: suffix.dtx suffix.drv
	$(PDFLATEX) '\nonstopmode\input{suffix.drv}'
	$(PDFLATEX) '\nonstopmode\input{suffix.drv}'
	$(PDFLATEX) '\nonstopmode\input{suffix.drv}'

bigfoot.tar.gz: $(DIST)
	tar czf $@ $(DIST)

bigfoot-ctan.tar.gz: $(DIST) $(DOC)
	tar czf $@ --transform 's,^\(\./\)\?,bigfoot/,' $(DIST) $(DOC)