4
# Copyright (c) 2003-200, PostgreSQL Global Development Group
5
# $Id: Makefile,v 1.14.2.2 2009-08-17 17:39:58 devrim Exp $
9
slony_subdir = tools/altperl
10
slony_top_builddir = ../..
11
include $(slony_top_builddir)/Makefile.global
13
DISTFILES = Makefile ToDo README $(wildcard *.pl) $(wildcard *.pm) slon_tools.conf-sample
18
@echo "The altperl tools require that Perl be installed."
22
@echo "sed is required to build the altperl tools."
25
@for file in $(wildcard *.pl) $(wildcard *.pm); do \
26
tmpname=`echo $$file | $(SED) "s#\.p[lm]##"` && \
27
$(SED) -e "s#@@PERL@@#$(PERL)#;" \
28
-e "s#@@SYSCONFDIR@@#$(sysconfdir)#;" \
29
-e "s#@@PGLIBDIR@@#$(pglibdir)#;" \
30
-e "s#@@PGBINDIR@@#$(pgbindir)#;" \
31
-e "s#@@SLONBINDIR@@#$(slonbindir)#;" \
32
-e "s#@@TOOLSBIN@@#$(toolsbin)#;" \
33
$$file > $$tmpname && \
41
@echo "The altperl tools won't be installed unless --with-perltools is specified in configure"
43
$(INSTALL_DATA) slon_tools.conf-sample $(DESTDIR)$(sysconfdir)
44
$(INSTALL_DATA) slon-tools $(DESTDIR)$(perlsharedir)/slon-tools.pm
45
for file in $(wildcard *.pl) ; do \
46
tmpname=`echo $$file | $(SED) "s#\.pl##"` && \
47
$(INSTALL_SCRIPT) $$tmpname $(DESTDIR)$(toolsbin) \
53
$(mkinstalldirs) $(DESTDIR)$(sysconfdir)
54
$(mkinstalldirs) $(DESTDIR)$(pglibdir)
55
$(mkinstalldirs) $(DESTDIR)$(toolsbin)
58
mkdir $(distdir)/$(subdir)
59
-chmod 777 $(distdir)/$(subdir)
60
for file in $(DISTFILES) ; do \
61
cp $$file $(distdir)/$(subdir)/$$file || exit; \
64
clean distclean maintainer-clean:
65
@for file in $(wildcard *.pl) $(wildcard *.pm); do \
66
tmpname=`echo $$file | $(SED) "s#\.p[lm]##"` && \