1 ## Process this file with automake to produce Makefile.in
3 SUFFIXES = .pod .pl .1 .3 .man .html .txt .pm .pdf .inc
5 AUTOMAKE_OPTIONS = foreign
7 #ACLOCAL_M4 = $(top_srcdir)/config/aclocal.m4
9 CLEANFILES = *.1 *.3 *.html *.txt *-dircache RRD?.pod *.pdf *~ core *itemcache *.rej *.orig *.tmp
11 POD = bin_dec_hex.pod rrddump.pod rrdgraph_examples.pod rrdrestore.pod rrdupdate.pod \
12 cdeftutorial.pod rrdfetch.pod rrdgraph_graph.pod rrdthreads.pod rrdxport.pod \
13 rpntutorial.pod rrdfirst.pod rrdgraph_rpn.pod rrdtool.pod rrdcached.pod \
14 rrd-beginners.pod rrdinfo.pod rrdtune.pod rrdbuild.pod rrdflushcached.pod \
15 rrdcgi.pod rrdgraph.pod rrdlast.pod rrdlastupdate.pod \
16 rrdcreate.pod rrdgraph_data.pod rrdresize.pod rrdtutorial.pod
19 POD += rrdgraph_libdbi.pod
28 PMP = RRDs.pod RRDp.pod
31 MAN3 = $(POD3:.pod=.3)
32 TXT = $(MAN:.1=.txt) $(MAN3:.3=.txt)
33 HTML = $(POD:.pod=.html) $(POD3:.pod=.html) $(PMP:.pod=.html)
34 PDF = $(MAN:.1=.pdf) $(MAN3:.3=.pdf)
36 # what should go into the distribution
37 EXTRA_DIST= $(POD) $(POD3) $(HTML) $(MAN) $(MAN3) $(TXT) rrdtool-dump.dtd rrdtool-xport.dtd rrdgraph_libdbi.pod rrdlua.pod
39 idocdir = $(RRDDOCDIR)/txt
40 idoc_DATA = $(POD) $(TXT)
41 ihtmldir = $(RRDDOCDIR)/html
43 imandir = $(mandir)/man1
45 iman3dir = $(mandir)/man3
48 all-local: link man txt html-local
51 perl -n -e 'if (/^=include\s+(\S+)/){open F,"$$1.inc" || die $$?;print <F>; close F} else {print}' $< > $@
54 $(AM_V_GEN)@POD2MAN@ --release=$(VERSION) --center=rrdtool $< > $@
57 $(AM_V_GEN)@POD2MAN@ --release=$(VERSION) --center=rrdtool --section=3 $< > $@
60 $(AM_V_GEN)GROFF_NO_SGR=1 @NROFF@ -man -Tlp $< > $@
63 $(AM_V_GEN)@TROFF@ -man $< | ps2pdf - $@
65 .pm.html .pod.html .pl.html:
66 $(AM_V_GEN)@POD2HTML@ --infile=$< --outfile=$@ --noindex --htmlroot=. --podpath=. --title=$*
69 $(AM_V_GEN)$(LN_S) $(top_srcdir)/bindings/perl-shared/RRDs.pm RRDs.pod
72 $(AM_V_GEN)$(LN_S) $(top_srcdir)/bindings/perl-piped/RRDp.pm RRDp.pod
74 link: RRDp.pod RRDs.pod
87 $(AM_V_GEN)cd $(DESTDIR)$(ihtmldir) && rm -f index.html && $(LN_S) rrdtool.html index.html