usbip: added runit service.

This commit is contained in:
Juan RP 2014-10-13 14:30:59 +02:00
parent a1cfbd87d7
commit 4f326bf34c
2 changed files with 10 additions and 5 deletions

View file

@ -0,0 +1,3 @@
#!/bin/sh
modprobe -q usbip || exit 1
exec usbipd

View file

@ -1,7 +1,7 @@
# Template file for 'linux-tools'
pkgname=linux-tools
version=3.16
revision=2
revision=3
wrksrc="linux-${version}"
short_desc="Linux kernel tools meta-pkg"
hostmakedepends="flex perl>=5.20 asciidoc xmlto python automake libtool"
@ -24,6 +24,7 @@ if [ "$XBPS_TARGET_MACHINE" = "i686" -o "$XBPS_TARGET_MACHINE" = "x86_64" ]; the
fi
nocross=yes
build_options="systemd"
do_build() {
cd ${wrksrc}/tools/perf
@ -80,7 +81,6 @@ do_install() {
vmkdir usr/lib/modules-load.d
printf 'usbip-core\nusbip-host\n' > \
${DESTDIR}/usr/lib/modules-load.d/usbip.conf
vinstall ${FILESDIR}/usbipd.service 644 usr/lib/systemd/system
if [ "$XBPS_TARGET_MACHINE" = "i686" -o "$XBPS_TARGET_MACHINE" = "x86_64" ]; then
# x86_energy_perf_policy
@ -158,14 +158,16 @@ x86_energy_perf_policy_package() {
vmove usr/share/man/man8/x86_energy_perf_policy.8
}
}
usbip_package() {
short_desc="An USB device sharing system over IP network"
systemd_services="usbipd.service"
replaces="runit-void<20141013_2"
pkg_install() {
vmove "usr/bin/usbip*"
vmove "usr/share/man/man8/usbip*"
vmove usr/lib/modules-load.d/usbip.conf
vmove usr/lib/systemd/system/usbipd.service
vsv usbipd
if [ "$build_option_systemd" ]; then
vinstall ${FILESDIR}/usbipd.service 644 usr/lib/systemd/system
fi
}
}