blob: 78eb3d4f6a59808203a54ae77d0d2681b549e031 (
plain)
1 # Description: Network Time Protocol software
2 # URL: http://www.ntp.org
3 # Maintainer: James Mills, prologic at shortcircuit dot net dot au
4 # Packager: James Mills, prologic at shortcircuit dot net dot au
5 #
6 # Depends on: openssl
7
8 name=ntp
9 version=4.2.4p0
10 release=1
11 source=(http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/$name-$version.tar.gz
12 ntpd
13 ntp.conf)
14
15 build () {
16 mkdir -p $PKG/etc/{rc.d,ntp} \
17 $PKG/var/log \
18 $PKG/var/run/ntp \
19 $PKG/var/lib/ntp/stats \
20 $PKG/usr/man/{man8,man5}
21
22 cd $name-$version
23
24 ./configure \
25 --prefix=/usr \
26 --with-sntp \
27 --with-crypto \
28 --enable-debugging=no \
29 --enable-ntpdate-step \
30 --enable-parse-clocks \
31 --enable-all-clocks \
32 CFLAGS="$CFLAGS" \
33 LDFLAGS="$LDFLAGS"
34
35 # substitute the default configuration path
36 sed -i -e 's;\(CONFIG_FILE[^"]*"\)/etc/ntp.conf;\1/etc/ntp/ntp.conf;' \
37 include/ntp_config.h ntpdate/ntptime_config.c
38
39 make
40 make DESTDIR=$PKG install
41 touch $PKG/var/log/ntp.log
42
43 install -m 644 $SRC/ntp.conf $PKG/etc/ntp
44 install -m 755 $SRC/ntpd $PKG/etc/rc.d
45
46 # initialize ntp.drift file
47 echo "0.0" > $PKG/var/lib/ntp/ntp.drift
48 }
|