POD = bin_dec_hex.pod rrddump.pod rrdgraph_examples.pod rrdrestore.pod rrdupdate.pod \
cdeftutorial.pod rrdfetch.pod rrdgraph_graph.pod rrdthreads.pod rrdxport.pod \
rpntutorial.pod rrdfirst.pod rrdgraph_rpn.pod rrdtool.pod \
- rrd-beginners.pod rrdinfo.pod rrdtune.pod \
+ rrd-beginners.pod rrdinfo.pod rrdtune.pod rrdbuild.pod \
rrdcgi.pod rrdgraph.pod rrdlast.pod \
rrdcreate.pod rrdgraph_data.pod rrdresize.pod rrdtutorial.pod
# what should go into the distribution
EXTRA_DIST= $(POD) $(HTML) $(TXT) rrdtool-dump.dtd rrdtool-xport.dtd
-# some install rules
-idocdir = $(prefix)/doc
+# some install rules if the install pat
+DOCPREFIX:=$(shell echo "@prefix@" | grep rrd >/dev/null && echo "rrdtool-@VERSION@/")
+idocdir = $(prefix)/shared/doc/$(DOCPREFIX)txt
idoc_DATA = $(POD) $(TXT)
-ihtmldir = $(prefix)/html
+ihtmldir = $(prefix)/shared/doc/$(DOCPREFIX)html
ihtml_DATA = $(HTML)
imandir = $(mandir)/man1
iman_DATA = $(MAN)