2007-01-11 10:38:24 +10:00
|
|
|
# Description: Network Time Protocol software
|
|
|
|
# URL: http://www.ntp.org
|
2008-03-12 22:55:05 +01:00
|
|
|
# Maintainer: Thomas Penteker, tek at serverop dot de
|
2007-01-20 12:21:06 +10:00
|
|
|
# Packager: James Mills, prologic at shortcircuit dot net dot au
|
2007-01-11 10:38:24 +10:00
|
|
|
# Depends on: openssl
|
2006-12-18 15:28:28 +10:00
|
|
|
|
|
|
|
name=ntp
|
2019-03-08 02:15:51 +01:00
|
|
|
version=4.2.8p13
|
2017-05-08 01:23:07 +02:00
|
|
|
release=1
|
2010-04-12 20:22:32 +02:00
|
|
|
source=(http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/$name-$version.tar.gz
|
2014-12-19 17:32:55 +01:00
|
|
|
ntpd ntpdate ntp.conf ntp-64bit.diff)
|
2007-01-11 10:38:24 +10:00
|
|
|
|
|
|
|
build () {
|
|
|
|
mkdir -p $PKG/etc/{rc.d,ntp} \
|
|
|
|
$PKG/var/log \
|
|
|
|
$PKG/var/run/ntp \
|
|
|
|
$PKG/var/lib/ntp/stats \
|
2017-08-20 23:38:34 +02:00
|
|
|
$PKG/usr/share/man/{man8,man5}
|
2007-01-11 10:38:24 +10:00
|
|
|
|
|
|
|
cd $name-$version
|
2009-06-04 19:09:27 +02:00
|
|
|
patch -p1 -i ../ntp-64bit.diff
|
|
|
|
|
2007-01-11 10:38:24 +10:00
|
|
|
./configure \
|
|
|
|
--prefix=/usr \
|
2017-04-13 22:53:02 +10:00
|
|
|
--libexecdir=/usr/lib/ntp \
|
2007-01-11 10:38:24 +10:00
|
|
|
--with-sntp \
|
|
|
|
--with-crypto \
|
2009-12-13 20:58:01 +01:00
|
|
|
--without-ntpsnmpd \
|
2007-01-11 10:38:24 +10:00
|
|
|
--enable-debugging=no \
|
|
|
|
--enable-ntpdate-step \
|
|
|
|
--enable-parse-clocks \
|
|
|
|
--enable-all-clocks \
|
|
|
|
CFLAGS="$CFLAGS" \
|
|
|
|
LDFLAGS="$LDFLAGS"
|
|
|
|
|
|
|
|
# substitute the default configuration path
|
|
|
|
sed -i -e 's;\(CONFIG_FILE[^"]*"\)/etc/ntp.conf;\1/etc/ntp/ntp.conf;' \
|
2014-12-19 17:32:55 +01:00
|
|
|
include/ntp_config.h
|
2007-01-11 10:38:24 +10:00
|
|
|
|
|
|
|
make
|
|
|
|
make DESTDIR=$PKG install
|
|
|
|
touch $PKG/var/log/ntp.log
|
|
|
|
|
|
|
|
install -m 644 $SRC/ntp.conf $PKG/etc/ntp
|
|
|
|
install -m 755 $SRC/ntpd $PKG/etc/rc.d
|
2008-03-16 00:09:09 +01:00
|
|
|
install -m 755 $SRC/ntpdate $PKG/etc/rc.d
|
2007-01-11 10:38:24 +10:00
|
|
|
|
2009-12-13 20:58:01 +01:00
|
|
|
# fix remove unnecessary directory
|
|
|
|
rm -r $PKG/usr/sbin
|
|
|
|
|
2007-01-11 10:38:24 +10:00
|
|
|
# initialize ntp.drift file
|
|
|
|
echo "0.0" > $PKG/var/lib/ntp/ntp.drift
|
2012-06-10 17:49:10 +02:00
|
|
|
|
|
|
|
# assign ownership to ntp:ntp
|
|
|
|
chown -R ntp:ntp $PKG/var/lib/ntp $PKG/var/run/ntp $PKG/var/log/ntp.log
|
2014-12-19 17:32:55 +01:00
|
|
|
|
|
|
|
# clean up the mess..
|
2017-04-13 22:53:02 +10:00
|
|
|
rm -r $PKG/usr/share/{doc,ntp}
|
2006-12-18 15:28:28 +10:00
|
|
|
}
|