Thu Feb 10 06:38:55 PST 2005
- Previous message: [Slony1-commit] By smsimms: Use fixed paths for altperl tools configuration and library
- Next message: [Slony1-commit] By darcyb: Install .sql and .conf files as mode 644 not 755
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Log Message: ----------- Added an "install" target to Makefile. It copies the configuration file, library, and slon start/stop/watch scripts to their relevant directories. I'm holding off on the slonik scripts until we decide where we want them to go. Adjusted DISTDIRS to reflect the slon.env -> slon_tools.conf change. Added a pgbindir substitution, and modified slon_start.pl so that it uses that path to get to slon_watchdog. Modified Files: -------------- slony1-engine/tools/altperl: Makefile (r1.3 -> r1.4) slon_start.pl (r1.11 -> r1.12) -------------- next part -------------- Index: slon_start.pl =================================================================== RCS file: /usr/local/cvsroot/slony1/slony1-engine/tools/altperl/slon_start.pl,v retrieving revision 1.11 retrieving revision 1.12 diff -Ltools/altperl/slon_start.pl -Ltools/altperl/slon_start.pl -u -w -r1.11 -r1.12 --- tools/altperl/slon_start.pl +++ tools/altperl/slon_start.pl @@ -67,6 +67,6 @@ print "PID [$pid]\n"; if ($START_WATCHDOG) { print "Start the watchdog process as well...\n"; - system "perl slon_watchdog.pl --config=$CONFIG_FILE $node $SLEEP_TIME &"; + system "@@PGBINDIR@@/slon_watchdog --config=$CONFIG_FILE $node $SLEEP_TIME &"; } } Index: Makefile =================================================================== RCS file: /usr/local/cvsroot/slony1/slony1-engine/tools/altperl/Makefile,v retrieving revision 1.3 retrieving revision 1.4 diff -Ltools/altperl/Makefile -Ltools/altperl/Makefile -u -w -r1.3 -r1.4 --- tools/altperl/Makefile +++ tools/altperl/Makefile @@ -10,7 +10,7 @@ slony_top_builddir = ../.. include $(slony_top_builddir)/Makefile.global -DISTFILES = Makefile ToDo README $(wildcard *.pl) $(wildcard *.pm) $(wildcard *.env) +DISTFILES = Makefile ToDo README $(wildcard *.pl) $(wildcard *.pm) slon_tools.conf-sample distdir: $(DISTFILES) mkdir $(distdir)/$(subdir) @@ -24,18 +24,29 @@ tmpname=`echo $$file | $(SED) "s#\.pl##"` ; \ rm $$tmpname ; \ done + all: ifndef PERL - @echo "You need perl to make use of these tools" -else + @echo "The altperl tools require that Perl be installed." + exit 1; +endif ifndef SED - @echo "You need sed to use slony" + @echo "sed is required to build the altperl tools." exit 1; -else +endif @for file in $(wildcard *.pl) ; do \ tmpname=`echo $$file | $(SED) "s#\.pl##"` ; \ - $(SED) -e "s#@@PERL@@#$(PERL)#; s#@@SYSCONFDIR@@#$(sysconfdir)#; s#@@PGLIBDIR@@#$(pglibdir)#;" $$file > $$tmpname; \ + $(SED) -e "s#@@PERL@@#$(PERL)#;" \ + -e "s#@@SYSCONFDIR@@#$(sysconfdir)#;" \ + -e "s#@@PGLIBDIR@@#$(pglibdir)#;" \ + -e "s#@@PGBINDIR@@#$(pgbindir)#;" $$file > $$tmpname; \ chmod 755 $$tmpname; \ done -endif -endif + +install: all + $(INSTALL_DATA) slon_tools.conf-sample $(sysconfdir) + $(INSTALL_DATA) slon-tools.pm $(pglibdir) + $(INSTALL_SCRIPT) slon_start.pl $(pgbindir) + $(INSTALL_SCRIPT) slon_kill.pl $(pgbindir) + $(INSTALL_SCRIPT) slon_watchdog.pl $(pgbindir) +
- Previous message: [Slony1-commit] By smsimms: Use fixed paths for altperl tools configuration and library
- Next message: [Slony1-commit] By darcyb: Install .sql and .conf files as mode 644 not 755
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Slony1-commit mailing list