commit:     24b4b5f2e6e5a748ea45ac666dfbfbd27c8e7283
Author:     Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
AuthorDate: Wed Dec 11 19:48:44 2019 +0000
Commit:     Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
CommitDate: Wed Dec 11 19:50:15 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=24b4b5f2

media-plugins/vdr-radio: install into paths t should be created at rntime

fixed installs into paths that should be created at runtime
now it will be created at start

Package-Manager: Portage-2.3.79, Repoman-2.3.18
Signed-off-by: Joerg Bornkessel <hd_brummy <AT> gentoo.org>

 media-plugins/vdr-radio/files/rc-addon.sh       | 17 +++++++++++++++--
 media-plugins/vdr-radio/files/rc-addon.sh-0.2.0 | 15 ---------------
 media-plugins/vdr-radio/vdr-radio-0.9.1.ebuild  | 11 ++++-------
 3 files changed, 19 insertions(+), 24 deletions(-)

diff --git a/media-plugins/vdr-radio/files/rc-addon.sh 
b/media-plugins/vdr-radio/files/rc-addon.sh
index fbd4d6e94b3..9c21c783530 100644
--- a/media-plugins/vdr-radio/files/rc-addon.sh
+++ b/media-plugins/vdr-radio/files/rc-addon.sh
@@ -2,12 +2,25 @@
 # rc-addon plugin-startup-skript for vdr-radio
 # 
 # This sript is called by gentoo-vdr-scripts on start of VDR
+#
+# Joerg Bornkessel <hd_bru...@astrali.de>
 
 # Set default DIR to the background picture
 RADIO_BACKGROUND_DIR=/usr/share/vdr/radio
+# Set default DIR for cache
+RADIO_TMP_DIR=/var/cache/vdr-radio
 
-plugin_pre_vdr_start() {
+_make_cachedir() {
+       if [ ! -e "${RADIO_TMP_DIR}" ]; then
+               mkdir "${RADIO_TMP_DIR}"
+               chown -R vdr:vdr "${RADIO_TMP_DIR}"
+       fi
+}
 
-    add_plugin_param "-f ${RADIO_BACKGROUND_DIR}"
+_make_cachedir
+
+plugin_pre_vdr_start() {
 
+       add_plugin_param "-f ${RADIO_BACKGROUND_DIR}"
+       add_plugin_param "-d ${RADIO_TMP_DIR}"
 }

diff --git a/media-plugins/vdr-radio/files/rc-addon.sh-0.2.0 
b/media-plugins/vdr-radio/files/rc-addon.sh-0.2.0
deleted file mode 100644
index ce83253073a..00000000000
--- a/media-plugins/vdr-radio/files/rc-addon.sh-0.2.0
+++ /dev/null
@@ -1,15 +0,0 @@
-#
-# rc-addon plugin-startup-skript for vdr-radio
-# 
-# This sript is called by gentoo-vdr-scripts on start of VDR
-
-# Set default DIR to the background picture
-RADIO_BACKGROUND_DIR=/usr/share/vdr/radio
-RADIO_TMP_DIR=/var/cache/vdr-radio
-
-plugin_pre_vdr_start() {
-
-    add_plugin_param "-f ${RADIO_BACKGROUND_DIR}"
-    add_plugin_param "-d ${RADIO_TMP_DIR}"
-
-}

diff --git a/media-plugins/vdr-radio/vdr-radio-0.9.1.ebuild 
b/media-plugins/vdr-radio/vdr-radio-0.9.1.ebuild
index 1ea94e5f574..b91b2138f6d 100644
--- a/media-plugins/vdr-radio/vdr-radio-0.9.1.ebuild
+++ b/media-plugins/vdr-radio/vdr-radio-0.9.1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2018 Gentoo Foundation
+# Copyright 1999-2019 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
@@ -14,15 +14,15 @@ SLOT="0"
 KEYWORDS="~amd64 ~x86"
 IUSE=""
 
-RDEPEND=">=media-video/vdr-1.7.34"
+RDEPEND="media-video/vdr"
 DEPEND="${RDEPEND}"
 
-VDR_RCADDON_FILE="${FILESDIR}/rc-addon.sh-0.2.0"
+VDR_RCADDON_FILE="${FILESDIR}/rc-addon.sh"
 
 src_install() {
        vdr-plugin-2_src_install
 
-       cd "${S}"/config
+       cd "${S}"/config || die "Can't enter source folder"
 
        insinto /usr/share/vdr/radio
        doins mpegstill/rtext*
@@ -31,7 +31,4 @@ src_install() {
 
        exeinto /usr/share/vdr/radio
        doexe scripts/radioinfo*
-
-       diropts -m 755 -o vdr -g vdr
-       keepdir "/var/cache/vdr-radio"
 }

Reply via email to