Added ntp-4.2.4p6 template.
--HG-- extra : convert_revision : c4a40d020f6aa132836167ea175cf2de7a47b0d3
This commit is contained in:
parent
7d0b1b03bb
commit
d8e6bb470a
6 changed files with 197 additions and 0 deletions
1
templates/ntp-perl
Symbolic link
1
templates/ntp-perl
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
ntp
|
83
templates/ntp/files/ntp.conf
Normal file
83
templates/ntp/files/ntp.conf
Normal file
|
@ -0,0 +1,83 @@
|
||||||
|
# $NetBSD: ntp.conf,v 1.9 2007/02/10 19:36:56 reed Exp $
|
||||||
|
#
|
||||||
|
# NetBSD default Network Time Protocol (NTP) configuration file for ntpd
|
||||||
|
|
||||||
|
# This file is intended to be both a usable default, and a Quick-Start
|
||||||
|
# Guide. The directives and options listed here are not at all complete.
|
||||||
|
# A great deal of additional documentation, including links to FAQS and
|
||||||
|
# other guides, may be found on the official NTP web site, in particular
|
||||||
|
#
|
||||||
|
# http://www.ntp.org/documentation.html
|
||||||
|
#
|
||||||
|
|
||||||
|
# Process ID file, so that the daemon can be signalled from scripts
|
||||||
|
|
||||||
|
pidfile /var/run/ntpd.pid
|
||||||
|
|
||||||
|
# The correction calculated by ntpd(8) for the local system clock's
|
||||||
|
# drift is stored here.
|
||||||
|
|
||||||
|
driftfile /var/db/ntp.drift
|
||||||
|
|
||||||
|
# Suppress the syslog(3) message for each peer synchronization change.
|
||||||
|
|
||||||
|
logconfig -syncstatus
|
||||||
|
|
||||||
|
# This will help minimize disruptions due to network congestion. Don't
|
||||||
|
# do this if you configure only one server!
|
||||||
|
|
||||||
|
tos minsane 2
|
||||||
|
|
||||||
|
# Hereafter should be "server" or "peer" statements to configure other
|
||||||
|
# hosts to exchange NTP packets with. Peers should be selected in such
|
||||||
|
# a way that the network path to them is symmetric (that is, the series
|
||||||
|
# of links and routers used to get to the peer is the same one that the
|
||||||
|
# peer uses to get back. NTP assumes such symmetry in its network delay
|
||||||
|
# calculation. NTP will apply an incorrect adjustment to timestamps
|
||||||
|
# received from the peer if the path is not symmetric. This can result
|
||||||
|
# in clock skew (your system clock being maintained consistently wrong
|
||||||
|
# by a certain amount).
|
||||||
|
#
|
||||||
|
# The best way to select symmetric peers is to make sure that the
|
||||||
|
# network path to them is as short as possible (this reduces the chance
|
||||||
|
# that there is more than one network path between you and your peer).
|
||||||
|
# You can measure these distances with the traceroute(8) program. The
|
||||||
|
# best place to start looking for NTP peers for your system is within
|
||||||
|
# your own network, or at your Internet Service Provider (ISP).
|
||||||
|
#
|
||||||
|
# Ideally, you should select at least three other systems to talk NTP
|
||||||
|
# with, for an "what I tell you three times is true" effect.
|
||||||
|
#
|
||||||
|
|
||||||
|
#peer an.ntp.peer.goes.here
|
||||||
|
#server an.ntp.server.goes.here
|
||||||
|
|
||||||
|
# Public servers from the pool.ntp.org project. Volunteer's servers
|
||||||
|
# are dynamically assigned to the CNAMES below via DNS round-robin.
|
||||||
|
# The pool.ntp.org project needs more volunteers! The only criteria to
|
||||||
|
# join are a nailed-up connection and a static IP address. For details,
|
||||||
|
# see the web page:
|
||||||
|
#
|
||||||
|
# http://www.pool.ntp.org/
|
||||||
|
#
|
||||||
|
|
||||||
|
# The country codes can help you find servers that are net-wise close.
|
||||||
|
# As explained above, closer is better...
|
||||||
|
|
||||||
|
# Northern U.S.A
|
||||||
|
#server ca.pool.ntp.org
|
||||||
|
#server us.pool.ntp.org
|
||||||
|
#server us.pool.ntp.org
|
||||||
|
|
||||||
|
# Northern Europe
|
||||||
|
#server de.pool.ntp.org
|
||||||
|
#server de.pool.ntp.org
|
||||||
|
#server dk.pool.ntp.org
|
||||||
|
|
||||||
|
# Depending on the vagaries of DNS can occasionally pull in the same
|
||||||
|
# server twice. The following CNAMES are guaranteed to be disjoint, at
|
||||||
|
# least over some short interval.
|
||||||
|
|
||||||
|
server 0.pool.ntp.org
|
||||||
|
server 1.pool.ntp.org
|
||||||
|
server 2.pool.ntp.org
|
19
templates/ntp/files/ntpd
Normal file
19
templates/ntp/files/ntpd
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
#!/bin/sh
|
||||||
|
#
|
||||||
|
# $NetBSD: ntpd,v 1.13 2004/08/13 18:08:03 mycroft Exp $
|
||||||
|
#
|
||||||
|
|
||||||
|
# PROVIDE: ntpd
|
||||||
|
# REQUIRE: DAEMON
|
||||||
|
# BEFORE: LOGIN
|
||||||
|
|
||||||
|
$_rc_subr_loaded . /etc/rc.subr
|
||||||
|
|
||||||
|
name="ntpd"
|
||||||
|
rcvar=$name
|
||||||
|
command="/usr/bin/${name}"
|
||||||
|
pidfile="/var/run/${name}.pid"
|
||||||
|
required_files="/etc/ntp.conf"
|
||||||
|
|
||||||
|
load_rc_config $name
|
||||||
|
run_rc_command "$1"
|
36
templates/ntp/files/ntpdate
Normal file
36
templates/ntp/files/ntpdate
Normal file
|
@ -0,0 +1,36 @@
|
||||||
|
#!/bin/sh
|
||||||
|
#
|
||||||
|
# $NetBSD: ntpdate,v 1.18 2005/03/15 12:06:12 lukem Exp $
|
||||||
|
#
|
||||||
|
|
||||||
|
# PROVIDE: ntpdate
|
||||||
|
# REQUIRE: NETWORKING LOGIN
|
||||||
|
|
||||||
|
$_rc_subr_loaded . /etc/rc.subr
|
||||||
|
|
||||||
|
name="ntpdate"
|
||||||
|
rcvar=$name
|
||||||
|
command="/usr/bin/${name}"
|
||||||
|
start_cmd="ntpdate_start"
|
||||||
|
stop_cmd=":"
|
||||||
|
|
||||||
|
ntpdate_start()
|
||||||
|
{
|
||||||
|
if [ -z "$ntpdate_hosts" ]; then
|
||||||
|
ntpdate_hosts=$(awk '
|
||||||
|
/^#/ { next }
|
||||||
|
/^(server|peer)[ \t]*127.127/ { next }
|
||||||
|
/^(server|peer)/ { if ($2 ~ /^-[46]/)
|
||||||
|
print $3
|
||||||
|
else
|
||||||
|
print $2 }
|
||||||
|
' </etc/ntp.conf)
|
||||||
|
fi
|
||||||
|
if [ -n "$ntpdate_hosts" ]; then
|
||||||
|
echo "Setting date via ntp."
|
||||||
|
$command $rc_flags $ntpdate_hosts
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
load_rc_config $name
|
||||||
|
run_rc_command "$1"
|
20
templates/ntp/perl.template
Normal file
20
templates/ntp/perl.template
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
# Template file for 'ntp-perl'.
|
||||||
|
#
|
||||||
|
short_desc="${short_desc} (perl scripts)"
|
||||||
|
long_desc="${long_desc}
|
||||||
|
|
||||||
|
This package contains perl scripts ntp-wait and ntptrace."
|
||||||
|
|
||||||
|
Add_dependency run ntp
|
||||||
|
Add_dependency run perl
|
||||||
|
|
||||||
|
do_install()
|
||||||
|
{
|
||||||
|
local destdir=${XBPS_DESTDIR}/${pkgname}-${version}
|
||||||
|
local origdir=${XBPS_DESTDIR}/${sourcepkg}-${version}
|
||||||
|
|
||||||
|
mkdir -p ${destdir}/usr/bin
|
||||||
|
for f in ntp-wait ntptrace; do
|
||||||
|
mv ${origdir}/usr/bin/${f} ${destdir}/usr/bin
|
||||||
|
done
|
||||||
|
}
|
38
templates/ntp/template
Normal file
38
templates/ntp/template
Normal file
|
@ -0,0 +1,38 @@
|
||||||
|
# Template file for 'ntp'
|
||||||
|
pkgname=ntp
|
||||||
|
sourcepkg=ntp
|
||||||
|
version=4.2.4p6
|
||||||
|
distfiles="http://archive.ntp.org/ntp4/$pkgname-$version.tar.gz"
|
||||||
|
build_style=gnu_configure
|
||||||
|
configure_args="--enable-linuxcaps --enable-getifaddrs=glibc
|
||||||
|
--enable-all-clocks --enable-parse-clocks --with-crypto=openssl
|
||||||
|
--enable-accurate-adjtime --without-rpath --mandir=/usr/share/man
|
||||||
|
--enable-ipv6"
|
||||||
|
make_install_target="DESTDIR=$XBPS_DESTDIR/$pkgname-$version install"
|
||||||
|
short_desc="The Network Time Protocol"
|
||||||
|
maintainer="Juan RP <xtraeme@gmail.com>"
|
||||||
|
checksum=647640067c7c6a4c568af54c139ce07bbf9f69b54bf9be2704b4c99c56651067
|
||||||
|
long_desc="
|
||||||
|
The Network Time Protocol (NTP) is used to synchronize a computer's
|
||||||
|
time with another reference time source. This package includes ntpd
|
||||||
|
(a daemon which continuously adjusts system time) and utilities used
|
||||||
|
to query and configure the ntpd daemon."
|
||||||
|
|
||||||
|
subpackages="perl"
|
||||||
|
|
||||||
|
Add_dependency full glibc
|
||||||
|
Add_dependency full openssl
|
||||||
|
|
||||||
|
post_install()
|
||||||
|
{
|
||||||
|
local destdir=$XBPS_DESTDIR/$pkgname-$version
|
||||||
|
|
||||||
|
install -d ${destdir}/etc/rc.d
|
||||||
|
install -d ${destdir}/usr/share/ntp
|
||||||
|
install -d ${destdir}/usr/share/doc/ntp
|
||||||
|
install -m 755 ${FILESDIR}/ntpd ${destdir}/etc/rc.d/ntpd
|
||||||
|
install -m 755 ${FILESDIR}/ntpdate ${destdir}/etc/rc.d/ntpdate
|
||||||
|
install -m 644 ${FILESDIR}/ntp.conf ${destdir}/etc/ntp.conf
|
||||||
|
cp -a ${wrksrc}/html ${destdir}/usr/share/doc/ntp
|
||||||
|
cp -a ${wrksrc}/conf ${destdir}/usr/share/ntp
|
||||||
|
}
|
Loading…
Add table
Reference in a new issue