tlp : install service files by init

This commit is contained in:
Victor Tebar
2023-11-03 20:32:56 +00:00
parent 54a0f191e2
commit e76c6e2cf0
2 changed files with 7 additions and 8 deletions

View File

@@ -1,14 +1,9 @@
tlp-1.6.1-1
tlp-1.6.1-2
drwxr-xr-x root/root etc/
drwxr-xr-x root/root etc/init.d/
-rwxr-xr-x root/root etc/init.d/tlp
drwxr-xr-x root/root etc/rc.d/
-rwxr-xr-x root/root etc/rc.d/tlpd
drwxr-xr-x root/root etc/sv/
drwxr-xr-x root/root etc/sv/tlpd/
-rwxr-xr-x root/root etc/sv/tlpd/finish
-rwxr-xr-x root/root etc/sv/tlpd/run
lrwxrwxrwx root/root etc/sv/tlpd/supervise -> /run/runit/supervise.tlpd
-rw-r--r-- root/root etc/tlp.conf
drwxr-xr-x root/root etc/tlp.d/
-rw-r--r-- root/root etc/tlp.d/00-template.conf

View File

@@ -3,7 +3,7 @@
name=tlp
version=1.6.1
release=1
release=2
source="https://github.com/linrunner/TLP/archive/$version/$name-$version.tar.gz
rc.tlpd
run.tlpd
@@ -13,11 +13,15 @@ build() {
cd TLP-$version
make DESTDIR=$PKG install
_runit() {
# runit service
install -Dm755 $SRC/run.tlpd $PKG/etc/sv/tlpd/run
install -Dm755 $SRC/finish.tlpd $PKG/etc/sv/tlpd/finish
ln -s /run/runit/supervise.tlpd $PKG/etc/sv/tlpd/supervise
}
_sysv() {
# rc service
install -Dm755 $SRC/rc.tlpd $PKG/etc/rc.d/tlpd
}
scratch isinstalled runit && _runit || _sysv
}