diff options
author | Omar Vega Ramos <ovruni@gnu.org.pe> | 2016-03-18 20:20:54 -0500 |
---|---|---|
committer | Omar Vega Ramos <ovruni@gnu.org.pe> | 2016-03-18 20:20:54 -0500 |
commit | 27d7c91f4cbfc3e774be535855ba4b7427aa623b (patch) | |
tree | 7c77ab86912e6c4ff0fa1058c52b59b23adc8ee0 | |
parent | 6fee4a09ee12c43bd0bc9f702aec4b7dd0d53a08 (diff) |
udev-openrc: clean up build
-rw-r--r-- | pcr/udev-openrc/PKGBUILD | 27 | ||||
-rw-r--r-- | pcr/udev-openrc/kmod-static-nodes.initd | 19 |
2 files changed, 27 insertions, 19 deletions
diff --git a/pcr/udev-openrc/PKGBUILD b/pcr/udev-openrc/PKGBUILD index af3c6df06..811da1f73 100644 --- a/pcr/udev-openrc/PKGBUILD +++ b/pcr/udev-openrc/PKGBUILD @@ -1,7 +1,8 @@ # Maintainer (Manjaro): artoo <artoo@manjaro.org> # Maintainer: Omar Vega Ramos <ovruni@gnu.org.pe> -_url="https://raw.githubusercontent.com/gentoo/gentoo/master" +_url="http://dev.gentoo.org/~williamh/dist" +_pkgname=udev-init-scripts pkgname=udev-openrc pkgver=30 @@ -13,26 +14,13 @@ license=('GPL2') groups=('openrc-base' 'openrc-desktop') depends=('openrc' 'udev') conflicts=('systemd-sysvcompat') -source=("http://dev.gentoo.org/~williamh/dist/udev-init-scripts-${pkgver}.tar.gz" - "kmod-static-nodes.initd::${_url}/sys-apps/kmod/files/kmod-static-nodes-r1") +source=("${_url}/${_pkgname}-${pkgver}.tar.gz" + "kmod-static-nodes.initd") sha256sums=('4de998d68e28f8ce4c1d4c9955aec0fa4cfe84673cbf3bfe1be71a1e9918693f' - 'b9452437b06aae67e19e2cade37e89398ab5a7162318e15d1ed083606b1fe7e0') - -_inst_initd(){ - install -Dm755 ${srcdir}/$1.initd ${pkgdir}/etc/init.d/$1 - - sed -e 's|#!/sbin/runscript|#!/usr/bin/openrc-run|' \ - -e 's|#!/sbin/openrc-run|#!/usr/bin/openrc-run|' \ - -e 's|/var/run|/run|g' \ - -i ${pkgdir}/etc/init.d/$1 -} - -_inst_confd(){ - install -Dm755 ${srcdir}/$1.confd ${pkgdir}/etc/conf.d/$1 -} + '3ecbe7761b92a123a5a3d395ec3d9e090b0dfba7910a5987b4a2298c20a7e571') package(){ - cd "${srcdir}/udev-init-scripts-${pkgver}" + cd "${srcdir}/${_pkgname}-${pkgver}" make DESTDIR="${pkgdir}" install for f in ${pkgdir}/etc/init.d/*;do sed -e "s|#!/sbin/openrc-run|#!/usr/bin/openrc-run|" \ @@ -42,11 +30,12 @@ package(){ -i "$f" done install -d "${pkgdir}/etc/runlevels/sysinit" + ln -sf "/etc/init.d/udev" "${pkgdir}/etc/runlevels/sysinit/udev" ln -sf "/etc/init.d/udev-trigger" "${pkgdir}/etc/runlevels/sysinit/udev-trigger" # kmod-static-nodes - _inst_initd 'kmod-static-nodes' + install -Dm755 ${srcdir}/kmod-static-nodes.initd ${pkgdir}/etc/init.d/kmod-static-nodes ln -sf "/etc/init.d/kmod-static-nodes" "${pkgdir}/etc/runlevels/sysinit/kmod-static-nodes" } diff --git a/pcr/udev-openrc/kmod-static-nodes.initd b/pcr/udev-openrc/kmod-static-nodes.initd new file mode 100644 index 000000000..7a3f529dc --- /dev/null +++ b/pcr/udev-openrc/kmod-static-nodes.initd @@ -0,0 +1,19 @@ +#!/usr/bin/openrc-run +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +description="Create list of required static device nodes for the current kernel" + +depend() { + after dev-mount + before tmpfiles.dev dev + keyword -lxc -systemd-nspawn +} + +start() { + ebegin "Creating list of required static device nodes for the current kernel" + checkpath -q -d /run/tmpfiles.d + kmod static-nodes --format=tmpfiles --output=/run/tmpfiles.d/kmod.conf + eend $? +} |