diff options
Diffstat (limited to 'media-tv')
-rw-r--r-- | media-tv/gentoo-vdr-scripts/ChangeLog | 9 | ||||
-rw-r--r-- | media-tv/gentoo-vdr-scripts/Manifest | 10 | ||||
-rw-r--r-- | media-tv/gentoo-vdr-scripts/gentoo-vdr-scripts-0.5.0.ebuild | 145 |
3 files changed, 159 insertions, 5 deletions
diff --git a/media-tv/gentoo-vdr-scripts/ChangeLog b/media-tv/gentoo-vdr-scripts/ChangeLog index 6e7e1542d524..8c9ad19839c3 100644 --- a/media-tv/gentoo-vdr-scripts/ChangeLog +++ b/media-tv/gentoo-vdr-scripts/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for media-tv/gentoo-vdr-scripts # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-tv/gentoo-vdr-scripts/ChangeLog,v 1.116 2012/02/20 11:38:43 hd_brummy Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-tv/gentoo-vdr-scripts/ChangeLog,v 1.117 2012/02/23 23:58:53 hd_brummy Exp $ + +*gentoo-vdr-scripts-0.5.0 (23 Feb 2012) + + 23 Feb 2012; Joerg Bornkessel <hd_brummy@gentoo.org> + +gentoo-vdr-scripts-0.5.0.ebuild: + bump; fix bug #331453; new sudo handling, thanks to L.Muresan W.Schricker on + bug #356133 for some inspiration *gentoo-vdr-scripts-0.5.0_rc2 (20 Feb 2012) diff --git a/media-tv/gentoo-vdr-scripts/Manifest b/media-tv/gentoo-vdr-scripts/Manifest index 065d7452d778..a455ef8ffa97 100644 --- a/media-tv/gentoo-vdr-scripts/Manifest +++ b/media-tv/gentoo-vdr-scripts/Manifest @@ -3,17 +3,19 @@ Hash: SHA1 DIST gentoo-vdr-scripts-0.4.7.tar.bz2 35564 RMD160 381c81f51e05e8736615b2f53f13ed4ac29eddc8 SHA1 a7ce08dd43369b2bc1ee8bca0126238c181a5178 SHA256 388181976069ca42dcbe865b7ae19014aa140bb4473f2bc1a085a9fbed79a515 DIST gentoo-vdr-scripts-0.4.9.tar.bz2 36868 RMD160 d6efc87d2bced33dd03291ebd0e231993bf2c604 SHA1 7179904a73ad857a6015dd286b544f077f354dcd SHA256 ea5475347d7a2a3b42f0ea216a659a7440b3d23119902c390d4457f8e6631677 +DIST gentoo-vdr-scripts-0.5.0.tar.bz2 36427 RMD160 e40ef77346243a6ebf50f467532207a009726290 SHA1 d7e46a3fbd30243f76b242aa20c07523e3d62536 SHA256 6af62c47caf952b27b66661c4520e1a044aa73c335ca728174774ccdd1d8225e DIST gentoo-vdr-scripts-0.5.0_rc2.tar.bz2 36236 RMD160 a97e44e60c33a809bef5385c164af077a591454b SHA1 131a6bc742b1f3433f67d6949c6162be3323c999 SHA256 40c11ac4f8d65cb8626b7c719f6db17f114fbf957c4e50e60cb14e7775d9e537 EBUILD gentoo-vdr-scripts-0.4.7.ebuild 3826 RMD160 847e895f87267bf1c8c988bd3eb807dacecabaa6 SHA1 9e136ed7bda95bd0e990b9f1e9f502af6fdd4bd1 SHA256 1920e8cd78a2787a3682d9056a2b580707cbd91f4196a104eda1a04d86f323ca EBUILD gentoo-vdr-scripts-0.4.9.ebuild 3600 RMD160 a13cbb094bf4119e1b14e35d564932de443dacea SHA1 7af040a791412d89bab11cd05001badc8bbb5de6 SHA256 7f8573744e7f2cadccda59ad88397191396d3f9b4f0ea72d4050f5e320119d87 +EBUILD gentoo-vdr-scripts-0.5.0.ebuild 3921 RMD160 a4d1241a11633cc2305e84816bfa7e89b9d5f0a5 SHA1 c09005c5e97611534b40eae18c71221cea7eb1fc SHA256 2673dc96e9af494648c520b5a7a170c8b79d3a6d57319cb5aba9d893b983e0bb EBUILD gentoo-vdr-scripts-0.5.0_rc2.ebuild 3606 RMD160 1cda6c23d347a534ba21384d1193d636c2b11e3a SHA1 ec903b35d2e2b11118e26e61ae7b1ebf01b6537a SHA256 7229cce8d95e489d4d75d932edba3353da43b268fabed2297144eacb61adf48e -MISC ChangeLog 23126 RMD160 d5de568b7ef99f0a2e8564d4d2864382df595f0d SHA1 3798e93aad96ccb554e712fa814121e660fed406 SHA256 c9213656ddf0cc0faa00fd9d09958eb08085d5184231f7254e487559f6fdc64c +MISC ChangeLog 23373 RMD160 2375df8eb65be9e097fd6e19eb07594ef8afb95d SHA1 7f74878fed19f4657d3f457eb5ec5960095df893 SHA256 08e8a7dab5f608ac47feb6c4d62c0310b789004f8fdc4159207ef3e3795cd2b1 MISC metadata.xml 366 RMD160 2c6ee9297820274dce664dfc05d65b36b5342984 SHA1 6e0c2ac753886340601e6058e5c306e0fbc1c760 SHA256 a92d2326d3f734f176d63173dd3a19fa2cd3b9744ee142cd3e4fb0771d08fd29 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (GNU/Linux) Comment: added by hd_brummy@gentoo.org -iD8DBQFPQjD5dn07HTTCgIoRAqXtAJ9rZDncAY3piGRsi8lQPu61OETUMwCggABv -4Ey0Gx24bIaRVfZFIPPpZKw= -=miBN +iD8DBQFPRtLIdn07HTTCgIoRAgyZAJ9J1QjLopVULw6oTAwhO0Qqy+KU/ACfY+va +xPJhQEk79BP5BPG25k05UhQ= +=AnHu -----END PGP SIGNATURE----- diff --git a/media-tv/gentoo-vdr-scripts/gentoo-vdr-scripts-0.5.0.ebuild b/media-tv/gentoo-vdr-scripts/gentoo-vdr-scripts-0.5.0.ebuild new file mode 100644 index 000000000000..1a3cbcd3409b --- /dev/null +++ b/media-tv/gentoo-vdr-scripts/gentoo-vdr-scripts-0.5.0.ebuild @@ -0,0 +1,145 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/media-tv/gentoo-vdr-scripts/gentoo-vdr-scripts-0.5.0.ebuild,v 1.1 2012/02/23 23:58:53 hd_brummy Exp $ + +EAPI="4" + +inherit eutils + +DESCRIPTION="Scripts necessary for use of vdr as a set-top-box" +HOMEPAGE="http://www.gentoo.org/" +SRC_URI="mirror://gentoo/${P}.tar.bz2 + http://dev.gentoo.org/~hd_brummy/distfiles/${P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~arm ~ppc ~x86" +IUSE="nvram" + +RDEPEND="nvram? ( sys-power/nvram-wakeup ) + app-admin/sudo + sys-process/wait_on_pid" + +VDR_HOME=/var/vdr + +pkg_setup() { + enewgroup vdr + + # Add user vdr to these groups: + # video - accessing dvb-devices + # audio - playing sound when using software-devices + # cdrom - playing dvds/audio-cds ... + enewuser vdr -1 /bin/bash "${VDR_HOME}" vdr,video,audio,cdrom +} + +src_prepare() { + # moved into own package + sed -e '/SUBDIRS =/s# bin # #' -i usr/Makefile + sed -e '/all:/s#compile##' -i Makefile +} + +src_install() { + emake -s install DESTDIR="${D}" || die "make install failed" + dodoc README TODO ChangeLog + + # create necessary directories + diropts -ovdr -gvdr + keepdir "${VDR_HOME}" + + local kd + for kd in shutdown-data merged-config-files dvd-images tmp; do + keepdir "${VDR_HOME}/${kd}" + done +} + +pkg_preinst() { + local PLUGINS_NEW=0 + if [[ -f "${ROOT}"/etc/conf.d/vdr.plugins ]]; then + PLUGINS_NEW=$(grep -v '^#' "${ROOT}"/etc/conf.d/vdr.plugins |grep -v '^$'|wc -l) + fi + if [[ ${PLUGINS_NEW} > 0 ]]; then + cp "${ROOT}"/etc/conf.d/vdr.plugins "${D}"/etc/conf.d/vdr.plugins + else + einfo "Migrating PLUGINS setting from /etc/conf.d/vdr to /etc/conf.d/vdr.plugins" + local PLUGIN + for PLUGIN in $(source "${ROOT}"/etc/conf.d/vdr;echo $PLUGINS); do + echo ${PLUGIN} >> "${D}"/etc/conf.d/vdr.plugins + done + fi + + has_version "<${CATEGORY}/${PN}-0.5.0_rc3" + previous_less_than_0_5_0_rc3=$? +} + +VDRSUDOENTRY="vdr ALL=NOPASSWD:/usr/share/vdr/bin/vdrshutdown-really.sh" + +pkg_postinst() { + if [[ $previous_less_than_0_5_0_rc3 = 0 ]] ; then + + if grep -q /usr/share/vdr/bin/vdrshutdown-really.sh "${ROOT}"/etc/sudoers; then + eerror + eerror "Depricated sudo entry in /etc/sudoers" + eerror + fi + + einfo "new file /etc/sudoers.d/vdr added" + echo + ewarn "IMPORTEND !!!" + ewarn "Please migrate to new sudo handling" + echo + ewarn "Upgrade Info:" + ewarn + ewarn "To keep the shutdown work correctly, remove the line from /etc/sudoers" + ewarn "\t${VDRSUDOENTRY}" + echo + ewarn "or execute this command:" + ewarn "\temerge --config gentoo-vdr-scripts" + echo + fi + + elog "nvram wakeup is optional." + elog "To make use of it emerge sys-power/nvram-wakeup." + elog + + elog "Plugins which should be used are now set via its" + elog "own config-file called /etc/conf.d/vdr.plugins" + elog "or enabled via the frontend eselect vdr-plugin." + elog + + if [[ -f "${ROOT}/etc/init.d/dvbsplash" ]]; then + ewarn + ewarn "You have dvbsplash installed!" + ewarn "/etc/init.d/dvbsplash will now be deleted" + ewarn "as it causes difficult to debug problems." + ewarn + rm "${ROOT}/etc/init.d/dvbsplash" + fi + + if [[ -f "${ROOT}"/etc/conf.d/vdr.dvdswitch ]] && + grep -q ^DVDSWITCH_BURNSPEED= "${ROOT}"/etc/conf.d/vdr.dvdswitch + then + ewarn "You are setting DVDSWITCH_BURNSPEED in /etc/conf.d/vdr.dvdswitch" + ewarn "This no longer has any effect, please use" + ewarn "VDR_DVDBURNSPEED in /etc/conf.d/vdr.cd-dvd" + fi +} + +pkg_config() { + if grep -q /usr/share/vdr/bin/vdrshutdown-really.sh "${ROOT}"/etc/sudoers; then + + einfo "Removing depricated entry from /etc/sudoers:" + einfo "- ${VDRSUDOENTRY}" + + cd "${T}" + cat >sudoedit-vdr.sh <<-SUDOEDITOR + #!/bin/bash + sed -i \${1} -e '/\/usr\/share\/vdr\/bin\/vdrshutdown-really.sh *$/d' + + SUDOEDITOR + chmod a+x sudoedit-vdr.sh + + VISUAL="${T}"/sudoedit-vdr.sh visudo -f "${ROOT}"/etc/sudoers || die "visudo failed" + + einfo "Edited /etc/sudoers" + fi +} |