summaryrefslogtreecommitdiff
path: root/ntp/Pkgfile
blob: dabf96c1bc3ed272677f6c2d30aaa85f746e7afc (plain)
    1 # Description: Network Time Protocol software
    2 # URL:         http://www.ntp.org
    3 # Maintainer:  Thomas Penteker, tek at serverop dot de
    4 # Packager:    James Mills, prologic at shortcircuit dot net dot au
    5 # Depends on:  openssl
    6 
    7 name=ntp
    8 version=4.2.4p5
    9 release=2
   10 source=(http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/$name-$version.tar.gz
   11         ntpd
   12         ntpdate
   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    install -m 755 $SRC/ntpdate $PKG/etc/rc.d
   46 
   47    # initialize ntp.drift file
   48    echo "0.0" > $PKG/var/lib/ntp/ntp.drift
   49 }

Generated by cgit