diff options
author | Lars Wendler <polynomial-c@gentoo.org> | 2018-01-06 23:08:03 +0100 |
---|---|---|
committer | Lars Wendler <polynomial-c@gentoo.org> | 2018-01-06 23:08:21 +0100 |
commit | ba57a1180fb0342c70b208cebf4a763ab020d5d6 (patch) | |
tree | 5c1059dee8b4d25aa89555304d7db1ab182c063f /sys-fs | |
parent | xfce-extra/xfce4-power-manager: Remove redundant dep on consolekit (diff) | |
download | gentoo-ba57a1180fb0342c70b208cebf4a763ab020d5d6.tar.gz gentoo-ba57a1180fb0342c70b208cebf4a763ab020d5d6.tar.bz2 gentoo-ba57a1180fb0342c70b208cebf4a763ab020d5d6.zip |
sys-fs/udftools: Revbumps to use fixed init script.
Closes: https://bugs.gentoo.org/642770
Package-Manager: Portage-2.3.19, Repoman-2.3.6
Diffstat (limited to 'sys-fs')
-rw-r--r-- | sys-fs/udftools/files/pktcdvd.init | 29 | ||||
-rw-r--r-- | sys-fs/udftools/udftools-1.1-r1.ebuild (renamed from sys-fs/udftools/udftools-1.1.ebuild) | 2 | ||||
-rw-r--r-- | sys-fs/udftools/udftools-1.3-r1.ebuild (renamed from sys-fs/udftools/udftools-1.3.ebuild) | 2 | ||||
-rw-r--r-- | sys-fs/udftools/udftools-2.0-r1.ebuild (renamed from sys-fs/udftools/udftools-2.0.ebuild) | 0 |
4 files changed, 18 insertions, 15 deletions
diff --git a/sys-fs/udftools/files/pktcdvd.init b/sys-fs/udftools/files/pktcdvd.init index 97375411e0e2..97bd34368240 100644 --- a/sys-fs/udftools/files/pktcdvd.init +++ b/sys-fs/udftools/files/pktcdvd.init @@ -1,13 +1,16 @@ #!/sbin/openrc-run -# Copyright 1999-2005 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License, v2 +command="/usr/sbin/pktsetup" +devdir="/dev/pktcdvd" + depend() { need localmount modules } checkconfig() { - if ! [ -e /dev/pktcdvd/control ]; then + if ! [ -e "${devdir}/control" ] ; then eerror "Could not find packet-writing control device at /dev/pktcdvd/control" eerror "Please ensure that your kernel includes packet writing support," eerror "and if modular, ensure that the module is loaded." @@ -16,20 +19,21 @@ checkconfig() { } get_rw_devices() { - devices_raw=$(sed -re '/^drive name:/I!d; s/.*:\s+//' /proc/sys/dev/cdrom/info) + local sys_file="/proc/sys/dev/cdrom/info" + devices_raw=$(sed -re '/^drive name:/I!d; s/.*:\s+//' ${sys_file}) count=0 - for i in $devices_raw; do + for i in ${devices_raw} ; do eval "devices_$count=\"\$i\"" count=$(( $count + 1 )) done devs="" - cdrw_caps=$(sed -re '/^Can write CD-RW:/I!d; s/.*:\s+//' /proc/sys/dev/cdrom/info) + cdrw_caps=$(sed -re '/^Can write CD-RW:/I!d; s/.*:\s+//' ${sys_file}) count=0 - for i in $cdrw_caps; do + for i in ${cdrw_caps} ; do [ "$i" -eq 1 ] && eval "devs=\"\$devs \$devices_$count\"" - count=$(( $count + 1 )) + count=$(( ${count} + 1 )) done echo ${devs} @@ -43,10 +47,10 @@ start() { devnode="/dev/${i}" [ -e "${devnode}" ] || continue - /usr/bin/pktsetup "${i}" "${devnode}" > /dev/null - [ -e "/dev/pktcdvd/${i}" ] || continue - chmod 660 "/dev/pktcdvd/${i}" - chgrp cdrw "/dev/pktcdvd/${i}" + ${command} "${i}" "${devnode}" > /dev/null + [ -e "${devdir}/${i}" ] || continue + chmod 660 "${devdir}/${i}" + chgrp cdrw "${devdir}/${i}" done } @@ -55,7 +59,6 @@ stop() { for i in $(get_rw_devices) do - /usr/bin/pktsetup -d "${i}" > /dev/null + ${command} -d "${i}" > /dev/null done } - diff --git a/sys-fs/udftools/udftools-1.1.ebuild b/sys-fs/udftools/udftools-1.1-r1.ebuild index efaa1d7e62cc..f0ef22a1e86d 100644 --- a/sys-fs/udftools/udftools-1.1.ebuild +++ b/sys-fs/udftools/udftools-1.1-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI="5" diff --git a/sys-fs/udftools/udftools-1.3.ebuild b/sys-fs/udftools/udftools-1.3-r1.ebuild index d2a858cd9b0a..cd7b7e75dada 100644 --- a/sys-fs/udftools/udftools-1.3.ebuild +++ b/sys-fs/udftools/udftools-1.3-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI="5" diff --git a/sys-fs/udftools/udftools-2.0.ebuild b/sys-fs/udftools/udftools-2.0-r1.ebuild index c5a2970d94c8..c5a2970d94c8 100644 --- a/sys-fs/udftools/udftools-2.0.ebuild +++ b/sys-fs/udftools/udftools-2.0-r1.ebuild |