From: Harlan Stenn Date: Thu, 10 Feb 2000 08:19:50 +0000 (-0000) Subject: Many files: X-Git-Tag: NTP_4_0_99_E~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d686b49fbd4b077e15087474c8ac15040c33999c;p=thirdparty%2Fntp.git Many files: Remove files with hardcoded path to perl... ...Put them back in using PATH_PERL * scripts/ntp-restart: It's ntpd now. Also, call ntp-wait. * configure.in (AC_CONFIG_*): New scripts that use PATH_PERL * scripts/Makefile.am (noinst_SCRIPTS): Added all of the scripts that now use PATH_PERL bk: 38a274a6If8ysXeLjUbvzi2o0vA_aw --- diff --git a/ChangeLog b/ChangeLog index 116a4a39d..332aea3ad 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,11 @@ 2000-02-10 Harlan Stenn - * scripts/Makefile.am (noinst_SCRIPTS): Addede ntp-wait + * scripts/ntp-restart: It's ntpd now. Also, call ntp-wait. + + * configure.in (AC_CONFIG_*): New scripts that use PATH_PERL + + * scripts/Makefile.am (noinst_SCRIPTS): Added ntp-wait + (noinst_SCRIPTS): Added all of the scripts that now use PATH_PERL * configure.in: Get the path to perl (AC_CONFIG_*): Added scripts/ntp-wait diff --git a/configure b/configure index 293439595..b87e8d964 100755 --- a/configure +++ b/configure @@ -10879,7 +10879,9 @@ config_files="\\ kernel/Makefile kernel/sys/Makefile libntp/Makefile libparse/Makefile librsaref/Makefile ntpd/Makefile ntpdc/Makefile ntpdate/Makefile ntpq/Makefile ntptrace/Makefile parseutil/Makefile scripts/Makefile - scripts/mkver scripts/ntp-wait scripts/ntpver util/Makefile" + scripts/calc_tickadj scripts/checktime scripts/freq_adj scripts/mkver + scripts/ntp-wait scripts/ntpsweep scripts/ntpver scripts/plot_summary + scripts/summary util/Makefile" config_headers="\\ config.h" config_commands="\\ @@ -10978,9 +10980,15 @@ do 'ntptrace/Makefile' ) CONFIG_FILES="\$CONFIG_FILES ntptrace/Makefile" ;; 'parseutil/Makefile' ) CONFIG_FILES="\$CONFIG_FILES parseutil/Makefile" ;; 'scripts/Makefile' ) CONFIG_FILES="\$CONFIG_FILES scripts/Makefile" ;; + 'scripts/calc_tickadj' ) CONFIG_FILES="\$CONFIG_FILES scripts/calc_tickadj" ;; + 'scripts/checktime' ) CONFIG_FILES="\$CONFIG_FILES scripts/checktime" ;; + 'scripts/freq_adj' ) CONFIG_FILES="\$CONFIG_FILES scripts/freq_adj" ;; 'scripts/mkver' ) CONFIG_FILES="\$CONFIG_FILES scripts/mkver" ;; 'scripts/ntp-wait' ) CONFIG_FILES="\$CONFIG_FILES scripts/ntp-wait" ;; + 'scripts/ntpsweep' ) CONFIG_FILES="\$CONFIG_FILES scripts/ntpsweep" ;; 'scripts/ntpver' ) CONFIG_FILES="\$CONFIG_FILES scripts/ntpver" ;; + 'scripts/plot_summary' ) CONFIG_FILES="\$CONFIG_FILES scripts/plot_summary" ;; + 'scripts/summary' ) CONFIG_FILES="\$CONFIG_FILES scripts/summary" ;; 'util/Makefile' ) CONFIG_FILES="\$CONFIG_FILES util/Makefile" ;; 'default-1' ) CONFIG_COMMANDS="\$CONFIG_COMMANDS default-1" ;; 'default-2' ) CONFIG_COMMANDS="\$CONFIG_COMMANDS default-2" ;; @@ -11429,7 +11437,7 @@ for mf in $CONFIG_FILES; do done done ;; - default ) chmod +x scripts/ntp-wait scripts/ntpver scripts/mkver ;; + default ) chmod +x scripts/calc_tickadj scripts/checktime scripts/freq_adj scripts/mkver scripts/ntp-wait scripts/ntpsweep scripts/ntpver scripts/plot_summary scripts/summary ;; esac fi;done EOF diff --git a/configure.in b/configure.in index cf6c762d6..a012b8a08 100644 --- a/configure.in +++ b/configure.in @@ -2993,7 +2993,9 @@ AC_CONFIG_FILES(Makefile adjtimed/Makefile clockstuff/Makefile \ include/Makefile kernel/Makefile kernel/sys/Makefile libntp/Makefile \ libparse/Makefile librsaref/Makefile ntpd/Makefile ntpdc/Makefile \ ntpdate/Makefile ntpq/Makefile ntptrace/Makefile parseutil/Makefile \ -scripts/Makefile scripts/mkver scripts/ntp-wait scripts/ntpver util/Makefile) -AC_CONFIG_COMMANDS(default, [[chmod +x scripts/ntp-wait scripts/ntpver scripts/mkver]], []) +scripts/Makefile scripts/calc_tickadj scripts/checktime scripts/freq_adj \ +scripts/mkver scripts/ntp-wait scripts/ntpsweep scripts/ntpver \ +scripts/plot_summary scripts/summary util/Makefile) +AC_CONFIG_COMMANDS(default, [[chmod +x scripts/calc_tickadj scripts/checktime scripts/freq_adj scripts/mkver scripts/ntp-wait scripts/ntpsweep scripts/ntpver scripts/plot_summary scripts/summary]], []) AC_OUTPUT #test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h]) diff --git a/scripts/Makefile.am b/scripts/Makefile.am index 4705dd9ed..173e60422 100644 --- a/scripts/Makefile.am +++ b/scripts/Makefile.am @@ -1 +1 @@ -noinst_SCRIPTS = mkver ntp-wait ntpver +noinst_SCRIPTS = calc_tickadj checktime freq_adj mkver ntp-wait ntpsweep ntpver plot_summary summary diff --git a/scripts/Makefile.in b/scripts/Makefile.in index 4233c10b8..214352447 100644 --- a/scripts/Makefile.in +++ b/scripts/Makefile.in @@ -100,16 +100,18 @@ VERSION = @VERSION@ install_sh = @install_sh@ -noinst_SCRIPTS = mkver ntp-wait ntpver +noinst_SCRIPTS = calc_tickadj checktime freq_adj mkver ntp-wait ntpsweep ntpver plot_summary summary subdir = scripts mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = ../config.h -CONFIG_CLEAN_FILES = mkver ntp-wait ntpver +CONFIG_CLEAN_FILES = calc_tickadj checktime freq_adj mkver ntp-wait \ +ntpsweep ntpver plot_summary summary SCRIPTS = $(noinst_SCRIPTS) DIST_SOURCES = -DIST_COMMON = README Makefile.am Makefile.in mkver.in ntp-wait.in \ -ntpver.in +DIST_COMMON = README Makefile.am Makefile.in calc_tickadj.in \ +checktime.in freq_adj.in mkver.in ntp-wait.in ntpsweep.in ntpver.in \ +plot_summary.in summary.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) @@ -124,12 +126,24 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES) cd $(top_builddir) \ && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status +calc_tickadj: $(top_builddir)/config.status calc_tickadj.in + cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status +checktime: $(top_builddir)/config.status checktime.in + cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status +freq_adj: $(top_builddir)/config.status freq_adj.in + cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status mkver: $(top_builddir)/config.status mkver.in cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status ntp-wait: $(top_builddir)/config.status ntp-wait.in cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status +ntpsweep: $(top_builddir)/config.status ntpsweep.in + cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status ntpver: $(top_builddir)/config.status ntpver.in cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status +plot_summary: $(top_builddir)/config.status plot_summary.in + cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status +summary: $(top_builddir)/config.status summary.in + cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status tags: TAGS TAGS: diff --git a/scripts/README b/scripts/README index 9e2946748..02eff5356 100644 --- a/scripts/README +++ b/scripts/README @@ -23,6 +23,10 @@ ntp-groper script useful for reaching out and rattling the cages of ntp-restart script useful for killing and restarting the NTP daemon +ntp-wait Blocks until ntpd is in state 4 (synchronized). + Hopefully useful at boot time, to delay the boot sequence + until after "ntpd -g" has set the time. + ntpsweep prints per host given in the NTP stratum level, the clock offset in seconds, the daemon version, the operating system and the processor. diff --git a/scripts/calc_tickadj b/scripts/calc_tickadj.in similarity index 96% rename from scripts/calc_tickadj rename to scripts/calc_tickadj.in index f7a9f9f1d..32eae1296 100644 --- a/scripts/calc_tickadj +++ b/scripts/calc_tickadj.in @@ -1,4 +1,4 @@ -#! /usr/local/bin/perl +#! @PATH_PERL@ # # drift of 104.8576 -> +1 tick. Base of 10000 ticks. # diff --git a/scripts/checktime b/scripts/checktime.in old mode 100755 new mode 100644 similarity index 97% rename from scripts/checktime rename to scripts/checktime.in index 850e2ecb1..2fe8f711b --- a/scripts/checktime +++ b/scripts/checktime.in @@ -1,5 +1,5 @@ -#!/usr/local/bin/perl -#!/usr/local/bin/perl -d +#! @PATH_PERL@ +#! @PATH_PERL@ -d # # This script compares the time of several machines with the # time on the local host. diff --git a/scripts/freq_adj b/scripts/freq_adj.in old mode 100755 new mode 100644 similarity index 99% rename from scripts/freq_adj rename to scripts/freq_adj.in index 4af431663..88eb390e1 --- a/scripts/freq_adj +++ b/scripts/freq_adj.in @@ -1,4 +1,4 @@ -#! /usr/bin/perl -w +#! @PATH_PERL@ -w die "perl5 needed\n" unless ($] > 5); diff --git a/scripts/ntp-restart b/scripts/ntp-restart index d2023f0b6..0a1d58a5c 100755 --- a/scripts/ntp-restart +++ b/scripts/ntp-restart @@ -1,9 +1,10 @@ #!/bin/sh # # This script can be used to kill and restart the NTP daemon. Edit the -# /usr/local/bin/xntpd line to fit. +# /usr/local/bin/ntpd line to fit. # -kill -INT `ps -ax | egrep "xntpd" | egrep -v "egrep" | sed 's/^\([ 0-9]*\) .*/\1'/` +kill -INT `ps -ax | egrep "ntpd" | egrep -v "egrep" | sed 's/^\([ 0-9]*\) .*/\1'/` sleep 10 -/usr/local/bin/xntpd +/usr/local/bin/ntpd -g +/usr/local/bin/ntp-wait exit 0 diff --git a/scripts/ntpsweep b/scripts/ntpsweep.in old mode 100755 new mode 100644 similarity index 99% rename from scripts/ntpsweep rename to scripts/ntpsweep.in index 7aca7ee80..156fb45c8 --- a/scripts/ntpsweep +++ b/scripts/ntpsweep.in @@ -1,4 +1,4 @@ -#!/usr/local/bin/perl -w +#! @PATH_PERL@ -w # # $Id$ # diff --git a/scripts/plot_summary.pl b/scripts/plot_summary.in old mode 100755 new mode 100644 similarity index 99% rename from scripts/plot_summary.pl rename to scripts/plot_summary.in index 7f892bc8f..3b46a0401 --- a/scripts/plot_summary.pl +++ b/scripts/plot_summary.in @@ -1,4 +1,4 @@ -#!/usr/bin/perl -w +#! @PATH_PERL@ -w # $Id$ # # Use Gnuplot to display data in summary files produced by summary.pl. diff --git a/scripts/summary.pl b/scripts/summary.in similarity index 99% rename from scripts/summary.pl rename to scripts/summary.in index 4fc58cb05..515dfc6b5 100644 --- a/scripts/summary.pl +++ b/scripts/summary.in @@ -1,4 +1,4 @@ -#!/usr/bin/perl -w +#! @PATH_PERL@ -w # $Id$ # Perl version of (summary.sh, loop.awk, peer.awk): # Create summaries from xntpd's loop and peer statistics.