commit: c58da727b48f86495eb0906cba0a973dc157b187 Author: Martin Dummer <martin.dummer <AT> gmx <DOT> net> AuthorDate: Thu Oct 2 20:42:57 2025 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Fri Oct 3 16:21:56 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c58da727
media-plugins/vdr-live: add 3.5.1 Closes: https://bugs.gentoo.org/963533 Closes: https://bugs.gentoo.org/837995 Closes: https://bugs.gentoo.org/948667 Closes: https://bugs.gentoo.org/955348 Signed-off-by: Martin Dummer <martin.dummer <AT> gmx.net> Part-of: https://github.com/gentoo/gentoo/pull/44015 Closes: https://github.com/gentoo/gentoo/pull/44015 Signed-off-by: Sam James <sam <AT> gentoo.org> media-plugins/vdr-live/Manifest | 1 + media-plugins/vdr-live/files/confd | 41 +++++++++++++++ media-plugins/vdr-live/files/rc-addon.sh | 33 ++++++++++++ media-plugins/vdr-live/vdr-live-3.5.1.ebuild | 78 ++++++++++++++++++++++++++++ 4 files changed, 153 insertions(+) diff --git a/media-plugins/vdr-live/Manifest b/media-plugins/vdr-live/Manifest index 96e6185d9397..479e1e5d7f2a 100644 --- a/media-plugins/vdr-live/Manifest +++ b/media-plugins/vdr-live/Manifest @@ -1 +1,2 @@ DIST vdr-live-3.0.6.tar.gz 737583 BLAKE2B e9fd7f95df7c3fcd11e9e63131c948c1d318e2bb0c5cbc2fab950abc2889df8ca8a33b71f5394b3c22c45f81ee1faf1bf71ca889ae64173be8965db6f6fbd8ac SHA512 f60cd14c3a02eeb571ffc181dabd83dd0af0595d378ed34bc9cee1d54b560d74027c758d3b4d69541a71dc6f94b5f64e3972fc51aeb5a9d688be7656636bcf98 +DIST vdr-live-3.5.1.tar.gz 2651284 BLAKE2B 3affc04d7c7053237f2856392d2f8dc4bad22e8980afcbed26bfd0300b5419028de4bdfb28b8507a9069979a865be10e8f5c25d014878b87a904fb95314bfeb7 SHA512 b928700185112b3e3bbcec163de2c195188d4849f593ce0a3d685a1c966af03deb98c2e4ca7b29a903caeef62779ac88f4c982d311c36c53118c2b8f74620440 diff --git a/media-plugins/vdr-live/files/confd b/media-plugins/vdr-live/files/confd new file mode 100644 index 000000000000..854d6c92eade --- /dev/null +++ b/media-plugins/vdr-live/files/confd @@ -0,0 +1,41 @@ +# configuration of media-plugins/vdr-live + +# for people who want more security with ssl access +# +# SSL ADDRESS --> https://<your-ip>:8443/ +# +# allowed values: yes no +# default: no +# +#LIVE_USE_SSL="yes" + +# default TCP portnumbers for live webserver +# +#LIVE_PORT="8008" +#LIVE_SSL_PORT="8443" + +# default installation of the LIVE plugin creates a self-signed certificate +# which has a lifetime of 365 days = 1 year +# +# If you want to replace this certificate with a new one, execute +# emerge --config vdr-live +# +# If you want a different certificate, store certificate and keyfile in +# /etc/vdr/plugins/live/ +# For security, make sure the keyfile is only readable by the vdr user! +# +# default: +#LIVE_SSL_CERTFILE="/etc/vdr/plugins/live/live.pem" +#LIVE_SSL_KEYFILE="/etc/vdr/plugins/live/live-key.pem" + +# bind webserver to IP addresses +# default: 0.0.0.0 (all IP addresses) +# +LIVE_BIND_IPS="127.0.0.1" + +# for people who have epgimages +# if the directory exists, it will be added to LIVE +# set this to your own path, if needed +# +# default: +#EPGIMAGES_DIR="/var/cache/vdr/epgimages" diff --git a/media-plugins/vdr-live/files/rc-addon.sh b/media-plugins/vdr-live/files/rc-addon.sh new file mode 100644 index 000000000000..ae05679ab365 --- /dev/null +++ b/media-plugins/vdr-live/files/rc-addon.sh @@ -0,0 +1,33 @@ +# +# [email protected] +# [email protected] +# [email protected] + +plugin_pre_vdr_start() { + if [ "${LIVE_USE_SSL:=no}" = "yes" ]; then + if [ -n "${LIVE_SSL_PORT}" ]; then + add_plugin_param "-s ${LIVE_SSL_PORT}" + fi + if [ -n "${LIVE_SSL_CERTFILE}" -a -n "${LIVE_SSL_KEYFILE}" ]; then + add_plugin_param "--cert=${LIVE_SSL_CERTFILE}" + add_plugin_param "--key=${LIVE_SSL_KEYFILE}" + fi + else + add_plugin_param "-s 0" + fi + + if [ -n "${LIVE_PORT}" ]; then + add_plugin_param "-p ${LIVE_PORT}" + fi + + if [ -d ${EPGIMAGES_DIR:=/var/cache/vdr/epgimages} ]; then + add_plugin_param "--epgimages=${EPGIMAGES_DIR}" + fi + + if [ -n "${LIVE_BIND_IPS}" ]; then + local ip + for ip in ${LIVE_BIND_IPS}; do + add_plugin_param "-i ${ip}" + done + fi +} diff --git a/media-plugins/vdr-live/vdr-live-3.5.1.ebuild b/media-plugins/vdr-live/vdr-live-3.5.1.ebuild new file mode 100644 index 000000000000..3d3af79df8e9 --- /dev/null +++ b/media-plugins/vdr-live/vdr-live-3.5.1.ebuild @@ -0,0 +1,78 @@ +# Copyright 2022-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit optfeature ssl-cert vdr-plugin-2 + +DESCRIPTION="VDR Plugin: Web Access To Settings" +HOMEPAGE="https://github.com/MarkusEh/vdr-plugin-live" +SRC_URI="https://github.com/MarkusEh/vdr-plugin-live/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" +S="${WORKDIR}/vdr-plugin-live-${PV}" + +LICENSE="Apache-2.0 GPL-2+ RSA" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" + media-video/vdr:= + >=dev-libs/cxxtools-3 + >=dev-libs/tntnet-3[ssl=]" +DEPEND="${RDEPEND}" +BDEPEND=" + acct-user/vdr + sys-apps/which" + +KEEP_I18NOBJECT="yes" +QA_FLAGS_IGNORED=" + usr/lib/vdr/plugins/libvdr-live.* + usr/lib64/vdr/plugins/libvdr-live.*" +LIVE_SSL_KEY_DIR="/etc/vdr/plugins/live" + +make_live_cert() { + elog "Create and install SSL certificate" + SSL_ORGANIZATION="VDR Plugin Live" + SSL_COMMONNAME=$("${ROOT}"/bin/hostname -f) + elog "install_cert ${LIVE_SSL_KEY_DIR}/live for host $SSL_COMMONNAME" + rm -f "${ROOT}${LIVE_SSL_KEY_DIR}/live.pem" "${ROOT}${LIVE_SSL_KEY_DIR}/live-key.pem" || die + install_cert "${ROOT}${LIVE_SSL_KEY_DIR}/live" + ls -la "${ROOT}${LIVE_SSL_KEY_DIR}/" + rm -f "${ROOT}${LIVE_SSL_KEY_DIR}/live.csr" || die + mv "${ROOT}${LIVE_SSL_KEY_DIR}/live.key" "${ROOT}${LIVE_SSL_KEY_DIR}/live-key.pem" || die + mv "${ROOT}${LIVE_SSL_KEY_DIR}/live.crt" "${ROOT}${LIVE_SSL_KEY_DIR}/live.pem" || die + chown vdr:vdr "${ROOT}${LIVE_SSL_KEY_DIR}/live.pem" || die + chown vdr:vdr "${ROOT}${LIVE_SSL_KEY_DIR}/live-key.pem" || die +} + +src_install() { + vdr-plugin-2_src_install + + insinto /usr/share/vdr/plugins/live + doins -r live/* + fowners -R vdr:vdr /usr/share/vdr/plugins/live +} + +pkg_postinst() { + vdr-plugin-2_pkg_postinst + + optfeature "to search the EPG" media-plugins/vdr-epgsearch + optfeature "for Live-TV streaming" media-plugins/vdr-streamdev + elog "The default username/password is:" + elog "\tadmin:live" + + if use ssl; then + # only create a certificate if none exists + if [[ -f ${ROOT}${LIVE_SSL_KEY_DIR}/live.pem ]]; then + elog "Existing SSL cert found, not touching it." + elog "To create a new SSL cert, execute command:" + elog "\temerge --config ${PN}" + else + elog "No SSL cert found, creating a default one now" + make_live_cert + fi + fi +} + +pkg_config() { + make_live_cert +}
