wok-next view ntpclient/receipt @ rev 20730
glib: up (2.56.1) with static libs and Python2
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Tue May 29 15:17:41 2018 +0300 (2018-05-29) |
parents | b278b2018965 |
children | d5aab818505e |
line source
1 # SliTaz package receipt v2.
3 PACKAGE="ntpclient"
4 VERSION="2015_365"
5 CATEGORY="system-tools"
6 SHORT_DESC="Tiny NTP Client"
7 MAINTAINER="erjo@slitaz.org"
8 LICENSE="GPL2"
9 WEB_SITE="http://doolittle.icarus.com/ntpclient/"
11 TARBALL="${PACKAGE}_$VERSION.tar.gz"
12 WGET_URL="$WEB_SITE$TARBALL"
14 compile_rules() {
15 # disable debug
16 sed -i 's/\(^CFLAGS += -DENABLE_DEBUG\)/#\1/' Makefile &&
17 make &&
18 install -Dm 755 $src/ntpclient $install/usr/bin/ntpclient
19 }
21 genpkg_rules() {
22 copy @std
23 }
25 post_install() {
26 [ -n "$1" -o -n "$quiet" ] && return
27 echo -en '\nDo you want to run ntpclient in automatic mode (y/N): '
28 read -t 30 anser
29 if [ "$anser" == 'y' ]; then
30 srv='fr.pool.ntp.org'
31 action 'Setting up crontab for ntpclient...'
32 crontab -l 2>/dev/null | grep -q '/usr/bin/ntpclient -s -h' ||
33 crontab - -u root <<EOT
34 $(crontab -l 2>/dev/null)
35 0 0 * * * /usr/bin/ntpclient -s -h $srv
36 EOT
37 else
38 cat <<EOT
40 .------------------------------.
41 | Don't forget to run: |
42 | |
43 | ntpclient -s -h <NTP Server> |
44 '------------------------------'
45 EOT
46 fi
47 }