ntp: install service files depending your init

This commit is contained in:
Victor Tebar
2023-11-03 19:58:23 +00:00
parent 1fa78ca509
commit 4ca53731d0
2 changed files with 7 additions and 6 deletions

View File

@@ -1,12 +1,8 @@
ntp-4.2.8p17-1
ntp-4.2.8p17-2
drwxr-xr-x root/root etc/
-rw-r--r-- root/root etc/ntp.conf
drwxr-xr-x root/root etc/rc.d/
-rwxr-xr-x root/root etc/rc.d/ntpd
drwxr-xr-x root/root etc/sv/
drwxr-xr-x root/root etc/sv/ntpd/
-rwxr-xr-x root/root etc/sv/ntpd/run
lrwxrwxrwx root/root etc/sv/ntpd/supervise -> /run/runit/supervise.ntpd
drwxr-xr-x root/root usr/
drwxr-xr-x root/root usr/lib/
drwxr-xr-x root/root usr/lib/ntp/

View File

@@ -3,7 +3,7 @@
name=ntp
version=4.2.8p17
release=1
release=2
source="https://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-${version%.*}/$name-$version.tar.gz
run.ntpd
rc.ntpd"
@@ -59,9 +59,14 @@ restrict 127.0.0.1
restrict ::1
EOF
_runit() {
# runit service
install -Dm755 $SRC/run.ntpd $PKG/etc/sv/ntpd/run
ln -s /run/runit/supervise.ntpd $PKG/etc/sv/ntpd/supervise
}
_sysv() {
# rc service
install -Dm755 $SRC/rc.ntpd $PKG/etc/rc.d/ntpd
}
scratch isinstalled runit && _runit || _sysv
}