summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/eskdx/include.mak
blob: 41491ee02f09a99e9cc4b04ecc9a8e79657bec18 (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
50
51
52
53
54
55
56
57
58
PACKAGE = eskdx
VERSION = 0.98
RELEASE_DATE = 2011/05/13
M4DEPS = $(TOP_DIR)/include.m4 $(TOP_DIR)/include.mak
M4FLAGS = -P -Dm4_ESKDX_INIT="m4_include($(TOP_DIR)/include.m4)" \
	  -Dm4_ESKDX_VERSION=$(VERSION) -Dm4_ESKDX_DATE=$(RELEASE_DATE)
PASS=1
DIST_DIR = $(TOP_DIR)/.dist
DIST_PREFIX = /$(PACKAGE)-$(VERSION)

all: all-recursive

%.pdf: %.eps
	epstopdf --outfile $@ $<

%.pdf: %.tex
	for i in `seq 1 $(PASS)`; do pdflatex $<; done
	
%.dvi: %.tex
	for i in `seq 1 $(PASS)`; do latex $<; done
	
%.ps: %.dvi
	dvips $(DVIPS_FLAGS) -o $@ $<

all-recursive:
	for i in $(SUBDIRS); do $(MAKE) -C $$i all || exit $$?; done

clean: clean-recursive

clean-recursive:
	for i in $(SUBDIRS); do $(MAKE) -C $$i clean || exit $$?; done

dist: $(DIST_FILES) dist-recursive
	mkdir -p $(DIST_DIR)$(DIST_PREFIX)
	cp -a $(DIST_FILES) $(DIST_DIR)$(DIST_PREFIX)

dist-recursive:
	for i in $(SUBDIRS); do $(MAKE) -C $$i \
	  DIST_PREFIX=$(DIST_PREFIX)/$$i dist || exit $$?; done

dist-bzip2: dist
	tar -C $(DIST_DIR) -cjf $(PACKAGE)-$(VERSION).tar.bz2 .
	rm -rf $(DIST_DIR)

dist-zip: dist
	zipfile=`pwd`/$(PACKAGE)-$(VERSION).zip; \
	rm -f "$$zipfile"; \
	cd $(DIST_DIR) && zip -r "$$zipfile" *
	rm -rf $(DIST_DIR)

dist-ctan: dist
	zipfile=`pwd`/$(PACKAGE)-$(VERSION)-ctan.zip; \
	rm -f "$$zipfile"; \
	cd $(DIST_DIR)$(DIST_PREFIX) && zip -r "$$zipfile" *
	rm -rf $(DIST_DIR)

.PHONY: all all-recursive clean clean-recursive \
	dist dist-recursive dist-bzip2