aboutsummaryrefslogtreecommitdiff
path: root/Makefile
blob: 36299f07196877d750e2c24c66fc05e0347613c7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
TMACDIR ?= /usr/share/tmac
BINDIR ?= /usr/local/bin
MANDIR ?= /usr/local/man

TROFF ?= troff
PDFROFF ?= troff | dpost | ps2pdf -

all: README.pdf HACKING.pdf

install:
	install -m 644 u.tmac t/toc.tmac $(TMACDIR)
	install -m 644 toc/toc.1 list/list.1 $(MANDIR)/man1
	install toc/toc list/list $(BINDIR)

HACKING.pdf: HACKING.t u.tmac
	perl -pe '$$_=`$$_` if s/^\!//' HACKING.t |\
	$(PDFROFF) > HACKING.pdf

README.pdf: README.t u.tmac
	TROFFONTS=/usr/pkg/share/fonts/X11/TTF/ \
	<README.t toc/toc list/list -p=.l \| $(PDFROFF) > README.pdf