Makefile.am revision 08e312fd
1Xtransincludedir = $(includedir)/X11/Xtrans
2Xtransinclude_HEADERS = \
3	Xtrans.h \
4	Xtrans.c \
5	Xtransint.h \
6	Xtranslcl.c \
7	Xtranssock.c \
8	Xtranstli.c \
9	Xtransutil.c \
10	transport.c
11
12aclocaldir = $(datadir)/aclocal
13aclocal_DATA = xtrans.m4
14
15pkgconfigdir = $(datadir)/pkgconfig
16pkgconfig_DATA = xtrans.pc
17
18EXTRA_DIST = xtrans.pc.in ${aclocal_DATA} ChangeLog Xtrans.mm
19
20MAINTAINERCLEANFILES = ChangeLog
21
22.PHONY: ChangeLog
23
24ChangeLog:
25	$(CHANGELOG_CMD)
26
27dist-hook: ChangeLog
28
29# Rules to convert documentation from troff to other formats
30doc_sources = Xtrans.mm
31
32if HAVE_PS2PDF
33printable_format = .pdf
34else
35printable_format = .ps
36endif
37
38if BUILD_DOCS
39doc_DATA =	$(doc_sources:.mm=.txt) \
40		$(doc_sources:.mm=$(printable_format)) \
41		$(doc_sources:.mm=.html)
42
43CLEANFILES = $(doc_DATA)
44MOSTLYCLEANFILES = index.*
45
46# Pass version string as a troff string for substitution
47GROFF_DEFS = -dxV="$(PACKAGE_STRING)"
48
49# -t to run through tbl
50GROFF_FLAGS = -t -mm $(GROFF_DEFS)
51
52SUFFIXES = .mm .ps .txt .html .pdf
53
54.mm.ps:
55	-$(AM_V_GEN) $(GROFF) -Tps $(GROFF_FLAGS) $< 2> index.$@.raw > $@
56	@if grep '^[^1-9.]' index.$@.raw | grep -v warning; then exit 1; \
57	 else test $$? -le 1; fi
58
59.mm.txt:
60	$(AM_V_GEN) env GROFF_NO_SGR=TRUE $(GROFF) -Tutf8 $(GROFF_FLAGS) \
61	 $< 2> index.$@.raw > $@
62
63.mm.html:
64	$(AM_V_GEN) $(GROFF) -Thtml $(GROFF_FLAGS) $< 2> index.$@.raw > $@
65
66.ps.pdf:
67	$(AM_V_GEN) $(PS2PDF) $< $@
68
69endif BUILD_DOCS
70