# DIST_HOOK_DIRS = conf html scripts ports
# HMS: Keep .gcc-warning first, as that way it gets printed first.
-BUILT_SOURCES = .gcc-warning $(srcdir)/COPYRIGHT $(srcdir)/version $(srcdir)/version.m4 $(srcdir)/include/version.def
+BUILT_SOURCES = .gcc-warning $(srcdir)/COPYRIGHT $(srcdir)/version $(srcdir)/version.m4 $(srcdir)/include/version.def $(srcdir)/include/version.texi
$(srcdir)/COPYRIGHT: $(srcdir)/html/copyright.html
( echo "This file is automatically generated from html/copyright.html" ; lynx -dump $(srcdir)/html/copyright.html ) > $(srcdir)/COPYRIGHT.new && mv $(srcdir)/COPYRIGHT.new $(srcdir)/COPYRIGHT
cd $(srcdir) && \
./scripts/genver include/version.def
+$(srcdir)/include/version.texi: $(srcdir)/packageinfo.sh
+ cd $(srcdir) && \
+ ./scripts/genver include/version.texi
+
dist-hook:
@find $(distdir) -type d -name CVS -print | xargs rm -rf
@find $(distdir) -type d -name SCCS -print | xargs rm -rf
case "$ac_cv_lib_dns_sd_DNSServiceRegister" in
yes) LIBS="-ldns_sd $LIBS" ;;
esac
-AC_CHECK_HEADERS(errno.h fcntl.h ieeefp.h math.h)
+AC_CHECK_HEADERS(errno.h fcntl.h ieeefp.h kvm.h math.h)
AC_CHECK_HEADERS(md5.h, [], [],
[#if HAVE_SYS_TYPES_H
AC_CHECK_FUNC(inet_ntop, [], [AC_DEFINE(ISC_PLATFORM_NEEDNTOP, 1, [ISC: provide inet_ntop()])])
AC_CHECK_FUNC(inet_pton, [], [AC_DEFINE(ISC_PLATFORM_NEEDPTON, 1, [ISC: provide inet_pton()])])
AC_CHECK_FUNC(inet_aton, [], [AC_DEFINE(ISC_PLATFORM_NEEDATON, 1, [ISC: provide inet_aton()])])
-AC_CHECK_FUNCS(K_open kvm_open memcpy memmove memset)
+case "$ac_cv_header_kvm_h" in
+ yes)
+ AC_CHECK_FUNCS(kvm_open)
+ ;;
+esac
+AC_CHECK_FUNCS(memcpy memmove memset)
case "$host" in
*-*-sco3.2v5.0.*)
# Just stubs. Idiots.
#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies
AUTOMAKE_OPTIONS =
ETAGS_ARGS = $(srcdir)/Makefile.am
-EXTRA_DIST = autogen-version.def copyright.def debug-opt.def homerc.def version.def
+EXTRA_DIST = autogen-version.def copyright.def debug-opt.def homerc.def version.def version.texi
NULL=
noinst_HEADERS = \
*version.def)
outputs="include/version.def $outputs"
;;
+ *version.texi)
+ outputs="include/version.texi $outputs"
+ ;;
*) echo "Unrecognized option: $i"
exit 1
;;
done
case "$outputs" in
- '') outputs="version.m4 include/version.def" ;;
+ '') outputs="version.m4 include/version.def include/version.texi" ;;
esac
set -e
esac
;;
esac
+
+case "$outputs" in
+ *version.texi*)
+ echo "@set UPDATED `date +'%d %B %Y'`" > /tmp/version.texi+
+ echo "@set EDITION $dversion" >> /tmp/version.texi+
+ echo "@set VERSION $dversion" >> /tmp/version.texi+
+ cmp -s /tmp/version.texi+ include/version.texi
+ rc=$?
+ case "$force$rc" in
+ 00)
+ rm -f /tmp/version.texi+
+ ;;
+ *)
+ mv /tmp/version.texi+ include/version.texi
+ ;;
+ esac
+ ;;
+esac
$(NULL)
OLD_EXTRA_DIST= \
autogen-version.def version.def version.m4
-BUILT_SOURCES= check-autogen-version.def check-version.def check-version.m4 \
- sntp-opts.c sntp-opts.h sntp.1 sntp-opts.texi sntp-opts.menu
+BUILT_SOURCES= check-autogen-version.def check-version.def \
+ check-version.m4 check-version.texi \
+ sntp-opts.c sntp-opts.h sntp-opts.texi sntp-opts.menu \
+ sntp.1 sntp.html
man_MANS= sntp.1
FRC:
echo "Installing new sntp/version.m4 file"; \
fi )
+check-version.texi: FRC
+foo4:
+ @cd $(srcdir) \
+ && test -r ../include/version.texi \
+ && ( if cmp -s ../include/version.texi version.texi; \
+ then : ; \
+ else cp ../include/version.texi version.texi; \
+ echo "Installing new sntp/version.texi file"; \
+ fi )
+
$(srcdir)/sntp-opts.h: $(srcdir)/sntp-opts.c
$(srcdir)/sntp-opts.c: $(srcdir)/sntp-opts.def $(srcdir)/../include/version.def
$(run_ag) sntp-opts.def
$(srcdir)/sntp-opts.texi $(srcdir)/sntp-opts.menu: $(srcdir)/sntp-opts.def $(srcdir)/../include/version.def
$(run_ag) -Taginfo.tpl -DLEVEL=section sntp-opts.def
+$(srcdir)/sntp.html: $(srcdir)/sntp-opts.menu $(srcdir)/sntp-opts.texi $(srcdir)/sntp.texi
+ cd $(srcdir) && makeinfo --force --html --no-split -o sntp.html sntp.texi
+
include bincheck.mf
prog-name = "sntp";
prog-title = "standard SNTP program";
homerc = $HOME, ".";
-argument = '...';
+argument = 'hostname-or-IP ...';
long-opts;
A Key in a 1-to-8 character ASCII string.
M Key in a 1-to-8 character ASCII string using the MD5 authentication scheme.
- See more information see ntp.keys(5).
+ For more information see ntp.keys(5).
_EndOfDoc_;
};
detail = <<- _END_DETAIL
.I sntp
-can be used as a SNTP client to query a NTP or SNTP server and either display
-the time or set the local system's time (given suitable privilege). It can be
-run as an interactive command or in a
+implements the Simple Network Time Protocol, and is used
+to query an NTP or SNTP server and either
+display the time
+or
+set the local system's time (given suitable privilege).
+It can be
+run interactively from the command line or as a
.I cron
job.
-NTP is the Network Time Protocol (RFC 1305) and SNTP is the
-Simple Network Time Protocol (RFC 2030, which supersedes RFC 1769).
+
+NTP and SNTP are defined by draft-ietf-ntp-ntpv4-proto-11, which
+obsoletes RFC 4330 and RFC 1305.
_END_DETAIL;
prog-man-descrip = <<- _END_PROG_MAN_DESCRIP
commands. For example:
.IP
.B sntp -a ntpserver.somewhere
-.PP
-More information on how to use this utility is given in the
-.I README
-file in the distribution. In particular, this
-.I man
-page does not describe how to set it up as a server, which needs special care
-to avoid propagating misinformation.
.SH RETURN VALUE
-When used as a client in non-daemon mode, the program returns a zero exit
-status for success, and a non-zero one otherwise. When used as a daemon
-(either client or server), it does not return except after a serious error.
+The program returns a zero exit
+status for success, and a non-zero one otherwise.
.SH BUGS
-The program implements the SNTP protocol, and does not provide all NTP
-facilities. In particular, it contains no checks against any form of spoofing.
-If this is a serious concern, some network security mechanism (like a firewall
-or even just
-.IR tcpwrappers )
-should be installed.
-.PP
-There are some errors, ambiguities and inconsistencies in the RFCs, and this
-code may not interwork with all other NTP implementations. Any unreasonable
-restrictions should be reported as bugs to whoever is responsible. It may
-be difficult to find out who that is.
-.PP
-The program will stop as soon as it feels that things have got out of control.
-In client daemon mode, it will usually fail during an extended period of
-network or server inaccessibility or excessively slow performance, or when the
-local clock is reset by another process. It will then need restarting
-manually. Experienced system administrators can write a shell script, a
-.I cron
-job or put it in
-.IR inittab ,
-to do this automatically.
-.PP
-.SH AUTHOR
-.I sntp
+Please report bugs to http://bugs.ntp.org .
_END_PROG_MAN_DESCRIP;