* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2018-01-21 17:55 Joerg Bornkessel
0 siblings, 0 replies; 15+ messages in thread
From: Joerg Bornkessel @ 2018-01-21 17:55 UTC (permalink / raw
To: gentoo-commits
commit: dd27e9b5f899b63e3babb0b39304e463d8789b17
Author: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
AuthorDate: Sun Jan 21 17:53:54 2018 +0000
Commit: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
CommitDate: Sun Jan 21 17:53:54 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=dd27e9b5
media-video/vdr: fixed LINGUAS to L10N handling
Package-Manager: Portage-2.3.20, Repoman-2.3.6
media-video/vdr/files/vdr-2.2.0-r2_gentoo.patch | 76 ++++++
media-video/vdr/vdr-2.2.0-r2.ebuild | 298 ++++++++++++++++++++++++
2 files changed, 374 insertions(+)
diff --git a/media-video/vdr/files/vdr-2.2.0-r2_gentoo.patch b/media-video/vdr/files/vdr-2.2.0-r2_gentoo.patch
new file mode 100644
index 00000000000..8bdae36ae51
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.2.0-r2_gentoo.patch
@@ -0,0 +1,76 @@
+Support L10N Variable in make.conf to select only the Language will be installed
+as it set in make.conf L10N
+(befor it was LINGUAS)
+correct some install path for libsi
+correct install in the right order
+signed-of-by: Joerg Bornkessel <hd_brummy@gentoo.org> (2018/Jan/21)
+diff -Naur vdr-2.1.7.orig/Makefile vdr-2.1.7/Makefile
+--- vdr-2.1.7.orig/Makefile 2015-01-18 12:37:45.506034673 +0100
++++ vdr-2.1.7/Makefile 2015-01-18 12:38:34.086037162 +0100
+@@ -116,7 +116,7 @@
+ VDRVERSION = $(shell sed -ne '/define VDRVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h)
+ APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h)
+
+-all: vdr i18n plugins
++all: vdr i18n
+
+ # Implicit rules:
+
+@@ -170,7 +170,7 @@
+
+ PODIR = po
+ LOCALEDIR = locale
+-I18Npo = $(wildcard $(PODIR)/*.po)
++I18Npo = $(foreach dir,$(L10N),$(wildcard $(PODIR)/$(dir)*.po))
+ I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file))))
+ I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr.mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file))))))
+ I18Npot = $(PODIR)/vdr.pot
+@@ -193,7 +193,7 @@
+
+ install-i18n: i18n
+ @mkdir -p $(DESTDIR)$(LOCDIR)
+- cp -r $(LOCALEDIR)/* $(DESTDIR)$(LOCDIR)
++ @(cd $(LOCALEDIR); for l10n in $(L10N); do [ "$$l10n" = "en" ] && continue; cp -r --parents $$l10n* $(DESTDIR)$(LOCDIR); done)
+
+ # The 'include' directory (for plugins):
+
+@@ -255,7 +255,7 @@
+
+ # Install the files (note that 'install-pc' must be first!):
+
+-install: install-pc install-bin install-dirs install-conf install-doc install-plugins install-i18n install-includes
++install: install-pc install-bin install-dirs install-conf install-doc install-i18n install-includes
+
+ # VDR binary:
+
+@@ -267,12 +267,13 @@
+
+ install-dirs:
+ @mkdir -p $(DESTDIR)$(VIDEODIR)
+- @mkdir -p $(DESTDIR)$(CONFDIR)
+- @mkdir -p $(DESTDIR)$(ARGSDIR)
+- @mkdir -p $(DESTDIR)$(CACHEDIR)
++# @mkdir -p $(DESTDIR)$(CONFDIR)
++# @mkdir -p $(DESTDIR)$(ARGSDIR)
++# @mkdir -p $(DESTDIR)$(CACHEDIR)
+ @mkdir -p $(DESTDIR)$(RESDIR)
+
+ install-conf:
++ @mkdir -p $(DESTDIR)$(CONFDIR)
+ @cp -pn *.conf $(DESTDIR)$(CONFDIR)
+
+ # Documentation:
+@@ -299,8 +300,11 @@
+ # Includes:
+
+ install-includes: include-dir
+- @mkdir -p $(DESTDIR)$(INCDIR)
+- @cp -pLR include/vdr include/libsi $(DESTDIR)$(INCDIR)
++# @mkdir -p $(DESTDIR)$(INCDIR)
++# @cp -pLR include/vdr include/libsi $(DESTDIR)$(INCDIR)
++ @mkdir -p $(DESTDIR)$(INCDIR)/vdr $(DESTDIR)$(INCDIR)/vdr/libsi
++ @cp -pLR include/vdr $(DESTDIR)$(INCDIR)
++ @cp -pLR include/libsi Make.config $(DESTDIR)$(INCDIR)/vdr
+
+ # pkg-config file:
+
diff --git a/media-video/vdr/vdr-2.2.0-r2.ebuild b/media-video/vdr/vdr-2.2.0-r2.ebuild
new file mode 100644
index 00000000000..6062fc62c64
--- /dev/null
+++ b/media-video/vdr/vdr-2.2.0-r2.ebuild
@@ -0,0 +1,298 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit flag-o-matic toolchain-funcs
+
+# Switches supported by extensions-patch
+EXT_PATCH_FLAGS="alternatechannel graphtft naludump permashift_v1 pinplugin
+ mainmenuhooks menuorg menuselection resumereset ttxtsubs"
+
+# names of the use-flags
+EXT_PATCH_FLAGS_RENAMED=""
+
+# names ext-patch uses internally, here only used for maintainer checks
+EXT_PATCH_FLAGS_RENAMED_EXT_NAME="bidi no_kbd sdnotify"
+
+IUSE="bidi debug +kbd html systemd vanilla ${EXT_PATCH_FLAGS} ${EXT_PATCH_FLAGS_RENAMED}"
+
+MY_PV="${PV%_p*}"
+MY_P="${PN}-${MY_PV}"
+S="${WORKDIR}/${MY_P}"
+
+EXT_P="extpng-${P}-gentoo-edition-v1"
+
+DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
+HOMEPAGE="http://www.tvdr.de/"
+SRC_URI="ftp://ftp.tvdr.de/vdr/${MY_P}.tar.bz2
+ https://dev.gentoo.org/~hd_brummy/distfiles/${EXT_P}.patch.bz2"
+
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~x86"
+SLOT="0"
+LICENSE="GPL-2"
+
+COMMON_DEPEND="virtual/jpeg:*
+ sys-libs/libcap
+ >=media-libs/fontconfig-2.4.2
+ >=media-libs/freetype-2"
+
+DEPEND="${COMMON_DEPEND}
+ >=virtual/linuxtv-dvb-headers-5.3
+ sys-devel/gettext"
+
+RDEPEND="${COMMON_DEPEND}
+ dev-lang/perl
+ >=media-tv/gentoo-vdr-scripts-2.7
+ media-fonts/corefonts
+ bidi? ( dev-libs/fribidi )
+ systemd? ( sys-apps/systemd )"
+
+CONF_DIR=/etc/vdr
+CAP_FILE=${S}/capabilities.sh
+CAPS="# Capabilities of the vdr-executable for use by startscript etc."
+
+pkg_setup() {
+
+ use debug && append-flags -g
+
+ PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
+
+ tc-export CC CXX AR
+}
+
+add_cap() {
+ local arg
+ for arg; do
+ CAPS="${CAPS}\n${arg}=1"
+ done
+}
+
+enable_patch() {
+ local arg ARG_UPPER
+ for arg; do
+ ARG_UPPER=$(echo $arg|tr '[:lower:]' '[:upper:]')
+ echo "${ARG_UPPER} = 1" >> Make.config
+
+ # codesnippet to bring the extpng defines into the vdr.pc CXXFLAGS CFLAGS
+ echo "-DUSE_${ARG_UPPER}" >> "${T}"/defines.tmp
+ cat "${T}"/defines.tmp | tr \\\012 ' ' > "${T}"/defines.IUSE
+ export DEFINES_IUSE=$( cat ${T}/defines.IUSE )
+ done
+}
+
+extensions_add_make_conf()
+{
+ # copy all ifdef for extensions-patch to Make.config
+ sed -e '1,/need to touch the following:/d' \
+ -e '/need to touch the following/,/^$/d' \
+ Make.config.template >> Make.config
+}
+
+extensions_all_defines() {
+ # extract all possible settings for extensions-patch
+ sed -e '/^#\?[A-Z].*= 1/!d' -e 's/^#\?//' -e 's/ .*//' \
+ Make.config.template \
+ | sort \
+ | tr '[:upper:]' '[:lower:]'
+}
+
+lang_po() {
+ LING_PO=$( ls ${S}/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
+}
+
+src_configure() {
+ # support languages, written from right to left
+ export "BIDI=$(usex bidi 1 0)"
+ # systemd notification support
+ export "SDNOTIFY=$(usex systemd 1 0)"
+ # with/without keyboard
+ export "USE_KBD=$(usex kbd 1 0)"
+}
+
+src_prepare() {
+ # apply maintainace-patches
+ ebegin "Changing paths for gentoo"
+
+ local DVBDIR=/usr/include
+ local i
+ for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
+ [[ -d ${i} ]] || continue
+ if [[ -f ${i}/linux/dvb/dmx.h ]]; then
+ einfo "Found DVB header files in ${i}"
+ DVBDIR=${i}
+ break
+ fi
+ done
+
+ # checking for s2api headers
+ local api_version
+ api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+ api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+
+ if [[ ${api_version:-0} -lt 5*3 ]]; then
+ eerror "DVB header files do not contain s2api support or too old for ${P}"
+ eerror "You cannot compile VDR against old dvb-header"
+ die "DVB headers too old"
+ fi
+
+ cat > Make.config <<-EOT
+ #
+ # Generated by ebuild ${PF}
+ #
+ PREFIX = /usr
+ DVBDIR = ${DVBDIR}
+ PLUGINLIBDIR = ${PLUGIN_LIBDIR}
+ CONFDIR = ${CONF_DIR}
+ VIDEODIR = /var/vdr/video
+ LOCDIR = \$(PREFIX)/share/locale
+ INCDIR = \$(PREFIX)/include
+
+ DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
+ INCLUDES += -I\$(DVBDIR)
+
+ # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
+ # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
+ LIBDIR = ${PLUGIN_LIBDIR}
+ PCDIR = /usr/$(get_libdir)/pkgconfig
+
+ EOT
+ eend 0
+
+ # wrt bug 586070
+ if has_version ">=sys-apps/systemd-230"; then
+ sed -e "s:libsystemd-daemon:libsystemd:g" -i Makefile || die "sed libsystemd failed"
+ fi
+
+ if ! use vanilla; then
+
+ # Now apply extensions patch
+ eapply "${WORKDIR}/${EXT_P}.patch"
+
+ # This allows us to start even if some plugin does not exist
+ # or is not loadable.
+ enable_patch PLUGINMISSING
+
+ if [[ -n ${VDR_MAINTAINER_MODE} ]]; then
+ einfo "Doing maintainer checks:"
+
+ # we do not support these patches
+ # (or have them already hard enabled)
+ local IGNORE_PATCHES="pluginmissing"
+
+ extensions_all_defines > "${T}"/new.IUSE
+ echo $EXT_PATCH_FLAGS $EXT_PATCH_FLAGS_RENAMED_EXT_NAME \
+ $IGNORE_PATCHES | \
+ tr ' ' '\n' |sort > "${T}"/old.IUSE
+ local DIFFS=$(diff -u "${T}"/old.IUSE "${T}"/new.IUSE|grep '^[+-][^+-]')
+ if [[ -z ${DIFFS} ]]; then
+ einfo "EXT_PATCH_FLAGS is up to date."
+ else
+ ewarn "IUSE differences!"
+ local diff
+ for diff in $DIFFS; do
+ ewarn "$diff"
+ done
+ fi
+ fi
+
+ ebegin "Enabling selected patches"
+ local flag
+ for flag in $EXT_PATCH_FLAGS; do
+ use $flag && enable_patch ${flag}
+ done
+
+ eend 0
+
+ extensions_add_make_conf
+
+ # add defined use-flags compile options to vdr.pc
+ sed -e "s:\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR):\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR) \$(DEFINES_IUSE):" \
+ -i Makefile
+
+ ebegin "Make depend"
+ emake .dependencies >/dev/null
+ eend $? "make depend failed"
+ fi
+
+ eapply "${FILESDIR}/${P}-r2_gentoo.patch"
+
+ # fix some makefile issues
+ sed -e "s:ifndef NO_KBD:ifeq (\$(USE_KBD),1):" \
+ -e "s:ifdef BIDI:ifeq (\$(BIDI),1):" \
+ -e "s:ifdef SDNOTIFY:ifeq (\$(SDNOTIFY),1):" \
+ -i "${S}"/Makefile
+
+ eapply_user
+
+ add_cap CAP_UTF8
+
+ add_cap CAP_IRCTRL_RUNTIME_PARAM \
+ CAP_VFAT_RUNTIME_PARAM \
+ CAP_CHUID \
+ CAP_SHUTDOWN_AUTO_RETRY
+
+ echo -e ${CAPS} > "${CAP_FILE}"
+
+ # L10N support
+ einfo "\n \t VDR supports the L10N values"
+
+ lang_po
+
+ einfo "\t Please set one of this values in your sytem make.conf"
+ einfo "\t L10N=\"${LING_PO}\"\n"
+
+ if [[ -z ${L10N} ]]; then
+ einfo "\n \t No values in L10N="
+ einfo "\t You will get only english text on OSD \n"
+ fi
+
+ strip-linguas ${LING_PO} en
+}
+
+src_install() {
+ # trick makefile not to create a videodir by supplying it with an existing
+ # directory
+ emake install \
+ VIDEODIR="/" \
+ DESTDIR="${D}" install || die "emake install failed"
+
+ keepdir "${PLUGIN_LIBDIR}"
+
+ # backup for plugins they don't be able to create this dir
+ keepdir "${CONF_DIR}"/plugins
+
+ if use html; then
+ local HTML_DOCS=( *.html )
+ fi
+
+ local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS )
+
+ einstalldocs
+
+ insinto /usr/share/vdr
+ doins "${CAP_FILE}"
+
+ if use alternatechannel; then
+ insinto /etc/vdr
+ doins "${FILESDIR}"/channel_alternative.conf
+ fi
+
+ chown -R vdr:vdr "${D}/${CONF_DIR}"
+}
+
+pkg_postinst() {
+
+ elog "\n\t---- 15 YEARS ANNIVERSARY EDITON ----\n"
+ elog "\tA lot of thanks to Klaus Schmidinger"
+ elog "\tfor this nice piece of Software...\n"
+
+ elog "It is a good idea to run vdrplugin-rebuild now."
+
+ elog "To get nice symbols in OSD we recommend to install"
+ elog "\t1. emerge media-fonts/vdrsymbols-ttf"
+ elog "\t2. select font VDRSymbolsSans in Setup"
+ elog ""
+ elog "To get an idea how to proceed now, have a look at our vdr-guide:"
+ elog "\thttps://wiki.gentoo.org/wiki/VDR"
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2018-08-27 13:32 Joerg Bornkessel
0 siblings, 0 replies; 15+ messages in thread
From: Joerg Bornkessel @ 2018-08-27 13:32 UTC (permalink / raw
To: gentoo-commits
commit: ddda7c9abad6a161baaf65520b6ca6b4fad7b325
Author: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
AuthorDate: Mon Aug 27 13:30:59 2018 +0000
Commit: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
CommitDate: Mon Aug 27 13:31:53 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ddda7c9a
media-video/vdr: glibc-2.24 deprecated warning fixed
Package-Manager: Portage-2.3.48, Repoman-2.3.10
media-video/vdr/files/vdr-2.2.0_glibc-2.24.patch | 35 ++++++++++++++++++++++++
media-video/vdr/vdr-2.2.0-r3.ebuild | 1 +
2 files changed, 36 insertions(+)
diff --git a/media-video/vdr/files/vdr-2.2.0_glibc-2.24.patch b/media-video/vdr/files/vdr-2.2.0_glibc-2.24.patch
new file mode 100644
index 00000000000..98cc13b0c3b
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.2.0_glibc-2.24.patch
@@ -0,0 +1,35 @@
+patch will fix readdir_r() is deprecated as of glibc-2.24
+https://www.vdr-portal.de/forum/index.php?thread/130752-handle-deprecated-functions-readdir-r-auto-ptr/&postID=1293833#post1293833
+
+Signed-of by: Joerg Bornkessel <hd_brummy@gentoo.org> (27 Aug 2018)
+diff -Naur vdr-2.2.0.orig/tools.c vdr-2.2.0/tools.c
+--- vdr-2.2.0.orig/tools.c 2018-08-27 12:59:28.571326559 +0200
++++ vdr-2.2.0/tools.c 2018-08-27 13:03:11.222326559 +0200
+@@ -1466,7 +1466,11 @@
+ struct dirent *cReadDir::Next(void)
+ {
+ if (directory) {
++#if !__GLIBC_PREREQ(2, 24) // readdir_r() is deprecated as of GLIBC 2.24
+ while (readdir_r(directory, &u.d, &result) == 0 && result) {
++#else
++ while ((result = readdir(directory)) != NULL) {
++#endif
+ if (strcmp(result->d_name, ".") && strcmp(result->d_name, ".."))
+ return result;
+ }
+diff -Naur vdr-2.2.0.orig/tools.h vdr-2.2.0/tools.h
+--- vdr-2.2.0.orig/tools.h 2018-08-27 12:59:28.641326559 +0200
++++ vdr-2.2.0/tools.h 2018-08-27 13:01:44.022326559 +0200
+@@ -369,10 +369,12 @@
+ private:
+ DIR *directory;
+ struct dirent *result;
++#if !__GLIBC_PREREQ(2, 24) // readdir_r() is deprecated as of GLIBC 2.24
+ union { // according to "The GNU C Library Reference Manual"
+ struct dirent d;
+ char b[offsetof(struct dirent, d_name) + NAME_MAX + 1];
+ } u;
++#endif
+ public:
+ cReadDir(const char *Directory);
+ ~cReadDir();
diff --git a/media-video/vdr/vdr-2.2.0-r3.ebuild b/media-video/vdr/vdr-2.2.0-r3.ebuild
index 2b4a137a165..dbb8e986c4a 100644
--- a/media-video/vdr/vdr-2.2.0-r3.ebuild
+++ b/media-video/vdr/vdr-2.2.0-r3.ebuild
@@ -218,6 +218,7 @@ src_prepare() {
eapply "${FILESDIR}/${P}_gentoo.patch"
#gcc-7.2, this will fix only the core vdr, not the extpatch
eapply "${FILESDIR}/${P}_unsignedtosigned.patch"
+ eapply "${FILESDIR}/${P}_glibc-2.24.patch"
# fix some makefile issues
sed -e "s:ifndef NO_KBD:ifeq (\$(USE_KBD),1):" \
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2018-08-29 10:17 Joerg Bornkessel
0 siblings, 0 replies; 15+ messages in thread
From: Joerg Bornkessel @ 2018-08-29 10:17 UTC (permalink / raw
To: gentoo-commits
commit: c20e014a0a9927935e6e0c5e2533b35504148f59
Author: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
AuthorDate: Wed Aug 29 10:17:03 2018 +0000
Commit: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
CommitDate: Wed Aug 29 10:17:03 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c20e014a
media-video/vdr: gcc7 compile issius fixed in extpng
Package-Manager: Portage-2.3.48, Repoman-2.3.10
media-video/vdr/files/vdr-2.2.0_gcc7extpng.patch | 16 ++++++++++++++++
media-video/vdr/vdr-2.2.0-r3.ebuild | 1 +
2 files changed, 17 insertions(+)
diff --git a/media-video/vdr/files/vdr-2.2.0_gcc7extpng.patch b/media-video/vdr/files/vdr-2.2.0_gcc7extpng.patch
new file mode 100644
index 00000000000..e00453c2a72
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.2.0_gcc7extpng.patch
@@ -0,0 +1,16 @@
+fix compile issius gcc7: ISO C++ forbids comparison between pointer and integer
+https://www.linuxtv.org/pipermail/vdr/2017-March/029230.html
+
+Signed-of by: Joerg Bornkessel <hd_brummy@gentoo.org> (29 Aug 2018)
+diff -Naur vdr-2.2.0.orig/osdbase.c vdr-2.2.0/osdbase.c
+--- vdr-2.2.0.orig/osdbase.c 2018-08-29 11:59:49.522326559 +0200
++++ vdr-2.2.0/osdbase.c 2018-08-29 11:59:13.861326559 +0200
+@@ -525,7 +525,7 @@
+ #ifdef USE_MENUSELECTION
+ i = 0;
+ item_nr = 0;
+- if (s && (s = skipspace(s)) != '\0' && '0' <= s[i] && s[i] <= '9') {
++ if (s && (s = skipspace(s)) != NULL && '0' <= s[i] && s[i] <= '9') {
+ do {
+ item_nr = item_nr * 10 + (s[i] - '0');
+ }
diff --git a/media-video/vdr/vdr-2.2.0-r3.ebuild b/media-video/vdr/vdr-2.2.0-r3.ebuild
index dbb8e986c4a..1da9aad71f8 100644
--- a/media-video/vdr/vdr-2.2.0-r3.ebuild
+++ b/media-video/vdr/vdr-2.2.0-r3.ebuild
@@ -219,6 +219,7 @@ src_prepare() {
#gcc-7.2, this will fix only the core vdr, not the extpatch
eapply "${FILESDIR}/${P}_unsignedtosigned.patch"
eapply "${FILESDIR}/${P}_glibc-2.24.patch"
+ eapply "${FILESDIR}/${P}_gcc7extpng.patch"
# fix some makefile issues
sed -e "s:ifndef NO_KBD:ifeq (\$(USE_KBD),1):" \
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2018-09-14 19:19 Joerg Bornkessel
0 siblings, 0 replies; 15+ messages in thread
From: Joerg Bornkessel @ 2018-09-14 19:19 UTC (permalink / raw
To: gentoo-commits
commit: 224855e3ca65e9784495d49167a40051f622a88a
Author: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
AuthorDate: Fri Sep 14 19:18:03 2018 +0000
Commit: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
CommitDate: Fri Sep 14 19:19:22 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=224855e3
media-video/vdr: cleanup old
Package-Manager: Portage-2.3.49, Repoman-2.3.10
media-video/vdr/Manifest | 1 -
.../vdr/files/vdr-2.0.7_systemd_argsdir.patch | 438 ---------------------
.../files/vdr-2.0.7_systemd_argsdir_vanilla.patch | 438 ---------------------
media-video/vdr/vdr-2.0.7.ebuild | 288 --------------
4 files changed, 1165 deletions(-)
diff --git a/media-video/vdr/Manifest b/media-video/vdr/Manifest
index 671820be372..e9b20f623a1 100644
--- a/media-video/vdr/Manifest
+++ b/media-video/vdr/Manifest
@@ -1,5 +1,4 @@
DIST extpng-vdr-2.0.6-gentoo-edition-v6.patch.bz2 69472 BLAKE2B 60669e9c20b2bd573eb05733bbf9548d2e643b36693be8b15a377b38470708a71b29e2a16baf7ed378132265f814ec9d35dae749ccf6ae204cd9beb787dc8f57 SHA512 f4ecb786ec5a026fa75fcf539518e80273bf43fc325c13a380c70eb85351910efa991b3ee71ca477e597bc2b4598a18620b6cf00fc02714acfcc4e6112d84b6c
DIST extpng-vdr-2.2.0-gentoo-edition-v1.patch.bz2 34664 BLAKE2B 81b68ebe0ef4588c3676f0b7a2c766d8d4d4f754a987b3be5868f3c6eff9158d4cea8e492ca81df535e637dbdc5baff638d1fafb4163e9d9a2d0125aba17e2e1 SHA512 16d6fbb8201f003dfe653b6a49424b794d7e697e27ad6f2383dbe17b76712ea5a3da88a676900b84d75ff7425bf3eb9084d60a89a4598758f482dc1f013f7b3e
DIST vdr-2.0.6.tar.bz2 839575 BLAKE2B 40de46d8465b7008bc29c7e2c1c241d4114aa3d62aa6a0acd81636133c295cd87c2fc618e725885c98f47445220e897c23188373457a96b51cf832ca417c9842 SHA512 070ebbfb85478887088567872a71744305dbf9c75de8b095a8fe46d883b0b4fe140539caeb2243715f42793a45790a127542655f549f7ea3cb71c4f9912fa07d
-DIST vdr-2.0.7.tar.bz2 841511 BLAKE2B bde06dd038ea2ebfa8768742c02bc7046448ade29032a90130f721af1c4c5d2301ff52065a04c51b31f14250d8ae252d796d93e3012ea1057f2359b1ef9c327c SHA512 cba35f62162cd681179872915023890f492e95cc94d65aadd3cb4d03d7e3c7e2f197e7f35149cdf872169af35c2b841e1042e054f28164860b7cea8367793ce0
DIST vdr-2.2.0.tar.bz2 922708 BLAKE2B 975e07d6d4c5bd13ee92be5d6a1826d6404b0c59e20fa2e30689b185a61e02d54782ad528e6a4f15e0d36806b30bcf48aa336d63adb3604e78056ff318e0fd2c SHA512 183f58133915c6c0fe8ec2b88becbcb2a36418210e6dcf7931053d3771d727c3581593f9eb5c9693abf39e22e728f7b41c42079cd704610c3636ec05134ea93d
diff --git a/media-video/vdr/files/vdr-2.0.7_systemd_argsdir.patch b/media-video/vdr/files/vdr-2.0.7_systemd_argsdir.patch
deleted file mode 100644
index de9f4b90163..00000000000
--- a/media-video/vdr/files/vdr-2.0.7_systemd_argsdir.patch
+++ /dev/null
@@ -1,438 +0,0 @@
-diff -Naur vdr-2.0.7.orig/HISTORY vdr-2.0.7/HISTORY
---- vdr-2.0.7.orig/HISTORY 2015-01-23 09:16:13.735620000 +0100
-+++ vdr-2.0.7/HISTORY 2015-01-23 09:17:29.038614491 +0100
-@@ -7916,6 +7916,16 @@
- - The APIVERSION has been increased to 2.0.6 due to the changes to pat.h, sdt.h and
- the functional modification to cFont::CreateFont().
-
-+2015-01-18: Version 2.0.6 + backport of systemd support from versions 2.1.6 and 2.1.7
-+
-+- Added support for systemd (thanks to Christopher Reimer). To activate this you
-+ need to add "SDNOTIFY=1" to the 'make' call.
-+
-+2015-01-18: Version 2.0.6 + backport of reading command line arguments from files, from version 2.1$
-+
-+- VDR now reads command line options from *.conf files in /etc/vdr/conf.d (thanks
-+ to Lars Hanisch). See vdr.1 and vdr.5 for details.
-+
- 2015-01-20: Version 2.0.7
-
- - Fixed a possible division by zero in frame rate detection.
-diff -Naur vdr-2.0.7.orig/Make.config.template vdr-2.0.7/Make.config.template
---- vdr-2.0.7.orig/Make.config.template 2015-01-23 09:16:13.736620000 +0100
-+++ vdr-2.0.7/Make.config.template 2015-01-23 09:16:34.199618503 +0100
-@@ -38,6 +38,7 @@
-
- #VIDEODIR = /srv/vdr/video
- #CONFDIR = /var/lib/vdr
-+#ARGSDIR = /etc/vdr/conf.d
- #CACHEDIR = /var/cache/vdr
-
- # Overrides for preset/legacy configurations:
-diff -Naur vdr-2.0.7.orig/Makefile vdr-2.0.7/Makefile
---- vdr-2.0.7.orig/Makefile 2015-01-23 09:16:13.724620001 +0100
-+++ vdr-2.0.7/Makefile 2015-01-23 09:17:58.588612330 +0100
-@@ -31,6 +31,7 @@
- DESTDIR ?=
- VIDEODIR ?= /srv/vdr/video
- CONFDIR ?= /var/lib/vdr
-+ARGSDIR ?= /etc/vdr/conf.d
- CACHEDIR ?= /var/cache/vdr
-
- PREFIX ?= /usr/local
-@@ -66,7 +67,7 @@
-
- SILIB = $(LSIDIR)/libsi.a
-
--OBJS = audio.o channels.o ci.o config.o cutter.o device.o diseqc.o dvbdevice.o dvbci.o\
-+OBJS = args.o audio.o channels.o ci.o config.o cutter.o device.o diseqc.o dvbdevice.o dvbci.o\
- dvbplayer.o dvbspu.o dvbsubtitle.o eit.o eitscan.o epg.o filter.o font.o i18n.o interface.o keys.o\
- lirc.o menu.o menuitems.o nit.o osdbase.o osd.o pat.o player.o plugin.o\
- receiver.o recorder.o recording.o remote.o remux.o ringbuffer.o sdt.o sections.o shutdown.o\
-@@ -111,12 +112,18 @@
- DEFINES += -DBIDI
- LIBS += $(shell pkg-config --libs fribidi)
- endif
-+ifdef SDNOTIFY
-+INCLUDES += $(shell pkg-config --cflags libsystemd-daemon)
-+DEFINES += -DSDNOTIFY
-+LIBS += $(shell pkg-config --libs libsystemd-daemon)
-+endif
-
- LIRC_DEVICE ?= /var/run/lirc/lircd
-
- DEFINES += -DLIRC_DEVICE=\"$(LIRC_DEVICE)\"
- DEFINES += -DVIDEODIR=\"$(VIDEODIR)\"
- DEFINES += -DCONFDIR=\"$(CONFDIR)\"
-+DEFINES += -DARGSDIR=\"$(ARGSDIR)\"
- DEFINES += -DCACHEDIR=\"$(CACHEDIR)\"
- DEFINES += -DRESDIR=\"$(RESDIR)\"
- DEFINES += -DPLUGINDIR=\"$(LIBDIR)\"
-@@ -161,6 +168,7 @@
- @echo "mandir=$(MANDIR)" >> $@
- @echo "configdir=$(CONFDIR)" >> $@
- @echo "videodir=$(VIDEODIR)" >> $@
-+ @echo "argsdir=$(ARGSDIR)" >> $@
- @echo "cachedir=$(CACHEDIR)" >> $@
- @echo "resdir=$(RESDIR)" >> $@
- @echo "libdir=$(LIBDIR)" >> $@
-@@ -278,6 +286,7 @@
- install-dirs:
- @mkdir -p $(DESTDIR)$(VIDEODIR)
- # @mkdir -p $(DESTDIR)$(CONFDIR)
-+ @mkdir -p $(DESTDIR)$(ARGSDIR)
- # @mkdir -p $(DESTDIR)$(CACHEDIR)
- @mkdir -p $(DESTDIR)$(RESDIR)
-
-diff -Naur vdr-2.0.7.orig/args.c vdr-2.0.7/args.c
---- vdr-2.0.7.orig/args.c 1970-01-01 01:00:00.000000000 +0100
-+++ vdr-2.0.7/args.c 2015-01-23 09:16:34.199618503 +0100
-@@ -0,0 +1,129 @@
-+/*
-+ * args.c: Read arguments from files
-+ *
-+ * See the main source file 'vdr.c' for copyright information and
-+ * how to reach the author.
-+ *
-+ * Original version written by Lars Hanisch <dvb@flensrocker.de>.
-+ *
-+ * $Id$
-+ */
-+
-+#include "args.h"
-+#include <unistd.h>
-+
-+cArgs::cArgs(const char *Argv0)
-+{
-+ argv0 = Argv0;
-+ argc = 0;
-+ argv = NULL;
-+}
-+
-+cArgs::~cArgs(void)
-+{
-+ if (argv != NULL)
-+ delete [] argv;
-+}
-+
-+bool cArgs::AddArg(const char *s)
-+{
-+ if (inVdrSection)
-+ args.Append(strdup(s));
-+ else if (*lastArg == NULL)
-+ return false;
-+ else
-+ lastArg = cString::sprintf("%s %s", *lastArg, s);
-+ return true;
-+}
-+
-+bool cArgs::ReadDirectory(const char *Directory)
-+{
-+ if (argv != NULL)
-+ delete [] argv;
-+ argc = 0;
-+ argv = NULL;
-+ args.Clear();
-+ lastArg = NULL;
-+ inVdrSection = false;
-+ cFileNameList files(Directory, false);
-+ if (files.Size() == 0)
-+ return false;
-+ for (int i = 0; i < files.Size(); i++) {
-+ const char *fileName = files.At(i);
-+ if (startswith(fileName, ".") || !endswith(fileName, ".conf"))
-+ continue;
-+ cString fullFileName = AddDirectory(Directory, fileName);
-+ struct stat fs;
-+ if ((access(*fullFileName, F_OK) != 0) || (stat(*fullFileName, &fs) != 0) || S_ISDIR(fs.st_mode))
-+ continue;
-+ bool ok = true;
-+ int line = 0;
-+ FILE *f = fopen(*fullFileName, "r");
-+ if (f) {
-+ char *s;
-+ cReadLine ReadLine;
-+ while ((s = ReadLine.Read(f)) != NULL) {
-+ line++;
-+ s = stripspace(skipspace(s));
-+ if (!isempty(s) && (s[0] != '#')) {
-+ if (startswith(s, "[") && endswith(s, "]")) {
-+ s[strlen(s) - 1] = 0;
-+ s++;
-+ if (*lastArg) {
-+ args.Append(strdup(*lastArg));
-+ lastArg = NULL;
-+ }
-+ if (strcmp(s, "vdr") == 0)
-+ inVdrSection = true;
-+ else {
-+ inVdrSection = false;
-+ lastArg = cString::sprintf("--plugin=%s", s);
-+ }
-+ }
-+ else {
-+ if ((strlen(s) > 2) && (s[0] == '-') && (s[1] != '-')) { // short option, split at first space
-+ char *p = strchr(s, ' ');
-+ if (p == NULL) {
-+ ok = AddArg(s);
-+ if (!ok)
-+ break;
-+ }
-+ else {
-+ *p = 0;
-+ p++;
-+ ok = AddArg(s);
-+ if (!ok)
-+ break;
-+ ok = AddArg(p);
-+ if (!ok)
-+ break;
-+ }
-+ }
-+ else {
-+ ok = AddArg(s);
-+ if (!ok)
-+ break;
-+ }
-+ }
-+ }
-+ }
-+ fclose(f);
-+ }
-+ if (!ok) {
-+ esyslog("ERROR: args file %s, line %d", *fullFileName, line);
-+ return false;
-+ }
-+ }
-+ if (*lastArg) {
-+ args.Append(strdup(*lastArg));
-+ lastArg = NULL;
-+ }
-+ argv = new char*[args.Size() + 1];
-+ argv[0] = strdup(*argv0);
-+ argc = 1;
-+ for (int i = 0; i < args.Size(); i++) {
-+ argv[argc] = args.At(i);
-+ argc++;
-+ }
-+ return true;
-+}
-diff -Naur vdr-2.0.7.orig/args.h vdr-2.0.7/args.h
---- vdr-2.0.7.orig/args.h 1970-01-01 01:00:00.000000000 +0100
-+++ vdr-2.0.7/args.h 2015-01-23 09:16:34.199618503 +0100
-@@ -0,0 +1,34 @@
-+/*
-+ * args.h: Read arguments from files
-+ *
-+ * See the main source file 'vdr.c' for copyright information and
-+ * how to reach the author.
-+ *
-+ * Original version written by Lars Hanisch <dvb@flensrocker.de>.
-+ *
-+ * $Id$
-+ */
-+
-+#ifndef __ARGS_H
-+#define __ARGS_H
-+
-+#include "tools.h"
-+
-+class cArgs {
-+private:
-+ cString argv0;
-+ cStringList args;
-+ cString lastArg;
-+ bool inVdrSection;
-+ int argc;
-+ char **argv;
-+ bool AddArg(const char *s);
-+public:
-+ cArgs(const char *Argv0);
-+ ~cArgs(void);
-+ bool ReadDirectory(const char *Directory);
-+ int GetArgc(void) const { return argc; };
-+ char **GetArgv(void) const { return argv; };
-+ };
-+
-+#endif //__ARGS_H
-diff -Naur vdr-2.0.7.orig/interface.c vdr-2.0.7/interface.c
---- vdr-2.0.7.orig/interface.c 2015-01-23 09:16:13.725620001 +0100
-+++ vdr-2.0.7/interface.c 2015-01-23 09:16:34.199618503 +0100
-@@ -10,6 +10,9 @@
- #include "interface.h"
- #include <ctype.h>
- #include <stdlib.h>
-+#ifdef SDNOTIFY
-+#include <systemd/sd-daemon.h>
-+#endif
- #include <unistd.h>
- #include "i18n.h"
- #include "status.h"
-@@ -159,6 +162,9 @@
- bool known = Keys.KnowsRemote(Remote->Name());
- dsyslog("remote control %s - %s", Remote->Name(), known ? "keys known" : "learning keys");
- if (!known) {
-+#ifdef SDNOTIFY
-+ sd_notify(0, "READY=1\nSTATUS=Learning keys...");
-+#endif
- cSkinDisplayMenu *DisplayMenu = Skins.Current()->DisplayMenu();
- DisplayMenu->SetMenuCategory(mcUnknown);
- char Headline[256];
-diff -Naur vdr-2.0.7.orig/vdr.1 vdr-2.0.7/vdr.1
---- vdr-2.0.7.orig/vdr.1 2015-01-23 09:16:13.730620000 +0100
-+++ vdr-2.0.7/vdr.1 2015-01-23 09:16:34.200618503 +0100
-@@ -178,6 +178,10 @@
- Read resource files from \fIdir\fR
- (default is to read them from the config directory).
- .TP
-+.BI \-\-showargs[= dir ]
-+Read command line arguments from \fIdir\fR (default is \fI/etc/vdr/conf.d\fR),
-+display them to the console and exit.
-+.TP
- .BI \-s\ cmd ,\ \-\-shutdown= cmd
- Call \fIcmd\fR to shutdown the computer. See the file \fIINSTALL\fR for more
- information.
-@@ -213,6 +217,10 @@
- .BI \-w\ sec ,\ \-\-watchdog= sec
- Activate the watchdog timer with a timeout of \fIsec\fR seconds.
- A value of \fB0\fR (default) disables the watchdog.
-+.P
-+If started without any options, vdr tries to read command line options
-+from files named '*.conf' in the directory /etc/vdr/conf.d. Files are
-+read in alphabetical order. See vdr(5) for details.
- .SH SIGNALS
- .TP
- .B SIGINT, SIGTERM
-diff -Naur vdr-2.0.7.orig/vdr.5 vdr-2.0.7/vdr.5
---- vdr-2.0.7.orig/vdr.5 2015-01-23 09:16:13.732620000 +0100
-+++ vdr-2.0.7/vdr.5 2015-01-23 09:16:34.200618503 +0100
-@@ -895,6 +895,33 @@
- just 16 bit wide. The internal representation in VDR allows for 32 bit to
- be used, so that external tools can generate EPG data that is guaranteed
- not to collide with the ids of existing data.
-+.SS COMMANDLINE OPTIONS
-+If started without any options, vdr tries to read any files in the directory
-+/etc/vdr/conf.d with names that do not begin with a '.' and that end with '.conf'.
-+These files are read in alphabetical order. The format of these files is
-+
-+# comment
-+.br
-+[name]
-+.br
-+-a
-+.br
-+-b 123
-+.br
-+--long
-+.br
-+--longarg=123
-+.br
-+
-+Any lines that begin with '#' as the first non-whitespace character are considered
-+comments and are ignored.
-+A command line option file consists of one or more sections, indicated by '[name]',
-+where 'name' is either the fixed word 'vdr' (if this section contains options for
-+the main VDR program) or the name of the plugin this section applies to.
-+Each option must be written on a separate line, including the leading '-' (for
-+a short option) or '--' (for a long option). If the option has additional arguments,
-+they have to be written on the same line as the option itself, separated from the
-+option with a blank (short option) or equal sign (long option).
- .SH SEE ALSO
- .BR vdr (1)
- .SH AUTHOR
-diff -Naur vdr-2.0.7.orig/vdr.c vdr-2.0.7/vdr.c
---- vdr-2.0.7.orig/vdr.c 2015-01-23 09:16:13.732620000 +0100
-+++ vdr-2.0.7/vdr.c 2015-01-23 09:16:34.200618503 +0100
-@@ -34,8 +34,12 @@
- #include <stdlib.h>
- #include <sys/capability.h>
- #include <sys/prctl.h>
-+#ifdef SDNOTIFY
-+#include <systemd/sd-daemon.h>
-+#endif
- #include <termios.h>
- #include <unistd.h>
-+#include "args.h"
- #include "audio.h"
- #include "channels.h"
- #include "config.h"
-@@ -192,6 +196,7 @@
- #define DEFAULTWATCHDOG 0 // seconds
- #define DEFAULTVIDEODIR VIDEODIR
- #define DEFAULTCONFDIR dd(CONFDIR, VideoDirectory)
-+#define DEFAULTARGSDIR dd(ARGSDIR, "/etc/vdr/conf.d")
- #define DEFAULTCACHEDIR dd(CACHEDIR, VideoDirectory)
- #define DEFAULTRESDIR dd(RESDIR, ConfigDirectory)
- #define DEFAULTPLUGINDIR PLUGINDIR
-@@ -229,6 +234,15 @@
- VdrUser = VDR_USER;
- #endif
-
-+ cArgs *Args = NULL;
-+ if (argc == 1) {
-+ Args = new cArgs(argv[0]);
-+ if (Args->ReadDirectory(DEFAULTARGSDIR)) {
-+ argc = Args->GetArgc();
-+ argv = Args->GetArgv();
-+ }
-+ }
-+
- SetVideoDirectory(VideoDirectory);
- cPluginManager PluginManager(DEFAULTPLUGINDIR);
-
-@@ -256,6 +270,7 @@
- { "port", required_argument, NULL, 'p' },
- { "record", required_argument, NULL, 'r' },
- { "resdir", required_argument, NULL, 'r' | 0x100 },
-+ { "showargs", optional_argument, NULL, 's' | 0x200 },
- { "shutdown", required_argument, NULL, 's' },
- { "split", no_argument, NULL, 's' | 0x100 },
- { "terminal", required_argument, NULL, 't' },
-@@ -428,6 +443,19 @@
- case 's' | 0x100:
- Setup.SplitEditedFiles = 1;
- break;
-+ case 's' | 0x200: {
-+ const char *ArgsDir = optarg ? optarg : DEFAULTARGSDIR;
-+ cArgs Args(argv[0]);
-+ if (!Args.ReadDirectory(ArgsDir)) {
-+ fprintf(stderr, "vdr: can't read arguments from directory: %s\n", ArgsDir);
-+ return 2;
-+ }
-+ int c = Args.GetArgc();
-+ char **v = Args.GetArgv();
-+ for (int i = 1; i < c; i++)
-+ printf("%s\n", v[i]);
-+ return 0;
-+ }
- case 't': Terminal = optarg;
- if (access(Terminal, R_OK | W_OK) < 0) {
- fprintf(stderr, "vdr: can't access terminal: %s\n", Terminal);
-@@ -541,6 +569,8 @@
- " -s CMD, --shutdown=CMD call CMD to shutdown the computer\n"
- " --split split edited files at the editing marks (only\n"
- " useful in conjunction with --edit)\n"
-+ " --showargs[=DIR] print the arguments read from DIR and exit\n"
-+ " (default: %s)\n"
- " -t TTY, --terminal=TTY controlling tty\n"
- " -u USER, --user=USER run as user USER; only applicable if started as\n"
- " root\n"
-@@ -563,6 +593,7 @@
- DEFAULTLOCDIR,
- DEFAULTSVDRPPORT,
- DEFAULTRESDIR,
-+ DEFAULTARGSDIR,
- DEFAULTVIDEODIR,
- DEFAULTWATCHDOG
- );
-@@ -848,6 +879,10 @@
- alarm(WatchdogTimeout); // Initial watchdog timer start
- }
-
-+#ifdef SDNOTIFY
-+ sd_notify(0, "READY=1\nSTATUS=Ready");
-+#endif
-+
- // Main program loop:
-
- #define DELETE_MENU ((IsInfoMenu &= (Menu == NULL)), delete Menu, Menu = NULL)
diff --git a/media-video/vdr/files/vdr-2.0.7_systemd_argsdir_vanilla.patch b/media-video/vdr/files/vdr-2.0.7_systemd_argsdir_vanilla.patch
deleted file mode 100644
index f7bae16fdd4..00000000000
--- a/media-video/vdr/files/vdr-2.0.7_systemd_argsdir_vanilla.patch
+++ /dev/null
@@ -1,438 +0,0 @@
-diff -Naur vdr-2.0.7.orig/HISTORY vdr-2.0.7/HISTORY
---- vdr-2.0.7.orig/HISTORY 2015-01-23 09:07:52.777656645 +0100
-+++ vdr-2.0.7/HISTORY 2015-01-23 09:09:57.798647500 +0100
-@@ -7916,6 +7916,16 @@
- - The APIVERSION has been increased to 2.0.6 due to the changes to pat.h, sdt.h and
- the functional modification to cFont::CreateFont().
-
-+2015-01-18: Version 2.0.6 + backport of systemd support from versions 2.1.6 and 2.1.7
-+
-+- Added support for systemd (thanks to Christopher Reimer). To activate this you
-+ need to add "SDNOTIFY=1" to the 'make' call.
-+
-+2015-01-18: Version 2.0.6 + backport of reading command line arguments from files, from version 2.1$
-+
-+- VDR now reads command line options from *.conf files in /etc/vdr/conf.d (thanks
-+ to Lars Hanisch). See vdr.1 and vdr.5 for details.
-+
- 2015-01-20: Version 2.0.7
-
- - Fixed a possible division by zero in frame rate detection.
-diff -Naur vdr-2.0.7.orig/Make.config.template vdr-2.0.7/Make.config.template
---- vdr-2.0.7.orig/Make.config.template 2015-01-23 09:07:52.765656646 +0100
-+++ vdr-2.0.7/Make.config.template 2015-01-23 09:08:15.775654963 +0100
-@@ -38,6 +38,7 @@
-
- #VIDEODIR = /srv/vdr/video
- #CONFDIR = /var/lib/vdr
-+#ARGSDIR = /etc/vdr/conf.d
- #CACHEDIR = /var/cache/vdr
-
- # Overrides for preset/legacy configurations:
-diff -Naur vdr-2.0.7.orig/Makefile vdr-2.0.7/Makefile
---- vdr-2.0.7.orig/Makefile 2015-01-23 09:07:52.778656645 +0100
-+++ vdr-2.0.7/Makefile 2015-01-23 09:11:11.158642134 +0100
-@@ -31,6 +31,7 @@
- DESTDIR ?=
- VIDEODIR ?= /srv/vdr/video
- CONFDIR ?= /var/lib/vdr
-+ARGSDIR ?= /etc/vdr/conf.d
- CACHEDIR ?= /var/cache/vdr
-
- PREFIX ?= /usr/local
-@@ -66,7 +67,7 @@
-
- SILIB = $(LSIDIR)/libsi.a
-
--OBJS = audio.o channels.o ci.o config.o cutter.o device.o diseqc.o dvbdevice.o dvbci.o\
-+OBJS = args.o audio.o channels.o ci.o config.o cutter.o device.o diseqc.o dvbdevice.o dvbci.o\
- dvbplayer.o dvbspu.o dvbsubtitle.o eit.o eitscan.o epg.o filter.o font.o i18n.o interface.o keys.o\
- lirc.o menu.o menuitems.o nit.o osdbase.o osd.o pat.o player.o plugin.o\
- receiver.o recorder.o recording.o remote.o remux.o ringbuffer.o sdt.o sections.o shutdown.o\
-@@ -93,12 +94,18 @@
- DEFINES += -DBIDI
- LIBS += $(shell pkg-config --libs fribidi)
- endif
-+ifdef SDNOTIFY
-+INCLUDES += $(shell pkg-config --cflags libsystemd-daemon)
-+DEFINES += -DSDNOTIFY
-+LIBS += $(shell pkg-config --libs libsystemd-daemon)
-+endif
-
- LIRC_DEVICE ?= /var/run/lirc/lircd
-
- DEFINES += -DLIRC_DEVICE=\"$(LIRC_DEVICE)\"
- DEFINES += -DVIDEODIR=\"$(VIDEODIR)\"
- DEFINES += -DCONFDIR=\"$(CONFDIR)\"
-+DEFINES += -DARGSDIR=\"$(ARGSDIR)\"
- DEFINES += -DCACHEDIR=\"$(CACHEDIR)\"
- DEFINES += -DRESDIR=\"$(RESDIR)\"
- DEFINES += -DPLUGINDIR=\"$(LIBDIR)\"
-@@ -143,6 +150,7 @@
- @echo "mandir=$(MANDIR)" >> $@
- @echo "configdir=$(CONFDIR)" >> $@
- @echo "videodir=$(VIDEODIR)" >> $@
-+ @echo "argsdir=$(ARGSDIR)" >> $@
- @echo "cachedir=$(CACHEDIR)" >> $@
- @echo "resdir=$(RESDIR)" >> $@
- @echo "libdir=$(LIBDIR)" >> $@
-@@ -260,6 +268,7 @@
- install-dirs:
- @mkdir -p $(DESTDIR)$(VIDEODIR)
- # @mkdir -p $(DESTDIR)$(CONFDIR)
-+ @mkdir -p $(DESTDIR)$(ARGSDIR)
- # @mkdir -p $(DESTDIR)$(CACHEDIR)
- @mkdir -p $(DESTDIR)$(RESDIR)
-
-diff -Naur vdr-2.0.7.orig/args.c vdr-2.0.7/args.c
---- vdr-2.0.7.orig/args.c 1970-01-01 01:00:00.000000000 +0100
-+++ vdr-2.0.7/args.c 2015-01-23 09:08:15.775654963 +0100
-@@ -0,0 +1,129 @@
-+/*
-+ * args.c: Read arguments from files
-+ *
-+ * See the main source file 'vdr.c' for copyright information and
-+ * how to reach the author.
-+ *
-+ * Original version written by Lars Hanisch <dvb@flensrocker.de>.
-+ *
-+ * $Id$
-+ */
-+
-+#include "args.h"
-+#include <unistd.h>
-+
-+cArgs::cArgs(const char *Argv0)
-+{
-+ argv0 = Argv0;
-+ argc = 0;
-+ argv = NULL;
-+}
-+
-+cArgs::~cArgs(void)
-+{
-+ if (argv != NULL)
-+ delete [] argv;
-+}
-+
-+bool cArgs::AddArg(const char *s)
-+{
-+ if (inVdrSection)
-+ args.Append(strdup(s));
-+ else if (*lastArg == NULL)
-+ return false;
-+ else
-+ lastArg = cString::sprintf("%s %s", *lastArg, s);
-+ return true;
-+}
-+
-+bool cArgs::ReadDirectory(const char *Directory)
-+{
-+ if (argv != NULL)
-+ delete [] argv;
-+ argc = 0;
-+ argv = NULL;
-+ args.Clear();
-+ lastArg = NULL;
-+ inVdrSection = false;
-+ cFileNameList files(Directory, false);
-+ if (files.Size() == 0)
-+ return false;
-+ for (int i = 0; i < files.Size(); i++) {
-+ const char *fileName = files.At(i);
-+ if (startswith(fileName, ".") || !endswith(fileName, ".conf"))
-+ continue;
-+ cString fullFileName = AddDirectory(Directory, fileName);
-+ struct stat fs;
-+ if ((access(*fullFileName, F_OK) != 0) || (stat(*fullFileName, &fs) != 0) || S_ISDIR(fs.st_mode))
-+ continue;
-+ bool ok = true;
-+ int line = 0;
-+ FILE *f = fopen(*fullFileName, "r");
-+ if (f) {
-+ char *s;
-+ cReadLine ReadLine;
-+ while ((s = ReadLine.Read(f)) != NULL) {
-+ line++;
-+ s = stripspace(skipspace(s));
-+ if (!isempty(s) && (s[0] != '#')) {
-+ if (startswith(s, "[") && endswith(s, "]")) {
-+ s[strlen(s) - 1] = 0;
-+ s++;
-+ if (*lastArg) {
-+ args.Append(strdup(*lastArg));
-+ lastArg = NULL;
-+ }
-+ if (strcmp(s, "vdr") == 0)
-+ inVdrSection = true;
-+ else {
-+ inVdrSection = false;
-+ lastArg = cString::sprintf("--plugin=%s", s);
-+ }
-+ }
-+ else {
-+ if ((strlen(s) > 2) && (s[0] == '-') && (s[1] != '-')) { // short option, split at first space
-+ char *p = strchr(s, ' ');
-+ if (p == NULL) {
-+ ok = AddArg(s);
-+ if (!ok)
-+ break;
-+ }
-+ else {
-+ *p = 0;
-+ p++;
-+ ok = AddArg(s);
-+ if (!ok)
-+ break;
-+ ok = AddArg(p);
-+ if (!ok)
-+ break;
-+ }
-+ }
-+ else {
-+ ok = AddArg(s);
-+ if (!ok)
-+ break;
-+ }
-+ }
-+ }
-+ }
-+ fclose(f);
-+ }
-+ if (!ok) {
-+ esyslog("ERROR: args file %s, line %d", *fullFileName, line);
-+ return false;
-+ }
-+ }
-+ if (*lastArg) {
-+ args.Append(strdup(*lastArg));
-+ lastArg = NULL;
-+ }
-+ argv = new char*[args.Size() + 1];
-+ argv[0] = strdup(*argv0);
-+ argc = 1;
-+ for (int i = 0; i < args.Size(); i++) {
-+ argv[argc] = args.At(i);
-+ argc++;
-+ }
-+ return true;
-+}
-diff -Naur vdr-2.0.7.orig/args.h vdr-2.0.7/args.h
---- vdr-2.0.7.orig/args.h 1970-01-01 01:00:00.000000000 +0100
-+++ vdr-2.0.7/args.h 2015-01-23 09:08:15.775654963 +0100
-@@ -0,0 +1,34 @@
-+/*
-+ * args.h: Read arguments from files
-+ *
-+ * See the main source file 'vdr.c' for copyright information and
-+ * how to reach the author.
-+ *
-+ * Original version written by Lars Hanisch <dvb@flensrocker.de>.
-+ *
-+ * $Id$
-+ */
-+
-+#ifndef __ARGS_H
-+#define __ARGS_H
-+
-+#include "tools.h"
-+
-+class cArgs {
-+private:
-+ cString argv0;
-+ cStringList args;
-+ cString lastArg;
-+ bool inVdrSection;
-+ int argc;
-+ char **argv;
-+ bool AddArg(const char *s);
-+public:
-+ cArgs(const char *Argv0);
-+ ~cArgs(void);
-+ bool ReadDirectory(const char *Directory);
-+ int GetArgc(void) const { return argc; };
-+ char **GetArgv(void) const { return argv; };
-+ };
-+
-+#endif //__ARGS_H
-diff -Naur vdr-2.0.7.orig/interface.c vdr-2.0.7/interface.c
---- vdr-2.0.7.orig/interface.c 2015-01-23 09:07:52.765656646 +0100
-+++ vdr-2.0.7/interface.c 2015-01-23 09:08:15.775654963 +0100
-@@ -10,6 +10,9 @@
- #include "interface.h"
- #include <ctype.h>
- #include <stdlib.h>
-+#ifdef SDNOTIFY
-+#include <systemd/sd-daemon.h>
-+#endif
- #include <unistd.h>
- #include "i18n.h"
- #include "status.h"
-@@ -159,6 +162,9 @@
- bool known = Keys.KnowsRemote(Remote->Name());
- dsyslog("remote control %s - %s", Remote->Name(), known ? "keys known" : "learning keys");
- if (!known) {
-+#ifdef SDNOTIFY
-+ sd_notify(0, "READY=1\nSTATUS=Learning keys...");
-+#endif
- cSkinDisplayMenu *DisplayMenu = Skins.Current()->DisplayMenu();
- DisplayMenu->SetMenuCategory(mcUnknown);
- char Headline[256];
-diff -Naur vdr-2.0.7.orig/vdr.1 vdr-2.0.7/vdr.1
---- vdr-2.0.7.orig/vdr.1 2015-01-23 09:07:52.770656646 +0100
-+++ vdr-2.0.7/vdr.1 2015-01-23 09:08:15.776654963 +0100
-@@ -178,6 +178,10 @@
- Read resource files from \fIdir\fR
- (default is to read them from the config directory).
- .TP
-+.BI \-\-showargs[= dir ]
-+Read command line arguments from \fIdir\fR (default is \fI/etc/vdr/conf.d\fR),
-+display them to the console and exit.
-+.TP
- .BI \-s\ cmd ,\ \-\-shutdown= cmd
- Call \fIcmd\fR to shutdown the computer. See the file \fIINSTALL\fR for more
- information.
-@@ -213,6 +217,10 @@
- .BI \-w\ sec ,\ \-\-watchdog= sec
- Activate the watchdog timer with a timeout of \fIsec\fR seconds.
- A value of \fB0\fR (default) disables the watchdog.
-+.P
-+If started without any options, vdr tries to read command line options
-+from files named '*.conf' in the directory /etc/vdr/conf.d. Files are
-+read in alphabetical order. See vdr(5) for details.
- .SH SIGNALS
- .TP
- .B SIGINT, SIGTERM
-diff -Naur vdr-2.0.7.orig/vdr.5 vdr-2.0.7/vdr.5
---- vdr-2.0.7.orig/vdr.5 2015-01-23 09:07:52.772656646 +0100
-+++ vdr-2.0.7/vdr.5 2015-01-23 09:08:15.776654963 +0100
-@@ -889,6 +889,33 @@
- just 16 bit wide. The internal representation in VDR allows for 32 bit to
- be used, so that external tools can generate EPG data that is guaranteed
- not to collide with the ids of existing data.
-+.SS COMMANDLINE OPTIONS
-+If started without any options, vdr tries to read any files in the directory
-+/etc/vdr/conf.d with names that do not begin with a '.' and that end with '.conf'.
-+These files are read in alphabetical order. The format of these files is
-+
-+# comment
-+.br
-+[name]
-+.br
-+-a
-+.br
-+-b 123
-+.br
-+--long
-+.br
-+--longarg=123
-+.br
-+
-+Any lines that begin with '#' as the first non-whitespace character are considered
-+comments and are ignored.
-+A command line option file consists of one or more sections, indicated by '[name]',
-+where 'name' is either the fixed word 'vdr' (if this section contains options for
-+the main VDR program) or the name of the plugin this section applies to.
-+Each option must be written on a separate line, including the leading '-' (for
-+a short option) or '--' (for a long option). If the option has additional arguments,
-+they have to be written on the same line as the option itself, separated from the
-+option with a blank (short option) or equal sign (long option).
- .SH SEE ALSO
- .BR vdr (1)
- .SH AUTHOR
-diff -Naur vdr-2.0.7.orig/vdr.c vdr-2.0.7/vdr.c
---- vdr-2.0.7.orig/vdr.c 2015-01-23 09:07:52.772656646 +0100
-+++ vdr-2.0.7/vdr.c 2015-01-23 09:08:15.776654963 +0100
-@@ -34,8 +34,12 @@
- #include <stdlib.h>
- #include <sys/capability.h>
- #include <sys/prctl.h>
-+#ifdef SDNOTIFY
-+#include <systemd/sd-daemon.h>
-+#endif
- #include <termios.h>
- #include <unistd.h>
-+#include "args.h"
- #include "audio.h"
- #include "channels.h"
- #include "config.h"
-@@ -186,6 +190,7 @@
- #define DEFAULTWATCHDOG 0 // seconds
- #define DEFAULTVIDEODIR VIDEODIR
- #define DEFAULTCONFDIR dd(CONFDIR, VideoDirectory)
-+#define DEFAULTARGSDIR dd(ARGSDIR, "/etc/vdr/conf.d")
- #define DEFAULTCACHEDIR dd(CACHEDIR, VideoDirectory)
- #define DEFAULTRESDIR dd(RESDIR, ConfigDirectory)
- #define DEFAULTPLUGINDIR PLUGINDIR
-@@ -223,6 +228,15 @@
- VdrUser = VDR_USER;
- #endif
-
-+ cArgs *Args = NULL;
-+ if (argc == 1) {
-+ Args = new cArgs(argv[0]);
-+ if (Args->ReadDirectory(DEFAULTARGSDIR)) {
-+ argc = Args->GetArgc();
-+ argv = Args->GetArgv();
-+ }
-+ }
-+
- SetVideoDirectory(VideoDirectory);
- cPluginManager PluginManager(DEFAULTPLUGINDIR);
-
-@@ -250,6 +264,7 @@
- { "port", required_argument, NULL, 'p' },
- { "record", required_argument, NULL, 'r' },
- { "resdir", required_argument, NULL, 'r' | 0x100 },
-+ { "showargs", optional_argument, NULL, 's' | 0x200 },
- { "shutdown", required_argument, NULL, 's' },
- { "split", no_argument, NULL, 's' | 0x100 },
- { "terminal", required_argument, NULL, 't' },
-@@ -422,6 +437,19 @@
- case 's' | 0x100:
- Setup.SplitEditedFiles = 1;
- break;
-+ case 's' | 0x200: {
-+ const char *ArgsDir = optarg ? optarg : DEFAULTARGSDIR;
-+ cArgs Args(argv[0]);
-+ if (!Args.ReadDirectory(ArgsDir)) {
-+ fprintf(stderr, "vdr: can't read arguments from directory: %s\n", ArgsDir);
-+ return 2;
-+ }
-+ int c = Args.GetArgc();
-+ char **v = Args.GetArgv();
-+ for (int i = 1; i < c; i++)
-+ printf("%s\n", v[i]);
-+ return 0;
-+ }
- case 't': Terminal = optarg;
- if (access(Terminal, R_OK | W_OK) < 0) {
- fprintf(stderr, "vdr: can't access terminal: %s\n", Terminal);
-@@ -535,6 +563,8 @@
- " -s CMD, --shutdown=CMD call CMD to shutdown the computer\n"
- " --split split edited files at the editing marks (only\n"
- " useful in conjunction with --edit)\n"
-+ " --showargs[=DIR] print the arguments read from DIR and exit\n"
-+ " (default: %s)\n"
- " -t TTY, --terminal=TTY controlling tty\n"
- " -u USER, --user=USER run as user USER; only applicable if started as\n"
- " root\n"
-@@ -557,6 +587,7 @@
- DEFAULTLOCDIR,
- DEFAULTSVDRPPORT,
- DEFAULTRESDIR,
-+ DEFAULTARGSDIR,
- DEFAULTVIDEODIR,
- DEFAULTWATCHDOG
- );
-@@ -837,6 +868,10 @@
- alarm(WatchdogTimeout); // Initial watchdog timer start
- }
-
-+#ifdef SDNOTIFY
-+ sd_notify(0, "READY=1\nSTATUS=Ready");
-+#endif
-+
- // Main program loop:
-
- #define DELETE_MENU ((IsInfoMenu &= (Menu == NULL)), delete Menu, Menu = NULL)
diff --git a/media-video/vdr/vdr-2.0.7.ebuild b/media-video/vdr/vdr-2.0.7.ebuild
deleted file mode 100644
index f5d9d5ed815..00000000000
--- a/media-video/vdr/vdr-2.0.7.ebuild
+++ /dev/null
@@ -1,288 +0,0 @@
-# Copyright 1999-2015 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-
-inherit eutils flag-o-matic multilib toolchain-funcs
-
-# Switches supported by extensions-patch
-EXT_PATCH_FLAGS="alternatechannel ddepgentry dvlvidprefer graphtft
- jumpplay jumpingseconds mainmenuhooks menuorg naludump permashift permashift_v1
- pinplugin rotor ttxtsubs vasarajanauloja wareagleicon yaepg"
-
-# names of the use-flags
-EXT_PATCH_FLAGS_RENAMED=""
-
-# names ext-patch uses internally, here only used for maintainer checks
-EXT_PATCH_FLAGS_RENAMED_EXT_NAME=""
-
-IUSE="bidi debug html systemd vanilla ${EXT_PATCH_FLAGS} ${EXT_PATCH_FLAGS_RENAMED}"
-
-MY_PV="${PV%_p*}"
-MY_P="${PN}-${MY_PV}"
-S="${WORKDIR}/${MY_P}"
-
-EXT_P="extpng-${PN}-2.0.6-gentoo-edition-v6"
-
-DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
-HOMEPAGE="http://www.tvdr.de/"
-SRC_URI="ftp://ftp.tvdr.de/vdr/${MY_P}.tar.bz2
- https://dev.gentoo.org/~hd_brummy/distfiles/${EXT_P}.patch.bz2"
-
-KEYWORDS="~arm ~amd64 ~ppc ~x86"
-SLOT="0"
-LICENSE="GPL-2"
-
-REQUIRED_USE="
- permashift? ( !permashift_v1 )
- permashift_v1? ( !permashift )"
-
-COMMON_DEPEND="virtual/jpeg:*
- sys-libs/libcap
- >=media-libs/fontconfig-2.4.2
- >=media-libs/freetype-2"
-
-DEPEND="${COMMON_DEPEND}
- >=virtual/linuxtv-dvb-headers-5.3
- sys-devel/gettext"
-
-RDEPEND="${COMMON_DEPEND}
- dev-lang/perl
- >=media-tv/gentoo-vdr-scripts-2.5
- media-fonts/corefonts
- bidi? ( dev-libs/fribidi )
- systemd? ( sys-apps/systemd )"
-
-CONF_DIR=/etc/vdr
-CAP_FILE=${S}/capabilities.sh
-CAPS="# Capabilities of the vdr-executable for use by startscript etc."
-
-pkg_setup() {
- use debug && append-flags -g
-
- PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
-
- tc-export CC CXX AR
-}
-
-add_cap() {
- local arg
- for arg; do
- CAPS="${CAPS}\n${arg}=1"
- done
-}
-
-enable_patch() {
- local arg ARG_UPPER
- for arg; do
- ARG_UPPER=$(echo $arg|tr '[:lower:]' '[:upper:]')
- echo "${ARG_UPPER} = 1" >> Make.config
-
- # codesnippet to bring the extpng defines into the vdr.pc CXXFLAGS CFLAGS
- echo "-DUSE_${ARG_UPPER}" >> "${T}"/defines.tmp
- cat "${T}"/defines.tmp | tr \\\012 ' ' > "${T}"/defines.IUSE
- export DEFINES_IUSE=$( cat ${T}/defines.IUSE )
- done
-}
-
-extensions_add_make_conf()
-{
- # copy all ifdef for extensions-patch to Make.config
- sed -e '1,/need to touch the following:/d' \
- -e '/need to touch the following/,/^$/d' \
- Make.config.template >> Make.config
-}
-
-extensions_all_defines() {
- # extract all possible settings for extensions-patch
- sed -e '/^#\?[A-Z].*= 1/!d' -e 's/^#\?//' -e 's/ .*//' \
- Make.config.template \
- | sort \
- | tr '[:upper:]' '[:lower:]'
-}
-
-lang_po() {
- LING_PO=$( ls ${S}/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
-}
-
-src_prepare() {
- # apply maintainace-patches
- ebegin "Changing paths for gentoo"
-
- local DVBDIR=/usr/include
- local i
- for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
- [[ -d ${i} ]] || continue
- if [[ -f ${i}/linux/dvb/dmx.h ]]; then
- einfo "Found DVB header files in ${i}"
- DVBDIR=${i}
- break
- fi
- done
-
- # checking for s2api headers
- local api_version
- api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
- api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
-
- if [[ ${api_version:-0} -lt 5*3 ]]; then
- eerror "DVB header files do not contain s2api support or too old for ${P}"
- eerror "You cannot compile VDR against old dvb-header"
- die "DVB headers too old"
- fi
-
- cat > Make.config <<-EOT
- #
- # Generated by ebuild ${PF}
- #
- PREFIX = /usr
- DVBDIR = ${DVBDIR}
- PLUGINLIBDIR = ${PLUGIN_LIBDIR}
- CONFDIR = ${CONF_DIR}
- VIDEODIR = /var/vdr/video
- LOCDIR = \$(PREFIX)/share/locale
- INCDIR = \$(PREFIX)/include
-
- DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
- INCLUDES += -I\$(DVBDIR)
-
- # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
- # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
- LIBDIR = ${PLUGIN_LIBDIR}
- PCDIR = /usr/$(get_libdir)/pkgconfig
- EOT
- eend 0
-
- # support languages, written from right to left
- BUILD_PARAMS+=" BIDI=$(usex bidi 1 0)"
-
- # systemd support
- use systemd && BUILD_PARAMS+=" SDNOTIFY=$(usex systemd 1 0)"
-
- if ! use vanilla; then
-
- # Now apply extensions patch
- epatch "${WORKDIR}/${EXT_P}.patch"
-
- # This allows us to start even if some plugin does not exist
- # or is not loadable.
- enable_patch PLUGINMISSING
- enable_patch CHANNELBIND
-
- if [[ -n ${VDR_MAINTAINER_MODE} ]]; then
- einfo "Doing maintainer checks:"
-
- # we do not support these patches
- # (or have them already hard enabled)
- local IGNORE_PATCHES="pluginmissing channelbind"
-
- extensions_all_defines > "${T}"/new.IUSE
- echo $EXT_PATCH_FLAGS $EXT_PATCH_FLAGS_RENAMED_EXT_NAME \
- $IGNORE_PATCHES | \
- tr ' ' '\n' |sort > "${T}"/old.IUSE
- local DIFFS=$(diff -u "${T}"/old.IUSE "${T}"/new.IUSE|grep '^[+-][^+-]')
- if [[ -z ${DIFFS} ]]; then
- einfo "EXT_PATCH_FLAGS is up to date."
- else
- ewarn "IUSE differences!"
- local diff
- for diff in $DIFFS; do
- ewarn "$diff"
- done
- fi
- fi
-
- ebegin "Enabling selected patches"
- local flag
- for flag in $EXT_PATCH_FLAGS; do
- use $flag && enable_patch ${flag}
- done
-
- eend 0
-
- extensions_add_make_conf
-
- # add defined use-flags compile options to vdr.pc
- sed -e "s:\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR):\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR) \$(DEFINES_IUSE):" \
- -i Makefile
-
- ebegin "Make depend"
- emake .dependencies >/dev/null
- eend $? "make depend failed"
- fi
-
- epatch "${FILESDIR}/${PN}-2.0.6-r2_gentoo.patch"
-
- # backport from vdr-2.1.7 for better systemd support
- if use vanilla; then
- epatch "${FILESDIR}/${P}_systemd_argsdir_vanilla.patch"
- else
- epatch "${FILESDIR}/${P}_systemd_argsdir.patch"
- fi
-
- epatch_user
-
- add_cap CAP_UTF8
-
- add_cap CAP_IRCTRL_RUNTIME_PARAM \
- CAP_VFAT_RUNTIME_PARAM \
- CAP_CHUID \
- CAP_SHUTDOWN_AUTO_RETRY
-
- echo -e ${CAPS} > "${CAP_FILE}"
-
- # LINGUAS support
- einfo "\n \t VDR supports the LINGUAS values"
-
- lang_po
-
- einfo "\t Please set one of this values in your sytem make.conf"
- einfo "\t LINGUAS=\"${LING_PO}\"\n"
-
- if [[ -z ${LINGUAS} ]]; then
- einfo "\n \t No values in LINGUAS="
- einfo "\t You will get only english text on OSD \n"
- fi
-
- strip-linguas ${LING_PO} en
-}
-
-src_install() {
-# # trick makefile not to create a videodir by supplying it with an existing
-# # directory
- emake \
- VIDEODIR="/" \
- DESTDIR="${D}" install || die "emake install failed"
-
- keepdir "${PLUGIN_LIBDIR}"
-
- # backup for plugins they don't be able to create this dir
- keepdir "${CONF_DIR}"/plugins
-
- if use html; then
- dohtml *.html
- fi
-
- dodoc MANUAL INSTALL README* HISTORY CONTRIBUTORS
-
- insinto /usr/share/vdr
- doins "${CAP_FILE}"
-
- if use alternatechannel; then
- insinto /etc/vdr
- doins "${FILESDIR}"/channel_alternative.conf
- fi
-
- chown -R vdr:vdr "${D}/${CONF_DIR}"
-}
-
-pkg_postinst() {
- elog "It is a good idea to run vdrplugin-rebuild now."
-
- elog "To get nice symbols in OSD we recommend to install"
- elog "\t1. emerge media-fonts/vdrsymbols-ttf"
- elog "\t2. select font VDRSymbolsSans in Setup"
- elog ""
- elog "To get an idea how to proceed now, have a look at our vdr-guide:"
- elog "\thttps://wiki.gentoo.org/wiki/VDR"
-}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2019-04-11 22:39 David Seifert
0 siblings, 0 replies; 15+ messages in thread
From: David Seifert @ 2019-04-11 22:39 UTC (permalink / raw
To: gentoo-commits
commit: f5fc0aa4c9cd0708692451bfb3b2e92ef2cbd4aa
Author: David Seifert <soap <AT> gentoo <DOT> org>
AuthorDate: Thu Apr 11 22:39:10 2019 +0000
Commit: David Seifert <soap <AT> gentoo <DOT> org>
CommitDate: Thu Apr 11 22:39:10 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f5fc0aa4
media-video/vdr: Fix building with media-libs/jpeg
Closes: https://bugs.gentoo.org/667934
Package-Manager: Portage-2.3.62, Repoman-2.3.12
Signed-off-by: David Seifert <soap <AT> gentoo.org>
media-video/vdr/files/vdr-2.2.0-jpeg-9c.patch | 34 +++++++++++++++++++++++++++
media-video/vdr/vdr-2.2.0-r3.ebuild | 3 ++-
2 files changed, 36 insertions(+), 1 deletion(-)
diff --git a/media-video/vdr/files/vdr-2.2.0-jpeg-9c.patch b/media-video/vdr/files/vdr-2.2.0-jpeg-9c.patch
new file mode 100644
index 00000000000..b67c94d7c57
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.2.0-jpeg-9c.patch
@@ -0,0 +1,34 @@
+https://bugs.gentoo.org/667934
+
+--- a/tools.c
++++ b/tools.c
+@@ -1221,15 +1221,15 @@
+ }
+ else {
+ esyslog("ERROR: out of memory");
+- return false;
++ return FALSE;
+ }
+ if (jcd->mem) {
+ cinfo->dest->next_output_byte = jcd->mem + Used;
+ cinfo->dest->free_in_buffer = jcd->size - Used;
+- return true;
++ return TRUE;
+ }
+ }
+- return false;
++ return FALSE;
+ }
+
+ static void JpegCompressTermDestination(j_compress_ptr cinfo)
+@@ -1274,8 +1274,8 @@
+ cinfo.in_color_space = JCS_RGB;
+
+ jpeg_set_defaults(&cinfo);
+- jpeg_set_quality(&cinfo, Quality, true);
+- jpeg_start_compress(&cinfo, true);
++ jpeg_set_quality(&cinfo, Quality, TRUE);
++ jpeg_start_compress(&cinfo, TRUE);
+
+ int rs = Width * 3;
+ JSAMPROW rp[Height];
diff --git a/media-video/vdr/vdr-2.2.0-r3.ebuild b/media-video/vdr/vdr-2.2.0-r3.ebuild
index ff3911ffe09..0b6e8222559 100644
--- a/media-video/vdr/vdr-2.2.0-r3.ebuild
+++ b/media-video/vdr/vdr-2.2.0-r3.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
@@ -220,6 +220,7 @@ src_prepare() {
eapply "${FILESDIR}/${P}_gentoo.patch"
eapply "${FILESDIR}/${P}_unsignedtosigned.patch"
eapply "${FILESDIR}/${P}_glibc-2.24.patch"
+ eapply "${FILESDIR}/${P}-jpeg-9c.patch"
# fix some makefile issues
sed -e "s:ifndef NO_KBD:ifeq (\$(USE_KBD),1):" \
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2019-07-31 13:55 Andreas Sturmlechner
0 siblings, 0 replies; 15+ messages in thread
From: Andreas Sturmlechner @ 2019-07-31 13:55 UTC (permalink / raw
To: gentoo-commits
commit: 32a83fbc6d69bdc5ed76260355d6a5be2806f2cb
Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Wed Jul 31 13:33:16 2019 +0000
Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Wed Jul 31 13:50:16 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=32a83fbc
media-video/vdr: Drop 2.0.6-r1 and 2.2.0-r1
Package-Manager: Portage-2.3.69, Repoman-2.3.16
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>
media-video/vdr/Manifest | 2 -
media-video/vdr/files/vdr-2.0.6_gentoo.patch | 68 ------
media-video/vdr/metadata.xml | 9 -
media-video/vdr/vdr-2.0.6-r1.ebuild | 277 -------------------------
media-video/vdr/vdr-2.2.0-r1.ebuild | 299 ---------------------------
5 files changed, 655 deletions(-)
diff --git a/media-video/vdr/Manifest b/media-video/vdr/Manifest
index e9b20f623a1..dac0f69a4e8 100644
--- a/media-video/vdr/Manifest
+++ b/media-video/vdr/Manifest
@@ -1,4 +1,2 @@
-DIST extpng-vdr-2.0.6-gentoo-edition-v6.patch.bz2 69472 BLAKE2B 60669e9c20b2bd573eb05733bbf9548d2e643b36693be8b15a377b38470708a71b29e2a16baf7ed378132265f814ec9d35dae749ccf6ae204cd9beb787dc8f57 SHA512 f4ecb786ec5a026fa75fcf539518e80273bf43fc325c13a380c70eb85351910efa991b3ee71ca477e597bc2b4598a18620b6cf00fc02714acfcc4e6112d84b6c
DIST extpng-vdr-2.2.0-gentoo-edition-v1.patch.bz2 34664 BLAKE2B 81b68ebe0ef4588c3676f0b7a2c766d8d4d4f754a987b3be5868f3c6eff9158d4cea8e492ca81df535e637dbdc5baff638d1fafb4163e9d9a2d0125aba17e2e1 SHA512 16d6fbb8201f003dfe653b6a49424b794d7e697e27ad6f2383dbe17b76712ea5a3da88a676900b84d75ff7425bf3eb9084d60a89a4598758f482dc1f013f7b3e
-DIST vdr-2.0.6.tar.bz2 839575 BLAKE2B 40de46d8465b7008bc29c7e2c1c241d4114aa3d62aa6a0acd81636133c295cd87c2fc618e725885c98f47445220e897c23188373457a96b51cf832ca417c9842 SHA512 070ebbfb85478887088567872a71744305dbf9c75de8b095a8fe46d883b0b4fe140539caeb2243715f42793a45790a127542655f549f7ea3cb71c4f9912fa07d
DIST vdr-2.2.0.tar.bz2 922708 BLAKE2B 975e07d6d4c5bd13ee92be5d6a1826d6404b0c59e20fa2e30689b185a61e02d54782ad528e6a4f15e0d36806b30bcf48aa336d63adb3604e78056ff318e0fd2c SHA512 183f58133915c6c0fe8ec2b88becbcb2a36418210e6dcf7931053d3771d727c3581593f9eb5c9693abf39e22e728f7b41c42079cd704610c3636ec05134ea93d
diff --git a/media-video/vdr/files/vdr-2.0.6_gentoo.patch b/media-video/vdr/files/vdr-2.0.6_gentoo.patch
deleted file mode 100644
index 1641fc8e2ee..00000000000
--- a/media-video/vdr/files/vdr-2.0.6_gentoo.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-diff -Naur vdr-2.0.6.orig/Makefile vdr-2.0.6/Makefile
---- vdr-2.0.6.orig/Makefile 2014-09-22 22:17:23.000000000 +0200
-+++ vdr-2.0.6/Makefile 2014-09-24 15:22:43.000000000 +0200
-@@ -109,7 +109,7 @@
- VDRVERSION = $(shell sed -ne '/define VDRVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h)
- APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h)
-
--all: vdr i18n plugins
-+all: vdr i18n
-
- # Implicit rules:
-
-@@ -162,7 +162,7 @@
-
- PODIR = po
- LOCALEDIR = locale
--I18Npo = $(wildcard $(PODIR)/*.po)
-+I18Npo = $(foreach dir,$(LINGUAS),$(wildcard $(PODIR)/$(dir)*.po))
- I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file))))
- I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr.mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file))))))
- I18Npot = $(PODIR)/vdr.pot
-@@ -185,7 +185,7 @@
-
- install-i18n: i18n
- @mkdir -p $(DESTDIR)$(LOCDIR)
-- cp -r $(LOCALEDIR)/* $(DESTDIR)$(LOCDIR)
-+ @(cd $(LOCALEDIR); for linguas in $(LINGUAS); do [ "$$linguas" = "en" ] && continue; cp -r --parents $$linguas* $(DESTDIR)$(LOCDIR); done)
-
- # The 'include' directory (for plugins):
-
-@@ -247,7 +247,7 @@
-
- # Install the files (note that 'install-pc' must be first!):
-
--install: install-pc install-bin install-dirs install-conf install-doc install-plugins install-i18n install-includes
-+install: install-pc install-bin install-dirs install-conf install-doc install-i18n install-includes
-
- # VDR binary:
-
-@@ -259,11 +259,12 @@
-
- install-dirs:
- @mkdir -p $(DESTDIR)$(VIDEODIR)
-- @mkdir -p $(DESTDIR)$(CONFDIR)
-- @mkdir -p $(DESTDIR)$(CACHEDIR)
-+# @mkdir -p $(DESTDIR)$(CONFDIR)
-+# @mkdir -p $(DESTDIR)$(CACHEDIR)
- @mkdir -p $(DESTDIR)$(RESDIR)
-
- install-conf:
-+ @mkdir -p $(DESTDIR)$(CONFDIR)
- @cp -pn *.conf $(DESTDIR)$(CONFDIR)
-
- # Documentation:
-@@ -290,8 +291,11 @@
- # Includes:
-
- install-includes: include-dir
-- @mkdir -p $(DESTDIR)$(INCDIR)
-- @cp -pLR include/vdr include/libsi $(DESTDIR)$(INCDIR)
-+# @mkdir -p $(DESTDIR)$(INCDIR)
-+# @cp -pLR include/vdr include/libsi $(DESTDIR)$(INCDIR)
-+ @mkdir -p $(DESTDIR)$(INCDIR)/vdr $(DESTDIR)$(INCDIR)/vdr/libsi
-+ @cp -pLR include/vdr $(DESTDIR)$(INCDIR)
-+ @cp -pLR include/libsi Make.config $(DESTDIR)$(INCDIR)/vdr
-
- # pkg-config file:
-
diff --git a/media-video/vdr/metadata.xml b/media-video/vdr/metadata.xml
index 8ebb4b08a51..f9813be524f 100644
--- a/media-video/vdr/metadata.xml
+++ b/media-video/vdr/metadata.xml
@@ -8,25 +8,16 @@
<use>
<flag name="alternatechannel">Use alternate channel on record</flag>
<flag name="bidi">fribidi support, for languages, written from right to left</flag>
- <flag name="ddepgentry">remove duplicate EPG entries</flag>
- <flag name="dvlvidprefer">controls video-dir choice on recording</flag>
<flag name="graphtft">support for vdr-graphtft plugin up from version 0.1.7</flag>
<flag name="html">Install HTML documentation</flag>
- <flag name="jumpplay">Enables automatic jumping over cut marks while watching a recording</flag>
- <flag name="jumpingseconds">skip seconds in played records</flag>
<flag name="kbd">enable keyboard support as remote device</flag>
<flag name="mainmenuhooks">Allows to replace main menu entries by some special plugins (like epgsearch, extrecmenu, ...)</flag>
<flag name="menuorg">Enables support for the <pkg>media-plugins/vdr-menuorg</pkg></flag>
<flag name="menuselection">adds support for menu hotkeys of double digits</flag>
<flag name="naludump">Removes NALU fill data from h.264-Streams of TS files</flag>
- <flag name="permashift">permanent timeshift by recording live TV on hard disk, need plugin <pkg>media-plugins/vdr-permashift</pkg></flag>
<flag name="permashift_v1">permanent timeshift by recording live TV on RAM, need plugin >=mediaplugins/vdr-permashift-1</flag>
<flag name="pinplugin">Support for <pkg>media-plugins/vdr-pin</pkg></flag>
<flag name="resumereset">rreset resume of EOF</flag>
- <flag name="rotor">Enable support for plugin vdr-rotor for dish-positioner.</flag>
<flag name="ttxtsubs">support for <pkg>media-plugins/vdr-ttxtsubs</pkg></flag>
- <flag name="vasarajanauloja">replacement for the liemikuutio patch, adds some nice must haves features</flag>
- <flag name="wareagleicon">Replace original icon set in menu</flag>
- <flag name="yaepg">Enables support for the vdr-yaepg plugin</flag>
</use>
</pkgmetadata>
diff --git a/media-video/vdr/vdr-2.0.6-r1.ebuild b/media-video/vdr/vdr-2.0.6-r1.ebuild
deleted file mode 100644
index 63de150c12f..00000000000
--- a/media-video/vdr/vdr-2.0.6-r1.ebuild
+++ /dev/null
@@ -1,277 +0,0 @@
-# Copyright 1999-2015 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-
-inherit eutils flag-o-matic multilib toolchain-funcs
-
-# Switches supported by extensions-patch
-EXT_PATCH_FLAGS="alternatechannel ddepgentry dvlvidprefer graphtft
- jumpplay jumpingseconds mainmenuhooks menuorg naludump permashift permashift_v1
- pinplugin rotor ttxtsubs vasarajanauloja wareagleicon yaepg"
-
-# names of the use-flags
-EXT_PATCH_FLAGS_RENAMED=""
-
-# names ext-patch uses internally, here only used for maintainer checks
-EXT_PATCH_FLAGS_RENAMED_EXT_NAME=""
-
-IUSE="bidi debug html vanilla ${EXT_PATCH_FLAGS} ${EXT_PATCH_FLAGS_RENAMED}"
-
-MY_PV="${PV%_p*}"
-MY_P="${PN}-${MY_PV}"
-S="${WORKDIR}/${MY_P}"
-
-EXT_P="extpng-${P}-gentoo-edition-v6"
-
-DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
-HOMEPAGE="http://www.tvdr.de/"
-SRC_URI="ftp://ftp.tvdr.de/vdr/${MY_P}.tar.bz2
- https://dev.gentoo.org/~hd_brummy/distfiles/${EXT_P}.patch.bz2"
-
-KEYWORDS="amd64 ~arm ~ppc x86"
-SLOT="0"
-LICENSE="GPL-2"
-
-REQUIRED_USE="
- permashift? ( !permashift_v1 )
- permashift_v1? ( !permashift )"
-
-COMMON_DEPEND="virtual/jpeg:*
- sys-libs/libcap
- >=media-libs/fontconfig-2.4.2
- >=media-libs/freetype-2"
-
-DEPEND="${COMMON_DEPEND}
- >=virtual/linuxtv-dvb-headers-5.3
- sys-devel/gettext"
-
-RDEPEND="${COMMON_DEPEND}
- dev-lang/perl
- >=media-tv/gentoo-vdr-scripts-2.5_rc1
- media-fonts/corefonts
- bidi? ( dev-libs/fribidi )"
-
-CONF_DIR=/etc/vdr
-CAP_FILE=${S}/capabilities.sh
-CAPS="# Capabilities of the vdr-executable for use by startscript etc."
-
-pkg_setup() {
- use debug && append-flags -g
-
- PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
-
- tc-export CC CXX AR
-}
-
-add_cap() {
- local arg
- for arg; do
- CAPS="${CAPS}\n${arg}=1"
- done
-}
-
-enable_patch() {
- local arg ARG_UPPER
- for arg; do
- ARG_UPPER=$(echo $arg|tr '[:lower:]' '[:upper:]')
- echo "${ARG_UPPER} = 1" >> Make.config
-
- # codesnippet to bring the extpng defines into the vdr.pc CXXFLAGS CFLAGS
- echo "-DUSE_${ARG_UPPER}" >> "${T}"/defines.tmp
- cat "${T}"/defines.tmp | tr \\\012 ' ' > "${T}"/defines.IUSE
- export DEFINES_IUSE=$( cat ${T}/defines.IUSE )
- done
-}
-
-extensions_add_make_conf()
-{
- # copy all ifdef for extensions-patch to Make.config
- sed -e '1,/need to touch the following:/d' \
- -e '/need to touch the following/,/^$/d' \
- Make.config.template >> Make.config
-}
-
-extensions_all_defines() {
- # extract all possible settings for extensions-patch
- sed -e '/^#\?[A-Z].*= 1/!d' -e 's/^#\?//' -e 's/ .*//' \
- Make.config.template \
- | sort \
- | tr '[:upper:]' '[:lower:]'
-}
-
-lang_po() {
- LING_PO=$( ls ${S}/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
-}
-
-src_prepare() {
- # apply maintainace-patches
- ebegin "Changing paths for gentoo"
-
- local DVBDIR=/usr/include
- local i
- for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
- [[ -d ${i} ]] || continue
- if [[ -f ${i}/linux/dvb/dmx.h ]]; then
- einfo "Found DVB header files in ${i}"
- DVBDIR=${i}
- break
- fi
- done
-
- # checking for s2api headers
- local api_version
- api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
- api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
-
- if [[ ${api_version:-0} -lt 5*3 ]]; then
- eerror "DVB header files do not contain s2api support or too old for ${P}"
- eerror "You cannot compile VDR against old dvb-header"
- die "DVB headers too old"
- fi
-
- cat > Make.config <<-EOT
- #
- # Generated by ebuild ${PF}
- #
- PREFIX = /usr
- DVBDIR = ${DVBDIR}
- PLUGINLIBDIR = ${PLUGIN_LIBDIR}
- CONFDIR = ${CONF_DIR}
- VIDEODIR = /var/vdr/video
- LOCDIR = \$(PREFIX)/share/locale
- INCDIR = \$(PREFIX)/include
-
- DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
- INCLUDES += -I\$(DVBDIR)
-
- # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
- # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
- LIBDIR = ${PLUGIN_LIBDIR}
- PCDIR = /usr/$(get_libdir)/pkgconfig
- EOT
- eend 0
-
- # support languages, written from right to left
- BUILD_PARAMS+=" BIDI=$(usex bidi 1 0)"
-
- epatch "${FILESDIR}/${PN}-2.0.6_gentoo.patch"
-
- if ! use vanilla; then
-
- # Now apply extensions patch
- epatch "${WORKDIR}/${EXT_P}.patch"
-
- # This allows us to start even if some plugin does not exist
- # or is not loadable.
- enable_patch PLUGINMISSING
- enable_patch CHANNELBIND
-
- if [[ -n ${VDR_MAINTAINER_MODE} ]]; then
- einfo "Doing maintainer checks:"
-
- # we do not support these patches
- # (or have them already hard enabled)
- local IGNORE_PATCHES="pluginmissing channelbind"
-
- extensions_all_defines > "${T}"/new.IUSE
- echo $EXT_PATCH_FLAGS $EXT_PATCH_FLAGS_RENAMED_EXT_NAME \
- $IGNORE_PATCHES | \
- tr ' ' '\n' |sort > "${T}"/old.IUSE
- local DIFFS=$(diff -u "${T}"/old.IUSE "${T}"/new.IUSE|grep '^[+-][^+-]')
- if [[ -z ${DIFFS} ]]; then
- einfo "EXT_PATCH_FLAGS is up to date."
- else
- ewarn "IUSE differences!"
- local diff
- for diff in $DIFFS; do
- ewarn "$diff"
- done
- fi
- fi
-
- ebegin "Enabling selected patches"
- local flag
- for flag in $EXT_PATCH_FLAGS; do
- use $flag && enable_patch ${flag}
- done
-
- eend 0
-
- extensions_add_make_conf
-
- # add defined use-flags compile options to vdr.pc
- sed -e "s:\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR):\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR) \$(DEFINES_IUSE):" \
- -i Makefile
-
- ebegin "Make depend"
- emake .dependencies >/dev/null
- eend $? "make depend failed"
- fi
-
- epatch_user
-
- add_cap CAP_UTF8
-
- add_cap CAP_IRCTRL_RUNTIME_PARAM \
- CAP_VFAT_RUNTIME_PARAM \
- CAP_CHUID \
- CAP_SHUTDOWN_AUTO_RETRY
-
- echo -e ${CAPS} > "${CAP_FILE}"
-
- # LINGUAS support
- einfo "\n \t VDR supports the LINGUAS values"
-
- lang_po
-
- einfo "\t Please set one of this values in your sytem make.conf"
- einfo "\t LINGUAS=\"${LING_PO}\"\n"
-
- if [[ -z ${LINGUAS} ]]; then
- einfo "\n \t No values in LINGUAS="
- einfo "\t You will get only english text on OSD \n"
- fi
-
- strip-linguas ${LING_PO} en
-}
-
-src_install() {
-# # trick makefile not to create a videodir by supplying it with an existing
-# # directory
- emake \
- VIDEODIR="/" \
- DESTDIR="${D}" install || die "emake install failed"
-
- keepdir "${PLUGIN_LIBDIR}"
-
- keepdir "${CONF_DIR}"/plugins
- keepdir "${CONF_DIR}"/themes
-
- if use html; then
- dohtml *.html
- fi
-
- dodoc MANUAL INSTALL README* HISTORY CONTRIBUTORS
-
- insinto /usr/share/vdr
- doins "${CAP_FILE}"
-
- if use alternatechannel; then
- insinto /etc/vdr
- doins "${FILESDIR}"/channel_alternative.conf
- fi
-
- chown -R vdr:vdr "${D}/${CONF_DIR}"
-}
-
-pkg_postinst() {
- elog "It is a good idea to run vdrplugin-rebuild now."
-
- elog "To get nice symbols in OSD we recommend to install"
- elog "\t1. emerge media-fonts/vdrsymbols-ttf"
- elog "\t2. select font VDRSymbolsSans in Setup"
- elog ""
- elog "To get an idea how to proceed now, have a look at our vdr-guide:"
- elog "\thttps://wiki.gentoo.org/wiki/VDR"
-}
diff --git a/media-video/vdr/vdr-2.2.0-r1.ebuild b/media-video/vdr/vdr-2.2.0-r1.ebuild
deleted file mode 100644
index ce73df6b100..00000000000
--- a/media-video/vdr/vdr-2.2.0-r1.ebuild
+++ /dev/null
@@ -1,299 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-#inherit eutils flag-o-matic multilib toolchain-funcs
-inherit flag-o-matic toolchain-funcs
-
-# Switches supported by extensions-patch
-EXT_PATCH_FLAGS="alternatechannel graphtft naludump permashift_v1 pinplugin
- mainmenuhooks menuorg menuselection resumereset ttxtsubs"
-
-# names of the use-flags
-EXT_PATCH_FLAGS_RENAMED=""
-
-# names ext-patch uses internally, here only used for maintainer checks
-EXT_PATCH_FLAGS_RENAMED_EXT_NAME="bidi no_kbd sdnotify"
-
-IUSE="bidi debug +kbd html systemd vanilla ${EXT_PATCH_FLAGS} ${EXT_PATCH_FLAGS_RENAMED}"
-
-MY_PV="${PV%_p*}"
-MY_P="${PN}-${MY_PV}"
-S="${WORKDIR}/${MY_P}"
-
-EXT_P="extpng-${P}-gentoo-edition-v1"
-
-DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
-HOMEPAGE="http://www.tvdr.de/"
-SRC_URI="ftp://ftp.tvdr.de/vdr/${MY_P}.tar.bz2
- https://dev.gentoo.org/~hd_brummy/distfiles/${EXT_P}.patch.bz2"
-
-KEYWORDS="amd64 ~arm ~arm64 ~ppc x86"
-SLOT="0"
-LICENSE="GPL-2"
-
-COMMON_DEPEND="virtual/jpeg:*
- sys-libs/libcap
- >=media-libs/fontconfig-2.4.2
- >=media-libs/freetype-2"
-
-DEPEND="${COMMON_DEPEND}
- >=virtual/linuxtv-dvb-headers-5.3
- sys-devel/gettext"
-
-RDEPEND="${COMMON_DEPEND}
- dev-lang/perl
- >=media-tv/gentoo-vdr-scripts-2.7
- media-fonts/corefonts
- bidi? ( dev-libs/fribidi )
- systemd? ( sys-apps/systemd )"
-
-CONF_DIR=/etc/vdr
-CAP_FILE=${S}/capabilities.sh
-CAPS="# Capabilities of the vdr-executable for use by startscript etc."
-
-pkg_setup() {
-
- use debug && append-flags -g
-
- PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
-
- tc-export CC CXX AR
-}
-
-add_cap() {
- local arg
- for arg; do
- CAPS="${CAPS}\n${arg}=1"
- done
-}
-
-enable_patch() {
- local arg ARG_UPPER
- for arg; do
- ARG_UPPER=$(echo $arg|tr '[:lower:]' '[:upper:]')
- echo "${ARG_UPPER} = 1" >> Make.config
-
- # codesnippet to bring the extpng defines into the vdr.pc CXXFLAGS CFLAGS
- echo "-DUSE_${ARG_UPPER}" >> "${T}"/defines.tmp
- cat "${T}"/defines.tmp | tr \\\012 ' ' > "${T}"/defines.IUSE
- export DEFINES_IUSE=$( cat ${T}/defines.IUSE )
- done
-}
-
-extensions_add_make_conf()
-{
- # copy all ifdef for extensions-patch to Make.config
- sed -e '1,/need to touch the following:/d' \
- -e '/need to touch the following/,/^$/d' \
- Make.config.template >> Make.config
-}
-
-extensions_all_defines() {
- # extract all possible settings for extensions-patch
- sed -e '/^#\?[A-Z].*= 1/!d' -e 's/^#\?//' -e 's/ .*//' \
- Make.config.template \
- | sort \
- | tr '[:upper:]' '[:lower:]'
-}
-
-lang_po() {
- LING_PO=$( ls ${S}/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
-}
-
-src_configure() {
- # support languages, written from right to left
- export "BIDI=$(usex bidi 1 0)"
- # systemd notification support
- export "SDNOTIFY=$(usex systemd 1 0)"
- # with/without keyboard
- export "USE_KBD=$(usex kbd 1 0)"
-}
-
-src_prepare() {
- # apply maintainace-patches
- ebegin "Changing paths for gentoo"
-
- local DVBDIR=/usr/include
- local i
- for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
- [[ -d ${i} ]] || continue
- if [[ -f ${i}/linux/dvb/dmx.h ]]; then
- einfo "Found DVB header files in ${i}"
- DVBDIR=${i}
- break
- fi
- done
-
- # checking for s2api headers
- local api_version
- api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
- api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
-
- if [[ ${api_version:-0} -lt 5*3 ]]; then
- eerror "DVB header files do not contain s2api support or too old for ${P}"
- eerror "You cannot compile VDR against old dvb-header"
- die "DVB headers too old"
- fi
-
- cat > Make.config <<-EOT
- #
- # Generated by ebuild ${PF}
- #
- PREFIX = /usr
- DVBDIR = ${DVBDIR}
- PLUGINLIBDIR = ${PLUGIN_LIBDIR}
- CONFDIR = ${CONF_DIR}
- VIDEODIR = /var/vdr/video
- LOCDIR = \$(PREFIX)/share/locale
- INCDIR = \$(PREFIX)/include
-
- DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
- INCLUDES += -I\$(DVBDIR)
-
- # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
- # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
- LIBDIR = ${PLUGIN_LIBDIR}
- PCDIR = /usr/$(get_libdir)/pkgconfig
-
- EOT
- eend 0
-
- # wrt bug 586070
- if has_version ">=sys-apps/systemd-230"; then
- sed -e "s:libsystemd-daemon:libsystemd:g" -i Makefile || die "sed libsystemd failed"
- fi
-
- if ! use vanilla; then
-
- # Now apply extensions patch
- eapply "${WORKDIR}/${EXT_P}.patch"
-
- # This allows us to start even if some plugin does not exist
- # or is not loadable.
- enable_patch PLUGINMISSING
-
- if [[ -n ${VDR_MAINTAINER_MODE} ]]; then
- einfo "Doing maintainer checks:"
-
- # we do not support these patches
- # (or have them already hard enabled)
- local IGNORE_PATCHES="pluginmissing"
-
- extensions_all_defines > "${T}"/new.IUSE
- echo $EXT_PATCH_FLAGS $EXT_PATCH_FLAGS_RENAMED_EXT_NAME \
- $IGNORE_PATCHES | \
- tr ' ' '\n' |sort > "${T}"/old.IUSE
- local DIFFS=$(diff -u "${T}"/old.IUSE "${T}"/new.IUSE|grep '^[+-][^+-]')
- if [[ -z ${DIFFS} ]]; then
- einfo "EXT_PATCH_FLAGS is up to date."
- else
- ewarn "IUSE differences!"
- local diff
- for diff in $DIFFS; do
- ewarn "$diff"
- done
- fi
- fi
-
- ebegin "Enabling selected patches"
- local flag
- for flag in $EXT_PATCH_FLAGS; do
- use $flag && enable_patch ${flag}
- done
-
- eend 0
-
- extensions_add_make_conf
-
- # add defined use-flags compile options to vdr.pc
- sed -e "s:\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR):\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR) \$(DEFINES_IUSE):" \
- -i Makefile
-
- ebegin "Make depend"
- emake .dependencies >/dev/null
- eend $? "make depend failed"
- fi
-
- eapply "${FILESDIR}/${P}_gentoo.patch"
-
- # fix some makefile issues
- sed -e "s:ifndef NO_KBD:ifeq (\$(USE_KBD),1):" \
- -e "s:ifdef BIDI:ifeq (\$(BIDI),1):" \
- -e "s:ifdef SDNOTIFY:ifeq (\$(SDNOTIFY),1):" \
- -i "${S}"/Makefile
-
- eapply_user
-
- add_cap CAP_UTF8
-
- add_cap CAP_IRCTRL_RUNTIME_PARAM \
- CAP_VFAT_RUNTIME_PARAM \
- CAP_CHUID \
- CAP_SHUTDOWN_AUTO_RETRY
-
- echo -e ${CAPS} > "${CAP_FILE}"
-
- # LINGUAS support
- einfo "\n \t VDR supports the LINGUAS values"
-
- lang_po
-
- einfo "\t Please set one of this values in your sytem make.conf"
- einfo "\t LINGUAS=\"${LING_PO}\"\n"
-
- if [[ -z ${LINGUAS} ]]; then
- einfo "\n \t No values in LINGUAS="
- einfo "\t You will get only english text on OSD \n"
- fi
-
- strip-linguas ${LING_PO} en
-}
-
-src_install() {
- # trick makefile not to create a videodir by supplying it with an existing
- # directory
- emake install \
- VIDEODIR="/" \
- DESTDIR="${D}" install || die "emake install failed"
-
- keepdir "${PLUGIN_LIBDIR}"
-
- # backup for plugins they don't be able to create this dir
- keepdir "${CONF_DIR}"/plugins
-
- if use html; then
- local HTML_DOCS=( *.html )
- fi
-
- local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS )
-
- einstalldocs
-
- insinto /usr/share/vdr
- doins "${CAP_FILE}"
-
- if use alternatechannel; then
- insinto /etc/vdr
- doins "${FILESDIR}"/channel_alternative.conf
- fi
-
- chown -R vdr:vdr "${D}/${CONF_DIR}"
-}
-
-pkg_postinst() {
-
- elog "\n\t---- 15 YEARS ANNIVERSARY EDITON ----\n"
- elog "\tA lot of thanks to Klaus Schmidinger"
- elog "\tfor this nice piece of Software...\n"
-
- elog "It is a good idea to run vdrplugin-rebuild now."
-
- elog "To get nice symbols in OSD we recommend to install"
- elog "\t1. emerge media-fonts/vdrsymbols-ttf"
- elog "\t2. select font VDRSymbolsSans in Setup"
- elog ""
- elog "To get an idea how to proceed now, have a look at our vdr-guide:"
- elog "\thttps://wiki.gentoo.org/wiki/VDR"
-}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2019-11-17 1:34 David Seifert
0 siblings, 0 replies; 15+ messages in thread
From: David Seifert @ 2019-11-17 1:34 UTC (permalink / raw
To: gentoo-commits
commit: 2f472c1f91d21444530ed18c29a26db3fccc40a8
Author: Martin Dummer <martin.dummer <AT> gmx <DOT> net>
AuthorDate: Sun Nov 17 01:33:46 2019 +0000
Commit: David Seifert <soap <AT> gentoo <DOT> org>
CommitDate: Sun Nov 17 01:33:46 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2f472c1f
media-video/vdr: fix multiple QA issues
* QA issue: USE flag 'permashift_v1' uses reserved underscore
character, rename USE flag 'permashift_v1' to 'permashift'
* QA issue: UnnecessarySlashStrip in DESTDIR="${D%/}"
* QA issue: makefile installs pre-compressed manpages
Bug: https://bugs.gentoo.org/695066
Closes: https://github.com/gentoo/gentoo/pull/13588
Package-Manager: Portage-2.3.78, Repoman-2.3.17
Signed-off-by: Martin Dummer <martin.dummer <AT> gmx.net>
Signed-off-by: David Seifert <soap <AT> gentoo.org>
media-video/vdr/files/vdr-2.2.0_gentoo.patch | 35 +++++++-----
media-video/vdr/metadata.xml | 12 ++++-
media-video/vdr/vdr-2.2.0-r3.ebuild | 4 +-
.../{vdr-2.2.0-r3.ebuild => vdr-2.2.0-r4.ebuild} | 62 +++++++++++-----------
4 files changed, 63 insertions(+), 50 deletions(-)
diff --git a/media-video/vdr/files/vdr-2.2.0_gentoo.patch b/media-video/vdr/files/vdr-2.2.0_gentoo.patch
index 37ffd3c7b2c..70066f5b0c8 100644
--- a/media-video/vdr/files/vdr-2.2.0_gentoo.patch
+++ b/media-video/vdr/files/vdr-2.2.0_gentoo.patch
@@ -1,7 +1,6 @@
-diff -Naur vdr-2.1.7.orig/Makefile vdr-2.1.7/Makefile
---- vdr-2.1.7.orig/Makefile 2015-01-18 12:37:45.506034673 +0100
-+++ vdr-2.1.7/Makefile 2015-01-18 12:38:34.086037162 +0100
-@@ -116,7 +116,7 @@
+--- a/Makefile
++++ b/Makefile
+@@ -124,7 +124,7 @@
VDRVERSION = $(shell sed -ne '/define VDRVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h)
APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h)
@@ -10,7 +9,7 @@ diff -Naur vdr-2.1.7.orig/Makefile vdr-2.1.7/Makefile
# Implicit rules:
-@@ -170,7 +170,7 @@
+@@ -179,7 +179,7 @@
PODIR = po
LOCALEDIR = locale
@@ -19,7 +18,7 @@ diff -Naur vdr-2.1.7.orig/Makefile vdr-2.1.7/Makefile
I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file))))
I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr.mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file))))))
I18Npot = $(PODIR)/vdr.pot
-@@ -193,7 +193,7 @@
+@@ -202,7 +202,7 @@
install-i18n: i18n
@mkdir -p $(DESTDIR)$(LOCDIR)
@@ -28,7 +27,7 @@ diff -Naur vdr-2.1.7.orig/Makefile vdr-2.1.7/Makefile
# The 'include' directory (for plugins):
-@@ -255,7 +255,7 @@
+@@ -264,7 +264,7 @@
# Install the files (note that 'install-pc' must be first!):
@@ -37,16 +36,13 @@ diff -Naur vdr-2.1.7.orig/Makefile vdr-2.1.7/Makefile
# VDR binary:
-@@ -267,12 +267,13 @@
+@@ -276,12 +276,10 @@
install-dirs:
@mkdir -p $(DESTDIR)$(VIDEODIR)
- @mkdir -p $(DESTDIR)$(CONFDIR)
- @mkdir -p $(DESTDIR)$(ARGSDIR)
- @mkdir -p $(DESTDIR)$(CACHEDIR)
-+# @mkdir -p $(DESTDIR)$(CONFDIR)
-+# @mkdir -p $(DESTDIR)$(ARGSDIR)
-+# @mkdir -p $(DESTDIR)$(CACHEDIR)
@mkdir -p $(DESTDIR)$(RESDIR)
install-conf:
@@ -54,14 +50,25 @@ diff -Naur vdr-2.1.7.orig/Makefile vdr-2.1.7/Makefile
@cp -pn *.conf $(DESTDIR)$(CONFDIR)
# Documentation:
-@@ -299,8 +300,11 @@
+@@ -289,9 +287,9 @@
+ install-doc:
+ @mkdir -p $(DESTDIR)$(MANDIR)/man1
+ @mkdir -p $(DESTDIR)$(MANDIR)/man5
+- @gzip -c vdr.1 > $(DESTDIR)$(MANDIR)/man1/vdr.1.gz
+- @gzip -c vdr.5 > $(DESTDIR)$(MANDIR)/man5/vdr.5.gz
+- @gzip -c svdrpsend.1 > $(DESTDIR)$(MANDIR)/man1/svdrpsend.1.gz
++ @cp vdr.1 $(DESTDIR)$(MANDIR)/man1/
++ @cp vdr.5 $(DESTDIR)$(MANDIR)/man5/
++ @cp svdrpsend.1 $(DESTDIR)$(MANDIR)/man1/
+
+ # Plugins:
+
+@@ -308,8 +306,9 @@
# Includes:
install-includes: include-dir
- @mkdir -p $(DESTDIR)$(INCDIR)
- @cp -pLR include/vdr include/libsi $(DESTDIR)$(INCDIR)
-+# @mkdir -p $(DESTDIR)$(INCDIR)
-+# @cp -pLR include/vdr include/libsi $(DESTDIR)$(INCDIR)
+ @mkdir -p $(DESTDIR)$(INCDIR)/vdr $(DESTDIR)$(INCDIR)/vdr/libsi
+ @cp -pLR include/vdr $(DESTDIR)$(INCDIR)
+ @cp -pLR include/libsi Make.config $(DESTDIR)$(INCDIR)/vdr
diff --git a/media-video/vdr/metadata.xml b/media-video/vdr/metadata.xml
index 8ebb4b08a51..246bd87c200 100644
--- a/media-video/vdr/metadata.xml
+++ b/media-video/vdr/metadata.xml
@@ -1,6 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
+ <maintainer type="person">
+ <email>martin.dummer@gmx.net</email>
+ <name>Martin Dummer</name>
+ </maintainer>
+ <maintainer type="project">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
+ </maintainer>
<maintainer type="project">
<email>vdr@gentoo.org</email>
<name>Gentoo VDR Project</name>
@@ -19,8 +27,8 @@
<flag name="menuorg">Enables support for the <pkg>media-plugins/vdr-menuorg</pkg></flag>
<flag name="menuselection">adds support for menu hotkeys of double digits</flag>
<flag name="naludump">Removes NALU fill data from h.264-Streams of TS files</flag>
- <flag name="permashift">permanent timeshift by recording live TV on hard disk, need plugin <pkg>media-plugins/vdr-permashift</pkg></flag>
- <flag name="permashift_v1">permanent timeshift by recording live TV on RAM, need plugin >=mediaplugins/vdr-permashift-1</flag>
+ <flag name="permashift">permanent timeshift by recording live TV into RAM, need plugin <pkg>media-plugins/vdr-permashift</pkg></flag>
+ <flag name="permashift_v1">permanent timeshift by recording live TV into RAM, need plugin <pkg>media-plugins/vdr-permashift</pkg></flag>
<flag name="pinplugin">Support for <pkg>media-plugins/vdr-pin</pkg></flag>
<flag name="resumereset">rreset resume of EOF</flag>
<flag name="rotor">Enable support for plugin vdr-rotor for dish-positioner.</flag>
diff --git a/media-video/vdr/vdr-2.2.0-r3.ebuild b/media-video/vdr/vdr-2.2.0-r3.ebuild
index 8dad304a1d8..dfbfd553e10 100644
--- a/media-video/vdr/vdr-2.2.0-r3.ebuild
+++ b/media-video/vdr/vdr-2.2.0-r3.ebuild
@@ -260,7 +260,7 @@ src_install() {
# directory
emake install \
VIDEODIR="/" \
- DESTDIR="${D%/}" install || die "emake install failed"
+ DESTDIR="${D}" install
keepdir "${PLUGIN_LIBDIR}"
@@ -283,7 +283,7 @@ src_install() {
doins "${FILESDIR}"/channel_alternative.conf
fi
- chown -R vdr:vdr "${D%/}/${CONF_DIR}"
+ chown -R vdr:vdr "${D}/${CONF_DIR}"
}
pkg_postinst() {
diff --git a/media-video/vdr/vdr-2.2.0-r3.ebuild b/media-video/vdr/vdr-2.2.0-r4.ebuild
similarity index 82%
copy from media-video/vdr/vdr-2.2.0-r3.ebuild
copy to media-video/vdr/vdr-2.2.0-r4.ebuild
index 8dad304a1d8..27229bab9fa 100644
--- a/media-video/vdr/vdr-2.2.0-r3.ebuild
+++ b/media-video/vdr/vdr-2.2.0-r4.ebuild
@@ -1,12 +1,12 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
-inherit eutils flag-o-matic toolchain-funcs
+inherit flag-o-matic toolchain-funcs
# Switches supported by extensions-patch
-EXT_PATCH_FLAGS="alternatechannel graphtft naludump permashift_v1 pinplugin
+EXT_PATCH_FLAGS="alternatechannel graphtft naludump permashift pinplugin
mainmenuhooks menuorg menuselection resumereset ttxtsubs"
# names of the use-flags
@@ -15,8 +15,6 @@ EXT_PATCH_FLAGS_RENAMED=""
# names ext-patch uses internally, here only used for maintainer checks
EXT_PATCH_FLAGS_RENAMED_EXT_NAME="bidi no_kbd sdnotify"
-IUSE="bidi debug +kbd html systemd vanilla ${EXT_PATCH_FLAGS} ${EXT_PATCH_FLAGS_RENAMED}"
-
MY_PV="${PV%_p*}"
MY_P="${PN}-${MY_PV}"
S="${WORKDIR}/${MY_P}"
@@ -26,34 +24,33 @@ EXT_P="extpng-${P}-gentoo-edition-v1"
DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
HOMEPAGE="http://www.tvdr.de/"
SRC_URI="ftp://ftp.tvdr.de/vdr/${MY_P}.tar.bz2
- https://dev.gentoo.org/~hd_brummy/distfiles/${EXT_P}.patch.bz2"
+ mirror://gentoo/${EXT_P}.patch.bz2"
-KEYWORDS="amd64 ~arm ~arm64 ~ppc x86"
-SLOT="0"
LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~x86"
+IUSE="bidi debug +kbd html systemd vanilla ${EXT_PATCH_FLAGS} ${EXT_PATCH_FLAGS_RENAMED}"
-COMMON_DEPEND="virtual/jpeg:*
+COMMON_DEPEND="
+ virtual/jpeg:*
sys-libs/libcap
>=media-libs/fontconfig-2.4.2
>=media-libs/freetype-2"
-
DEPEND="${COMMON_DEPEND}
- >=virtual/linuxtv-dvb-headers-5.3
- sys-devel/gettext"
-
+ >=virtual/linuxtv-dvb-headers-5.3"
RDEPEND="${COMMON_DEPEND}
dev-lang/perl
>=media-tv/gentoo-vdr-scripts-2.7
media-fonts/corefonts
bidi? ( dev-libs/fribidi )
systemd? ( sys-apps/systemd )"
+BDEPEND="sys-devel/gettext"
-CONF_DIR=/etc/vdr
-CAP_FILE=${S}/capabilities.sh
+CONF_DIR="/etc/vdr"
+CAP_FILE="${S}/capabilities.sh"
CAPS="# Capabilities of the vdr-executable for use by startscript etc."
pkg_setup() {
-
use debug && append-flags -g
PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
@@ -71,12 +68,12 @@ add_cap() {
enable_patch() {
local arg ARG_UPPER
for arg; do
- ARG_UPPER=$(echo $arg|tr '[:lower:]' '[:upper:]')
- echo "${ARG_UPPER} = 1" >> Make.config
+ ARG_UPPER=$(echo $arg | tr '[:lower:]' '[:upper:]')
+ echo "${ARG_UPPER} = 1" >> Make.config || die "cannot write to Make.config"
# codesnippet to bring the extpng defines into the vdr.pc CXXFLAGS CFLAGS
- echo "-DUSE_${ARG_UPPER}" >> "${T}"/defines.tmp
- cat "${T}"/defines.tmp | tr \\\012 ' ' > "${T}"/defines.IUSE
+ echo "-DUSE_${ARG_UPPER}" >> "${T}"/defines.tmp || die "cannot write to defines.tmp"
+ cat "${T}"/defines.tmp | tr \\\012 ' ' > "${T}"/defines.IUSE || die "cannot write to defines.tmp"
export DEFINES_IUSE=$( cat ${T}/defines.IUSE )
done
}
@@ -86,7 +83,7 @@ extensions_add_make_conf()
# copy all ifdef for extensions-patch to Make.config
sed -e '1,/need to touch the following:/d' \
-e '/need to touch the following/,/^$/d' \
- Make.config.template >> Make.config
+ Make.config.template >> Make.config || die "cannot write to Make.config"
}
extensions_all_defines() {
@@ -94,7 +91,7 @@ extensions_all_defines() {
sed -e '/^#\?[A-Z].*= 1/!d' -e 's/^#\?//' -e 's/ .*//' \
Make.config.template \
| sort \
- | tr '[:upper:]' '[:lower:]'
+ | tr '[:upper:]' '[:lower:]' || die "error in function extensions_all_defines"
}
lang_po() {
@@ -111,16 +108,16 @@ src_configure() {
}
src_prepare() {
- # apply maintainace-patches
+ # apply maintenance-patches
ebegin "Changing paths for gentoo"
- local DVBDIR=/usr/include
+ local DVBDIR="/usr/include"
local i
for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
[[ -d ${i} ]] || continue
if [[ -f ${i}/linux/dvb/dmx.h ]]; then
einfo "Found DVB header files in ${i}"
- DVBDIR=${i}
+ DVBDIR="${i}"
break
fi
done
@@ -136,7 +133,7 @@ src_prepare() {
die "DVB headers too old"
fi
- cat > Make.config <<-EOT
+ cat > Make.config <<-EOT || die "cannot write to Make.config"
#
# Generated by ebuild ${PF}
#
@@ -168,6 +165,7 @@ src_prepare() {
# Now apply extensions patch
eapply "${WORKDIR}/${EXT_P}.patch"
+ sed -e 's/PERMASHIFT_V1/PERMASHIFT/g' -i "${S}"/*.[ch] "${S}"/Make.config* || die "sed failed"
# This allows us to start even if some plugin does not exist
# or is not loadable.
@@ -180,10 +178,10 @@ src_prepare() {
# (or have them already hard enabled)
local IGNORE_PATCHES="pluginmissing"
- extensions_all_defines > "${T}"/new.IUSE
+ extensions_all_defines > "${T}"/new.IUSE || die "cannot write to new.IUSE"
echo $EXT_PATCH_FLAGS $EXT_PATCH_FLAGS_RENAMED_EXT_NAME \
$IGNORE_PATCHES | \
- tr ' ' '\n' |sort > "${T}"/old.IUSE
+ tr ' ' '\n' |sort > "${T}"/old.IUSE || die "cannot write to old.IUSE"
local DIFFS=$(diff -u "${T}"/old.IUSE "${T}"/new.IUSE|grep '^[+-][^+-]')
if [[ -z ${DIFFS} ]]; then
einfo "EXT_PATCH_FLAGS are up to date."
@@ -208,7 +206,7 @@ src_prepare() {
# add defined use-flags compile options to vdr.pc
sed -e "s:\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR):\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR) \$(DEFINES_IUSE):" \
- -i Makefile
+ -i Makefile || die "sed fails on Makefile"
ebegin "Make depend"
emake .dependencies >/dev/null
@@ -226,7 +224,7 @@ src_prepare() {
sed -e "s:ifndef NO_KBD:ifeq (\$(USE_KBD),1):" \
-e "s:ifdef BIDI:ifeq (\$(BIDI),1):" \
-e "s:ifdef SDNOTIFY:ifeq (\$(SDNOTIFY),1):" \
- -i "${S}"/Makefile
+ -i "${S}"/Makefile || die "sed fails on Makefile"
eapply_user
@@ -260,7 +258,7 @@ src_install() {
# directory
emake install \
VIDEODIR="/" \
- DESTDIR="${D%/}" install || die "emake install failed"
+ DESTDIR="${ED}" install
keepdir "${PLUGIN_LIBDIR}"
@@ -283,7 +281,7 @@ src_install() {
doins "${FILESDIR}"/channel_alternative.conf
fi
- chown -R vdr:vdr "${D%/}/${CONF_DIR}"
+ chown -R vdr:vdr "${ED}/${CONF_DIR}" || die "chown failed"
}
pkg_postinst() {
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2019-12-25 18:26 Jörg Bornkessel
0 siblings, 0 replies; 15+ messages in thread
From: Jörg Bornkessel @ 2019-12-25 18:26 UTC (permalink / raw
To: gentoo-commits
commit: 2b8297d91439c9eebacef0ed85eaa45908b29464
Author: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
AuthorDate: Wed Dec 25 18:25:29 2019 +0000
Commit: Jörg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
CommitDate: Wed Dec 25 18:25:29 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2b8297d9
media-video/vdr: version bump to vdr-2.4.1
this version is a major update to
vdr-2.4.1
Signed-off-by: Martin Dummer <martin.dummer <AT> gmx.net>
Package-Manager: Portage-2.3.82, Repoman-2.3.18
Signed-off-by: Joerg Bornkessel <hd_brummy <AT> gentoo.org>
media-video/vdr/Manifest | 6 +
media-video/vdr/files/vdr-2.2.0-jpeg-9c.patch | 2 +
media-video/vdr/files/vdr-2.4.1_gentoo.patch | 66 +++++++
.../vdr/files/vdr-2.4.1_makefile-variables.patch | 40 ++++
media-video/vdr/files/vdr-2.4_remove_plugins.patch | 25 +++
media-video/vdr/metadata.xml | 2 +
media-video/vdr/vdr-2.4.1.ebuild | 201 +++++++++++++++++++++
7 files changed, 342 insertions(+)
diff --git a/media-video/vdr/Manifest b/media-video/vdr/Manifest
index dac0f69a4e8..645fd58bd16 100644
--- a/media-video/vdr/Manifest
+++ b/media-video/vdr/Manifest
@@ -1,2 +1,8 @@
DIST extpng-vdr-2.2.0-gentoo-edition-v1.patch.bz2 34664 BLAKE2B 81b68ebe0ef4588c3676f0b7a2c766d8d4d4f754a987b3be5868f3c6eff9158d4cea8e492ca81df535e637dbdc5baff638d1fafb4163e9d9a2d0125aba17e2e1 SHA512 16d6fbb8201f003dfe653b6a49424b794d7e697e27ad6f2383dbe17b76712ea5a3da88a676900b84d75ff7425bf3eb9084d60a89a4598758f482dc1f013f7b3e
+DIST vdr-2.1.5-naludump-0.1.diff 21548 BLAKE2B f193d982d072bbba2261d7dabd82e27795b2e4d8d18ae4486d8c559e7325b87f5902def7bb313e98585331144af62597f6f025f44ca142187e724516bc32c175 SHA512 d9188d5bfcf0588c22dc526fc1082253a1b505b322ccfbe676b8b2c12d4471af7b605924bcea85e879c9606d5e2cecdf6a6e8819cd9b8d877e5bb9f62b91251f
DIST vdr-2.2.0.tar.bz2 922708 BLAKE2B 975e07d6d4c5bd13ee92be5d6a1826d6404b0c59e20fa2e30689b185a61e02d54782ad528e6a4f15e0d36806b30bcf48aa336d63adb3604e78056ff318e0fd2c SHA512 183f58133915c6c0fe8ec2b88becbcb2a36418210e6dcf7931053d3771d727c3581593f9eb5c9693abf39e22e728f7b41c42079cd704610c3636ec05134ea93d
+DIST vdr-2.4.0-ttxtsubs.patch.bz2 16721 BLAKE2B d5c3da713cd82ed8c3baccd1336d283404ebf1099116e76776c26a41ac193aa88bcb5bc2aaa8409a6d40e61c122bbc8ac0d67cb6ff8f83b0dbaea392101643b9 SHA512 99f2cab268d3f6af11607333a35583e5802f90636712e0429eb89eb66ccea7b1fb16a0d3ed2ff266e6f87c338bf77f97028a372eef5e6116b27220a5670a6d31
+DIST vdr-2.4.1.tar.bz2 940623 BLAKE2B 6fa7858e1c0fc25d3332d20347b30515276fc2b54905f32109dfa7f59e4e0c8a83687be405fac063a673c89d77e191f62162b1bd0ed6ee179d32a27f73076fb3 SHA512 b851ebf626de1a6aea11ee9c0cd87d78ebebdc34128925d2027a7030db1262064edb8818566a87ce22d37a9bd2b4f0b4ff1aad8dd251061d9ff972ffe0cf022d
+DIST vdr-2.4.1_mainmenuhook-1.0.1.patch.bz2 1463 BLAKE2B 2be3597a273a92d02be0d072e3d74b39275cbbe17d22e570f416d42c46b53f43209498e569142a2cc357e5f7176d2454cb2a86d0822b29cca913eab2ae9cc27f SHA512 9d3eb501fa06ff5b03361ef65c8ddeeba5f37493cc0edc2d4f54e200e48e17607957fa95bd1540f028bc9a98ad6f42b4d38cf79e9ce971de36bed30def108759
+DIST vdr-2.4.1_pinplugin.patch.bz2 8641 BLAKE2B 339bb23ed0f505087bdbbefb192824d5def37bb00c4d5dc300f545c7951f11504115d058c157d1964f5f32e483e668675e13254465b5acce76cfdcf07faae216 SHA512 f402fa51314ad6c34439f71b7cb81e1ca51e0fa3b120a1fdaee119c2dd1b13174db2e666bf5e6204aa28e4acef8f6bd6e3ab8324793c3484eafb16dc8cf808d5
+DIST vdr-menuorg-2.3.x.diff 8852 BLAKE2B 19b98d51a69f52ecda5500f51ef1741a8397953b20c490055eab0393da5f56ff9598c3e1e8ed8b915f5877e08deeb9ba7a9ef8d9356ad3a1fa12e3778869174a SHA512 7b41c3a529858a4953a57f21619ea01864e140cc1755ee0b03caf1c4de41e80c3f805653502bc8d39d02a4dfcddf720acd4a8c8bd91f4871eef31d86e8e915c0
diff --git a/media-video/vdr/files/vdr-2.2.0-jpeg-9c.patch b/media-video/vdr/files/vdr-2.2.0-jpeg-9c.patch
index b67c94d7c57..8ae498a28fd 100644
--- a/media-video/vdr/files/vdr-2.2.0-jpeg-9c.patch
+++ b/media-video/vdr/files/vdr-2.2.0-jpeg-9c.patch
@@ -1,5 +1,7 @@
https://bugs.gentoo.org/667934
+Signed-off-by: Martin Dummer <martin.dummer@gmx.net>
+Reviewed-by: Joerg Bornkessel <hd_brummy@gentoo.org>
--- a/tools.c
+++ b/tools.c
@@ -1221,15 +1221,15 @@
diff --git a/media-video/vdr/files/vdr-2.4.1_gentoo.patch b/media-video/vdr/files/vdr-2.4.1_gentoo.patch
new file mode 100644
index 00000000000..71aca7f5f96
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.4.1_gentoo.patch
@@ -0,0 +1,66 @@
+this patch will disable some handling in the core Makefile
+as we use for Linux FHS a different handling in gentoo
+demoplugins from core vdr install disabled
+support from Linguas variable
+
+Signed-off-by: Martin Dummer <martin.dummer@gmx.net>
+Reviewed-by: Joerg Bornkessel <hd_brummy@gentoo.org>
+--- a/Makefile
++++ b/Makefile
+@@ -182,7 +182,7 @@
+
+ PODIR = po
+ LOCALEDIR = locale
+-I18Npo = $(wildcard $(PODIR)/*.po)
++I18Npo = $(foreach dir,$(LINGUAS),$(wildcard $(PODIR)/$(dir)*.po))
+ I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file))))
+ I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr.mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file))))))
+ I18Npot = $(PODIR)/vdr.pot
+@@ -209,7 +209,7 @@
+
+ install-i18n: i18n
+ @mkdir -p $(DESTDIR)$(LOCDIR)
+- cp -r $(LOCALEDIR)/* $(DESTDIR)$(LOCDIR)
++ @(cd $(LOCALEDIR); for linguas in $(LINGUAS); do [ "$$linguas" = "en" ] && continue; cp -r --parents $$linguas* $(DESTDIR)$(LOCDIR); done)
+
+ # The 'include' directory (for plugins):
+
+@@ -283,12 +283,11 @@
+
+ install-dirs:
+ @mkdir -p $(DESTDIR)$(VIDEODIR)
+- @mkdir -p $(DESTDIR)$(CONFDIR)
+ @mkdir -p $(DESTDIR)$(ARGSDIR)
+- @mkdir -p $(DESTDIR)$(CACHEDIR)
+ @mkdir -p $(DESTDIR)$(RESDIR)
+
+ install-conf: install-dirs
++ @mkdir -p $(DESTDIR)$(CONFDIR)
+ @cp -pn *.conf $(DESTDIR)$(CONFDIR)
+
+ # Documentation:
+@@ -296,9 +295,9 @@
+ install-doc:
+ @mkdir -p $(DESTDIR)$(MANDIR)/man1
+ @mkdir -p $(DESTDIR)$(MANDIR)/man5
+- @gzip -c vdr.1 > $(DESTDIR)$(MANDIR)/man1/vdr.1.gz
+- @gzip -c vdr.5 > $(DESTDIR)$(MANDIR)/man5/vdr.5.gz
+- @gzip -c svdrpsend.1 > $(DESTDIR)$(MANDIR)/man1/svdrpsend.1.gz
++ @cp vdr.1 $(DESTDIR)$(MANDIR)/man1/
++ @cp vdr.5 $(DESTDIR)$(MANDIR)/man5/
++ @cp svdrpsend.1 $(DESTDIR)$(MANDIR)/man1/
+
+ # Plugins:
+
+@@ -315,8 +314,9 @@
+ # Includes:
+
+ install-includes: include-dir
+- @mkdir -p $(DESTDIR)$(INCDIR)
+- @cp -pLR include/vdr include/libsi $(DESTDIR)$(INCDIR)
++ @mkdir -p $(DESTDIR)$(INCDIR)/vdr $(DESTDIR)$(INCDIR)/vdr/libsi
++ @cp -pLR include/vdr $(DESTDIR)$(INCDIR)
++ @cp -pLR include/libsi Make.config $(DESTDIR)$(INCDIR)/vdr
+
+ # pkg-config file:
+
diff --git a/media-video/vdr/files/vdr-2.4.1_makefile-variables.patch b/media-video/vdr/files/vdr-2.4.1_makefile-variables.patch
new file mode 100644
index 00000000000..30cd39528f9
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.4.1_makefile-variables.patch
@@ -0,0 +1,40 @@
+we change some variables in the Makefile
+for a better handling in gentoo ebuild
+
+Signed-off-by: Joerg Bornkessel <hd_brummy@gentoo.org> ( 22 Dec 2019 )
+diff -Naur vdr-2.4.1.orig/Makefile vdr-2.4.1/Makefile
+--- vdr-2.4.1.orig/Makefile 2019-12-22 00:51:31.000000000 +0100
++++ vdr-2.4.1/Makefile 2019-12-22 00:53:34.000000000 +0100
+@@ -54,7 +54,7 @@
+
+ # Output control
+
+-ifdef VERBOSE
++ifeq ($(VERBOSE),1)
+ Q =
+ else
+ Q = @
+@@ -89,7 +89,7 @@
+ ifdef HDRDIR
+ HDRDIR := -I$(HDRDIR)
+ endif
+-ifndef NO_KBD
++ifeq ($(USE_KBD),1)
+ DEFINES += -DREMOTE_KBD
+ endif
+ ifdef REMOTE
+@@ -98,12 +98,12 @@
+ ifdef VDR_USER
+ DEFINES += -DVDR_USER=\"$(VDR_USER)\"
+ endif
+-ifdef BIDI
++ifeq ($(BIDI),1)
+ INCLUDES += $(shell pkg-config --cflags fribidi)
+ DEFINES += -DBIDI
+ LIBS += $(shell pkg-config --libs fribidi)
+ endif
+-ifdef SDNOTIFY
++ifeq ($(SDNOTIFY),1)
+ INCLUDES += $(shell pkg-config --silence-errors --cflags libsystemd-daemon || pkg-config --cflags libsystemd)
+ DEFINES += -DSDNOTIFY
+ LIBS += $(shell pkg-config --silence-errors --libs libsystemd-daemon || pkg-config --libs libsystemd)
diff --git a/media-video/vdr/files/vdr-2.4_remove_plugins.patch b/media-video/vdr/files/vdr-2.4_remove_plugins.patch
new file mode 100644
index 00000000000..56997968d60
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.4_remove_plugins.patch
@@ -0,0 +1,25 @@
+we do not install any plugins from core vdr
+
+Signed-off-by: Martin Dummer <martin.dummer@gmx.net>
+Reviewed-by: Joerg Bornkessel <hd_brummy@gentoo.org>
+diff -Naur vdr-2.4.0.orig/Makefile vdr-2.4.0/Makefile
+--- vdr-2.4.0.orig/Makefile 2017-05-29 10:48:42.000000000 +0200
++++ vdr-2.4.0/Makefile 2019-03-14 12:08:56.857495048 +0100
+@@ -125,7 +125,7 @@
+ VDRVERSION = $(shell sed -ne '/define VDRVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h)
+ APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h)
+
+-all: vdr i18n plugins
++all: vdr i18n
+
+ # Implicit rules:
+
+@@ -271,7 +271,7 @@
+
+ # Install the files (note that 'install-pc' must be first!):
+
+-install: install-pc install-bin install-conf install-doc install-plugins install-i18n install-includes
++install: install-pc install-bin install-conf install-doc install-i18n install-includes
+
+ # VDR binary:
+
diff --git a/media-video/vdr/metadata.xml b/media-video/vdr/metadata.xml
index acf02374158..eea6df4fdb2 100644
--- a/media-video/vdr/metadata.xml
+++ b/media-video/vdr/metadata.xml
@@ -20,6 +20,7 @@
<use>
<flag name="alternatechannel">Use alternate channel on record</flag>
<flag name="bidi">fribidi support, for languages, written from right to left</flag>
+ <flag name="demoplugins">Install demo and example plugins coming with vanilla vdr</flag>
<flag name="graphtft">support for vdr-graphtft plugin up from version 0.1.7</flag>
<flag name="html">Install HTML documentation</flag>
<flag name="keyboard">enable keyboard support as remote device</flag>
@@ -31,5 +32,6 @@
<flag name="pinplugin">Support for <pkg>media-plugins/vdr-pin</pkg></flag>
<flag name="resumereset">rreset resume of EOF</flag>
<flag name="ttxtsubs">support for <pkg>media-plugins/vdr-ttxtsubs</pkg></flag>
+ <flag name="verbose">enable full output on compile</flag>
</use>
</pkgmetadata>
diff --git a/media-video/vdr/vdr-2.4.1.ebuild b/media-video/vdr/vdr-2.4.1.ebuild
new file mode 100644
index 00000000000..d2f923913af
--- /dev/null
+++ b/media-video/vdr/vdr-2.4.1.ebuild
@@ -0,0 +1,201 @@
+# Copyright 2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit flag-o-matic multilib toolchain-funcs
+
+DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
+HOMEPAGE="http://www.tvdr.de/"
+SRC_URI="ftp://ftp.tvdr.de/vdr/${P}.tar.bz2
+ mainmenuhooks? ( http://vdr.websitec.de/download/${PN}/${P}/${P}_mainmenuhook-1.0.1.patch.bz2 )
+ menuorg? ( https://projects.vdr-developer.org/projects/plg-menuorg/repository/revisions/master/raw/vdr-patch/vdr-menuorg-2.3.x.diff )
+ naludump? ( http://www.udo-richter.de/vdr/files/vdr-2.1.5-naludump-0.1.diff )
+ pinplugin? ( http://vdr.websitec.de/download/${PN}/${P}/${P}_pinplugin.patch.bz2 )
+ ttxtsubs? ( http://vdr.websitec.de/download/${PN}/${P}/${PN}-2.4.0-ttxtsubs.patch.bz2 )"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~x86"
+IUSE="bidi debug demoplugins html keyboard mainmenuhooks menuorg naludump pinplugin systemd ttxtsubs verbose"
+
+COMMON_DEPEND="
+ virtual/jpeg:*
+ sys-libs/libcap
+ >=media-libs/fontconfig-2.4.2
+ >=media-libs/freetype-2"
+DEPEND="${COMMON_DEPEND}
+ >=virtual/linuxtv-dvb-headers-5.3"
+RDEPEND="${COMMON_DEPEND}
+ dev-lang/perl
+ media-tv/gentoo-vdr-scripts
+ media-fonts/corefonts
+ bidi? ( dev-libs/fribidi )
+ systemd? ( sys-apps/systemd )"
+BDEPEND="sys-devel/gettext"
+
+REQUIRED_USE="pinplugin? ( !mainmenuhooks )"
+
+CONF_DIR="/etc/vdr"
+CAP_FILE="${S}/capabilities.sh"
+CAPS="# Capabilities of the vdr-executable for use by startscript etc."
+
+pkg_setup() {
+ use debug && append-flags -g
+
+ PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
+
+ tc-export CC CXX AR
+}
+
+add_cap() {
+ local arg
+ for arg; do
+ CAPS="${CAPS}\n${arg}=1"
+ done
+}
+
+lang_po() {
+ LING_PO=$( ls ${S}/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
+}
+
+src_configure() {
+ # support languages, written from right to left
+ export "BIDI=$(usex bidi 1 0)"
+ # systemd notification support
+ export "SDNOTIFY=$(usex systemd 1 0)"
+ # with/without keyboard
+ export "USE_KBD=$(usex keyboard 1 0)"
+ # detailed compile output for debug
+ export "VERBOSE=$(usex verbose 1 0)"
+}
+
+src_prepare() {
+ # apply maintenance-patches
+ ebegin "Changing paths for gentoo"
+
+ local DVBDIR=/usr/include
+ local i
+ for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
+ [[ -d ${i} ]] || continue
+ if [[ -f ${i}/linux/dvb/dmx.h ]]; then
+ einfo "Found DVB header files in ${i}"
+ DVBDIR=${i}
+ break
+ fi
+ done
+
+ # checking for s2api headers
+ local api_version
+ api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+ api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+
+ if [[ ${api_version:-0} -lt 5*3 ]]; then
+ eerror "DVB header files do not contain s2api support or too old for ${P}"
+ eerror "You cannot compile VDR against old dvb-header"
+ die "DVB headers too old"
+ fi
+
+ cat > Make.config <<-EOT || die "cannot write to Make.config"
+ #
+ # Generated by ebuild ${PF}
+ #
+ PREFIX = /usr
+ DVBDIR = ${DVBDIR}
+ PLUGINLIBDIR = ${PLUGIN_LIBDIR}
+ CONFDIR = ${CONF_DIR}
+ ARGSDIR = \$(CONFDIR)/conf.d
+ VIDEODIR = /var/vdr/video
+ LOCDIR = \$(PREFIX)/share/locale
+ INCDIR = \$(PREFIX)/include
+
+ DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
+ INCLUDES += -I\$(DVBDIR)
+
+ # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
+ # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
+ LIBDIR = ${PLUGIN_LIBDIR}
+ PCDIR = /usr/$(get_libdir)/pkgconfig
+
+ EOT
+ eend 0
+
+ eapply "${FILESDIR}/${P}_gentoo.patch"
+ eapply "${FILESDIR}/vdr-2.2.0-jpeg-9c.patch"
+ use demoplugins || eapply "${FILESDIR}/vdr-2.4_remove_plugins.patch"
+ eapply "${FILESDIR}/${P}_makefile-variables.patch"
+
+ # works
+ use naludump && eapply "${DISTDIR}/${PN}-2.1.5-naludump-0.1.diff"
+# # request to upstream for new patch
+# use permashift && eapply "${DISTDIR}/vdr-2.3-patch-for-permashift.diff"
+ #pinplugin works
+ use pinplugin && eapply "${WORKDIR}/${P}_pinplugin.patch"
+ # ttxtsubs works
+ use ttxtsubs && eapply "${WORKDIR}/${PN}-2.4.0-ttxtsubs.patch"
+ # menuorg works
+ use menuorg && eapply "${DISTDIR}/vdr-menuorg-2.3.x.diff"
+ # mainmenuhooks, works
+ use mainmenuhooks && eapply "${WORKDIR}/${P}_mainmenuhook-1.0.1.patch"
+
+ add_cap CAP_UTF8 \
+ CAP_IRCTRL_RUNTIME_PARAM \
+ CAP_VFAT_RUNTIME_PARAM \
+ CAP_CHUID \
+ CAP_SHUTDOWN_AUTO_RETRY
+
+ echo -e ${CAPS} > "${CAP_FILE}" || die "cannot write to CAP_FILE"
+
+ # LINGUAS support
+ einfo "\n \t VDR supports the LINGUAS values"
+
+ lang_po
+
+ einfo "\t Please set one of this values in your sytem make.conf"
+ einfo "\t LINGUAS=\"${LING_PO}\"\n"
+
+ if [[ -z ${LINGUAS} ]]; then
+ einfo "\n \t No values in LINGUAS="
+ einfo "\t You will get only english text on OSD \n"
+ fi
+
+ strip-linguas ${LING_PO} en
+
+ default
+}
+
+src_install() {
+ # trick the makefile to not create a VIDEODIR by supplying it with an
+ # existing directory
+ emake VIDEODIR="/" DESTDIR="${ED}" install
+
+ keepdir "${PLUGIN_LIBDIR}"
+
+ # backup for plugins they don't be able to create this dir
+ keepdir "${CONF_DIR}/plugins"
+
+ if use html; then
+ local HTML_DOCS=( *.html )
+ fi
+ local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS UPDATE-2* )
+ einstalldocs
+
+ insinto /usr/share/vdr
+ doins "${CAP_FILE}"
+
+ fowners vdr:vdr "${CONF_DIR}" -R
+}
+
+pkg_postinst() {
+ elog "Please read the /usr/share/doc/${PF}/UPDATE-2.4"
+ elog "for major changes in this version\n"
+
+ elog "It is a good idea to run vdrplugin-rebuild now.\n"
+
+ elog "To get nice symbols in OSD we recommend to install"
+ elog "\t1. emerge media-fonts/vdrsymbols-ttf"
+ elog "\t2. select font VDRSymbolsSans in Setup\n"
+
+ elog "To get an idea how to proceed now, have a look at our vdr-guide:"
+ elog "\thttps://wiki.gentoo.org/wiki/VDR"
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2020-03-02 20:05 Jörg Bornkessel
0 siblings, 0 replies; 15+ messages in thread
From: Jörg Bornkessel @ 2020-03-02 20:05 UTC (permalink / raw
To: gentoo-commits
commit: 1a77777812a5edfdb1f6a9676fc035fe91dc1032
Author: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
AuthorDate: Mon Mar 2 20:05:15 2020 +0000
Commit: Jörg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
CommitDate: Mon Mar 2 20:05:15 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1a777778
media-video/vdr: segfault in ttxtsub patch uses fixed
reported by several users
in IRC #gentoo-vdr
vdr-portal.de
Package-Manager: Portage-2.3.90, Repoman-2.3.20
Signed-off-by: Joerg Bornkessel <hd_brummy <AT> gentoo.org>
.../vdr/files/vdr-2.4.1_ttxtsubs_segfault.patch | 49 +++++
media-video/vdr/vdr-2.4.1-r2.ebuild | 198 +++++++++++++++++++++
2 files changed, 247 insertions(+)
diff --git a/media-video/vdr/files/vdr-2.4.1_ttxtsubs_segfault.patch b/media-video/vdr/files/vdr-2.4.1_ttxtsubs_segfault.patch
new file mode 100644
index 00000000000..deba0197961
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.4.1_ttxtsubs_segfault.patch
@@ -0,0 +1,49 @@
+fixing segfault, reported on IRC #gentoo-vdr & vdr-portal.de
+https://www.vdr-portal.de/forum/index.php?thread/132017-videotextuntertitel-f%C3%BCr-vdr-2-4-0/&postID=1306478#post1306478
+
+Signed-Off-By: Joerg Bornkessel <hd_brummy@gentoo.org> ( 2020 Mar 02 )
+diff -Naur vdr-2.4.1.orig/channels.c vdr-2.4.1/channels.c
+--- vdr-2.4.1.orig/channels.c 2020-03-02 19:52:51.052496538 +0100
++++ vdr-2.4.1/channels.c 2020-03-02 19:54:05.096496538 +0100
+@@ -429,7 +429,7 @@
+ return Modified;
+ }
+
+-void cChannel::SetTeletextSubtitlePages(tTeletextSubtitlePage pages[], int numberOfPages)
++bool cChannel::SetTeletextSubtitlePages(tTeletextSubtitlePage pages[], int numberOfPages)
+ {
+ int mod = CHANNELMOD_NONE;
+ LOCK_CHANNELS_WRITE;
+@@ -447,7 +447,7 @@
+ totalTtxtSubtitlePages++;
+ }
+ modification |= mod;
+- Channels->SetModified();
++ return true;
+ }
+
+ void cChannel::SetSeen(void)
+diff -Naur vdr-2.4.1.orig/channels.h vdr-2.4.1/channels.h
+--- vdr-2.4.1.orig/channels.h 2020-03-02 19:52:51.052496538 +0100
++++ vdr-2.4.1/channels.h 2020-03-02 19:54:31.745496538 +0100
+@@ -212,7 +212,7 @@
+ bool SetName(const char *Name, const char *ShortName, const char *Provider);
+ bool SetPortalName(const char *PortalName);
+ bool SetPids(int Vpid, int Ppid, int Vtype, int *Apids, int *Atypes, char ALangs[][MAXLANGCODE2], int *Dpids, int *Dtypes, char DLangs[][MAXLANGCODE2], int *Spids, char SLangs[][MAXLANGCODE2], int Tpid);
+- void SetTeletextSubtitlePages(tTeletextSubtitlePage pages[], int numberOfPages);
++ bool SetTeletextSubtitlePages(tTeletextSubtitlePage pages[], int numberOfPages);
+ bool SetCaIds(const int *CaIds); // list must be zero-terminated
+ bool SetCaDescriptors(int Level);
+ bool SetLinkChannels(cLinkChannels *LinkChannels);
+diff -Naur vdr-2.4.1.orig/pat.c vdr-2.4.1/pat.c
+--- vdr-2.4.1.orig/pat.c 2020-03-02 19:52:51.053496538 +0100
++++ vdr-2.4.1/pat.c 2020-03-02 19:55:40.819496538 +0100
+@@ -649,7 +649,7 @@
+ if (manualPageNumber)
+ TeletextSubtitlePages[NumTPages++] = tTeletextSubtitlePage(manualPageNumber);
+ }
+- Channel->SetTeletextSubtitlePages(TeletextSubtitlePages, NumTPages);
++ ChannelsModified |= Channel->SetTeletextSubtitlePages(TeletextSubtitlePages, NumTPages);
+ ChannelsModified |= Channel->SetCaIds(CaDescriptors->CaIds());
+ ChannelsModified |= Channel->SetSubtitlingDescriptors(SubtitlingTypes, CompositionPageIds, AncillaryPageIds);
+ }
diff --git a/media-video/vdr/vdr-2.4.1-r2.ebuild b/media-video/vdr/vdr-2.4.1-r2.ebuild
new file mode 100644
index 00000000000..53df602b471
--- /dev/null
+++ b/media-video/vdr/vdr-2.4.1-r2.ebuild
@@ -0,0 +1,198 @@
+# Copyright 2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit eutils flag-o-matic multilib toolchain-funcs
+
+DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
+HOMEPAGE="http://www.tvdr.de/"
+SRC_URI="ftp://ftp.tvdr.de/vdr/${P}.tar.bz2
+ mainmenuhooks? ( http://vdr.websitec.de/download/${PN}/${P}/${P}_mainmenuhook-1.0.1.patch.bz2 )
+ menuorg? ( https://projects.vdr-developer.org/projects/plg-menuorg/repository/revisions/master/raw/vdr-patch/vdr-menuorg-2.3.x.diff )
+ naludump? ( http://www.udo-richter.de/vdr/files/vdr-2.1.5-naludump-0.1.diff )
+ pinplugin? ( http://vdr.websitec.de/download/${PN}/${P}/${P}_pinplugin.patch.bz2 )
+ ttxtsubs? ( http://vdr.websitec.de/download/${PN}/${P}/${PN}-2.4.0-ttxtsubs.patch.bz2 )"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~x86"
+IUSE="bidi debug demoplugins html keyboard mainmenuhooks menuorg naludump pinplugin systemd ttxtsubs verbose"
+
+COMMON_DEPEND="
+ virtual/jpeg:*
+ sys-libs/libcap
+ >=media-libs/fontconfig-2.4.2
+ >=media-libs/freetype-2"
+DEPEND="${COMMON_DEPEND}
+ >=virtual/linuxtv-dvb-headers-5.3"
+RDEPEND="${COMMON_DEPEND}
+ dev-lang/perl
+ media-tv/gentoo-vdr-scripts
+ media-fonts/corefonts
+ bidi? ( dev-libs/fribidi )
+ systemd? ( sys-apps/systemd )"
+BDEPEND="sys-devel/gettext"
+
+REQUIRED_USE="pinplugin? ( !mainmenuhooks )"
+
+CONF_DIR="/etc/vdr"
+CAP_FILE="${S}/capabilities.sh"
+CAPS="# Capabilities of the vdr-executable for use by startscript etc."
+
+pkg_setup() {
+ use debug && append-flags -g
+
+ PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
+
+ tc-export CC CXX AR
+}
+
+add_cap() {
+ local arg
+ for arg; do
+ CAPS="${CAPS}\n${arg}=1"
+ done
+}
+
+lang_po() {
+ LING_PO=$( ls ${S}/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
+}
+
+src_configure() {
+ # support languages, written from right to left
+ export "BIDI=$(usex bidi 1 0)"
+ # systemd notification support
+ export "SDNOTIFY=$(usex systemd 1 0)"
+ # with/without keyboard
+ export "USE_KBD=$(usex keyboard 1 0)"
+ # detailed compile output for debug
+ export "VERBOSE=$(usex verbose 1 0)"
+}
+
+src_prepare() {
+ # apply maintenance-patches
+ ebegin "Changing paths for gentoo"
+
+ local DVBDIR=/usr/include
+ local i
+ for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
+ [[ -d ${i} ]] || continue
+ if [[ -f ${i}/linux/dvb/dmx.h ]]; then
+ einfo "Found DVB header files in ${i}"
+ DVBDIR=${i}
+ break
+ fi
+ done
+
+ # checking for s2api headers
+ local api_version
+ api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+ api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+
+ if [[ ${api_version:-0} -lt 5*3 ]]; then
+ eerror "DVB header files do not contain s2api support or too old for ${P}"
+ eerror "You cannot compile VDR against old dvb-header"
+ die "DVB headers too old"
+ fi
+
+ cat > Make.config <<-EOT || die "cannot write to Make.config"
+ #
+ # Generated by ebuild ${PF}
+ #
+ PREFIX = /usr
+ DVBDIR = ${DVBDIR}
+ PLUGINLIBDIR = ${PLUGIN_LIBDIR}
+ CONFDIR = ${CONF_DIR}
+ ARGSDIR = \$(CONFDIR)/conf.d
+ VIDEODIR = /var/vdr/video
+ LOCDIR = \$(PREFIX)/share/locale
+ INCDIR = \$(PREFIX)/include
+
+ DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
+ INCLUDES += -I\$(DVBDIR)
+
+ # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
+ # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
+ LIBDIR = ${PLUGIN_LIBDIR}
+ PCDIR = /usr/$(get_libdir)/pkgconfig
+
+ EOT
+ eend 0
+
+ eapply "${FILESDIR}/${P}_gentoo.patch"
+ eapply "${FILESDIR}/vdr-2.2.0-jpeg-9c.patch"
+ use demoplugins || eapply "${FILESDIR}/vdr-2.4_remove_plugins.patch"
+ eapply "${FILESDIR}/${P}_makefile-variables.patch"
+ eapply "${FILESDIR}/${P}_glibc-2.31.patch"
+
+ use naludump && eapply "${DISTDIR}/${PN}-2.1.5-naludump-0.1.diff"
+# # requested to upstream for new patch
+# use permashift && eapply "${DISTDIR}/vdr-2.3-patch-for-permashift.diff"
+ use pinplugin && eapply "${WORKDIR}/${P}_pinplugin.patch"
+ use ttxtsubs && eapply "${WORKDIR}/${PN}-2.4.0-ttxtsubs.patch"
+ use ttxtsubs && eapply "${FILESDIR}/${P}_ttxtsubs_segfault.patch"
+ use menuorg && eapply "${DISTDIR}/vdr-menuorg-2.3.x.diff"
+ use mainmenuhooks && eapply "${WORKDIR}/${P}_mainmenuhook-1.0.1.patch"
+
+ add_cap CAP_UTF8 \
+ CAP_IRCTRL_RUNTIME_PARAM \
+ CAP_VFAT_RUNTIME_PARAM \
+ CAP_CHUID \
+ CAP_SHUTDOWN_AUTO_RETRY
+
+ echo -e ${CAPS} > "${CAP_FILE}" || die "cannot write to CAP_FILE"
+
+ # LINGUAS support
+ einfo "\n \t VDR supports the LINGUAS values"
+
+ lang_po
+
+ einfo "\t Please set one of this values in your sytem make.conf"
+ einfo "\t LINGUAS=\"${LING_PO}\"\n"
+
+ if [[ -z ${LINGUAS} ]]; then
+ einfo "\n \t No values in LINGUAS="
+ einfo "\t You will get only english text on OSD \n"
+ fi
+
+ strip-linguas ${LING_PO} en
+
+ default
+}
+
+src_install() {
+ # trick the makefile to not create a VIDEODIR by supplying it with an
+ # existing directory
+ emake VIDEODIR="/" DESTDIR="${ED}" install
+
+ keepdir "${PLUGIN_LIBDIR}"
+
+ # backup for plugins they don't be able to create this dir
+ keepdir "${CONF_DIR}/plugins"
+
+ if use html; then
+ local HTML_DOCS=( *.html )
+ fi
+ local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS UPDATE-2* )
+ einstalldocs
+
+ insinto /usr/share/vdr
+ doins "${CAP_FILE}"
+
+ fowners vdr:vdr "${CONF_DIR}" -R
+}
+
+pkg_postinst() {
+ elog "Please read the /usr/share/doc/${PF}/UPDATE-2.4"
+ elog "for major changes in this version\n"
+
+ elog "It is a good idea to run vdrplugin-rebuild now.\n"
+
+ elog "To get nice symbols in OSD we recommend to install"
+ elog "\t1. emerge media-fonts/vdrsymbols-ttf"
+ elog "\t2. select font VDRSymbolsSans in Setup\n"
+
+ elog "To get an idea how to proceed now, have a look at our vdr-guide:"
+ elog "\thttps://wiki.gentoo.org/wiki/VDR"
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2021-02-11 17:20 Jörg Bornkessel
0 siblings, 0 replies; 15+ messages in thread
From: Jörg Bornkessel @ 2021-02-11 17:20 UTC (permalink / raw
To: gentoo-commits
commit: 3f50eab87a6bef5bc45fc1754f35db7b769bcdba
Author: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
AuthorDate: Thu Feb 11 16:55:00 2021 +0000
Commit: Jörg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
CommitDate: Thu Feb 11 17:20:19 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3f50eab8
media-video/vdr: version bump
temp droped use-flag permashift, pinplugin
as we do not have a addopted patch from plugins upstream yet
Package-Manager: Portage-3.0.14, Repoman-3.0.2
Signed-off-by: Joerg Bornkessel <hd_brummy <AT> gentoo.org>
media-video/vdr/Manifest | 2 +
media-video/vdr/files/vdr-2.4.6_gentoo.patch | 66 +++++++
.../vdr/files/vdr-2.4.6_makefile-variables.patch | 40 ++++
.../vdr/files/vdr-2.4.6_remove_plugins.patch | 24 +++
media-video/vdr/vdr-2.4.6.ebuild | 202 +++++++++++++++++++++
5 files changed, 334 insertions(+)
diff --git a/media-video/vdr/Manifest b/media-video/vdr/Manifest
index 715cb3e5d65..43de58b6f2e 100644
--- a/media-video/vdr/Manifest
+++ b/media-video/vdr/Manifest
@@ -6,4 +6,6 @@ DIST vdr-2.4.0-ttxtsubs.patch.bz2 16721 BLAKE2B d5c3da713cd82ed8c3baccd1336d2834
DIST vdr-2.4.1.tar.bz2 940623 BLAKE2B 6fa7858e1c0fc25d3332d20347b30515276fc2b54905f32109dfa7f59e4e0c8a83687be405fac063a673c89d77e191f62162b1bd0ed6ee179d32a27f73076fb3 SHA512 b851ebf626de1a6aea11ee9c0cd87d78ebebdc34128925d2027a7030db1262064edb8818566a87ce22d37a9bd2b4f0b4ff1aad8dd251061d9ff972ffe0cf022d
DIST vdr-2.4.1_mainmenuhook-1.0.1.patch.bz2 1463 BLAKE2B 2be3597a273a92d02be0d072e3d74b39275cbbe17d22e570f416d42c46b53f43209498e569142a2cc357e5f7176d2454cb2a86d0822b29cca913eab2ae9cc27f SHA512 9d3eb501fa06ff5b03361ef65c8ddeeba5f37493cc0edc2d4f54e200e48e17607957fa95bd1540f028bc9a98ad6f42b4d38cf79e9ce971de36bed30def108759
DIST vdr-2.4.1_pinplugin.patch.bz2 8641 BLAKE2B 339bb23ed0f505087bdbbefb192824d5def37bb00c4d5dc300f545c7951f11504115d058c157d1964f5f32e483e668675e13254465b5acce76cfdcf07faae216 SHA512 f402fa51314ad6c34439f71b7cb81e1ca51e0fa3b120a1fdaee119c2dd1b13174db2e666bf5e6204aa28e4acef8f6bd6e3ab8324793c3484eafb16dc8cf808d5
+DIST vdr-2.4.6.tar.bz2 951272 BLAKE2B 52e92eb7e5fdc9bb9209cbef61f8db47e2e9a4750c75bc5b4f88069f95e54faac6b1af5b4c77a6a53990d8f083b6ff8ddeb33418386081c128617217129374fd SHA512 bed8b7740a97b681cf4273c01b6ce80046c1e5914c06d12cffc46fdca615331d0e97771ec09697cf72897583fcf272d83b6bf188ef476715cd0c0c5fd4c5e9d4
+DIST vdr-2.4.6_ttxtsubs.patch.bz2 14964 BLAKE2B b07e26077fe5af02df00b3580031615390ba6b3ea1c5a6e9c91f5e6d1964da7114e0ad939a9e4de640a97f5a887c45f6c8b5793a4da9341c7c238993a997c87c SHA512 cd60496b4a8a2dbed209dcf6645c0a6886091c5d5fca791a5ff3ec9fdf7f6c3f2c9a99976636aa985257b9baef10439e75f844f58f3f0a25d5ebcd361ec552ae
DIST vdr-menuorg-2.3.x.diff 8852 BLAKE2B 19b98d51a69f52ecda5500f51ef1741a8397953b20c490055eab0393da5f56ff9598c3e1e8ed8b915f5877e08deeb9ba7a9ef8d9356ad3a1fa12e3778869174a SHA512 7b41c3a529858a4953a57f21619ea01864e140cc1755ee0b03caf1c4de41e80c3f805653502bc8d39d02a4dfcddf720acd4a8c8bd91f4871eef31d86e8e915c0
diff --git a/media-video/vdr/files/vdr-2.4.6_gentoo.patch b/media-video/vdr/files/vdr-2.4.6_gentoo.patch
new file mode 100644
index 00000000000..6ecd2ccfd43
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.4.6_gentoo.patch
@@ -0,0 +1,66 @@
+this patch will disable some handling in the core Makefile
+as we use for Linux FHS a different handling in gentoo
+demoplugins from core vdr install disabled
+support from Linguas variable
+
+Signed-off-by: Joerg Bornkessel <hd_brummy@gentoo.org> 2021/Feb/11
+diff -Naur vdr-2.4.6.orig/Makefile vdr-2.4.6/Makefile
+--- vdr-2.4.6.orig/Makefile 2020-06-27 11:13:04.000000000 +0200
++++ vdr-2.4.6/Makefile 2020-08-08 18:16:02.519719542 +0200
+@@ -193,7 +193,7 @@
+
+ PODIR = po
+ LOCALEDIR = locale
+-I18Npo = $(wildcard $(PODIR)/*.po)
++I18Npo = $(foreach dir,$(LINGUAS),$(wildcard $(PODIR)/$(dir)*.po))
+ I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file))))
+ I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr.mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file))))))
+ I18Npot = $(PODIR)/vdr.pot
+@@ -220,7 +220,7 @@
+
+ install-i18n: i18n
+ @mkdir -p $(DESTDIR)$(LOCDIR)
+- cp -r $(LOCALEDIR)/* $(DESTDIR)$(LOCDIR)
++ @(cd $(LOCALEDIR); for linguas in $(LINGUAS); do [ "$$linguas" = "en" ] && continue; cp -r --parents $$linguas* $(DESTDIR)$(LOCDIR); done)
+
+ # The 'include' directory (for plugins):
+
+@@ -294,12 +294,11 @@
+
+ install-dirs:
+ @mkdir -p $(DESTDIR)$(VIDEODIR)
+- @mkdir -p $(DESTDIR)$(CONFDIR)
+ @mkdir -p $(DESTDIR)$(ARGSDIR)
+- @mkdir -p $(DESTDIR)$(CACHEDIR)
+ @mkdir -p $(DESTDIR)$(RESDIR)
+
+ install-conf: install-dirs
++ @mkdir -p $(DESTDIR)$(CONFDIR)
+ @cp -pn *.conf $(DESTDIR)$(CONFDIR)
+
+ # Documentation:
+@@ -307,9 +306,9 @@
+ install-doc:
+ @mkdir -p $(DESTDIR)$(MANDIR)/man1
+ @mkdir -p $(DESTDIR)$(MANDIR)/man5
+- @gzip -c vdr.1 > $(DESTDIR)$(MANDIR)/man1/vdr.1.gz
+- @gzip -c vdr.5 > $(DESTDIR)$(MANDIR)/man5/vdr.5.gz
+- @gzip -c svdrpsend.1 > $(DESTDIR)$(MANDIR)/man1/svdrpsend.1.gz
++ @cp vdr.1 $(DESTDIR)$(MANDIR)/man1/
++ @cp vdr.5 $(DESTDIR)$(MANDIR)/man5/
++ @cp svdrpsend.1 $(DESTDIR)$(MANDIR)/man1/
+
+ # Plugins:
+
+@@ -326,8 +325,9 @@
+ # Includes:
+
+ install-includes: include-dir
+- @mkdir -p $(DESTDIR)$(INCDIR)
+- @cp -pLR include/vdr include/libsi $(DESTDIR)$(INCDIR)
++ @mkdir -p $(DESTDIR)$(INCDIR)/vdr $(DESTDIR)$(INCDIR)/vdr/libsi
++ @cp -pLR include/vdr $(DESTDIR)$(INCDIR)
++ @cp -pLR include/libsi Make.config $(DESTDIR)$(INCDIR)/vdr
+
+ # pkg-config file:
+
diff --git a/media-video/vdr/files/vdr-2.4.6_makefile-variables.patch b/media-video/vdr/files/vdr-2.4.6_makefile-variables.patch
new file mode 100644
index 00000000000..0731b91443c
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.4.6_makefile-variables.patch
@@ -0,0 +1,40 @@
+we change some variables in the Makefile
+for a better handling in gentoo ebuild
+
+Signed-off-by: Joerg Bornkessel <hd_brummy@gentoo.org> 2021/Feb/11
+diff -Naur vdr-2.4.6.orig/Makefile vdr-2.4.6/Makefile
+--- vdr-2.4.6.orig/Makefile 2020-06-27 11:13:04.000000000 +0200
++++ vdr-2.4.6/Makefile 2020-08-08 18:16:02.519719542 +0200
+@@ -65,7 +65,7 @@
+
+ # Output control
+
+-ifdef VERBOSE
++ifeq ($(VERBOSE),1)
+ Q =
+ else
+ Q = @
+@@ -100,7 +100,7 @@
+ ifdef HDRDIR
+ HDRDIR := -I$(HDRDIR)
+ endif
+-ifndef NO_KBD
++ifeq ($(USE_KBD),1)
+ DEFINES += -DREMOTE_KBD
+ endif
+ ifdef REMOTE
+@@ -109,12 +109,12 @@
+ ifdef VDR_USER
+ DEFINES += -DVDR_USER=\"$(VDR_USER)\"
+ endif
+-ifdef BIDI
++ifeq ($(BIDI),1)
+ INCLUDES += $(shell $(PKG_CONFIG) --cflags fribidi)
+ DEFINES += -DBIDI
+ LIBS += $(shell $(PKG_CONFIG) --libs fribidi)
+ endif
+-ifdef SDNOTIFY
++ifeq ($(SDNOTIFY),1)
+ INCLUDES += $(shell $(PKG_CONFIG) --silence-errors --cflags libsystemd-daemon || $(PKG_CONFIG) --cflags libsystemd)
+ DEFINES += -DSDNOTIFY
+ LIBS += $(shell $(PKG_CONFIG) --silence-errors --libs libsystemd-daemon || $(PKG_CONFIG) --libs libsystemd)
diff --git a/media-video/vdr/files/vdr-2.4.6_remove_plugins.patch b/media-video/vdr/files/vdr-2.4.6_remove_plugins.patch
new file mode 100644
index 00000000000..d2571ea687c
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.4.6_remove_plugins.patch
@@ -0,0 +1,24 @@
+we do not install any plugins from core vdr
+
+Signed-off-by: Joerg Bornkessel <hd_brummy@gentoo.org> 2021/Feb/11
+diff -Naur vdr-2.4.6.orig/Makefile vdr-2.4.6/Makefile
+--- vdr-2.4.6.orig/Makefile 2020-06-27 11:13:04.000000000 +0200
++++ vdr-2.4.6/Makefile 2020-08-08 18:16:02.519719542 +0200
+@@ -136,7 +136,7 @@
+ VDRVERSION = $(shell sed -ne '/define VDRVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h)
+ APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h)
+
+-all: vdr i18n plugins
++all: vdr i18n
+
+ # Implicit rules:
+
+@@ -282,7 +282,7 @@
+
+ # Install the files (note that 'install-pc' must be first!):
+
+-install: install-pc install-bin install-conf install-doc install-plugins install-i18n install-includes
++install: install-pc install-bin install-conf install-doc install-i18n install-includes
+
+ # VDR binary:
+
diff --git a/media-video/vdr/vdr-2.4.6.ebuild b/media-video/vdr/vdr-2.4.6.ebuild
new file mode 100644
index 00000000000..b8ba1b702c6
--- /dev/null
+++ b/media-video/vdr/vdr-2.4.6.ebuild
@@ -0,0 +1,202 @@
+# Copyright 2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit flag-o-matic multilib toolchain-funcs
+
+DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
+HOMEPAGE="http://www.tvdr.de/"
+SRC_URI="ftp://ftp.tvdr.de/vdr/${P}.tar.bz2
+ mainmenuhooks? ( http://vdr.websitec.de/download/${PN}/${PN}-2.4.1/${PN}-2.4.1_mainmenuhook-1.0.1.patch.bz2 )
+ menuorg? ( https://projects.vdr-developer.org/projects/plg-menuorg/repository/revisions/master/raw/vdr-patch/vdr-menuorg-2.3.x.diff )
+ naludump? ( http://www.udo-richter.de/vdr/files/vdr-2.1.5-naludump-0.1.diff )
+ ttxtsubs? ( http://vdr.websitec.de/download/${PN}/${P}/${P}_ttxtsubs.patch.bz2 )"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~x86"
+IUSE="bidi debug demoplugins html keyboard mainmenuhooks menuorg naludump systemd ttxtsubs verbose"
+# use-flag permashift, pinplugin tmp droped
+COMMON_DEPEND="
+ virtual/jpeg:*
+ sys-libs/libcap
+ >=media-libs/fontconfig-2.4.2
+ >=media-libs/freetype-2"
+DEPEND="${COMMON_DEPEND}
+ >=virtual/linuxtv-dvb-headers-5.3"
+RDEPEND="${COMMON_DEPEND}
+ dev-lang/perl
+ media-tv/gentoo-vdr-scripts
+ media-fonts/corefonts
+ bidi? ( dev-libs/fribidi )
+ systemd? ( sys-apps/systemd )"
+BDEPEND="sys-devel/gettext"
+
+# permashift, pinplugin tmp droped
+#REQUIRED_USE="pinplugin? ( !mainmenuhooks )"
+# permashift? ( !naludump !pinplugin )"
+
+CONF_DIR="/etc/vdr"
+CAP_FILE="${S}/capabilities.sh"
+CAPS="# Capabilities of the vdr-executable for use by startscript etc."
+
+pkg_setup() {
+ use debug && append-flags -g
+
+ PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
+
+ # use the corrected DIR /var/lib/vdr/* for acct/{user,group) handling
+ if has_version ">=media-tv/gentoo-vdr-scripts-3.0_rc1"; then
+ VIDEO_DIR="/var/lib/vdr/video"
+ else
+ VIDEO_DIR="/var/vdr/video"
+ fi
+
+ tc-export CC CXX AR
+}
+
+add_cap() {
+ local arg
+ for arg; do
+ CAPS="${CAPS}\n${arg}=1"
+ done
+}
+
+lang_po() {
+ LING_PO=$( ls ${S}/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
+}
+
+src_configure() {
+ # support languages, written from right to left
+ export "BIDI=$(usex bidi 1 0)"
+ # systemd notification support
+ export "SDNOTIFY=$(usex systemd 1 0)"
+ # with/without keyboard
+ export "USE_KBD=$(usex keyboard 1 0)"
+ # detailed compile output for debug
+ export "VERBOSE=$(usex verbose 1 0)"
+}
+
+src_prepare() {
+ # apply maintenance-patches
+ ebegin "Changing paths for gentoo"
+
+ local DVBDIR=/usr/include
+ local i
+ for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
+ [[ -d ${i} ]] || continue
+ if [[ -f ${i}/linux/dvb/dmx.h ]]; then
+ einfo "Found DVB header files in ${i}"
+ DVBDIR=${i}
+ break
+ fi
+ done
+
+ # checking for s2api headers
+ local api_version
+ api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+ api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+
+ if [[ ${api_version:-0} -lt 5*3 ]]; then
+ eerror "DVB header files do not contain s2api support or too old for ${P}"
+ eerror "You cannot compile VDR against old dvb-header"
+ die "DVB headers too old"
+ fi
+
+ cat > Make.config <<-EOT || die "cannot write to Make.config"
+ #
+ # Generated by ebuild ${PF}
+ #
+ PREFIX = /usr
+ DVBDIR = ${DVBDIR}
+ PLUGINLIBDIR = ${PLUGIN_LIBDIR}
+ CONFDIR = ${CONF_DIR}
+ ARGSDIR = \$(CONFDIR)/conf.d
+ VIDEODIR = ${VIDEO_DIR}
+ LOCDIR = \$(PREFIX)/share/locale
+ INCDIR = \$(PREFIX)/include
+
+ DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
+ INCLUDES += -I\$(DVBDIR)
+
+ # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
+ # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
+ LIBDIR = ${PLUGIN_LIBDIR}
+ PCDIR = /usr/$(get_libdir)/pkgconfig
+
+ EOT
+ eend 0
+
+ eapply "${FILESDIR}/${P}_gentoo.patch"
+ use demoplugins || eapply "${FILESDIR}/vdr-2.4_remove_plugins.patch"
+ eapply "${FILESDIR}/${P}_makefile-variables.patch"
+
+ use naludump && eapply "${DISTDIR}/${PN}-2.1.5-naludump-0.1.diff"
+# tmp droped, use permashift && eapply "${DISTDIR}/${PN}-2.4-patch-for-permashift.diff"
+# tmp droped, use pinplugin && eapply "${WORKDIR}/${PN}-2.4.1_pinplugin.patch"
+ use ttxtsubs && eapply "${WORKDIR}/${P}_ttxtsubs.patch"
+ use menuorg && eapply "${DISTDIR}/vdr-menuorg-2.3.x.diff"
+ use mainmenuhooks && eapply "${WORKDIR}/${PN}-2.4.1_mainmenuhook-1.0.1.patch"
+
+ add_cap CAP_UTF8 \
+ CAP_IRCTRL_RUNTIME_PARAM \
+ CAP_VFAT_RUNTIME_PARAM \
+ CAP_CHUID \
+ CAP_SHUTDOWN_AUTO_RETRY
+
+ echo -e ${CAPS} > "${CAP_FILE}" || die "cannot write to CAP_FILE"
+
+ # LINGUAS support
+ einfo "\n \t VDR supports the LINGUAS values"
+
+ lang_po
+
+ einfo "\t Please set one of this values in your sytem make.conf"
+ einfo "\t LINGUAS=\"${LING_PO}\"\n"
+
+ if [[ -z ${LINGUAS} ]]; then
+ einfo "\n \t No values in LINGUAS="
+ einfo "\t You will get only english text on OSD \n"
+ fi
+
+ strip-linguas ${LING_PO} en
+
+ default
+}
+
+src_install() {
+ # trick the makefile to not create a VIDEODIR by supplying it with an
+ # existing directory
+ emake VIDEODIR="/" DESTDIR="${ED}" install
+
+ keepdir "${PLUGIN_LIBDIR}"
+
+ # backup for plugins they don't be able to create this dir
+ keepdir "${CONF_DIR}/plugins"
+
+ if use html; then
+ local HTML_DOCS=( *.html )
+ fi
+ local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS UPDATE-2* )
+ einstalldocs
+
+ insinto /usr/share/vdr
+ doins "${CAP_FILE}"
+
+ fowners vdr:vdr "${CONF_DIR}" -R
+}
+
+pkg_postinst() {
+ elog "Please read the /usr/share/doc/${PF}/UPDATE-2.4"
+ elog "for major changes in this version\n"
+
+ elog "It is a good idea to run vdrplugin-rebuild now.\n"
+
+ elog "To get nice symbols in OSD we recommend to install"
+ elog "\t1. emerge media-fonts/vdrsymbols-ttf"
+ elog "\t2. select font VDRSymbolsSans in Setup\n"
+
+ elog "To get an idea how to proceed now, have a look at our vdr-guide:"
+ elog "\thttps://wiki.gentoo.org/wiki/VDR"
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2021-05-02 20:33 Jörg Bornkessel
0 siblings, 0 replies; 15+ messages in thread
From: Jörg Bornkessel @ 2021-05-02 20:33 UTC (permalink / raw
To: gentoo-commits
commit: 862ca1738ccf75e258934ba641d4bdb98f0d2a44
Author: Joerg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
AuthorDate: Sun May 2 20:32:52 2021 +0000
Commit: Jörg Bornkessel <hd_brummy <AT> gentoo <DOT> org>
CommitDate: Sun May 2 20:33:23 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=862ca173
media-video/vdr: version bump
in this bump is also the gcc11 compile error
fixed by patch
we skip here vdr-2.4.6 and go straid to vdr-2.4.7
Closes: https://bugs.gentoo.org/786882
Package-Manager: Portage-3.0.18, Repoman-3.0.2
Signed-off-by: Joerg Bornkessel <hd_brummy <AT> gentoo.org>
media-video/vdr/Manifest | 1 +
media-video/vdr/files/vdr-2.4.7_gcc11.patch | 292 ++++++++++++++++++++++++++++
media-video/vdr/vdr-2.4.7.ebuild | 209 ++++++++++++++++++++
3 files changed, 502 insertions(+)
diff --git a/media-video/vdr/Manifest b/media-video/vdr/Manifest
index 7611c3c1c5a..a46fe47fab9 100644
--- a/media-video/vdr/Manifest
+++ b/media-video/vdr/Manifest
@@ -10,4 +10,5 @@ DIST vdr-2.4.1_pinplugin.patch.bz2 8641 BLAKE2B 339bb23ed0f505087bdbbefb192824d5
DIST vdr-2.4.6.tar.bz2 951272 BLAKE2B 52e92eb7e5fdc9bb9209cbef61f8db47e2e9a4750c75bc5b4f88069f95e54faac6b1af5b4c77a6a53990d8f083b6ff8ddeb33418386081c128617217129374fd SHA512 bed8b7740a97b681cf4273c01b6ce80046c1e5914c06d12cffc46fdca615331d0e97771ec09697cf72897583fcf272d83b6bf188ef476715cd0c0c5fd4c5e9d4
DIST vdr-2.4.6_pinplugin.patch.bz2 5176 BLAKE2B 142ad6551b8e37d223acf86f8c2f511cf2cb3664b5ff968bac5e44420c56bf5fdb974360df574141c424cd7a4b1e1489c4a504207420af10f722a77e6d2bad2f SHA512 d5c7263b908302ebf88a5e5ddcb658f56ee92656b40797fd48af1ff9852454adc1d1672cc97411e7744cc31a56f4d0f51df5ece102c21b2aa25d87e3c3c8fe12
DIST vdr-2.4.6_ttxtsubs_v2.patch.bz2 51971 BLAKE2B e4915314e8f659df1c3e0ff631fd0c3dcec89053ff727fd28400dc6eecc49c1d4743a9bedaf3b11fce03fc6082309d4b4658d00a5b01aa5cbe8686e05412f882 SHA512 14c7b4397ba65e0ff9a5fb0705872f1cb6f1cdd1752b14f83f260540da25b5957632900232f83904c3d4fd6759e537c85bda2cce61455729eab3050a96441548
+DIST vdr-2.4.7.tbz2 919632 BLAKE2B be4e1ec365330855e4b2b26f44b1f35dc323e4783e96ef344a67b3e9fe2c0499760ab0f3d27c5e3bdddf5a65ebb65b0c81a62092301d34370aa19d0dd63bb1ab SHA512 41b8453bc6cdbb0db728b5d7d6624ab3ff9034b58ba443a8196f5fcc9fa78d18698cc91905890244e69d482ffc493374e6da2c97baed95fe742b888bdc63e42b
DIST vdr-menuorg-2.3.x.diff 8852 BLAKE2B 19b98d51a69f52ecda5500f51ef1741a8397953b20c490055eab0393da5f56ff9598c3e1e8ed8b915f5877e08deeb9ba7a9ef8d9356ad3a1fa12e3778869174a SHA512 7b41c3a529858a4953a57f21619ea01864e140cc1755ee0b03caf1c4de41e80c3f805653502bc8d39d02a4dfcddf720acd4a8c8bd91f4871eef31d86e8e915c0
diff --git a/media-video/vdr/files/vdr-2.4.7_gcc11.patch b/media-video/vdr/files/vdr-2.4.7_gcc11.patch
new file mode 100644
index 00000000000..866b018b5b7
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.4.7_gcc11.patch
@@ -0,0 +1,292 @@
+https://bugs.gentoo.org/786882
+
+compile fix for gcc-11
+
+Signed-off-by: Joerg Bornkessel <hd_brummy@gentoo.org> (02 May 2021)
+diff -Naur vdr-2.4.7.orig/channels.c vdr-2.4.7/channels.c
+--- vdr-2.4.7.orig/channels.c 2021-05-02 19:34:32.312653108 +0200
++++ vdr-2.4.7/channels.c 2021-05-02 19:39:19.241653108 +0200
+@@ -11,6 +11,7 @@
+ #include <ctype.h>
+ #include "device.h"
+ #include "libsi/si.h"
++using namespace std;
+
+ // IMPORTANT NOTE: in the 'sscanf()' calls there is a blank after the '%d'
+ // format characters in order to allow any number of blanks after a numeric
+diff -Naur vdr-2.4.7.orig/ci.c vdr-2.4.7/ci.c
+--- vdr-2.4.7.orig/ci.c 2021-05-02 19:34:32.313653108 +0200
++++ vdr-2.4.7/ci.c 2021-05-02 19:49:53.216653108 +0200
+@@ -27,6 +27,8 @@
+ #include "skins.h"
+ #include "tools.h"
+
++using namespace std;
++
+ // Set these to 'true' for debug output:
+ static bool DumpTPDUDataTransfer = false;
+ static bool DebugProtocol = false;
+diff -Naur vdr-2.4.7.orig/device.c vdr-2.4.7/device.c
+--- vdr-2.4.7.orig/device.c 2021-05-02 19:34:32.313653108 +0200
++++ vdr-2.4.7/device.c 2021-05-02 19:43:19.071653108 +0200
+@@ -20,6 +20,8 @@
+ #include "status.h"
+ #include "transfer.h"
+
++using namespace std;
++
+ // --- cLiveSubtitle ---------------------------------------------------------
+
+ class cLiveSubtitle : public cReceiver {
+diff -Naur vdr-2.4.7.orig/diseqc.c vdr-2.4.7/diseqc.c
+--- vdr-2.4.7.orig/diseqc.c 2021-05-02 19:34:32.314653108 +0200
++++ vdr-2.4.7/diseqc.c 2021-05-02 19:50:14.177653108 +0200
+@@ -14,6 +14,8 @@
+ #include "sources.h"
+ #include "thread.h"
+
++using namespace std;
++
+ #define ALL_DEVICES (~0) // all bits set to '1'
+ #define MAX_DEVICES 32 // each bit in a 32-bit integer represents one device
+
+diff -Naur vdr-2.4.7.orig/dvbdevice.c vdr-2.4.7/dvbdevice.c
+--- vdr-2.4.7.orig/dvbdevice.c 2021-05-02 19:34:32.314653108 +0200
++++ vdr-2.4.7/dvbdevice.c 2021-05-02 19:50:35.634653108 +0200
+@@ -21,6 +21,8 @@
+ #include "menuitems.h"
+ #include "sourceparams.h"
+
++using namespace std;
++
+ static int DvbApiVersion = 0x0000; // the version of the DVB driver actually in use (will be determined by the first device created)
+
+ #define DVBS_TUNE_TIMEOUT 9000 //ms
+diff -Naur vdr-2.4.7.orig/dvbplayer.c vdr-2.4.7/dvbplayer.c
+--- vdr-2.4.7.orig/dvbplayer.c 2021-05-02 19:34:32.314653108 +0200
++++ vdr-2.4.7/dvbplayer.c 2021-05-02 19:43:47.344653108 +0200
+@@ -15,6 +15,8 @@
+ #include "thread.h"
+ #include "tools.h"
+
++using namespace std;
++
+ // --- cPtsIndex -------------------------------------------------------------
+
+ #define PTSINDEX_ENTRIES 1024
+diff -Naur vdr-2.4.7.orig/dvbspu.c vdr-2.4.7/dvbspu.c
+--- vdr-2.4.7.orig/dvbspu.c 2021-05-02 19:34:32.314653108 +0200
++++ vdr-2.4.7/dvbspu.c 2021-05-02 19:44:08.952653108 +0200
+@@ -17,6 +17,8 @@
+ #include <inttypes.h>
+ #include <math.h>
+
++using namespace std;
++
+ /*
+ * cDvbSpubitmap:
+ *
+diff -Naur vdr-2.4.7.orig/dvbsubtitle.c vdr-2.4.7/dvbsubtitle.c
+--- vdr-2.4.7.orig/dvbsubtitle.c 2021-05-02 19:34:32.315653108 +0200
++++ vdr-2.4.7/dvbsubtitle.c 2021-05-02 19:44:42.537653108 +0200
+@@ -16,6 +16,8 @@
+ #include "device.h"
+ #include "libsi/si.h"
+
++using namespace std;
++
+ #define PAGE_COMPOSITION_SEGMENT 0x10
+ #define REGION_COMPOSITION_SEGMENT 0x11
+ #define CLUT_DEFINITION_SEGMENT 0x12
+diff -Naur vdr-2.4.7.orig/eit.c vdr-2.4.7/eit.c
+--- vdr-2.4.7.orig/eit.c 2021-05-02 19:34:32.315653108 +0200
++++ vdr-2.4.7/eit.c 2021-05-02 19:45:16.962653108 +0200
+@@ -18,6 +18,8 @@
+ #include "libsi/section.h"
+ #include "libsi/descriptor.h"
+
++using namespace std;
++
+ #define VALID_TIME (31536000 * 2) // two years
+
+ #define DBGEIT 0
+diff -Naur vdr-2.4.7.orig/font.c vdr-2.4.7/font.c
+--- vdr-2.4.7.orig/font.c 2021-05-02 19:34:32.315653108 +0200
++++ vdr-2.4.7/font.c 2021-05-02 19:51:53.540653108 +0200
+@@ -21,6 +21,8 @@
+ #include "osd.h"
+ #include "tools.h"
+
++using namespace std;
++
+ const char *DefaultFontOsd = "Sans Serif:Bold";
+ const char *DefaultFontSml = "Sans Serif";
+ const char *DefaultFontFix = "Courier:Bold";
+diff -Naur vdr-2.4.7.orig/menu.c vdr-2.4.7/menu.c
+--- vdr-2.4.7.orig/menu.c 2021-05-02 19:34:32.317653108 +0200
++++ vdr-2.4.7/menu.c 2021-05-02 19:45:44.891653108 +0200
+@@ -33,6 +33,8 @@
+ #include "transfer.h"
+ #include "videodir.h"
+
++using namespace std;
++
+ #define MAXWAIT4EPGINFO 3 // seconds
+ #define MODETIMEOUT 3 // seconds
+ #define NEWTIMERLIMIT 120 // seconds until the start time of a new timer created from the Schedule menu,
+diff -Naur vdr-2.4.7.orig/menuitems.c vdr-2.4.7/menuitems.c
+--- vdr-2.4.7.orig/menuitems.c 2021-05-02 19:34:32.318653108 +0200
++++ vdr-2.4.7/menuitems.c 2021-05-02 19:46:02.483653108 +0200
+@@ -17,6 +17,8 @@
+ #include "skins.h"
+ #include "status.h"
+
++using namespace std;
++
+ #define AUTO_ADVANCE_TIMEOUT 1500 // ms before auto advance when entering characters via numeric keys
+
+ const char *FileNameChars = trNOOP("FileNameChars$ abcdefghijklmnopqrstuvwxyz0123456789-.,#~\\^$[]|()*+?{}/:%@&");
+diff -Naur vdr-2.4.7.orig/mtd.c vdr-2.4.7/mtd.c
+--- vdr-2.4.7.orig/mtd.c 2021-05-02 19:34:32.318653108 +0200
++++ vdr-2.4.7/mtd.c 2021-05-02 19:46:23.355653108 +0200
+@@ -10,6 +10,8 @@
+ #include "mtd.h"
+ #include "receiver.h"
+
++using namespace std;
++
+ //#define DEBUG_MTD
+ #ifdef DEBUG_MTD
+ #define DBGMTD(a...) dsyslog(a)
+diff -Naur vdr-2.4.7.orig/nit.c vdr-2.4.7/nit.c
+--- vdr-2.4.7.orig/nit.c 2021-05-02 19:34:32.318653108 +0200
++++ vdr-2.4.7/nit.c 2021-05-02 19:52:19.012653108 +0200
+@@ -16,6 +16,8 @@
+ #include "libsi/descriptor.h"
+ #include "tools.h"
+
++using namespace std;
++
+ #define DVB_SYSTEM_1 0 // see also dvbdevice.c
+ #define DVB_SYSTEM_2 1
+
+diff -Naur vdr-2.4.7.orig/osd.c vdr-2.4.7/osd.c
+--- vdr-2.4.7.orig/osd.c 2021-05-02 19:34:32.318653108 +0200
++++ vdr-2.4.7/osd.c 2021-05-02 19:47:12.501653108 +0200
+@@ -16,6 +16,8 @@
+ #include "device.h"
+ #include "tools.h"
+
++using namespace std;
++
+ tColor HsvToColor(double H, double S, double V)
+ {
+ if (S > 0) {
+diff -Naur vdr-2.4.7.orig/osdbase.c vdr-2.4.7/osdbase.c
+--- vdr-2.4.7.orig/osdbase.c 2021-05-02 19:34:32.318653108 +0200
++++ vdr-2.4.7/osdbase.c 2021-05-02 19:46:53.516653108 +0200
+@@ -15,6 +15,8 @@
+ #include "remote.h"
+ #include "status.h"
+
++using namespace std;
++
+ // --- cOsdItem --------------------------------------------------------------
+
+ cOsdItem::cOsdItem(eOSState State)
+diff -Naur vdr-2.4.7.orig/recording.c vdr-2.4.7/recording.c
+--- vdr-2.4.7.orig/recording.c 2021-05-02 19:34:32.323653108 +0200
++++ vdr-2.4.7/recording.c 2021-05-02 19:47:45.990653108 +0200
+@@ -31,6 +31,8 @@
+ #include "tools.h"
+ #include "videodir.h"
+
++using namespace std;
++
+ #define SUMMARYFALLBACK
+
+ #define RECEXT ".rec"
+diff -Naur vdr-2.4.7.orig/remux.c vdr-2.4.7/remux.c
+--- vdr-2.4.7.orig/remux.c 2021-05-02 19:34:32.323653108 +0200
++++ vdr-2.4.7/remux.c 2021-05-02 19:48:03.230653108 +0200
+@@ -16,6 +16,8 @@
+ #include "shutdown.h"
+ #include "tools.h"
+
++using namespace std;
++
+ // Set these to 'true' for debug output:
+ static bool DebugPatPmt = false;
+ static bool DebugFrames = false;
+diff -Naur vdr-2.4.7.orig/skinclassic.c vdr-2.4.7/skinclassic.c
+--- vdr-2.4.7.orig/skinclassic.c 2021-05-02 19:34:32.324653108 +0200
++++ vdr-2.4.7/skinclassic.c 2021-05-02 19:48:26.271653108 +0200
+@@ -14,6 +14,8 @@
+ #include "themes.h"
+ #include "videodir.h"
+
++using namespace std;
++
+ #define ScrollWidth (Setup.FontOsdSize / 4)
+ #define TextFrame (Setup.FontOsdSize / 10)
+ #define TextSpacing (Setup.FontOsdSize / 4)
+diff -Naur vdr-2.4.7.orig/skinlcars.c vdr-2.4.7/skinlcars.c
+--- vdr-2.4.7.orig/skinlcars.c 2021-05-02 19:34:32.324653108 +0200
++++ vdr-2.4.7/skinlcars.c 2021-05-02 19:48:46.063653108 +0200
+@@ -63,6 +63,8 @@
+ #include "symbols/teletext.xpm"
+ #include "symbols/volume.xpm"
+
++using namespace std;
++
+ #define Gap (Setup.FontOsdSize / 5 & ~1) // must be even
+ #define TextFrame (Setup.FontOsdSize / TEXT_ALIGN_BORDER)
+ #define TextSpacing (2 * TextFrame)
+diff -Naur vdr-2.4.7.orig/skinsttng.c vdr-2.4.7/skinsttng.c
+--- vdr-2.4.7.orig/skinsttng.c 2021-05-02 19:34:32.324653108 +0200
++++ vdr-2.4.7/skinsttng.c 2021-05-02 19:49:15.256653108 +0200
+@@ -50,6 +50,8 @@
+ #include "symbols/teletext.xpm"
+ #include "symbols/volume.xpm"
+
++using namespace std;
++
+ #define Roundness (Setup.FontOsdSize / 2)
+ #define Gap (Setup.FontOsdSize / 5)
+ #define ScrollWidth (Setup.FontOsdSize / 4)
+diff -Naur vdr-2.4.7.orig/thread.c vdr-2.4.7/thread.c
+--- vdr-2.4.7.orig/thread.c 2021-05-02 19:59:16.883653108 +0200
++++ vdr-2.4.7/thread.c 2021-05-02 20:00:08.879653108 +0200
+@@ -24,6 +24,8 @@
+ #include <unistd.h>
+ #include "tools.h"
+
++using namespace std;
++
+ #define ABORT { dsyslog("ABORT!"); cBackTrace::BackTrace(); abort(); }
+
+ //#define DEBUG_LOCKING // uncomment this line to activate debug output for locking
+diff -Naur vdr-2.4.7.orig/timers.c vdr-2.4.7/timers.c
+--- vdr-2.4.7.orig/timers.c 2021-05-02 19:59:16.883653108 +0200
++++ vdr-2.4.7/timers.c 2021-05-02 19:59:52.287653108 +0200
+@@ -17,6 +17,8 @@
+ #include "status.h"
+ #include "svdrp.h"
+
++using namespace std;
++
+ // IMPORTANT NOTE: in the 'sscanf()' calls there is a blank after the '%d'
+ // format characters in order to allow any number of blanks after a numeric
+ // value!
+diff -Naur vdr-2.4.7.orig/tools.c vdr-2.4.7/tools.c
+--- vdr-2.4.7.orig/tools.c 2021-05-02 20:02:40.535653108 +0200
++++ vdr-2.4.7/tools.c 2021-05-02 20:03:06.859653108 +0200
+@@ -28,6 +28,8 @@
+ #include "i18n.h"
+ #include "thread.h"
+
++using namespace std;
++
+ int SysLogLevel = 3;
+
+ #define MAXSYSLOGBUF 256
diff --git a/media-video/vdr/vdr-2.4.7.ebuild b/media-video/vdr/vdr-2.4.7.ebuild
new file mode 100644
index 00000000000..c1f9413c302
--- /dev/null
+++ b/media-video/vdr/vdr-2.4.7.ebuild
@@ -0,0 +1,209 @@
+# Copyright 2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit flag-o-matic l10n toolchain-funcs
+
+DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
+HOMEPAGE="http://www.tvdr.de/"
+SRC_URI="http://git.tvdr.de/?p=vdr.git;a=snapshot;h=refs/tags/2.4.7;sf=tbz2 -> ${P}.tbz2
+ mainmenuhooks? ( http://vdr.websitec.de/download/${PN}/${PN}-2.4.1/${PN}-2.4.1_mainmenuhook-1.0.1.patch.bz2 )
+ menuorg? ( https://projects.vdr-developer.org/projects/plg-menuorg/repository/revisions/master/raw/vdr-patch/vdr-menuorg-2.3.x.diff )
+ naludump? ( http://www.udo-richter.de/vdr/files/vdr-2.1.5-naludump-0.1.diff )
+ pinplugin? ( http://vdr.websitec.de/download/${PN}/${P}/${PN}-2.4.6_pinplugin.patch.bz2 )
+ ttxtsubs? ( http://vdr.websitec.de/download/${PN}/${P}/${PN}-2.4.6_ttxtsubs_v2.patch.bz2 )
+ permashift? ( http://vdr.websitec.de/download/${PN}/${P}/vdr-2.4-patch-for-permashift.diff.bz2 )"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~x86"
+IUSE="bidi debug demoplugins html keyboard mainmenuhooks menuorg naludump permashift pinplugin systemd ttxtsubs verbose"
+
+COMMON_DEPEND="
+ virtual/jpeg:*
+ sys-libs/libcap
+ >=media-libs/fontconfig-2.4.2
+ >=media-libs/freetype-2"
+DEPEND="${COMMON_DEPEND}
+ >=virtual/linuxtv-dvb-headers-5.3"
+RDEPEND="${COMMON_DEPEND}
+ dev-lang/perl
+ media-tv/gentoo-vdr-scripts
+ media-fonts/corefonts
+ bidi? ( dev-libs/fribidi )
+ systemd? ( sys-apps/systemd )"
+BDEPEND="sys-devel/gettext"
+
+REQUIRED_USE="pinplugin? ( !mainmenuhooks )
+ permashift? ( !naludump !pinplugin )"
+
+CONF_DIR="/etc/vdr"
+CAP_FILE="${S}/capabilities.sh"
+CAPS="# Capabilities of the vdr-executable for use by startscript etc."
+
+pkg_setup() {
+ use debug && append-flags -g
+
+ PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
+
+ # use the corrected DIR /var/lib/vdr/* for acct/{user,group) handling
+ if has_version ">=media-tv/gentoo-vdr-scripts-3.0_rc1"; then
+ VIDEO_DIR="/var/lib/vdr/video"
+ else
+ VIDEO_DIR="/var/vdr/video"
+ fi
+
+ tc-export CC CXX AR
+}
+
+add_cap() {
+ local arg
+ for arg; do
+ CAPS="${CAPS}\n${arg}=1"
+ done
+}
+
+lang_po() {
+ LING_PO=$( ls ${S}/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
+}
+
+src_configure() {
+ # support languages, written from right to left
+ export "BIDI=$(usex bidi 1 0)"
+ # systemd notification support
+ export "SDNOTIFY=$(usex systemd 1 0)"
+ # with/without keyboard
+ export "USE_KBD=$(usex keyboard 1 0)"
+ # detailed compile output for debug
+ export "VERBOSE=$(usex verbose 1 0)"
+}
+
+src_prepare() {
+ # apply maintenance-patches
+ ebegin "Changing paths for gentoo"
+
+ local DVBDIR=/usr/include
+ local i
+ for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
+ [[ -d ${i} ]] || continue
+ if [[ -f ${i}/linux/dvb/dmx.h ]]; then
+ einfo "Found DVB header files in ${i}"
+ DVBDIR=${i}
+ break
+ fi
+ done
+
+ # checking for s2api headers
+ local api_version
+ api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+ api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+
+ if [[ ${api_version:-0} -lt 5*3 ]]; then
+ eerror "DVB header files do not contain s2api support or too old for ${P}"
+ eerror "You cannot compile VDR against old dvb-header"
+ die "DVB headers too old"
+ fi
+
+ cat > Make.config <<-EOT || die "cannot write to Make.config"
+ #
+ # Generated by ebuild ${PF}
+ #
+ PREFIX = /usr
+ DVBDIR = ${DVBDIR}
+ PLUGINLIBDIR = ${PLUGIN_LIBDIR}
+ CONFDIR = ${CONF_DIR}
+ ARGSDIR = \$(CONFDIR)/conf.d
+ VIDEODIR = ${VIDEO_DIR}
+ LOCDIR = \$(PREFIX)/share/locale
+ INCDIR = \$(PREFIX)/include
+
+ DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
+ INCLUDES += -I\$(DVBDIR)
+
+ # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
+ # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
+ LIBDIR = ${PLUGIN_LIBDIR}
+ PCDIR = /usr/$(get_libdir)/pkgconfig
+
+ EOT
+ eend 0
+
+ eapply "${FILESDIR}/${PN}-2.4.6_gentoo.patch"
+ use demoplugins || eapply "${FILESDIR}/vdr-2.4_remove_plugins.patch"
+ eapply "${FILESDIR}/${PN}-2.4.6_makefile-variables.patch"
+
+ # fix clang/LLVM compile
+ eapply "${FILESDIR}/${PN}-2.4.6_clang.patch"
+
+ # fix gcc-11 compile
+ eapply "${FILESDIR}/${P}_gcc11.patch"
+
+ use naludump && eapply "${DISTDIR}/${PN}-2.1.5-naludump-0.1.diff"
+ use permashift && eapply "${WORKDIR}/${PN}-2.4-patch-for-permashift.diff"
+ use pinplugin && eapply "${WORKDIR}/${PN}-2.4.6_pinplugin.patch"
+ use ttxtsubs && eapply "${WORKDIR}/${PN}-2.4.6_ttxtsubs_v2.patch"
+ use menuorg && eapply "${DISTDIR}/vdr-menuorg-2.3.x.diff"
+ use mainmenuhooks && eapply "${WORKDIR}/${PN}-2.4.1_mainmenuhook-1.0.1.patch"
+
+ add_cap CAP_UTF8 \
+ CAP_IRCTRL_RUNTIME_PARAM \
+ CAP_VFAT_RUNTIME_PARAM \
+ CAP_CHUID \
+ CAP_SHUTDOWN_AUTO_RETRY
+
+ echo -e ${CAPS} > "${CAP_FILE}" || die "cannot write to CAP_FILE"
+
+ # LINGUAS support
+ einfo "\n \t VDR supports the LINGUAS values"
+
+ lang_po
+
+ einfo "\t Please set one of this values in your sytem make.conf"
+ einfo "\t LINGUAS=\"${LING_PO}\"\n"
+
+ if [[ -z ${LINGUAS} ]]; then
+ einfo "\n \t No values in LINGUAS="
+ einfo "\t You will get only english text on OSD \n"
+ fi
+
+ strip-linguas ${LING_PO} en
+
+ default
+}
+
+src_install() {
+ # trick the makefile to not create a VIDEODIR by supplying it with an
+ # existing directory
+ emake VIDEODIR="/" DESTDIR="${ED}" install
+
+ keepdir "${PLUGIN_LIBDIR}"
+
+ # backup for plugins they don't be able to create this dir
+ keepdir "${CONF_DIR}/plugins"
+
+ if use html; then
+ local HTML_DOCS=( *.html )
+ fi
+ local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS UPDATE-2* )
+ einstalldocs
+
+ insinto /usr/share/vdr
+ doins "${CAP_FILE}"
+
+ fowners vdr:vdr "${CONF_DIR}" -R
+}
+
+pkg_postinst() {
+ elog "Please read the /usr/share/doc/${PF}/UPDATE-2.4"
+ elog "for major changes in this version\n"
+
+ elog "It is a good idea to run vdrplugin-rebuild now.\n"
+
+ elog "To get nice symbols in OSD we recommend to install"
+ elog "\t1. emerge media-fonts/vdrsymbols-ttf"
+ elog "\t2. select font VDRSymbolsSans in Setup\n"
+
+ elog "To get an idea how to proceed now, have a look at our vdr-guide:"
+ elog "\thttps://wiki.gentoo.org/wiki/VDR"
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2021-05-06 8:47 Joonas Niilola
0 siblings, 0 replies; 15+ messages in thread
From: Joonas Niilola @ 2021-05-06 8:47 UTC (permalink / raw
To: gentoo-commits
commit: 124a95a62c264394f08d70dc0eb66db06b8c9d04
Author: Martin Dummer <martin.dummer <AT> gmx <DOT> net>
AuthorDate: Wed May 5 22:31:44 2021 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Thu May 6 08:46:42 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=124a95a6
media-video/vdr: add gcc-11 compile fix
vdr defines std:: functions "min" "max" and "swap" as Template, which
collides with gcc-11. Add a patch from upstream which fixes this, and fixes
also compile problems with all media-video/vdr-* plugins using this
functions, too
Closes: https://bugs.gentoo.org/786882
Closes: https://bugs.gentoo.org/787389
Closes: https://bugs.gentoo.org/787236
Closes: https://bugs.gentoo.org/787140
Closes: https://bugs.gentoo.org/786801
Closes: https://bugs.gentoo.org/786795
Closes: https://bugs.gentoo.org/786672
Closes: https://bugs.gentoo.org/786285
Closes: https://bugs.gentoo.org/786258
Closes: https://bugs.gentoo.org/788583
Package-Manager: Portage-3.0.17, Repoman-3.0.2
Signed-off-by: Martin Dummer <martin.dummer <AT> gmx.net>
Closes: https://github.com/gentoo/gentoo/pull/20695
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
media-video/vdr/files/vdr-2.2.0_gcc11.patch | 29 ++
media-video/vdr/files/vdr-2.4.7_gcc11.patch | 314 ++-------------------
media-video/vdr/vdr-2.2.0-r7.ebuild | 302 ++++++++++++++++++++
.../vdr/{vdr-2.4.7.ebuild => vdr-2.4.7-r1.ebuild} | 8 +-
4 files changed, 359 insertions(+), 294 deletions(-)
diff --git a/media-video/vdr/files/vdr-2.2.0_gcc11.patch b/media-video/vdr/files/vdr-2.2.0_gcc11.patch
new file mode 100644
index 00000000000..297cdceabf5
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.2.0_gcc11.patch
@@ -0,0 +1,29 @@
+Fix compile with gcc-11, officially from kls
+
+Signed-off-by: Martin Dummer <martin.dummer@gmx.net>
+
+--- a/tools.h 2021-05-05 21:48:32.382919856 +0200
++++ b/tools.h 2021-05-05 21:53:10.184522278 +0200
+@@ -50,7 +50,10 @@
+ #define CHECK(s) { if ((s) < 0) LOG_ERROR; } // used for 'ioctl()' calls
+ #define FATALERRNO (errno && errno != EAGAIN && errno != EINTR)
+
+-#ifndef __STL_CONFIG_H // in case some plugin needs to use the STL
++// In case some plugin needs to use the STL and gets an error message regarding one
++// of these functions, you can #define DISABLE_TEMPLATES_COLLIDING_WITH_STL before
++// including any VDR header files.
++#if !defined(DISABLE_TEMPLATES_COLLIDING_WITH_STL)
+ template<class T> inline T min(T a, T b) { return a <= b ? a : b; }
+ template<class T> inline T max(T a, T b) { return a >= b ? a : b; }
+ template<class T> inline int sgn(T a) { return a < 0 ? -1 : a > 0 ? 1 : 0; }
+--- a/recording.c 2021-05-05 22:08:23.898974097 +0200
++++ b/recording.c 2021-05-05 22:08:39.323280274 +0200
+@@ -2949,7 +2949,7 @@
+ }
+ // found a non existing file suffix
+ }
+- if (Open() >= 0) {
++ if (Open()) {
+ if (!record && Offset >= 0 && file && file->Seek(Offset, SEEK_SET) != Offset) {
+ LOG_ERROR_STR(fileName);
+ return NULL;
diff --git a/media-video/vdr/files/vdr-2.4.7_gcc11.patch b/media-video/vdr/files/vdr-2.4.7_gcc11.patch
index 866b018b5b7..1e37b2f0010 100644
--- a/media-video/vdr/files/vdr-2.4.7_gcc11.patch
+++ b/media-video/vdr/files/vdr-2.4.7_gcc11.patch
@@ -1,292 +1,26 @@
-https://bugs.gentoo.org/786882
+Fix compile with gcc-11, officially from kls
-compile fix for gcc-11
+Signed-off-by: Martin Dummer <martin.dummer@gmx.net>
-Signed-off-by: Joerg Bornkessel <hd_brummy@gentoo.org> (02 May 2021)
-diff -Naur vdr-2.4.7.orig/channels.c vdr-2.4.7/channels.c
---- vdr-2.4.7.orig/channels.c 2021-05-02 19:34:32.312653108 +0200
-+++ vdr-2.4.7/channels.c 2021-05-02 19:39:19.241653108 +0200
-@@ -11,6 +11,7 @@
- #include <ctype.h>
- #include "device.h"
- #include "libsi/si.h"
-+using namespace std;
-
- // IMPORTANT NOTE: in the 'sscanf()' calls there is a blank after the '%d'
- // format characters in order to allow any number of blanks after a numeric
-diff -Naur vdr-2.4.7.orig/ci.c vdr-2.4.7/ci.c
---- vdr-2.4.7.orig/ci.c 2021-05-02 19:34:32.313653108 +0200
-+++ vdr-2.4.7/ci.c 2021-05-02 19:49:53.216653108 +0200
-@@ -27,6 +27,8 @@
- #include "skins.h"
- #include "tools.h"
-
-+using namespace std;
-+
- // Set these to 'true' for debug output:
- static bool DumpTPDUDataTransfer = false;
- static bool DebugProtocol = false;
-diff -Naur vdr-2.4.7.orig/device.c vdr-2.4.7/device.c
---- vdr-2.4.7.orig/device.c 2021-05-02 19:34:32.313653108 +0200
-+++ vdr-2.4.7/device.c 2021-05-02 19:43:19.071653108 +0200
-@@ -20,6 +20,8 @@
- #include "status.h"
- #include "transfer.h"
-
-+using namespace std;
-+
- // --- cLiveSubtitle ---------------------------------------------------------
-
- class cLiveSubtitle : public cReceiver {
-diff -Naur vdr-2.4.7.orig/diseqc.c vdr-2.4.7/diseqc.c
---- vdr-2.4.7.orig/diseqc.c 2021-05-02 19:34:32.314653108 +0200
-+++ vdr-2.4.7/diseqc.c 2021-05-02 19:50:14.177653108 +0200
-@@ -14,6 +14,8 @@
- #include "sources.h"
- #include "thread.h"
-
-+using namespace std;
-+
- #define ALL_DEVICES (~0) // all bits set to '1'
- #define MAX_DEVICES 32 // each bit in a 32-bit integer represents one device
-
-diff -Naur vdr-2.4.7.orig/dvbdevice.c vdr-2.4.7/dvbdevice.c
---- vdr-2.4.7.orig/dvbdevice.c 2021-05-02 19:34:32.314653108 +0200
-+++ vdr-2.4.7/dvbdevice.c 2021-05-02 19:50:35.634653108 +0200
-@@ -21,6 +21,8 @@
- #include "menuitems.h"
- #include "sourceparams.h"
-
-+using namespace std;
-+
- static int DvbApiVersion = 0x0000; // the version of the DVB driver actually in use (will be determined by the first device created)
-
- #define DVBS_TUNE_TIMEOUT 9000 //ms
-diff -Naur vdr-2.4.7.orig/dvbplayer.c vdr-2.4.7/dvbplayer.c
---- vdr-2.4.7.orig/dvbplayer.c 2021-05-02 19:34:32.314653108 +0200
-+++ vdr-2.4.7/dvbplayer.c 2021-05-02 19:43:47.344653108 +0200
-@@ -15,6 +15,8 @@
- #include "thread.h"
- #include "tools.h"
-
-+using namespace std;
-+
- // --- cPtsIndex -------------------------------------------------------------
-
- #define PTSINDEX_ENTRIES 1024
-diff -Naur vdr-2.4.7.orig/dvbspu.c vdr-2.4.7/dvbspu.c
---- vdr-2.4.7.orig/dvbspu.c 2021-05-02 19:34:32.314653108 +0200
-+++ vdr-2.4.7/dvbspu.c 2021-05-02 19:44:08.952653108 +0200
-@@ -17,6 +17,8 @@
- #include <inttypes.h>
- #include <math.h>
-
-+using namespace std;
-+
- /*
- * cDvbSpubitmap:
- *
-diff -Naur vdr-2.4.7.orig/dvbsubtitle.c vdr-2.4.7/dvbsubtitle.c
---- vdr-2.4.7.orig/dvbsubtitle.c 2021-05-02 19:34:32.315653108 +0200
-+++ vdr-2.4.7/dvbsubtitle.c 2021-05-02 19:44:42.537653108 +0200
-@@ -16,6 +16,8 @@
- #include "device.h"
- #include "libsi/si.h"
-
-+using namespace std;
-+
- #define PAGE_COMPOSITION_SEGMENT 0x10
- #define REGION_COMPOSITION_SEGMENT 0x11
- #define CLUT_DEFINITION_SEGMENT 0x12
-diff -Naur vdr-2.4.7.orig/eit.c vdr-2.4.7/eit.c
---- vdr-2.4.7.orig/eit.c 2021-05-02 19:34:32.315653108 +0200
-+++ vdr-2.4.7/eit.c 2021-05-02 19:45:16.962653108 +0200
-@@ -18,6 +18,8 @@
- #include "libsi/section.h"
- #include "libsi/descriptor.h"
-
-+using namespace std;
-+
- #define VALID_TIME (31536000 * 2) // two years
-
- #define DBGEIT 0
-diff -Naur vdr-2.4.7.orig/font.c vdr-2.4.7/font.c
---- vdr-2.4.7.orig/font.c 2021-05-02 19:34:32.315653108 +0200
-+++ vdr-2.4.7/font.c 2021-05-02 19:51:53.540653108 +0200
-@@ -21,6 +21,8 @@
- #include "osd.h"
- #include "tools.h"
-
-+using namespace std;
-+
- const char *DefaultFontOsd = "Sans Serif:Bold";
- const char *DefaultFontSml = "Sans Serif";
- const char *DefaultFontFix = "Courier:Bold";
-diff -Naur vdr-2.4.7.orig/menu.c vdr-2.4.7/menu.c
---- vdr-2.4.7.orig/menu.c 2021-05-02 19:34:32.317653108 +0200
-+++ vdr-2.4.7/menu.c 2021-05-02 19:45:44.891653108 +0200
-@@ -33,6 +33,8 @@
- #include "transfer.h"
- #include "videodir.h"
-
-+using namespace std;
-+
- #define MAXWAIT4EPGINFO 3 // seconds
- #define MODETIMEOUT 3 // seconds
- #define NEWTIMERLIMIT 120 // seconds until the start time of a new timer created from the Schedule menu,
-diff -Naur vdr-2.4.7.orig/menuitems.c vdr-2.4.7/menuitems.c
---- vdr-2.4.7.orig/menuitems.c 2021-05-02 19:34:32.318653108 +0200
-+++ vdr-2.4.7/menuitems.c 2021-05-02 19:46:02.483653108 +0200
-@@ -17,6 +17,8 @@
- #include "skins.h"
- #include "status.h"
-
-+using namespace std;
-+
- #define AUTO_ADVANCE_TIMEOUT 1500 // ms before auto advance when entering characters via numeric keys
-
- const char *FileNameChars = trNOOP("FileNameChars$ abcdefghijklmnopqrstuvwxyz0123456789-.,#~\\^$[]|()*+?{}/:%@&");
-diff -Naur vdr-2.4.7.orig/mtd.c vdr-2.4.7/mtd.c
---- vdr-2.4.7.orig/mtd.c 2021-05-02 19:34:32.318653108 +0200
-+++ vdr-2.4.7/mtd.c 2021-05-02 19:46:23.355653108 +0200
-@@ -10,6 +10,8 @@
- #include "mtd.h"
- #include "receiver.h"
-
-+using namespace std;
-+
- //#define DEBUG_MTD
- #ifdef DEBUG_MTD
- #define DBGMTD(a...) dsyslog(a)
-diff -Naur vdr-2.4.7.orig/nit.c vdr-2.4.7/nit.c
---- vdr-2.4.7.orig/nit.c 2021-05-02 19:34:32.318653108 +0200
-+++ vdr-2.4.7/nit.c 2021-05-02 19:52:19.012653108 +0200
-@@ -16,6 +16,8 @@
- #include "libsi/descriptor.h"
- #include "tools.h"
-
-+using namespace std;
-+
- #define DVB_SYSTEM_1 0 // see also dvbdevice.c
- #define DVB_SYSTEM_2 1
-
-diff -Naur vdr-2.4.7.orig/osd.c vdr-2.4.7/osd.c
---- vdr-2.4.7.orig/osd.c 2021-05-02 19:34:32.318653108 +0200
-+++ vdr-2.4.7/osd.c 2021-05-02 19:47:12.501653108 +0200
-@@ -16,6 +16,8 @@
- #include "device.h"
- #include "tools.h"
-
-+using namespace std;
-+
- tColor HsvToColor(double H, double S, double V)
- {
- if (S > 0) {
-diff -Naur vdr-2.4.7.orig/osdbase.c vdr-2.4.7/osdbase.c
---- vdr-2.4.7.orig/osdbase.c 2021-05-02 19:34:32.318653108 +0200
-+++ vdr-2.4.7/osdbase.c 2021-05-02 19:46:53.516653108 +0200
-@@ -15,6 +15,8 @@
- #include "remote.h"
- #include "status.h"
-
-+using namespace std;
-+
- // --- cOsdItem --------------------------------------------------------------
-
- cOsdItem::cOsdItem(eOSState State)
-diff -Naur vdr-2.4.7.orig/recording.c vdr-2.4.7/recording.c
---- vdr-2.4.7.orig/recording.c 2021-05-02 19:34:32.323653108 +0200
-+++ vdr-2.4.7/recording.c 2021-05-02 19:47:45.990653108 +0200
-@@ -31,6 +31,8 @@
- #include "tools.h"
- #include "videodir.h"
-
-+using namespace std;
-+
- #define SUMMARYFALLBACK
-
- #define RECEXT ".rec"
-diff -Naur vdr-2.4.7.orig/remux.c vdr-2.4.7/remux.c
---- vdr-2.4.7.orig/remux.c 2021-05-02 19:34:32.323653108 +0200
-+++ vdr-2.4.7/remux.c 2021-05-02 19:48:03.230653108 +0200
-@@ -16,6 +16,8 @@
- #include "shutdown.h"
- #include "tools.h"
-
-+using namespace std;
-+
- // Set these to 'true' for debug output:
- static bool DebugPatPmt = false;
- static bool DebugFrames = false;
-diff -Naur vdr-2.4.7.orig/skinclassic.c vdr-2.4.7/skinclassic.c
---- vdr-2.4.7.orig/skinclassic.c 2021-05-02 19:34:32.324653108 +0200
-+++ vdr-2.4.7/skinclassic.c 2021-05-02 19:48:26.271653108 +0200
-@@ -14,6 +14,8 @@
- #include "themes.h"
- #include "videodir.h"
-
-+using namespace std;
-+
- #define ScrollWidth (Setup.FontOsdSize / 4)
- #define TextFrame (Setup.FontOsdSize / 10)
- #define TextSpacing (Setup.FontOsdSize / 4)
-diff -Naur vdr-2.4.7.orig/skinlcars.c vdr-2.4.7/skinlcars.c
---- vdr-2.4.7.orig/skinlcars.c 2021-05-02 19:34:32.324653108 +0200
-+++ vdr-2.4.7/skinlcars.c 2021-05-02 19:48:46.063653108 +0200
-@@ -63,6 +63,8 @@
- #include "symbols/teletext.xpm"
- #include "symbols/volume.xpm"
-
-+using namespace std;
-+
- #define Gap (Setup.FontOsdSize / 5 & ~1) // must be even
- #define TextFrame (Setup.FontOsdSize / TEXT_ALIGN_BORDER)
- #define TextSpacing (2 * TextFrame)
-diff -Naur vdr-2.4.7.orig/skinsttng.c vdr-2.4.7/skinsttng.c
---- vdr-2.4.7.orig/skinsttng.c 2021-05-02 19:34:32.324653108 +0200
-+++ vdr-2.4.7/skinsttng.c 2021-05-02 19:49:15.256653108 +0200
-@@ -50,6 +50,8 @@
- #include "symbols/teletext.xpm"
- #include "symbols/volume.xpm"
-
-+using namespace std;
-+
- #define Roundness (Setup.FontOsdSize / 2)
- #define Gap (Setup.FontOsdSize / 5)
- #define ScrollWidth (Setup.FontOsdSize / 4)
-diff -Naur vdr-2.4.7.orig/thread.c vdr-2.4.7/thread.c
---- vdr-2.4.7.orig/thread.c 2021-05-02 19:59:16.883653108 +0200
-+++ vdr-2.4.7/thread.c 2021-05-02 20:00:08.879653108 +0200
-@@ -24,6 +24,8 @@
- #include <unistd.h>
- #include "tools.h"
-
-+using namespace std;
-+
- #define ABORT { dsyslog("ABORT!"); cBackTrace::BackTrace(); abort(); }
-
- //#define DEBUG_LOCKING // uncomment this line to activate debug output for locking
-diff -Naur vdr-2.4.7.orig/timers.c vdr-2.4.7/timers.c
---- vdr-2.4.7.orig/timers.c 2021-05-02 19:59:16.883653108 +0200
-+++ vdr-2.4.7/timers.c 2021-05-02 19:59:52.287653108 +0200
-@@ -17,6 +17,8 @@
- #include "status.h"
- #include "svdrp.h"
-
-+using namespace std;
-+
- // IMPORTANT NOTE: in the 'sscanf()' calls there is a blank after the '%d'
- // format characters in order to allow any number of blanks after a numeric
- // value!
-diff -Naur vdr-2.4.7.orig/tools.c vdr-2.4.7/tools.c
---- vdr-2.4.7.orig/tools.c 2021-05-02 20:02:40.535653108 +0200
-+++ vdr-2.4.7/tools.c 2021-05-02 20:03:06.859653108 +0200
-@@ -28,6 +28,8 @@
- #include "i18n.h"
- #include "thread.h"
-
-+using namespace std;
-+
- int SysLogLevel = 3;
-
- #define MAXSYSLOGBUF 256
+--- a/tools.h 2021/01/19 20:38:28 5.3
++++ b/tools.h 2021/05/05 15:16:45
+@@ -53,17 +53,15 @@
+
+ // In case some plugin needs to use the STL and gets an error message regarding one
+ // of these functions, you can #define DISABLE_TEMPLATES_COLLIDING_WITH_STL before
+-// including tools.h.
+-#if !defined(__STL_CONFIG_H) // for old versions of the STL
+-#if !defined(DISABLE_TEMPLATES_COLLIDING_WITH_STL) && !defined(_STL_ALGOBASE_H)
++// including any VDR header files.
++#if !defined(DISABLE_TEMPLATES_COLLIDING_WITH_STL)
+ template<class T> inline T min(T a, T b) { return a <= b ? a : b; }
+ template<class T> inline T max(T a, T b) { return a >= b ? a : b; }
+ #endif
+ template<class T> inline int sgn(T a) { return a < 0 ? -1 : a > 0 ? 1 : 0; }
+-#if !defined(DISABLE_TEMPLATES_COLLIDING_WITH_STL) && !defined(_MOVE_H)
++#if !defined(DISABLE_TEMPLATES_COLLIDING_WITH_STL)
+ template<class T> inline void swap(T &a, T &b) { T t = a; a = b; b = t; }
+ #endif
+-#endif
+
+ template<class T> inline T constrain(T v, T l, T h) { return v < l ? l : v > h ? h : v; }
diff --git a/media-video/vdr/vdr-2.2.0-r7.ebuild b/media-video/vdr/vdr-2.2.0-r7.ebuild
new file mode 100644
index 00000000000..42c9e675b2b
--- /dev/null
+++ b/media-video/vdr/vdr-2.2.0-r7.ebuild
@@ -0,0 +1,302 @@
+# Copyright 2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit flag-o-matic l10n toolchain-funcs
+
+# Switches supported by extensions-patch
+EXT_PATCH_FLAGS="alternatechannel graphtft naludump permashift pinplugin
+ mainmenuhooks menuorg menuselection resumereset ttxtsubs"
+
+# names of the use-flags
+EXT_PATCH_FLAGS_RENAMED=""
+
+# names ext-patch uses internally, here only used for maintainer checks
+EXT_PATCH_FLAGS_RENAMED_EXT_NAME="bidi no_kbd sdnotify"
+
+MY_PV="${PV%_p*}"
+MY_P="${PN}-${MY_PV}"
+S="${WORKDIR}/${MY_P}"
+
+EXT_P="extpng-${P}-gentoo-edition-v1"
+
+DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
+HOMEPAGE="http://www.tvdr.de/"
+SRC_URI="ftp://ftp.tvdr.de/vdr/${MY_P}.tar.bz2
+ mirror://gentoo/${EXT_P}.patch.bz2"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~x86"
+IUSE="bidi debug keyboard html systemd vanilla ${EXT_PATCH_FLAGS} ${EXT_PATCH_FLAGS_RENAMED}"
+
+COMMON_DEPEND="
+ virtual/jpeg:*
+ sys-libs/libcap
+ >=media-libs/fontconfig-2.4.2
+ >=media-libs/freetype-2"
+DEPEND="${COMMON_DEPEND}
+ >=virtual/linuxtv-dvb-headers-5.3"
+RDEPEND="${COMMON_DEPEND}
+ dev-lang/perl
+ >=media-tv/gentoo-vdr-scripts-2.7
+ media-fonts/corefonts
+ bidi? ( dev-libs/fribidi )
+ systemd? ( sys-apps/systemd )"
+BDEPEND="sys-devel/gettext"
+
+CONF_DIR="/etc/vdr"
+CAP_FILE="${S}/capabilities.sh"
+CAPS="# Capabilities of the vdr-executable for use by startscript etc."
+
+pkg_setup() {
+ use debug && append-flags -g
+
+ PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
+
+ tc-export CC CXX AR
+}
+
+add_cap() {
+ local arg
+ for arg; do
+ CAPS="${CAPS}\n${arg}=1"
+ done
+}
+
+enable_patch() {
+ local arg ARG_UPPER
+ for arg; do
+ ARG_UPPER=$(echo $arg | tr '[:lower:]' '[:upper:]')
+ echo "${ARG_UPPER} = 1" >> Make.config || die "cannot write to Make.config"
+
+ # codesnippet to bring the extpng defines into the vdr.pc CXXFLAGS CFLAGS
+ echo "-DUSE_${ARG_UPPER}" >> "${T}"/defines.tmp || die "cannot write to defines.tmp"
+ cat "${T}"/defines.tmp | tr \\\012 ' ' > "${T}"/defines.IUSE || die "cannot write to defines.tmp"
+ export DEFINES_IUSE=$( cat ${T}/defines.IUSE )
+ done
+}
+
+extensions_add_make_conf() {
+ # copy all ifdef for extensions-patch to Make.config
+ sed -e '1,/need to touch the following:/d' \
+ -e '/need to touch the following/,/^$/d' \
+ Make.config.template >> Make.config || die "cannot write to Make.config"
+}
+
+extensions_all_defines() {
+ # extract all possible settings for extensions-patch
+ sed -e '/^#\?[A-Z].*= 1/!d' -e 's/^#\?//' -e 's/ .*//' \
+ Make.config.template \
+ | sort \
+ | tr '[:upper:]' '[:lower:]' || die "error in function extensions_all_defines"
+}
+
+lang_po() {
+ LING_PO=$( ls ${S}/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
+}
+
+src_configure() {
+ # support languages, written from right to left
+ export "BIDI=$(usex bidi 1 0)"
+ # systemd notification support
+ export "SDNOTIFY=$(usex systemd 1 0)"
+ # with/without keyboard
+ export "USE_KBD=$(usex keyboard 1 0)"
+}
+
+src_prepare() {
+ # apply maintenance-patches
+ ebegin "Changing paths for gentoo"
+
+ local DVBDIR="/usr/include"
+ local i
+ for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
+ [[ -d ${i} ]] || continue
+ if [[ -f ${i}/linux/dvb/dmx.h ]]; then
+ einfo "Found DVB header files in ${i}"
+ DVBDIR="${i}"
+ break
+ fi
+ done
+
+ # checking for s2api headers
+ local api_version
+ api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+ api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+
+ if [[ ${api_version:-0} -lt 5*3 ]]; then
+ eerror "DVB header files do not contain s2api support or too old for ${P}"
+ eerror "You cannot compile VDR against old dvb-header"
+ die "DVB headers too old"
+ fi
+
+ cat > Make.config <<-EOT || die "cannot write to Make.config"
+ #
+ # Generated by ebuild ${PF}
+ #
+ PREFIX = /usr
+ DVBDIR = ${DVBDIR}
+ PLUGINLIBDIR = ${PLUGIN_LIBDIR}
+ CONFDIR = ${CONF_DIR}
+ VIDEODIR = /var/vdr/video
+ LOCDIR = \$(PREFIX)/share/locale
+ INCDIR = \$(PREFIX)/include
+
+ DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
+ INCLUDES += -I\$(DVBDIR)
+
+ # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
+ # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
+ LIBDIR = ${PLUGIN_LIBDIR}
+ PCDIR = /usr/$(get_libdir)/pkgconfig
+
+ EOT
+ eend 0
+
+ # wrt bug 586070
+ if has_version ">=sys-apps/systemd-230"; then
+ sed -e "s:libsystemd-daemon:libsystemd:g" -i Makefile || die "sed libsystemd failed"
+ fi
+
+ if ! use vanilla; then
+
+ # Now apply extensions patch
+ eapply "${WORKDIR}/${EXT_P}.patch"
+ sed -e 's/PERMASHIFT_V1/PERMASHIFT/g' -i "${S}"/*.[ch] "${S}"/Make.config* || die "sed failed"
+
+ # This allows us to start even if some plugin does not exist
+ # or is not loadable.
+ enable_patch PLUGINMISSING
+
+ if [[ -n ${VDR_MAINTAINER_MODE} ]]; then
+ einfo "Doing maintainer checks:"
+
+ # we do not support these patches
+ # (or have them already hard enabled)
+ local IGNORE_PATCHES="pluginmissing"
+
+ extensions_all_defines > "${T}"/new.IUSE || die "cannot write to new.IUSE"
+ echo $EXT_PATCH_FLAGS $EXT_PATCH_FLAGS_RENAMED_EXT_NAME \
+ $IGNORE_PATCHES | \
+ tr ' ' '\n' |sort > "${T}"/old.IUSE || die "cannot write to old.IUSE"
+ local DIFFS=$(diff -u "${T}"/old.IUSE "${T}"/new.IUSE|grep '^[+-][^+-]')
+ if [[ -z ${DIFFS} ]]; then
+ einfo "EXT_PATCH_FLAGS are up to date."
+ else
+ ewarn "IUSE differences!"
+ local diff
+ for diff in $DIFFS; do
+ ewarn "$diff"
+ done
+ fi
+ fi
+
+ ebegin "Enabling selected patches"
+ local flag
+ for flag in $EXT_PATCH_FLAGS; do
+ use $flag && enable_patch ${flag}
+ done
+
+ eend 0
+
+ extensions_add_make_conf
+
+ # add defined use-flags compile options to vdr.pc
+ sed -e "s:\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR):\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR) \$(DEFINES_IUSE):" \
+ -i Makefile || die "sed fails on Makefile"
+
+ ebegin "Make depend"
+ emake .dependencies >/dev/null
+ eend $? "make depend failed"
+
+ eapply "${FILESDIR}/${P}_gcc7extpng.patch"
+ eapply "${FILESDIR}/${P}_gcc11.patch"
+ fi
+
+ eapply "${FILESDIR}/${P}_gentoo.patch"
+ eapply "${FILESDIR}/${P}_unsignedtosigned.patch"
+ eapply "${FILESDIR}/${P}_glibc-2.24.patch"
+ eapply "${FILESDIR}/${P}-jpeg-9c.patch"
+ eapply "${FILESDIR}/${P}_glibc-2.31.patch"
+
+ # fix some makefile issues
+ sed -e "s:ifndef NO_KBD:ifeq (\$(USE_KBD),1):" \
+ -e "s:ifdef BIDI:ifeq (\$(BIDI),1):" \
+ -e "s:ifdef SDNOTIFY:ifeq (\$(SDNOTIFY),1):" \
+ -i "${S}"/Makefile || die "sed fails on Makefile"
+
+ eapply_user
+
+ add_cap CAP_UTF8
+
+ add_cap CAP_IRCTRL_RUNTIME_PARAM \
+ CAP_VFAT_RUNTIME_PARAM \
+ CAP_CHUID \
+ CAP_SHUTDOWN_AUTO_RETRY
+
+ echo -e ${CAPS} > "${CAP_FILE}"
+
+ # LINGUAS support
+ einfo "\n \t VDR supports the LINGUAS values"
+
+ lang_po
+
+ einfo "\t Please set one of this values in your sytem make.conf"
+ einfo "\t LINGUAS=\"${LING_PO}\"\n"
+
+ if [[ -z ${LINGUAS} ]]; then
+ einfo "\n \t No values in LINGUAS="
+ einfo "\t You will get only english text on OSD \n"
+ fi
+
+ strip-linguas ${LING_PO} en
+}
+
+src_install() {
+ # trick makefile not to create a videodir by supplying it with an existing
+ # directory
+ emake install \
+ VIDEODIR="/" \
+ DESTDIR="${ED}" install
+
+ keepdir "${PLUGIN_LIBDIR}"
+
+ # backup for plugins they don't be able to create this dir
+ keepdir "${CONF_DIR}"/plugins
+
+ if use html; then
+ local HTML_DOCS=( *.html )
+ fi
+
+ local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS )
+
+ einstalldocs
+
+ insinto /usr/share/vdr
+ doins "${CAP_FILE}"
+
+ if use alternatechannel; then
+ insinto /etc/vdr
+ doins "${FILESDIR}"/channel_alternative.conf
+ fi
+
+ chown -R vdr:vdr "${ED}/${CONF_DIR}" || die "chown failed"
+}
+
+pkg_postinst() {
+
+ elog "\n\t---- 15 YEARS ANNIVERSARY EDITON ----\n"
+ elog "\tA lot of thanks to Klaus Schmidinger"
+ elog "\tfor this nice piece of Software...\n"
+
+ elog "It is a good idea to run vdrplugin-rebuild now."
+
+ elog "To get nice symbols in OSD we recommend to install"
+ elog "\t1. emerge media-fonts/vdrsymbols-ttf"
+ elog "\t2. select font VDRSymbolsSans in Setup"
+ elog ""
+ elog "To get an idea how to proceed now, have a look at our vdr-guide:"
+ elog "\thttps://wiki.gentoo.org/wiki/VDR"
+}
diff --git a/media-video/vdr/vdr-2.4.7.ebuild b/media-video/vdr/vdr-2.4.7-r1.ebuild
similarity index 93%
rename from media-video/vdr/vdr-2.4.7.ebuild
rename to media-video/vdr/vdr-2.4.7-r1.ebuild
index c1f9413c302..8fda32ee217 100644
--- a/media-video/vdr/vdr-2.4.7.ebuild
+++ b/media-video/vdr/vdr-2.4.7-r1.ebuild
@@ -10,10 +10,10 @@ HOMEPAGE="http://www.tvdr.de/"
SRC_URI="http://git.tvdr.de/?p=vdr.git;a=snapshot;h=refs/tags/2.4.7;sf=tbz2 -> ${P}.tbz2
mainmenuhooks? ( http://vdr.websitec.de/download/${PN}/${PN}-2.4.1/${PN}-2.4.1_mainmenuhook-1.0.1.patch.bz2 )
menuorg? ( https://projects.vdr-developer.org/projects/plg-menuorg/repository/revisions/master/raw/vdr-patch/vdr-menuorg-2.3.x.diff )
- naludump? ( http://www.udo-richter.de/vdr/files/vdr-2.1.5-naludump-0.1.diff )
- pinplugin? ( http://vdr.websitec.de/download/${PN}/${P}/${PN}-2.4.6_pinplugin.patch.bz2 )
- ttxtsubs? ( http://vdr.websitec.de/download/${PN}/${P}/${PN}-2.4.6_ttxtsubs_v2.patch.bz2 )
- permashift? ( http://vdr.websitec.de/download/${PN}/${P}/vdr-2.4-patch-for-permashift.diff.bz2 )"
+ naludump? ( https://www.udo-richter.de/vdr/files/vdr-2.1.5-naludump-0.1.diff )
+ pinplugin? ( http://vdr.websitec.de/download/${PN}/vdr-2.4.6/${PN}-2.4.6_pinplugin.patch.bz2 )
+ ttxtsubs? ( http://vdr.websitec.de/download/${PN}/vdr-2.4.6/${PN}-2.4.6_ttxtsubs_v2.patch.bz2 )
+ permashift? ( http://vdr.websitec.de/download/${PN}/vdr-2.4.6/vdr-2.4-patch-for-permashift.diff.bz2 )"
LICENSE="GPL-2+"
SLOT="0"
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2022-07-03 8:57 Joonas Niilola
0 siblings, 0 replies; 15+ messages in thread
From: Joonas Niilola @ 2022-07-03 8:57 UTC (permalink / raw
To: gentoo-commits
commit: 8fb604b710052829970783edc8de32804b2ad7ca
Author: Martin Dummer <martin.dummer <AT> gmx <DOT> net>
AuthorDate: Mon Jun 20 09:38:59 2022 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Sun Jul 3 08:57:54 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8fb604b7
media-video/vdr: version bump to 2.6.1
- new stable release
- rebase most patches for this version
- retirement of http://projects.vdr-developer.org: move some SRC_URI
to github.com/vdr-projects
Package-Manager: Portage-3.0.30, Repoman-3.0.3
Signed-off-by: Martin Dummer <martin.dummer <AT> gmx.net>
Closes: https://github.com/gentoo/gentoo/pull/26000
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
media-video/vdr/Manifest | 2 +
.../vdr/files/vdr-2.4.1_mainmenuhook-1.0.1.patch | 114 ++++
.../vdr/files/vdr-2.6.1-patch-for-permashift.patch | 517 ++++++++++++++++++
media-video/vdr/files/vdr-2.6.1_naludump.patch | 598 +++++++++++++++++++++
media-video/vdr/files/vdr-2.6.1_pinplugin.patch | 447 +++++++++++++++
media-video/vdr/vdr-2.6.1.ebuild | 197 +++++++
6 files changed, 1875 insertions(+)
diff --git a/media-video/vdr/Manifest b/media-video/vdr/Manifest
index 42d12f50673f..b4c6683d67bb 100644
--- a/media-video/vdr/Manifest
+++ b/media-video/vdr/Manifest
@@ -6,4 +6,6 @@ DIST vdr-2.4.1_mainmenuhook-1.0.1.patch.bz2 1463 BLAKE2B 2be3597a273a92d02be0d07
DIST vdr-2.4.6_pinplugin.patch.bz2 5176 BLAKE2B 142ad6551b8e37d223acf86f8c2f511cf2cb3664b5ff968bac5e44420c56bf5fdb974360df574141c424cd7a4b1e1489c4a504207420af10f722a77e6d2bad2f SHA512 d5c7263b908302ebf88a5e5ddcb658f56ee92656b40797fd48af1ff9852454adc1d1672cc97411e7744cc31a56f4d0f51df5ece102c21b2aa25d87e3c3c8fe12
DIST vdr-2.4.6_ttxtsubs_v2.patch.bz2 51971 BLAKE2B e4915314e8f659df1c3e0ff631fd0c3dcec89053ff727fd28400dc6eecc49c1d4743a9bedaf3b11fce03fc6082309d4b4658d00a5b01aa5cbe8686e05412f882 SHA512 14c7b4397ba65e0ff9a5fb0705872f1cb6f1cdd1752b14f83f260540da25b5957632900232f83904c3d4fd6759e537c85bda2cce61455729eab3050a96441548
DIST vdr-2.4.7.tbz2 919632 BLAKE2B be4e1ec365330855e4b2b26f44b1f35dc323e4783e96ef344a67b3e9fe2c0499760ab0f3d27c5e3bdddf5a65ebb65b0c81a62092301d34370aa19d0dd63bb1ab SHA512 41b8453bc6cdbb0db728b5d7d6624ab3ff9034b58ba443a8196f5fcc9fa78d18698cc91905890244e69d482ffc493374e6da2c97baed95fe742b888bdc63e42b
+DIST vdr-2.6.1.tbz2 937103 BLAKE2B d8bbf8cb74f79c328ba7a367cd120d9472be667def851fbdff2f2fda3addbf33ae1f0ab0f20dc0ea6b3a03667e36164a5acf5a17cff8f7934c15f4e61b3a8db2 SHA512 235ffd1654d8f13ba658533bfa5db9c9669e93106a63a770297997f9b8342807f270f26e7a6f5a3c127cd9f760bb94ae77f884dcad42a500615c28e1cf3fd92f
+DIST vdr-2.6.1_ttxtsubs_v2.patch 40549 BLAKE2B 525c05b72fa957372cc1ef91428428f664f42d92eebc06fd0b179afbe99e4ecc4919c69cef000cc15c8340c9a2506d38cbf755fd6665cde1708ce17d4320a35f SHA512 590c43e63818de8be9637cb3b32bf3399b82a181ca151d67e2341232669619020ab78ba9934da3a9c58cdb3bac56fc2a332a5838a92ee0851e42c3707726eb49
DIST vdr-menuorg-2.3.x.diff 8852 BLAKE2B 19b98d51a69f52ecda5500f51ef1741a8397953b20c490055eab0393da5f56ff9598c3e1e8ed8b915f5877e08deeb9ba7a9ef8d9356ad3a1fa12e3778869174a SHA512 7b41c3a529858a4953a57f21619ea01864e140cc1755ee0b03caf1c4de41e80c3f805653502bc8d39d02a4dfcddf720acd4a8c8bd91f4871eef31d86e8e915c0
diff --git a/media-video/vdr/files/vdr-2.4.1_mainmenuhook-1.0.1.patch b/media-video/vdr/files/vdr-2.4.1_mainmenuhook-1.0.1.patch
new file mode 100644
index 000000000000..deec2cd7cfdb
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.4.1_mainmenuhook-1.0.1.patch
@@ -0,0 +1,114 @@
+original https://raw.githubusercontent.com/VDR4Arch/vdr4arch/master/vdr/vdr-MainMenuHooks.patch
+
+rebased for media-video/vdr-2.4.1
+
+Signed-off-by: Joerg Bornkessel <hd_brummy@gentoo.org> ( 2019 Dez 22 )
+diff -Naur vdr-2.4.1.orig/config.h vdr-2.4.1/config.h
+--- vdr-2.4.1.orig/config.h 2019-12-22 00:04:59.000000000 +0100
++++ vdr-2.4.1/config.h 2019-12-22 00:11:25.000000000 +0100
+@@ -36,6 +36,10 @@
+ // plugins to work with newer versions of the core VDR as long as no
+ // VDR header files have changed.
+
++// The MainMenuHook Patch's version number:
++#define MAINMENUHOOKSVERSION "1.0.1"
++#define MAINMENUHOOKSVERSNUM 10001 // Version * 10000 + Major * 100 + Minor
++
+ #define MAXPRIORITY 99
+ #define MINPRIORITY (-MAXPRIORITY)
+ #define LIVEPRIORITY 0 // priority used when selecting a device for live viewing
+diff -Naur vdr-2.4.1.orig/menu.c vdr-2.4.1/menu.c
+--- vdr-2.4.1.orig/menu.c 2019-12-22 00:04:59.000000000 +0100
++++ vdr-2.4.1/menu.c 2019-12-22 00:11:25.000000000 +0100
+@@ -4395,15 +4395,31 @@
+
+ // Initial submenus:
+
++ cOsdObject *menu = NULL;
+ switch (State) {
+- case osSchedule: AddSubMenu(new cMenuSchedule); break;
+- case osChannels: AddSubMenu(new cMenuChannels); break;
+- case osTimers: AddSubMenu(new cMenuTimers); break;
+- case osRecordings: AddSubMenu(new cMenuRecordings(NULL, 0, OpenSubMenus)); break;
+- case osSetup: AddSubMenu(new cMenuSetup); break;
+- case osCommands: AddSubMenu(new cMenuCommands(tr("Commands"), &Commands)); break;
++ case osSchedule:
++ if (!cPluginManager::CallFirstService("MainMenuHooksPatch-v1.0::osSchedule", &menu))
++ menu = new cMenuSchedule;
++ break;
++ case osChannels:
++ if (!cPluginManager::CallFirstService("MainMenuHooksPatch-v1.0::osChannels", &menu))
++ menu = new cMenuChannels;
++ break;
++ case osTimers:
++ if (!cPluginManager::CallFirstService("MainMenuHooksPatch-v1.0::osTimers", &menu))
++ menu = new cMenuTimers;
++ break;
++ case osRecordings:
++ if (!cPluginManager::CallFirstService("MainMenuHooksPatch-v1.0::osRecordings", &menu))
++ menu = new cMenuRecordings(NULL, 0, OpenSubMenus);
++ break;
++ case osSetup: menu = new cMenuSetup; break;
++ case osCommands: menu = new cMenuCommands(tr("Commands"), &Commands); break;
+ default: break;
+ }
++ if (menu)
++ if (menu->IsMenu())
++ AddSubMenu((cOsdMenu *) menu);
+ }
+
+ cOsdObject *cMenuMain::PluginOsdObject(void)
+@@ -4511,13 +4527,34 @@
+ eOSState state = cOsdMenu::ProcessKey(Key);
+ HadSubMenu |= HasSubMenu();
+
++ cOsdObject *menu = NULL;
+ switch (state) {
+- case osSchedule: return AddSubMenu(new cMenuSchedule);
+- case osChannels: return AddSubMenu(new cMenuChannels);
+- case osTimers: return AddSubMenu(new cMenuTimers);
+- case osRecordings: return AddSubMenu(new cMenuRecordings);
+- case osSetup: return AddSubMenu(new cMenuSetup);
+- case osCommands: return AddSubMenu(new cMenuCommands(tr("Commands"), &Commands));
++ case osSchedule:
++ if (!cPluginManager::CallFirstService("MainMenuHooksPatch-v1.0::osSchedule", &menu))
++ menu = new cMenuSchedule;
++ else
++ state = osContinue;
++ break;
++ case osChannels:
++ if (!cPluginManager::CallFirstService("MainMenuHooksPatch-v1.0::osChannels", &menu))
++ menu = new cMenuChannels;
++ else
++ state = osContinue;
++ break;
++ case osTimers:
++ if (!cPluginManager::CallFirstService("MainMenuHooksPatch-v1.0::osTimers", &menu))
++ menu = new cMenuTimers;
++ else
++ state = osContinue;
++ break;
++ case osRecordings:
++ if (!cPluginManager::CallFirstService("MainMenuHooksPatch-v1.0::osRecordings", &menu))
++ menu = new cMenuRecordings;
++ else
++ state = osContinue;
++ break;
++ case osSetup: menu = new cMenuSetup; break;
++ case osCommands: menu = new cMenuCommands(tr("Commands"), &Commands); break;
+ case osStopRecord: if (Interface->Confirm(tr("Stop recording?"))) {
+ if (cOsdItem *item = Get(Current())) {
+ cRecordControls::Stop(item->Text() + strlen(tr(STOP_RECORDING)));
+@@ -4568,6 +4605,12 @@
+ default: break;
+ }
+ }
++ if (menu) {
++ if (menu->IsMenu())
++ return AddSubMenu((cOsdMenu *) menu);
++ pluginOsdObject = menu;
++ return osPlugin;
++ }
+ if (!HasSubMenu() && Update(HadSubMenu))
+ Display();
+ if (Key != kNone) {
diff --git a/media-video/vdr/files/vdr-2.6.1-patch-for-permashift.patch b/media-video/vdr/files/vdr-2.6.1-patch-for-permashift.patch
new file mode 100644
index 000000000000..03b476f986bb
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.6.1-patch-for-permashift.patch
@@ -0,0 +1,517 @@
+Adapted Patch from forum post
+https://www.vdr-portal.de/forum/index.php?thread/134171-permashift-1-0-4-f%C3%BCr-vdr-2-4-betaversion/&postID=1341243#post1341243
+
+SRC Url https://www.vdr-portal.de/index.php?attachment/45632-vdr-2-5-4-patch-for-permashift-diff-gz/ adapted for vdr-2.6.1
+
+Signed-off-by: Martin Dummer <martin.dummer@gmx.net>
+
+diff -Naur vdr-2.6.1.orig/device.c vdr-2.6.1/device.c
+--- vdr-2.6.1.orig/device.c 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/device.c 2022-02-06 18:05:26.452890690 +0100
+@@ -1880,6 +1880,17 @@
+ ReleaseCamSlot();
+ }
+
++cRecorder* cDevice::GetPreRecording(const cChannel *Channel)
++{
++ cMutexLock MutexLock(&mutexReceiver);
++ for (int i = 0; i < MAXRECEIVERS; i++) {
++ if (receiver[i])
++ if (receiver[i]->IsPreRecording(Channel))
++ return (cRecorder*)receiver[i];
++ }
++ return NULL;
++}
++
+ // --- cTSBuffer -------------------------------------------------------------
+
+ cTSBuffer::cTSBuffer(int File, int Size, int DeviceNumber)
+diff -Naur vdr-2.6.1.orig/device.h vdr-2.6.1/device.h
+--- vdr-2.6.1.orig/device.h 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/device.h 2022-02-06 18:05:51.541429884 +0100
+@@ -85,6 +85,7 @@
+
+ class cPlayer;
+ class cReceiver;
++class cRecorder;
+ class cLiveSubtitle;
+
+ class cDeviceHook : public cListObject {
+@@ -854,6 +855,8 @@
+ ///< Returns true if we are currently receiving. The parameter has no meaning (for backwards compatibility only).
+ bool AttachReceiver(cReceiver *Receiver);
+ ///< Attaches the given receiver to this device.
++ cRecorder* GetPreRecording(const cChannel *Channel);
++ ///< Get precocious recording for the channel if there is one.
+ void Detach(cReceiver *Receiver, bool ReleaseCam = true);
+ ///< Detaches the given receiver from this device.
+ ///< If ReleaseCam is true, the CAM slot will be released if it
+diff -Naur vdr-2.6.1.orig/dvbplayer.c vdr-2.6.1/dvbplayer.c
+--- vdr-2.6.1.orig/dvbplayer.c 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/dvbplayer.c 2022-02-06 18:05:26.452890690 +0100
+@@ -249,13 +249,14 @@
+ cUnbufferedFile *replayFile;
+ double framesPerSecond;
+ bool isPesRecording;
+- bool pauseLive;
++ ReplayState replayState;
+ bool eof;
+ bool firstPacket;
+ ePlayModes playMode;
+ ePlayDirs playDir;
+ int trickSpeed;
+ int readIndex;
++ int startIndex;
+ bool readIndependent;
+ cFrame *readFrame;
+ cFrame *playFrame;
+@@ -271,6 +272,8 @@
+ virtual void Action(void);
+ public:
+ cDvbPlayer(const char *FileName, bool PauseLive);
++ cDvbPlayer(const char *FileName, ReplayState newReplayState);
++ void Construct(const char *FileName, ReplayState newReplayState);
+ virtual ~cDvbPlayer();
+ void SetMarks(const cMarks *Marks);
+ bool Active(void) { return cThread::Running(); }
+@@ -297,6 +300,17 @@
+ cDvbPlayer::cDvbPlayer(const char *FileName, bool PauseLive)
+ :cThread("dvbplayer")
+ {
++ Construct(FileName, PauseLive? restPauseLive : restNormal);
++}
++
++cDvbPlayer::cDvbPlayer(const char *FileName, ReplayState newReplayState)
++:cThread("dvbplayer")
++{
++ Construct(FileName, newReplayState);
++}
++
++void cDvbPlayer::Construct(const char *FileName, ReplayState newReplayState)
++{
+ nonBlockingFileReader = NULL;
+ ringBuffer = NULL;
+ marks = NULL;
+@@ -304,7 +318,8 @@
+ cRecording Recording(FileName);
+ framesPerSecond = Recording.FramesPerSecond();
+ isPesRecording = Recording.IsPesRecording();
+- pauseLive = PauseLive;
++ replayState = newReplayState;
++ bool reuse = (replayState == restReusePause || replayState == restReuseRewind);
+ eof = false;
+ firstPacket = true;
+ playMode = pmPlay;
+@@ -323,15 +338,21 @@
+ return;
+ ringBuffer = new cRingBufferFrame(PLAYERBUFSIZE);
+ // Create the index file:
+- index = new cIndexFile(FileName, false, isPesRecording, pauseLive);
++ index = new cIndexFile(FileName, false, isPesRecording, replayState == restPauseLive);
+ if (!index)
+ esyslog("ERROR: can't allocate index");
+ else if (!index->Ok()) {
+ delete index;
+ index = NULL;
+ }
+- else if (PauseLive)
++ else if (reuse)
+ framesPerSecond = cRecording(FileName).FramesPerSecond(); // the fps rate might have changed from the default
++ startIndex = 0;
++ if (replayState == restReuseRewind || replayState == restReusePause) {
++ int Current, Total;
++ GetIndex(Current, Total, false);
++ startIndex = max(Total - 1, 0);
++ }
+ }
+
+ cDvbPlayer::~cDvbPlayer()
+@@ -481,8 +502,21 @@
+ bool CutIn = false;
+ bool AtLastMark = false;
+
+- if (pauseLive)
+- Goto(0, true);
++ if (replayState == restPauseLive) {
++ Goto(0, true);
++ }
++ else if (replayState == restReuseRewind || replayState == restReusePause) {
++ readIndex = startIndex;
++ Goto(readIndex, true);
++ playMode = pmPlay;
++ if (replayState == restReuseRewind) {
++ Backward();
++ }
++ else if (replayState == restReusePause) {
++ Pause();
++ }
++ }
++
+ while (Running()) {
+ if (WaitingForData)
+ WaitingForData = !nonBlockingFileReader->WaitForDataMs(3); // this keeps the CPU load low, but reacts immediately on new data
+@@ -985,6 +1019,11 @@
+ {
+ }
+
++cDvbPlayerControl::cDvbPlayerControl(const char *FileName, ReplayState replayState)
++:cControl(player = new cDvbPlayer(FileName, replayState))
++{
++}
++
+ cDvbPlayerControl::~cDvbPlayerControl()
+ {
+ Stop();
+diff -Naur vdr-2.6.1.orig/dvbplayer.h vdr-2.6.1/dvbplayer.h
+--- vdr-2.6.1.orig/dvbplayer.h 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/dvbplayer.h 2022-02-06 18:05:26.452890690 +0100
+@@ -16,6 +16,14 @@
+
+ class cDvbPlayer;
+
++enum ReplayState
++{
++ restNormal,
++ restPauseLive,
++ restReusePause,
++ restReuseRewind
++};
++
+ class cDvbPlayerControl : public cControl {
+ private:
+ cDvbPlayer *player;
+@@ -25,6 +33,8 @@
+ // If PauseLive is true, special care is taken to make sure the index
+ // file of the recording is long enough to allow the player to display
+ // the first frame in still picture mode.
++ cDvbPlayerControl(const char *FileName, ReplayState replayState);
++ // Sets up a player for the given file. replayState represents the initial state.
+ virtual ~cDvbPlayerControl();
+ void SetMarks(const cMarks *Marks);
+ bool Active(void);
+diff -Naur vdr-2.6.1.orig/menu.c vdr-2.6.1/menu.c
+--- vdr-2.6.1.orig/menu.c 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/menu.c 2022-02-06 18:05:26.452890690 +0100
+@@ -5303,6 +5303,16 @@
+
+ cRecordControl::cRecordControl(cDevice *Device, cTimers *Timers, cTimer *Timer, bool Pause)
+ {
++ Construct(Device, Timers, Timer, Pause, NULL);
++}
++
++cRecordControl::cRecordControl(cDevice *Device, cTimers *Timers, cTimer *Timer, bool Pause, bool* reused)
++{
++ Construct(Device, Timers, Timer, Pause, reused);
++}
++
++void cRecordControl::Construct(cDevice *Device, cTimers *Timers, cTimer *Timer, bool Pause, bool* reused)
++{
+ const char *LastReplayed = cReplayControl::LastReplayed(); // must do this before locking schedules!
+ // Whatever happens here, the timers will be modified in some way...
+ Timers->SetModified();
+@@ -5331,6 +5341,7 @@
+ timer->SetPending(true);
+ timer->SetRecording(true);
+ event = timer->Event();
++ if (reused != NULL) *reused = false;
+
+ if (event || GetEvent())
+ dsyslog("Title: '%s' Subtitle: '%s'", event->Title(), event->ShortText());
+@@ -5360,8 +5371,21 @@
+ if (MakeDirs(fileName, true)) {
+ Recording.WriteInfo(); // we write this *before* attaching the recorder to the device, to make sure the info file is present when the recorder needs to update the fps value!
+ const cChannel *ch = timer->Channel();
+- recorder = new cRecorder(fileName, ch, timer->Priority());
+- if (device->AttachReceiver(recorder)) {
++
++ if (!Timer) {
++ recorder = device->GetPreRecording(ch);
++ if (recorder != NULL) {
++ recorder->ActivatePreRecording(fileName, timer->Priority());
++ if (reused != NULL) *reused = true;
++ }
++ }
++
++ if (recorder == NULL) {
++ recorder = new cRecorder(fileName, ch, timer->Priority());
++ if (!device->AttachReceiver(recorder)) DELETENULL(recorder);
++ }
++
++ if (recorder != NULL) {
+ cStatus::MsgRecording(device, Recording.Name(), Recording.FileName(), true);
+ if (!Timer && !LastReplayed) // an instant recording, maybe from cRecordControls::PauseLiveVideo()
+ cReplayControl::SetRecording(fileName);
+@@ -5371,8 +5395,6 @@
+ Recordings->AddByName(fileName);
+ return;
+ }
+- else
+- DELETENULL(recorder);
+ }
+ else
+ timer->SetDeferred(DEFERTIMER);
+@@ -5452,7 +5474,7 @@
+ cRecordControl *cRecordControls::RecordControls[MAXRECORDCONTROLS] = { NULL };
+ int cRecordControls::state = 0;
+
+-bool cRecordControls::Start(cTimers *Timers, cTimer *Timer, bool Pause)
++bool cRecordControls::Start(cTimers *Timers, cTimer *Timer, bool Pause, bool* reused)
+ {
+ static time_t LastNoDiskSpaceMessage = 0;
+ int FreeMB = 0;
+@@ -5490,7 +5512,7 @@
+ if (!Timer || Timer->Matches()) {
+ for (int i = 0; i < MAXRECORDCONTROLS; i++) {
+ if (!RecordControls[i]) {
+- RecordControls[i] = new cRecordControl(device, Timers, Timer, Pause);
++ RecordControls[i] = new cRecordControl(device, Timers, Timer, Pause, reused);
+ return RecordControls[i]->Process(time(NULL));
+ }
+ }
+@@ -5514,6 +5536,11 @@
+ return Start(Timers, NULL, Pause);
+ }
+
++bool cRecordControls::Start(cTimers *Timers, cTimer *Timer, bool Pause)
++{
++ return Start(Timers, Timer, Pause, NULL);
++}
++
+ void cRecordControls::Stop(const char *InstantId)
+ {
+ LOCK_TIMERS_WRITE;
+@@ -5549,10 +5576,17 @@
+
+ bool cRecordControls::PauseLiveVideo(void)
+ {
++ return PauseLiveVideo(false);
++}
++
++bool cRecordControls::PauseLiveVideo(bool rewind)
++{
+ Skins.Message(mtStatus, tr("Pausing live video..."));
++ bool reused = false;
+ cReplayControl::SetRecording(NULL); // make sure the new cRecordControl will set cReplayControl::LastReplayed()
+- if (Start(true)) {
+- cReplayControl *rc = new cReplayControl(true);
++ LOCK_TIMERS_WRITE;
++ if (Start(Timers, NULL, true, &reused)) {
++ cReplayControl *rc = new cReplayControl(rewind? restReuseRewind : reused? restReusePause : restPauseLive);
+ cControl::Launch(rc);
+ cControl::Attach();
+ Skins.Message(mtStatus, NULL);
+@@ -5695,7 +5729,18 @@
+ cReplayControl::cReplayControl(bool PauseLive)
+ :cDvbPlayerControl(fileName, PauseLive)
+ {
+- cDevice::PrimaryDevice()->SetKeepTracks(PauseLive);
++ Construct(PauseLive? restPauseLive : restNormal);
++}
++
++cReplayControl::cReplayControl(ReplayState replayState)
++:cDvbPlayerControl(fileName, replayState)
++{
++ Construct(replayState);
++}
++
++void cReplayControl::Construct(ReplayState replayState)
++{
++ cDevice::PrimaryDevice()->SetKeepTracks(replayState == restPauseLive);
+ currentReplayControl = this;
+ displayReplay = NULL;
+ marksModified = false;
+diff -Naur vdr-2.6.1.orig/menu.h vdr-2.6.1/menu.h
+--- vdr-2.6.1.orig/menu.h 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/menu.h 2022-02-06 18:05:26.452890690 +0100
+@@ -246,6 +246,8 @@
+ bool GetEvent(void);
+ public:
+ cRecordControl(cDevice *Device, cTimers *Timers, cTimer *Timer = NULL, bool Pause = false);
++ cRecordControl(cDevice *Device, cTimers *Timers, cTimer *Timer, bool Pause, bool* reused);
++ void Construct(cDevice *Device, cTimers *Timers, cTimer *Timer, bool Pause, bool* reused);
+ virtual ~cRecordControl();
+ bool Process(time_t t);
+ cDevice *Device(void) { return device; }
+@@ -261,10 +263,12 @@
+ static int state;
+ public:
+ static bool Start(cTimers *Timers, cTimer *Timer, bool Pause = false);
++ static bool Start(cTimers *Timers, cTimer *Timer, bool Pause, bool* reused);
+ static bool Start(bool Pause = false);
+ static void Stop(const char *InstantId);
+ static void Stop(cTimer *Timer);
+ static bool PauseLiveVideo(void);
++ static bool PauseLiveVideo(bool rewind);
+ static const char *GetInstantId(const char *LastInstantId);
+ static cRecordControl *GetRecordControl(const char *FileName);
+ static cRecordControl *GetRecordControl(const cTimer *Timer);
+@@ -320,6 +324,8 @@
+ void EditTest(void);
+ public:
+ cReplayControl(bool PauseLive = false);
++ cReplayControl(ReplayState replayState);
++ void Construct(ReplayState replayState);
+ virtual ~cReplayControl();
+ void Stop(void);
+ virtual cOsdObject *GetInfo(void);
+diff -Naur vdr-2.6.1.orig/receiver.h vdr-2.6.1/receiver.h
+--- vdr-2.6.1.orig/receiver.h 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/receiver.h 2022-02-06 18:05:26.452890690 +0100
+@@ -85,6 +85,10 @@
+ ///< case the device is needed otherwise, so code that uses a cReceiver
+ ///< should repeatedly check whether it is still attached, and if
+ ///< it isn't, delete it (or take any other appropriate measures).
++ virtual bool IsPreRecording(const cChannel *Channel) { return false; }
++ ///< prerecords given channel; may be turned into a disc recording.
++ virtual bool ActivatePreRecording(const char* fileName, int Priority) { return false; }
++ ///< turn prerecording into a disc recording
+ };
+
+ #endif //__RECEIVER_H
+diff -Naur vdr-2.6.1.orig/recorder.c vdr-2.6.1/recorder.c
+--- vdr-2.6.1.orig/recorder.c 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/recorder.c 2022-02-06 18:05:26.452890690 +0100
+@@ -164,11 +164,25 @@
+ cRecorder::cRecorder(const char *FileName, const cChannel *Channel, int Priority)
+ :cReceiver(Channel, Priority)
+ ,cThread("recording")
++,tsChecker(NULL), frameChecker(NULL), recordingInfo(NULL), ringBuffer(NULL), frameDetector(NULL), fileName(NULL), index(NULL), recordFile(NULL), recordingName(NULL)
+ {
+- tsChecker = new cTsChecker;
+- frameChecker = new cFrameChecker;
++ if (FileName != NULL) {
++ InitializeFile(FileName, Channel);
++ }
++}
++
++void cRecorder::InitializeFile(const char *FileName, const cChannel *Channel)
++{
++ if (tsChecker == NULL) {
++ tsChecker = new cTsChecker;
++ }
++ if (frameChecker == NULL) {
++ frameChecker = new cFrameChecker;
++ }
+ recordingName = strdup(FileName);
+- recordingInfo = new cRecordingInfo(recordingName);
++ if (recordingInfo == NULL) {
++ recordingInfo = new cRecordingInfo(recordingName);
++ }
+ recordingInfo->Read();
+ oldErrors = max(0, recordingInfo->Errors()); // in case this is a re-started recording
+ errors = oldErrors;
+@@ -193,7 +207,9 @@
+ Pid = Channel->Dpid(0);
+ Type = 0x06;
+ }
+- frameDetector = new cFrameDetector(Pid, Type);
++ if (frameDetector == NULL) {
++ frameDetector = new cFrameDetector(Pid, Type);
++ }
+ index = NULL;
+ fileSize = 0;
+ lastDiskSpaceCheck = time(NULL);
+diff -Naur vdr-2.6.1.orig/recorder.h vdr-2.6.1/recorder.h
+--- vdr-2.6.1.orig/recorder.h 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/recorder.h 2022-02-06 18:05:26.452890690 +0100
+@@ -19,8 +19,8 @@
+ class cTsChecker;
+ class cFrameChecker;
+
+-class cRecorder : public cReceiver, cThread {
+-private:
++class cRecorder : public cReceiver, protected cThread {
++protected:
+ cTsChecker *tsChecker;
+ cFrameChecker *frameChecker;
+ cRingBufferLinear *ringBuffer;
+@@ -41,7 +41,6 @@
+ bool RunningLowOnDiskSpace(void);
+ bool NextFile(void);
+ void HandleErrors(bool Force = false);
+-protected:
+ virtual void Activate(bool On);
+ ///< If you override Activate() you need to call Detach() (which is a
+ ///< member of the cReceiver class) from your own destructor in order
+@@ -49,6 +48,9 @@
+ ///< destroyed.
+ virtual void Receive(const uchar *Data, int Length);
+ virtual void Action(void);
++ void InitializeFile(const char *FileName, const cChannel *Channel);
++ ///< Starts recording to file.
++ ///< Called in constructor if file name has been given.
+ public:
+ cRecorder(const char *FileName, const cChannel *Channel, int Priority);
+ ///< Creates a new recorder for the given Channel and
+diff -Naur vdr-2.6.1.orig/ringbuffer.c vdr-2.6.1/ringbuffer.c
+--- vdr-2.6.1.orig/ringbuffer.c 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/ringbuffer.c 2022-02-06 18:05:26.452890690 +0100
+@@ -368,6 +368,25 @@
+ return NULL;
+ }
+
++uchar *cRingBufferLinear::GetRest(int &Count)
++{
++ int Head = head;
++ if (getThreadTid <= 0)
++ getThreadTid = cThread::ThreadId();
++ int rest = Size() - tail;
++ int diff = Head - tail;
++ int cont = (diff >= 0) ? diff : Size() + diff - margin;
++ if (cont > rest)
++ cont = rest;
++ uchar *p = buffer + tail;
++ if (cont > 0) {
++ Count = gotten = cont;
++ return p;
++ }
++ WaitForGet();
++ return NULL;
++}
++
+ void cRingBufferLinear::Del(int Count)
+ {
+ if (Count > gotten) {
+diff -Naur vdr-2.6.1.orig/ringbuffer.h vdr-2.6.1/ringbuffer.h
+--- vdr-2.6.1.orig/ringbuffer.h 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/ringbuffer.h 2022-02-06 18:05:26.452890690 +0100
+@@ -98,6 +98,12 @@
+ ///< The data will remain in the buffer until a call to Del() deletes it.
+ ///< Returns a pointer to the data, and stores the number of bytes
+ ///< actually available in Count. If the returned pointer is NULL, Count has no meaning.
++ uchar *GetRest(int &Count);
++ ///< Gets data from the ring buffer disregarding the margin.
++ ///< Might have to be called several times to get all data.
++ ///< The data will remain in the buffer until a call to Del() deletes it.
++ ///< Returns a pointer to the data, and stores the number of bytes
++ ///< actually available in Count. If the returned pointer is NULL, Count has no meaning.
+ void Del(int Count);
+ ///< Deletes at most Count bytes from the ring buffer.
+ ///< Count must be less or equal to the number that was returned by a previous
+diff -Naur vdr-2.6.1.orig/vdr.c vdr-2.6.1/vdr.c
+--- vdr-2.6.1.orig/vdr.c 2022-02-02 10:56:43.000000000 +0100
++++ vdr-2.6.1/vdr.c 2022-02-06 18:05:26.452890690 +0100
+@@ -1352,13 +1352,22 @@
+ key = kNone;
+ break;
+ // Pausing live video:
++ case kFastRew:
++ {
++ // test if there's a live buffer to rewind into...
++ LOCK_CHANNELS_READ;
++ if (cDevice::ActualDevice()->GetPreRecording(Channels->GetByNumber(cDevice::CurrentChannel())) == NULL) {
++ break;
++ }
++ }
++ // fall through to pause
+ case kPlayPause:
+ case kPause:
+ if (!Control) {
+ DELETE_MENU;
+ if (Setup.PauseKeyHandling) {
+ if (Setup.PauseKeyHandling > 1 || Interface->Confirm(tr("Pause live video?"))) {
+- if (!cRecordControls::PauseLiveVideo())
++ if (!cRecordControls::PauseLiveVideo(int(key) == kFastRew))
+ Skins.QueueMessage(mtError, tr("No free DVB device to record!"));
+ }
+ }
diff --git a/media-video/vdr/files/vdr-2.6.1_naludump.patch b/media-video/vdr/files/vdr-2.6.1_naludump.patch
new file mode 100644
index 000000000000..efea3a1d74f7
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.6.1_naludump.patch
@@ -0,0 +1,598 @@
+diff -a -U 2 -r a/config.c b/config.c
+--- a/config.c
++++ b/config.c
+@@ -469,4 +469,5 @@
+ SplitEditedFiles = 0;
+ DelTimeshiftRec = 0;
++ DumpNaluFill = 0;
+ MinEventTimeout = 30;
+ MinUserInactivity = 300;
+@@ -697,4 +698,5 @@
+ else if (!strcasecmp(Name, "SplitEditedFiles")) SplitEditedFiles = atoi(Value);
+ else if (!strcasecmp(Name, "DelTimeshiftRec")) DelTimeshiftRec = atoi(Value);
++ else if (!strcasecmp(Name, "DumpNaluFill")) DumpNaluFill = atoi(Value);
+ else if (!strcasecmp(Name, "MinEventTimeout")) MinEventTimeout = atoi(Value);
+ else if (!strcasecmp(Name, "MinUserInactivity")) MinUserInactivity = atoi(Value);
+@@ -829,4 +831,5 @@
+ Store("SplitEditedFiles", SplitEditedFiles);
+ Store("DelTimeshiftRec", DelTimeshiftRec);
++ Store("DumpNaluFill", DumpNaluFill);
+ Store("MinEventTimeout", MinEventTimeout);
+ Store("MinUserInactivity", MinUserInactivity);
+diff -a -U 2 -r a/config.h b/config.h
+--- a/config.h
++++ b/config.h
+@@ -341,4 +341,5 @@
+ int SplitEditedFiles;
+ int DelTimeshiftRec;
++ int DumpNaluFill;
+ int MinEventTimeout, MinUserInactivity;
+ time_t NextWakeupTime;
+diff -a -U 2 -r a/menu.c b/menu.c
+--- a/menu.c
++++ b/menu.c
+@@ -4185,4 +4185,5 @@
+ Add(new cMenuEditBoolItem(tr("Setup.Recording$Split edited files"), &data.SplitEditedFiles));
+ Add(new cMenuEditStraItem(tr("Setup.Recording$Delete timeshift recording"),&data.DelTimeshiftRec, 3, delTimeshiftRecTexts));
++ Add(new cMenuEditBoolItem(tr("Setup.Recording$Dump NALU Fill data"), &data.DumpNaluFill));
+ }
+
+diff -a -U 2 -r a/recorder.c b/recorder.c
+--- a/recorder.c
++++ b/recorder.c
+@@ -195,4 +195,12 @@
+ }
+ frameDetector = new cFrameDetector(Pid, Type);
++ if ( Type == 0x1B // MPEG4 video
++ && (Setup.DumpNaluFill ? (strstr(FileName, "NALUKEEP") == NULL) : (strstr(FileName, "NALUDUMP") != NULL))) { // MPEG4
++ isyslog("Starting NALU fill dumper");
++ naluStreamProcessor = new cNaluStreamProcessor();
++ naluStreamProcessor->SetPid(Pid);
++ }
++ else
++ naluStreamProcessor = NULL;
+ index = NULL;
+ fileSize = 0;
+@@ -217,4 +225,10 @@
+ {
+ Detach();
++ if (naluStreamProcessor) {
++ long long int TotalPackets = naluStreamProcessor->GetTotalPackets();
++ long long int DroppedPackets = naluStreamProcessor->GetDroppedPackets();
++ isyslog("NALU fill dumper: %lld of %lld packets dropped, %lli%%", DroppedPackets, TotalPackets, TotalPackets ? DroppedPackets*100/TotalPackets : 0);
++ delete naluStreamProcessor;
++ }
+ delete index;
+ delete fileName;
+@@ -357,10 +371,32 @@
+ t.Set(MAXBROKENTIMEOUT);
+ }
+- if (recordFile->Write(b, Count) < 0) {
+- LOG_ERROR_STR(fileName->Name());
+- break;
++ if (naluStreamProcessor) {
++ naluStreamProcessor->PutBuffer(b, Count);
++ bool Fail = false;
++ while (true) {
++ int OutLength = 0;
++ uchar *OutData = naluStreamProcessor->GetBuffer(OutLength);
++ if (!OutData || OutLength <= 0)
++ break;
++ if (recordFile->Write(OutData, OutLength) < 0) {
++ LOG_ERROR_STR(fileName->Name());
++ Fail = true;
++ break;
++ }
++ HandleErrors();
++ fileSize += OutLength;
++ }
++ if (Fail)
++ break;
++ }
++ else {
++ if (recordFile->Write(b, Count) < 0) {
++ LOG_ERROR_STR(fileName->Name());
++ break;
++ }
++ HandleErrors();
++ fileSize += Count;
+ }
+- HandleErrors();
+- fileSize += Count;
++
+ }
+ }
+diff -a -U 2 -r a/recorder.h b/recorder.h
+--- a/recorder.h
++++ b/recorder.h C2022-01-08 17:51:00.397595525 +0100
+@@ -27,4 +27,5 @@
+ cFrameDetector *frameDetector;
+ cPatPmtGenerator patPmtGenerator;
++ cNaluStreamProcessor *naluStreamProcessor;
+ cFileName *fileName;
+ cRecordingInfo *recordingInfo;
+diff -a -U 2 -r a/remux.c b/remux.c
+--- a/remux.c
++++ b/remux.c
+@@ -357,4 +357,40 @@
+ }
+
++void TsExtendAdaptionField(unsigned char *Packet, int ToLength)
++{
++ // Hint: ExtenAdaptionField(p, TsPayloadOffset(p) - 4) is a null operation
++
++ int Offset = TsPayloadOffset(Packet); // First byte after existing adaption field
++
++ if (ToLength <= 0)
++ {
++ // Remove adaption field
++ Packet[3] = Packet[3] & ~TS_ADAPT_FIELD_EXISTS;
++ return;
++ }
++
++ // Set adaption field present
++ Packet[3] = Packet[3] | TS_ADAPT_FIELD_EXISTS;
++
++ // Set new length of adaption field:
++ Packet[4] = ToLength <= TS_SIZE-4 ? ToLength-1 : TS_SIZE-4-1;
++
++ if (Packet[4] == TS_SIZE-4-1)
++ {
++ // No more payload, remove payload flag
++ Packet[3] = Packet[3] & ~TS_PAYLOAD_EXISTS;
++ }
++
++ int NewPayload = TsPayloadOffset(Packet); // First byte after new adaption field
++
++ // Fill new adaption field
++ if (Offset == 4 && Offset < NewPayload)
++ Offset++; // skip adaptation_field_length
++ if (Offset == 5 && Offset < NewPayload)
++ Packet[Offset++] = 0; // various flags set to 0
++ while (Offset < NewPayload)
++ Packet[Offset++] = 0xff; // stuffing byte
++}
++
+ // --- cPatPmtGenerator ------------------------------------------------------
+
+@@ -1765,2 +1801,343 @@
+ return Processed;
+ }
++
++// --- cNaluDumper ---------------------------------------------------------
++
++cNaluDumper::cNaluDumper()
++{
++ LastContinuityOutput = -1;
++ reset();
++}
++
++void cNaluDumper::reset()
++{
++ LastContinuityInput = -1;
++ ContinuityOffset = 0;
++ PesId = -1;
++ PesOffset = 0;
++ NaluFillState = NALU_NONE;
++ NaluOffset = 0;
++ History = 0xffffffff;
++ DropAllPayload = false;
++}
++
++void cNaluDumper::ProcessPayload(unsigned char *Payload, int size, bool PayloadStart, sPayloadInfo &Info)
++{
++ Info.DropPayloadStartBytes = 0;
++ Info.DropPayloadEndBytes = 0;
++ int LastKeepByte = -1;
++
++ if (PayloadStart)
++ {
++ History = 0xffffffff;
++ PesId = -1;
++ NaluFillState = NALU_NONE;
++ }
++
++ for (int i=0; i<size; i++) {
++ History = (History << 8) | Payload[i];
++
++ PesOffset++;
++ NaluOffset++;
++
++ bool DropByte = false;
++
++ if (History >= 0x00000180 && History <= 0x000001FF)
++ {
++ // Start of PES packet
++ PesId = History & 0xff;
++ PesOffset = 0;
++ NaluFillState = NALU_NONE;
++ }
++ else if (PesId >= 0xe0 && PesId <= 0xef // video stream
++ && History >= 0x00000100 && History <= 0x0000017F) // NALU start code
++ {
++ int NaluId = History & 0xff;
++ NaluOffset = 0;
++ NaluFillState = ((NaluId & 0x1f) == 0x0c) ? NALU_FILL : NALU_NONE;
++ }
++
++ if (PesId >= 0xe0 && PesId <= 0xef // video stream
++ && PesOffset >= 1 && PesOffset <= 2)
++ {
++ Payload[i] = 0; // Zero out PES length field
++ }
++
++ if (NaluFillState == NALU_FILL && NaluOffset > 0) // Within NALU fill data
++ {
++ // We expect a series of 0xff bytes terminated by a single 0x80 byte.
++
++ if (Payload[i] == 0xFF)
++ {
++ DropByte = true;
++ }
++ else if (Payload[i] == 0x80)
++ {
++ NaluFillState = NALU_TERM; // Last byte of NALU fill, next byte sets NaluFillEnd=true
++ DropByte = true;
++ }
++ else // Invalid NALU fill
++ {
++ dsyslog("cNaluDumper: Unexpected NALU fill data: %02x", Payload[i]);
++ NaluFillState = NALU_END;
++ if (LastKeepByte == -1)
++ {
++ // Nalu fill from beginning of packet until last byte
++ // packet start needs to be dropped
++ Info.DropPayloadStartBytes = i;
++ }
++ }
++ }
++ else if (NaluFillState == NALU_TERM) // Within NALU fill data
++ {
++ // We are after the terminating 0x80 byte
++ NaluFillState = NALU_END;
++ if (LastKeepByte == -1)
++ {
++ // Nalu fill from beginning of packet until last byte
++ // packet start needs to be dropped
++ Info.DropPayloadStartBytes = i;
++ }
++ }
++
++ if (!DropByte)
++ LastKeepByte = i; // Last useful byte
++ }
++
++ Info.DropAllPayloadBytes = (LastKeepByte == -1);
++ Info.DropPayloadEndBytes = size-1-LastKeepByte;
++}
++
++bool cNaluDumper::ProcessTSPacket(unsigned char *Packet)
++{
++ bool HasAdaption = TsHasAdaptationField(Packet);
++ bool HasPayload = TsHasPayload(Packet);
++
++ // Check continuity:
++ int ContinuityInput = TsContinuityCounter(Packet);
++ if (LastContinuityInput >= 0)
++ {
++ int NewContinuityInput = HasPayload ? (LastContinuityInput + 1) & TS_CONT_CNT_MASK : LastContinuityInput;
++ int Offset = (NewContinuityInput - ContinuityInput) & TS_CONT_CNT_MASK;
++ if (Offset > 0)
++ dsyslog("cNaluDumper: TS continuity offset %i", Offset);
++ if (Offset > ContinuityOffset)
++ ContinuityOffset = Offset; // max if packets get dropped, otherwise always the current one.
++ }
++ LastContinuityInput = ContinuityInput;
++
++ if (HasPayload) {
++ sPayloadInfo Info;
++ int Offset = TsPayloadOffset(Packet);
++ ProcessPayload(Packet + Offset, TS_SIZE - Offset, TsPayloadStart(Packet), Info);
++
++ if (DropAllPayload && !Info.DropAllPayloadBytes)
++ {
++ // Return from drop packet mode to normal mode
++ DropAllPayload = false;
++
++ // Does the packet start with some remaining NALU fill data?
++ if (Info.DropPayloadStartBytes > 0)
++ {
++ // Add these bytes as stuffing to the adaption field.
++
++ // Sample payload layout:
++ // FF FF FF FF FF 80 00 00 01 xx xx xx xx
++ // ^DropPayloadStartBytes
++
++ TsExtendAdaptionField(Packet, Offset - 4 + Info.DropPayloadStartBytes);
++ }
++ }
++
++ bool DropThisPayload = DropAllPayload;
++
++ if (!DropAllPayload && Info.DropPayloadEndBytes > 0) // Payload ends with 0xff NALU Fill
++ {
++ // Last packet of useful data
++ // Do early termination of NALU fill data
++ Packet[TS_SIZE-1] = 0x80;
++ DropAllPayload = true;
++ // Drop all packets AFTER this one
++
++ // Since we already wrote the 0x80, we have to make sure that
++ // as soon as we stop dropping packets, any beginning NALU fill of next
++ // packet gets dumped. (see DropPayloadStartBytes above)
++ }
++
++ if (DropThisPayload && HasAdaption)
++ {
++ // Drop payload data, but keep adaption field data
++ TsExtendAdaptionField(Packet, TS_SIZE-4);
++ DropThisPayload = false;
++ }
++
++ if (DropThisPayload)
++ {
++ return true; // Drop packet
++ }
++ }
++
++ // Fix Continuity Counter and reproduce incoming offsets:
++ int NewContinuityOutput = TsHasPayload(Packet) ? (LastContinuityOutput + 1) & TS_CONT_CNT_MASK : LastContinuityOutput;
++ NewContinuityOutput = (NewContinuityOutput + ContinuityOffset) & TS_CONT_CNT_MASK;
++ TsSetContinuityCounter(Packet, NewContinuityOutput);
++ LastContinuityOutput = NewContinuityOutput;
++ ContinuityOffset = 0;
++
++ return false; // Keep packet
++}
++
++// --- cNaluStreamProcessor ---------------------------------------------------------
++
++cNaluStreamProcessor::cNaluStreamProcessor()
++{
++ pPatPmtParser = NULL;
++ vpid = -1;
++ data = NULL;
++ length = 0;
++ tempLength = 0;
++ tempLengthAtEnd = false;
++ TotalPackets = 0;
++ DroppedPackets = 0;
++}
++
++void cNaluStreamProcessor::PutBuffer(uchar *Data, int Length)
++{
++ if (length > 0)
++ esyslog("cNaluStreamProcessor::PutBuffer: New data before old data was processed!");
++
++ data = Data;
++ length = Length;
++}
++
++uchar* cNaluStreamProcessor::GetBuffer(int &OutLength)
++{
++ if (length <= 0)
++ {
++ // Need more data - quick exit
++ OutLength = 0;
++ return NULL;
++ }
++ if (tempLength > 0) // Data in temp buffer?
++ {
++ if (tempLengthAtEnd) // Data is at end, copy to beginning
++ {
++ // Overlapping src and dst!
++ for (int i=0; i<tempLength; i++)
++ tempBuffer[i] = tempBuffer[TS_SIZE-tempLength+i];
++ }
++ // Normalize TempBuffer fill
++ if (tempLength < TS_SIZE && length > 0)
++ {
++ int Size = min(TS_SIZE-tempLength, length);
++ memcpy(tempBuffer+tempLength, data, Size);
++ data += Size;
++ length -= Size;
++ tempLength += Size;
++ }
++ if (tempLength < TS_SIZE)
++ {
++ // All incoming data buffered, but need more data
++ tempLengthAtEnd = false;
++ OutLength = 0;
++ return NULL;
++ }
++ // Now: TempLength==TS_SIZE
++ if (tempBuffer[0] != TS_SYNC_BYTE)
++ {
++ // Need to sync on TS within temp buffer
++ int Skipped = 1;
++ while (Skipped < TS_SIZE && (tempBuffer[Skipped] != TS_SYNC_BYTE || (Skipped < length && data[Skipped] != TS_SYNC_BYTE)))
++ Skipped++;
++ esyslog("ERROR: skipped %d bytes to sync on start of TS packet", Skipped);
++ // Pass through skipped bytes
++ tempLengthAtEnd = true;
++ tempLength = TS_SIZE - Skipped; // may be 0, thats ok
++ OutLength = Skipped;
++ return tempBuffer;
++ }
++ // Now: TempBuffer is a TS packet
++ int Pid = TsPid(tempBuffer);
++ if (pPatPmtParser)
++ {
++ if (Pid == 0)
++ pPatPmtParser->ParsePat(tempBuffer, TS_SIZE);
++ else if (pPatPmtParser->IsPmtPid(Pid))
++ pPatPmtParser->ParsePmt(tempBuffer, TS_SIZE);
++ }
++
++ TotalPackets++;
++ bool Drop = false;
++ if (Pid == vpid || (pPatPmtParser && Pid == pPatPmtParser->Vpid() && pPatPmtParser->Vtype() == 0x1B))
++ Drop = NaluDumper.ProcessTSPacket(tempBuffer);
++ if (!Drop)
++ {
++ // Keep this packet, then continue with new data
++ tempLength = 0;
++ OutLength = TS_SIZE;
++ return tempBuffer;
++ }
++ // Drop TempBuffer
++ DroppedPackets++;
++ tempLength = 0;
++ }
++ // Now: TempLength==0, just process data/length
++
++ // Pointer to processed data / length:
++ uchar *Out = data;
++ uchar *OutEnd = Out;
++
++ while (length >= TS_SIZE)
++ {
++ if (data[0] != TS_SYNC_BYTE) {
++ int Skipped = 1;
++ while (Skipped < length && (data[Skipped] != TS_SYNC_BYTE || (length - Skipped > TS_SIZE && data[Skipped + TS_SIZE] != TS_SYNC_BYTE)))
++ Skipped++;
++ esyslog("ERROR: skipped %d bytes to sync on start of TS packet", Skipped);
++
++ // Pass through skipped bytes
++ if (OutEnd != data)
++ memcpy(OutEnd, data, Skipped);
++ OutEnd += Skipped;
++ continue;
++ }
++ // Now: Data starts with complete TS packet
++
++ int Pid = TsPid(data);
++ if (pPatPmtParser)
++ {
++ if (Pid == 0)
++ pPatPmtParser->ParsePat(data, TS_SIZE);
++ else if (pPatPmtParser->IsPmtPid(Pid))
++ pPatPmtParser->ParsePmt(data, TS_SIZE);
++ }
++
++ TotalPackets++;
++ bool Drop = false;
++ if (Pid == vpid || (pPatPmtParser && Pid == pPatPmtParser->Vpid() && pPatPmtParser->Vtype() == 0x1B))
++ Drop = NaluDumper.ProcessTSPacket(data);
++ if (!Drop)
++ {
++ if (OutEnd != data)
++ memcpy(OutEnd, data, TS_SIZE);
++ OutEnd += TS_SIZE;
++ }
++ else
++ {
++ DroppedPackets++;
++ }
++ data += TS_SIZE;
++ length -= TS_SIZE;
++ }
++ // Now: Less than a packet remains.
++ if (length > 0)
++ {
++ // copy remains into temp buffer
++ memcpy(tempBuffer, data, length);
++ tempLength = length;
++ tempLengthAtEnd = false;
++ length = 0;
++ }
++ OutLength = (OutEnd - Out);
++ return OutLength > 0 ? Out : NULL;
++}
+diff -a -U 2 -r a/remux.h b/remux.h
+--- a/remux.h
++++ b/remux.h
+@@ -65,4 +65,9 @@
+ }
+
++inline bool TsSetPayload(const uchar *p)
++{
++ return p[3] & TS_PAYLOAD_EXISTS;
++}
++
+ inline bool TsHasAdaptationField(const uchar *p)
+ {
+@@ -156,4 +161,5 @@
+ void TsSetPts(uchar *p, int l, int64_t Pts);
+ void TsSetDts(uchar *p, int l, int64_t Dts);
++void TsExtendAdaptionField(unsigned char *Packet, int ToLength);
+
+ // Some PES handling tools:
+@@ -550,3 +556,77 @@
+ };
+
++
++#define PATCH_NALUDUMP 100
++
++class cNaluDumper {
++ unsigned int History;
++
++ int LastContinuityInput;
++ int LastContinuityOutput;
++ int ContinuityOffset;
++
++ bool DropAllPayload;
++
++ int PesId;
++ int PesOffset;
++
++ int NaluOffset;
++
++ enum eNaluFillState {
++ NALU_NONE=0, // currently not NALU fill stream
++ NALU_FILL, // Within NALU fill stream, 0xff bytes and NALU start code in byte 0
++ NALU_TERM, // Within NALU fill stream, read 0x80 terminating byte
++ NALU_END // Beyond end of NALU fill stream, expecting 0x00 0x00 0x01 now
++ };
++
++ eNaluFillState NaluFillState;
++
++ struct sPayloadInfo {
++ int DropPayloadStartBytes;
++ int DropPayloadEndBytes;
++ bool DropAllPayloadBytes;
++ };
++
++public:
++ cNaluDumper();
++
++ void reset();
++
++ // Single packet interface:
++ bool ProcessTSPacket(unsigned char *Packet);
++
++private:
++ void ProcessPayload(unsigned char *Payload, int size, bool PayloadStart, sPayloadInfo &Info);
++};
++
++class cNaluStreamProcessor {
++ //Buffer stream interface:
++ int vpid;
++ uchar *data;
++ int length;
++ uchar tempBuffer[TS_SIZE];
++ int tempLength;
++ bool tempLengthAtEnd;
++ cPatPmtParser *pPatPmtParser;
++ cNaluDumper NaluDumper;
++
++ long long int TotalPackets;
++ long long int DroppedPackets;
++public:
++ cNaluStreamProcessor();
++
++ void SetPid(int VPid) { vpid = VPid; }
++ void SetPatPmtParser(cPatPmtParser *_pPatPmtParser) { pPatPmtParser = _pPatPmtParser; }
++ // Set either a PID or set a pointer to an PatPmtParser that will detect _one_ PID
++
++ void PutBuffer(uchar *Data, int Length);
++ // Add new data to be processed. Data must be valid until Get() returns NULL.
++ uchar* GetBuffer(int &OutLength);
++ // Returns filtered data, or NULL/0 to indicate that all data from Put() was processed
++ // or buffered.
++
++ long long int GetTotalPackets() { return TotalPackets; }
++ long long int GetDroppedPackets() { return DroppedPackets; }
++};
++
+ #endif // __REMUX_H
diff --git a/media-video/vdr/files/vdr-2.6.1_pinplugin.patch b/media-video/vdr/files/vdr-2.6.1_pinplugin.patch
new file mode 100644
index 000000000000..2552f9e7109f
--- /dev/null
+++ b/media-video/vdr/files/vdr-2.6.1_pinplugin.patch
@@ -0,0 +1,447 @@
+original vdr-pinplugin_vdr-2.3.1.diff
+rebased for media-video/vdr-2.6.1
+
+Signed-off-by: Christian Kunkel <ch.kunkel@gmx.de> ( 2021 Feb 12 )
+Reviewed-by: Martin Dummer <martin.dummer@gmx.net> ( 2022-06-22 )
+diff -Naur a/Makefile b/Makefile
+--- a/Makefile 2022-02-02 10:56:43.000000000 +0100
++++ b/Makefile 2022-06-20 08:08:11.346956148 +0200
+@@ -351,7 +351,7 @@
+ clean:
+ @$(MAKE) --no-print-directory -C $(LSIDIR) clean
+ @-rm -f $(OBJS) $(DEPFILE) vdr vdr.pc core* *~
+- @-rm -rf $(LOCALEDIR) $(PODIR)/*.mo $(PODIR)/*.pot
++ @-rm -rf $(LOCALEDIR) $(PODIR)/*~ $(PODIR)/*.mo $(PODIR)/*.pot
+ @-rm -rf include
+ @-rm -rf srcdoc
+ CLEAN: clean
+diff -Naur a/device.c b/device.c
+--- a/device.c 2022-02-02 10:56:43.000000000 +0100
++++ b/device.c 2022-06-20 08:08:11.346956148 +0200
+@@ -839,6 +839,7 @@
+ const cChannel *Channel;
+ while ((Channel = Channels->GetByNumber(n, Direction)) != NULL) {
+ // try only channels which are currently available
++ if (!cStatus::MsgChannelProtected(0, Channel)) // PIN PATCH
+ if (GetDevice(Channel, LIVEPRIORITY, true, true))
+ break;
+ n = Channel->Number() + Direction;
+@@ -860,6 +861,12 @@
+
+ eSetChannelResult cDevice::SetChannel(const cChannel *Channel, bool LiveView)
+ {
++ // I hope 'LiveView = false' indicates a channel switch for recording, // PIN PATCH
++ // I really don't know, but it works ... // PIN PATCH
++
++ if (LiveView && cStatus::MsgChannelProtected(this, Channel)) // PIN PATCH
++ return scrNotAvailable; // PIN PATCH
++
+ cMutexLock MutexLock(&mutexChannel); // to avoid a race between SVDRP CHAN and HasProgramme()
+ cStatus::MsgChannelSwitch(this, 0, LiveView);
+
+diff -Naur a/menu.c b/menu.c
+--- a/menu.c 2022-02-02 10:56:43.000000000 +0100
++++ b/menu.c 2022-06-20 08:08:11.346956148 +0200
+@@ -1035,6 +1035,18 @@
+ Add(new cMenuEditBitItem( tr("VPS"), &data.flags, tfVps));
+ Add(new cMenuEditIntItem( tr("Priority"), &data.priority, 0, MAXPRIORITY));
+ Add(new cMenuEditIntItem( tr("Lifetime"), &data.lifetime, 0, MAXLIFETIME));
++
++ // PIN PATCH
++ if (cOsd::pinValid || !data.fskProtection) Add(new cMenuEditBoolItem(tr("Childlock"),&data.fskProtection));
++ else {
++ char* buf = 0;
++ int res = 0;
++ res = asprintf(&buf, "%s\t%s", tr("Childlock"), data.fskProtection ? tr("yes") : tr("no"));
++ if (res < 0) ; // memory problems :o
++ Add(new cOsdItem(buf));
++ free(buf);
++ }
++
+ Add(file = new cMenuEditStrItem( tr("File"), data.file, sizeof(data.file)));
+ SetFirstDayItem();
+ SetPatternItem(true);
+@@ -3130,7 +3142,8 @@
+ }
+ }
+ }
+- if (*Item->Text() && !LastDir) {
++ if (*Item->Text() && !LastDir
++ && (!cStatus::MsgReplayProtected(Item->Recording(), Item->Name(), base, Item->IsDirectory(), true))) { // PIN PATCH
+ Add(Item);
+ LastItem = Item;
+ if (Item->IsDirectory())
+@@ -3201,6 +3214,9 @@
+ {
+ cMenuRecordingItem *ri = (cMenuRecordingItem *)Get(Current());
+ if (ri) {
++ if (cStatus::MsgReplayProtected(ri->Recording(), ri->Name(), base,
++ ri->IsDirectory()) == true) // PIN PATCH
++ return osContinue;
+ if (ri->IsDirectory())
+ Open();
+ else {
+@@ -4506,28 +4522,32 @@
+
+ // Basic menu items:
+
+- Add(new cOsdItem(hk(tr("Schedule")), osSchedule));
+- Add(new cOsdItem(hk(tr("Channels")), osChannels));
+- Add(new cOsdItem(hk(tr("Timers")), osTimers));
+- Add(new cOsdItem(hk(tr("Recordings")), osRecordings));
++ // PIN PATCH
++ if (!cStatus::MsgMenuItemProtected("Schedule", true)) Add(new cOsdItem(hk(tr("Schedule")), osSchedule));
++ if (!cStatus::MsgMenuItemProtected("Channels", true)) Add(new cOsdItem(hk(tr("Channels")), osChannels));
++ if (!cStatus::MsgMenuItemProtected("Timers", true)) Add(new cOsdItem(hk(tr("Timers")), osTimers));
++ if (!cStatus::MsgMenuItemProtected("Recordings", true)) Add(new cOsdItem(hk(tr("Recordings")), osRecordings));
+
+ // Plugins:
+
+ for (int i = 0; ; i++) {
+ cPlugin *p = cPluginManager::GetPlugin(i);
+ if (p) {
++ if (!cStatus::MsgPluginProtected(p, true)) { // PIN PATCH
+ const char *item = p->MainMenuEntry();
+ if (item)
+ Add(new cMenuPluginItem(hk(item), i));
+ }
++ }
+ else
+ break;
+ }
+
+ // More basic menu items:
+
+- Add(new cOsdItem(hk(tr("Setup")), osSetup));
++ if (!cStatus::MsgMenuItemProtected("Setup", true)) Add(new cOsdItem(hk(tr("Setup")), osSetup)); // PIN PATCH
+ if (Commands.Count())
++ if (!cStatus::MsgMenuItemProtected("Commands", true)) // PIN PATCH
+ Add(new cOsdItem(hk(tr("Commands")), osCommands));
+
+ Update(true);
+@@ -4600,6 +4620,14 @@
+ eOSState state = cOsdMenu::ProcessKey(Key);
+ HadSubMenu |= HasSubMenu();
+
++ // > PIN PATCH
++ cOsdItem* item = Get(Current());
++
++ if (item && item->Text() && state != osContinue && state != osUnknown && state != osBack)
++ if (cStatus::MsgMenuItemProtected(item->Text()))
++ return osContinue;
++ // PIN PATCH <
++
+ switch (state) {
+ case osSchedule: return AddSubMenu(new cMenuSchedule);
+ case osChannels: return AddSubMenu(new cMenuChannels);
+@@ -4624,6 +4652,7 @@
+ if (item) {
+ cPlugin *p = cPluginManager::GetPlugin(item->PluginIndex());
+ if (p) {
++ if (!cStatus::MsgPluginProtected(p)) { // PIN PATCH
+ cOsdObject *menu = p->MainMenuAction();
+ if (menu) {
+ if (menu->IsMenu())
+@@ -4635,6 +4664,7 @@
+ }
+ }
+ }
++ }
+ state = osEnd;
+ }
+ break;
+@@ -4814,6 +4844,7 @@
+ Channel = Direction > 0 ? Channels->Next(Channel) : Channels->Prev(Channel);
+ if (!Channel && Setup.ChannelsWrap)
+ Channel = Direction > 0 ? Channels->First() : Channels->Last();
++ if (!cStatus::MsgChannelProtected(0, Channel)) // PIN PATCH
+ if (Channel && !Channel->GroupSep() && cDevice::GetDevice(Channel, LIVEPRIORITY, true, true))
+ return Channel;
+ }
+@@ -5491,6 +5522,7 @@
+ for (int i = 0; i < MAXRECORDCONTROLS; i++) {
+ if (!RecordControls[i]) {
+ RecordControls[i] = new cRecordControl(device, Timers, Timer, Pause);
++ cStatus::MsgRecordingFile(RecordControls[i]->FileName()); // PIN PATCH
+ return RecordControls[i]->Process(time(NULL));
+ }
+ }
+diff -Naur a/osd.c b/osd.c
+--- a/osd.c 2022-02-02 10:56:43.000000000 +0100
++++ b/osd.c 2022-06-20 08:08:11.346956148 +0200
+@@ -1844,6 +1844,7 @@
+ cSize cOsd::maxPixmapSize(INT_MAX, INT_MAX);
+ cVector<cOsd *> cOsd::Osds;
+ cMutex cOsd::mutex;
++bool cOsd::pinValid = false; // PIN PATCH
+
+ cOsd::cOsd(int Left, int Top, uint Level)
+ {
+diff -Naur a/osd.h b/osd.h
+--- a/osd.h 2022-02-02 10:56:43.000000000 +0100
++++ b/osd.h 2022-06-20 08:08:11.346956148 +0200
+@@ -957,6 +957,7 @@
+ ///<
+ ///< If a plugin uses a derived cPixmap implementation, it needs to use that
+ ///< type instead of cPixmapMemory.
++ static bool pinValid; // PIN PATCH
+ };
+
+ #define MAXOSDIMAGES 64
+diff -Naur a/status.c b/status.c
+--- a/status.c 2022-02-02 10:56:43.000000000 +0100
++++ b/status.c 2022-06-20 08:08:11.346956148 +0200
+@@ -136,3 +136,55 @@
+ for (cStatus *sm = statusMonitors.First(); sm; sm = statusMonitors.Next(sm))
+ sm->OsdProgramme(PresentTime, PresentTitle, PresentSubtitle, FollowingTime, FollowingTitle, FollowingSubtitle);
+ }
++
++bool cStatus::MsgChannelProtected(const cDevice* Device, const cChannel* Channel) // PIN PATCH
++{
++ for (cStatus *sm = statusMonitors.First(); sm; sm = statusMonitors.Next(sm))
++ if (sm->ChannelProtected(Device, Channel) == true)
++ return true;
++
++ return false;
++}
++
++bool cStatus::MsgReplayProtected(const cRecording* Recording, const char* Name,
++ const char* Base, bool isDirectory, int menuView) // PIN PATCH
++{
++ for (cStatus *sm = statusMonitors.First(); sm; sm = statusMonitors.Next(sm))
++ if (sm->ReplayProtected(Recording, Name, Base, isDirectory, menuView) == true)
++ return true;
++ return false;
++}
++
++void cStatus::MsgRecordingFile(const char* FileName)
++{
++ for (cStatus *sm = statusMonitors.First(); sm; sm = statusMonitors.Next(sm)) // PIN PATCH
++ sm->RecordingFile(FileName);
++}
++
++void cStatus::MsgTimerCreation(cTimer* Timer, const cEvent *Event)
++{
++ for (cStatus *sm = statusMonitors.First(); sm; sm = statusMonitors.Next(sm)) // PIN PATCH
++ sm->TimerCreation(Timer, Event);
++}
++
++bool cStatus::MsgPluginProtected(cPlugin* Plugin, int menuView) // PIN PATCH
++{
++ for (cStatus *sm = statusMonitors.First(); sm; sm = statusMonitors.Next(sm))
++ if (sm->PluginProtected(Plugin, menuView) == true)
++ return true;
++ return false;
++}
++
++void cStatus::MsgUserAction(const eKeys key) // PIN PATCH
++{
++ for (cStatus *sm = statusMonitors.First(); sm; sm = statusMonitors.Next(sm))
++ sm->UserAction(key);
++}
++
++bool cStatus::MsgMenuItemProtected(const char* Name, int menuView) // PIN PATCH
++{
++ for (cStatus *sm = statusMonitors.First(); sm; sm = statusMonitors.Next(sm))
++ if (sm->MenuItemProtected(Name, menuView) == true)
++ return true;
++ return false;
++}
+diff -Naur a/status.h b/status.h
+--- a/status.h 2022-02-02 10:56:43.000000000 +0100
++++ b/status.h 2022-06-20 08:08:11.350956230 +0200
+@@ -14,6 +14,7 @@
+ #include "device.h"
+ #include "player.h"
+ #include "tools.h"
++#include "plugin.h"
+
+ // Several member functions of the following classes are called with a pointer to
+ // an object from a global list (cTimer, cChannel, cRecording or cEvent). In these
+@@ -99,6 +100,22 @@
+ // The OSD displays the single line Text with the current channel information.
+ virtual void OsdProgramme(time_t PresentTime, const char *PresentTitle, const char *PresentSubtitle, time_t FollowingTime, const char *FollowingTitle, const char *FollowingSubtitle) {}
+ // The OSD displays the given programme information.
++ virtual bool ChannelProtected(const cDevice *Device, const cChannel* Channel) { return false; } // PIN PATCH
++ // Checks if a channel is protected.
++ virtual bool ReplayProtected(const cRecording* Recording, const char* Name,
++ const char* Base, bool isDirectory, int menuView = false) { return false; } // PIN PATCH
++ // Checks if a recording is protected.
++ virtual void RecordingFile(const char* FileName) {} // PIN PATCH
++ // The given DVB device has started recording to FileName. FileName is the name of the
++ // recording directory
++ virtual void TimerCreation(cTimer* Timer, const cEvent *Event) {} // PIN PATCH
++ // The given timer is created
++ virtual bool PluginProtected(cPlugin* Plugin, int menuView = false) { return false; } // PIN PATCH
++ // Checks if a plugin is protected.
++ virtual void UserAction(const eKeys key) {} // PIN PATCH
++ // report user action
++ virtual bool MenuItemProtected(const char* Name, int menuView = false) { return false; } // PIN PATCH
++
+ public:
+ cStatus(void);
+ virtual ~cStatus();
+@@ -122,6 +139,14 @@
+ static void MsgOsdTextItem(const char *Text, bool Scroll = false);
+ static void MsgOsdChannel(const char *Text);
+ static void MsgOsdProgramme(time_t PresentTime, const char *PresentTitle, const char *PresentSubtitle, time_t FollowingTime, const char *FollowingTitle, const char *FollowingSubtitle);
++ static bool MsgChannelProtected(const cDevice* Device, const cChannel* Channel); // PIN PATCH
++ static bool MsgReplayProtected(const cRecording* Recording, const char* Name,
++ const char* Base, bool isDirectory, int menuView = false); // PIN PATCH
++ static void MsgRecordingFile(const char* FileName); // PIN PATCH
++ static void MsgTimerCreation(cTimer* Timer, const cEvent *Event); // PIN PATCH
++ static bool MsgPluginProtected(cPlugin* Plugin, int menuView = false); // PIN PATCH
++ static void MsgUserAction(const eKeys key); // PIN PATCH
++ static bool MsgMenuItemProtected(const char* Name, int menuView = false); // PIN PATCH
+ };
+
+ #endif //__STATUS_H
+diff -Naur a/timers.c b/timers.c
+--- a/timers.c 2022-02-02 10:56:43.000000000 +0100
++++ b/timers.c 2022-06-20 08:14:07.898392829 +0200
+@@ -81,6 +81,7 @@
+ stop -= 2400;
+ priority = Pause ? Setup.PausePriority : Setup.DefaultPriority;
+ lifetime = Pause ? Setup.PauseLifetime : Setup.DefaultLifetime;
++ fskProtection = 0; // PIN PATCH
+ if (Instant && channel)
+ snprintf(file, sizeof(file), "%s%s", Setup.MarkInstantRecord ? "@" : "", *Setup.NameInstantRecord ? Setup.NameInstantRecord : channel->Name());
+ }
+@@ -212,11 +213,13 @@
+ stop -= 2400;
+ priority = PatternTimer ? PatternTimer->Priority() : Setup.DefaultPriority;
+ lifetime = PatternTimer ? PatternTimer->Lifetime() : Setup.DefaultLifetime;
++ fskProtection = 0; // PIN PATCH
+ if (!FileName)
+ FileName = Event->Title();
+ if (!isempty(FileName))
+ Utf8Strn0Cpy(file, FileName, sizeof(file));
+ SetEvent(Event);
++ cStatus::MsgTimerCreation(this, Event); // PIN PATCH
+ }
+
+ cTimer::cTimer(const cTimer &Timer)
+@@ -255,6 +258,7 @@
+ stop = Timer.stop;
+ priority = Timer.priority;
+ lifetime = Timer.lifetime;
++ fskProtection = Timer.fskProtection; // PIN PATCH
+ strncpy(pattern, Timer.pattern, sizeof(pattern));
+ strncpy(file, Timer.file, sizeof(file));
+ free(aux);
+@@ -484,6 +488,7 @@
+ result = false;
+ }
+ }
++ fskProtection = aux && strstr(aux, "<pin-plugin><protected>yes</protected></pin-plugin>"); // PIN PATCH
+ free(channelbuffer);
+ free(daybuffer);
+ free(filebuffer);
+@@ -1037,6 +1042,36 @@
+ Matches(); // refresh start and end time
+ }
+
++void cTimer::SetFskProtection(int aFlag) // PIN PATCH
++{
++ char* p;
++ char* tmp = 0;
++ int res = 0;
++
++ fskProtection = aFlag;
++
++ if (fskProtection && (!aux || !strstr(aux, "<pin-plugin><protected>yes</protected></pin-plugin>")))
++ {
++ // add protection info to aux
++
++ if (aux) { tmp = strdup(aux); free(aux); }
++ res = asprintf(&aux, "%s<pin-plugin><protected>yes</protected></pin-plugin>", tmp ? tmp : "");
++ }
++ else if (!fskProtection && aux && (p = strstr(aux, "<pin-plugin><protected>yes</protected></pin-plugin>")))
++ {
++ // remove protection info from aux
++
++ res = asprintf(&tmp, "%.*s%s", (int)(p-aux), aux, p+strlen("<pin-plugin><protected>yes</protected></pin-plugin>"));
++ free(aux);
++ aux = strdup(tmp);
++ }
++
++ if (res < 0) ; // memory problems :o
++
++ if (tmp)
++ free(tmp);
++}
++
+ // --- cTimers ---------------------------------------------------------------
+
+ cTimers cTimers::timers;
+diff -Naur a/timers.h b/timers.h
+--- a/timers.h 2022-02-02 10:56:43.000000000 +0100
++++ b/timers.h 2022-06-20 08:08:11.350956230 +0200
+@@ -45,6 +45,7 @@
+ int start; ///< the start and stop time of this timer as given by the user,
+ int stop; ///< in the form hhmm, with hh (00..23) and mm (00..59) added as hh*100+mm
+ int priority;
++ int fskProtection; // PIN PATCH
+ int lifetime;
+ mutable char pattern[NAME_MAX * 2 + 1]; // same size as 'file', to be able to initially fill 'pattern' with 'file' in the 'Edit timer' menu
+ mutable char file[NAME_MAX * 2 + 1]; // *2 to be able to hold 'title' and 'episode', which can each be up to 255 characters long
+@@ -70,6 +71,7 @@
+ int Start(void) const { return start; }
+ int Stop(void) const { return stop; }
+ int Priority(void) const { return priority; }
++ int FskProtection(void) const { return fskProtection; } // PIN PATCH
+ int Lifetime(void) const { return lifetime; }
+ const char *Pattern(void) const { return pattern; }
+ const char *File(void) const { return file; }
+@@ -120,6 +122,7 @@
+ void SetRemote(const char *Remote);
+ void SetDeferred(int Seconds);
+ void SetFlags(uint Flags);
++ void SetFskProtection(int aFlag); // PIN PATCH
+ void ClrFlags(uint Flags);
+ void InvFlags(uint Flags);
+ bool HasFlags(uint Flags) const;
+diff -Naur a/vdr.c b/vdr.c
+--- a/vdr.c 2022-02-02 10:56:43.000000000 +0100
++++ b/vdr.c 2022-06-20 08:08:11.350956230 +0200
+@@ -71,6 +71,7 @@
+ #include "tools.h"
+ #include "transfer.h"
+ #include "videodir.h"
++#include "status.h" // PIN PATCH
+
+ #define MINCHANNELWAIT 10 // seconds to wait between failed channel switchings
+ #define ACTIVITYTIMEOUT 60 // seconds before starting housekeeping
+@@ -1210,6 +1211,7 @@
+ if (!Menu)
+ Interact = Control = cControl::Control(ControlMutexLock);
+ if (ISREALKEY(key)) {
++ cStatus::MsgUserAction(key); // PIN PATCH
+ EITScanner.Activity();
+ // Cancel shutdown countdown:
+ if (ShutdownHandler.countdown)
+@@ -1282,10 +1284,12 @@
+ Control->Hide();
+ cPlugin *plugin = cPluginManager::GetPlugin(PluginName);
+ if (plugin) {
++ if (!cStatus::MsgPluginProtected(plugin)) { // PIN PATCH
+ Menu = plugin->MainMenuAction();
+ if (Menu)
+ Menu->Show();
+ }
++ }
+ else
+ esyslog("ERROR: unknown plugin '%s'", PluginName);
+ }
+@@ -1505,9 +1509,11 @@
+ case kPlay:
+ if (cReplayControl::LastReplayed()) {
+ Control = NULL;
++ if (cStatus::MsgReplayProtected(0, cReplayControl::LastReplayed(), 0, false) == false) { // PIN PATCH
+ cControl::Shutdown();
+ cControl::Launch(new cReplayControl);
+ }
++ }
+ else
+ DirectMainFunction(osRecordings); // no last viewed recording, so enter the Recordings menu
+ break;
diff --git a/media-video/vdr/vdr-2.6.1.ebuild b/media-video/vdr/vdr-2.6.1.ebuild
new file mode 100644
index 000000000000..4300433dcc75
--- /dev/null
+++ b/media-video/vdr/vdr-2.6.1.ebuild
@@ -0,0 +1,197 @@
+# Copyright 2021-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit flag-o-matic strip-linguas toolchain-funcs user-info
+
+DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
+HOMEPAGE="http://www.tvdr.de/"
+SRC_URI="http://git.tvdr.de/?p=vdr.git;a=snapshot;h=refs/tags/${PV};sf=tbz2 -> ${P}.tbz2
+ menuorg? ( https://github.com/vdr-projects/vdr-plugin-menuorg/raw/master/vdr-patch/vdr-menuorg-2.3.x.diff )
+ ttxtsubs? ( https://md11.it.cx/download/${PN}/${PN}-2.6.1_ttxtsubs_v2.patch )"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~x86"
+IUSE="bidi debug demoplugins html keyboard mainmenuhooks menuorg naludump permashift pinplugin systemd ttxtsubs verbose"
+
+COMMON_DEPEND="
+ media-libs/fontconfig
+ media-libs/freetype
+ media-libs/libjpeg-turbo
+ sys-libs/libcap"
+DEPEND="${COMMON_DEPEND}
+ >=virtual/linuxtv-dvb-headers-5.3"
+RDEPEND="${COMMON_DEPEND}
+ dev-lang/perl
+ media-tv/gentoo-vdr-scripts
+ media-fonts/corefonts
+ bidi? ( dev-libs/fribidi )
+ systemd? ( sys-apps/systemd )"
+BDEPEND="
+ acct-user/vdr
+ sys-devel/gettext"
+
+REQUIRED_USE="permashift? ( !naludump !pinplugin )"
+
+CONF_DIR="/etc/vdr"
+CAP_FILE="${S}/capabilities.sh"
+CAPS="# Capabilities of the vdr-executable for use by startscript etc."
+
+pkg_setup() {
+ use debug && append-flags -g
+
+ PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
+ VIDEO_DIR="$(egethome vdr)/video"
+
+ tc-export CC CXX AR
+}
+
+add_cap() {
+ local arg
+ for arg; do
+ CAPS="${CAPS}\n${arg}=1"
+ done
+}
+
+lang_po() {
+ LING_PO=$( ls ${S}/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
+}
+
+src_prepare() {
+ # apply maintenance-patches
+ ebegin "Changing paths for gentoo"
+
+ local DVBDIR=/usr/include
+ local i
+ for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
+ [[ -d ${i} ]] || continue
+ if [[ -f ${i}/linux/dvb/dmx.h ]]; then
+ einfo "Found DVB header files in ${i}"
+ DVBDIR=${i}
+ break
+ fi
+ done
+
+ # checking for s2api headers
+ local api_version
+ api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+ api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
+
+ if [[ ${api_version:-0} -lt 5*3 ]]; then
+ eerror "DVB header files do not contain s2api support or too old for ${P}"
+ eerror "You cannot compile VDR against old dvb-header"
+ die "DVB headers too old"
+ fi
+
+ cat > Make.config <<-EOT || die "cannot write to Make.config"
+ #
+ # Generated by ebuild ${PF}
+ #
+ PREFIX = /usr
+ DVBDIR = ${DVBDIR}
+ PLUGINLIBDIR = ${PLUGIN_LIBDIR}
+ CONFDIR = ${CONF_DIR}
+ ARGSDIR = \$(CONFDIR)/conf.d
+ VIDEODIR = ${VIDEO_DIR}
+ LOCDIR = \$(PREFIX)/share/locale
+ INCDIR = \$(PREFIX)/include
+
+ DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
+ INCLUDES += -I\$(DVBDIR)
+
+ # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
+ # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
+ LIBDIR = ${PLUGIN_LIBDIR}
+ PCDIR = /usr/$(get_libdir)/pkgconfig
+
+ EOT
+ eend 0
+
+ eapply "${FILESDIR}/${PN}-2.4.6_gentoo.patch"
+ use demoplugins || eapply "${FILESDIR}/vdr-2.4_remove_plugins.patch"
+ eapply "${FILESDIR}/${PN}-2.4.6_makefile-variables.patch"
+
+ # fix clang/LLVM compile
+ eapply "${FILESDIR}/${PN}-2.4.6_clang.patch"
+
+ use naludump && eapply "${FILESDIR}/${P}_naludump.patch"
+ use permashift && eapply "${FILESDIR}/${P}-patch-for-permashift.patch"
+ use pinplugin && eapply "${FILESDIR}/${P}_pinplugin.patch"
+ use ttxtsubs && eapply "${DISTDIR}/${P}_ttxtsubs_v2.patch"
+ use menuorg && eapply "${DISTDIR}/vdr-menuorg-2.3.x.diff"
+ use mainmenuhooks && eapply "${FILESDIR}/${PN}-2.4.1_mainmenuhook-1.0.1.patch"
+
+ add_cap CAP_UTF8 \
+ CAP_IRCTRL_RUNTIME_PARAM \
+ CAP_VFAT_RUNTIME_PARAM \
+ CAP_CHUID \
+ CAP_SHUTDOWN_AUTO_RETRY
+
+ echo -e ${CAPS} > "${CAP_FILE}" || die "cannot write to CAP_FILE"
+
+ # LINGUAS support
+ einfo "\n \t VDR supports the LINGUAS values"
+
+ lang_po
+
+ einfo "\t Please set one of this values in your sytem make.conf"
+ einfo "\t LINGUAS=\"${LING_PO}\"\n"
+
+ if [[ -z ${LINGUAS} ]]; then
+ einfo "\n \t No values in LINGUAS="
+ einfo "\t You will get only english text on OSD \n"
+ fi
+
+ strip-linguas ${LING_PO} en
+
+ default
+}
+
+src_configure() {
+ # support languages, written from right to left
+ export "BIDI=$(usex bidi 1 0)"
+ # systemd notification support
+ export "SDNOTIFY=$(usex systemd 1 0)"
+ # with/without keyboard
+ export "USE_KBD=$(usex keyboard 1 0)"
+ # detailed compile output for debug
+ export "VERBOSE=$(usex verbose 1 0)"
+}
+
+src_install() {
+ # trick the makefile to not create a VIDEODIR by supplying it with an
+ # existing directory
+ emake VIDEODIR="/" DESTDIR="${ED}" install
+
+ keepdir "${PLUGIN_LIBDIR}"
+
+ # backup for plugins they don't be able to create this dir
+ keepdir "${CONF_DIR}/plugins"
+
+ if use html; then
+ local HTML_DOCS=( *.html )
+ fi
+ local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS UPDATE-2* )
+ einstalldocs
+
+ insinto /usr/share/vdr
+ doins "${CAP_FILE}"
+
+ fowners vdr:vdr "${CONF_DIR}" -R
+}
+
+pkg_postinst() {
+ elog "Please read the /usr/share/doc/${PF}/UPDATE-2.4"
+ elog "for major changes in this version\n"
+
+ elog "It is a good idea to run vdrplugin-rebuild now.\n"
+
+ elog "To get nice symbols in OSD we recommend to install"
+ elog "\t1. emerge media-fonts/vdrsymbols-ttf"
+ elog "\t2. select font VDRSymbolsSans in Setup\n"
+
+ elog "To get an idea how to proceed now, have a look at our vdr-guide:"
+ elog "\thttps://wiki.gentoo.org/wiki/VDR"
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2023-01-09 13:28 Joonas Niilola
0 siblings, 0 replies; 15+ messages in thread
From: Joonas Niilola @ 2023-01-09 13:28 UTC (permalink / raw
To: gentoo-commits
commit: b63c79cb15c1d4289d93608ba3bf78a6ee6ee2a9
Author: Martin Dummer <martin.dummer <AT> gmx <DOT> net>
AuthorDate: Sat Dec 3 21:43:29 2022 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Mon Jan 9 13:26:26 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b63c79cb
media-video/vdr: remove redundant old versions
Signed-off-by: Martin Dummer <martin.dummer <AT> gmx.net>
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
media-video/vdr/Manifest | 6 -
media-video/vdr/files/vdr-2.4.7_gcc11.patch | 26 ---
media-video/vdr/vdr-2.2.0-r6.ebuild | 301 ----------------------------
media-video/vdr/vdr-2.4.7-r1.ebuild | 209 -------------------
4 files changed, 542 deletions(-)
diff --git a/media-video/vdr/Manifest b/media-video/vdr/Manifest
index b4c6683d67bb..655e5797b1c4 100644
--- a/media-video/vdr/Manifest
+++ b/media-video/vdr/Manifest
@@ -1,11 +1,5 @@
DIST extpng-vdr-2.2.0-gentoo-edition-v1.patch.bz2 34664 BLAKE2B 81b68ebe0ef4588c3676f0b7a2c766d8d4d4f754a987b3be5868f3c6eff9158d4cea8e492ca81df535e637dbdc5baff638d1fafb4163e9d9a2d0125aba17e2e1 SHA512 16d6fbb8201f003dfe653b6a49424b794d7e697e27ad6f2383dbe17b76712ea5a3da88a676900b84d75ff7425bf3eb9084d60a89a4598758f482dc1f013f7b3e
-DIST vdr-2.1.5-naludump-0.1.diff 21548 BLAKE2B f193d982d072bbba2261d7dabd82e27795b2e4d8d18ae4486d8c559e7325b87f5902def7bb313e98585331144af62597f6f025f44ca142187e724516bc32c175 SHA512 d9188d5bfcf0588c22dc526fc1082253a1b505b322ccfbe676b8b2c12d4471af7b605924bcea85e879c9606d5e2cecdf6a6e8819cd9b8d877e5bb9f62b91251f
DIST vdr-2.2.0.tar.bz2 922708 BLAKE2B 975e07d6d4c5bd13ee92be5d6a1826d6404b0c59e20fa2e30689b185a61e02d54782ad528e6a4f15e0d36806b30bcf48aa336d63adb3604e78056ff318e0fd2c SHA512 183f58133915c6c0fe8ec2b88becbcb2a36418210e6dcf7931053d3771d727c3581593f9eb5c9693abf39e22e728f7b41c42079cd704610c3636ec05134ea93d
-DIST vdr-2.4-patch-for-permashift.diff.bz2 5298 BLAKE2B ebd00ba1c66783f97f5a6cc757cc9be6d937bd460f46b1880eec8b86ead1a5673a25ab64b733b8030e1c9a94123af28a5d6383905da265c67b2a945ba2c06c33 SHA512 3ba1968d2710061627e2a3b320e24ffeb08be6d8a7e71ed0c6732ebe6ed02d25f3a8afff524a6185ad0025d187ed9c7b259a9fb63dcf0c91e3fd2a079b5ef9d3
-DIST vdr-2.4.1_mainmenuhook-1.0.1.patch.bz2 1463 BLAKE2B 2be3597a273a92d02be0d072e3d74b39275cbbe17d22e570f416d42c46b53f43209498e569142a2cc357e5f7176d2454cb2a86d0822b29cca913eab2ae9cc27f SHA512 9d3eb501fa06ff5b03361ef65c8ddeeba5f37493cc0edc2d4f54e200e48e17607957fa95bd1540f028bc9a98ad6f42b4d38cf79e9ce971de36bed30def108759
-DIST vdr-2.4.6_pinplugin.patch.bz2 5176 BLAKE2B 142ad6551b8e37d223acf86f8c2f511cf2cb3664b5ff968bac5e44420c56bf5fdb974360df574141c424cd7a4b1e1489c4a504207420af10f722a77e6d2bad2f SHA512 d5c7263b908302ebf88a5e5ddcb658f56ee92656b40797fd48af1ff9852454adc1d1672cc97411e7744cc31a56f4d0f51df5ece102c21b2aa25d87e3c3c8fe12
-DIST vdr-2.4.6_ttxtsubs_v2.patch.bz2 51971 BLAKE2B e4915314e8f659df1c3e0ff631fd0c3dcec89053ff727fd28400dc6eecc49c1d4743a9bedaf3b11fce03fc6082309d4b4658d00a5b01aa5cbe8686e05412f882 SHA512 14c7b4397ba65e0ff9a5fb0705872f1cb6f1cdd1752b14f83f260540da25b5957632900232f83904c3d4fd6759e537c85bda2cce61455729eab3050a96441548
-DIST vdr-2.4.7.tbz2 919632 BLAKE2B be4e1ec365330855e4b2b26f44b1f35dc323e4783e96ef344a67b3e9fe2c0499760ab0f3d27c5e3bdddf5a65ebb65b0c81a62092301d34370aa19d0dd63bb1ab SHA512 41b8453bc6cdbb0db728b5d7d6624ab3ff9034b58ba443a8196f5fcc9fa78d18698cc91905890244e69d482ffc493374e6da2c97baed95fe742b888bdc63e42b
DIST vdr-2.6.1.tbz2 937103 BLAKE2B d8bbf8cb74f79c328ba7a367cd120d9472be667def851fbdff2f2fda3addbf33ae1f0ab0f20dc0ea6b3a03667e36164a5acf5a17cff8f7934c15f4e61b3a8db2 SHA512 235ffd1654d8f13ba658533bfa5db9c9669e93106a63a770297997f9b8342807f270f26e7a6f5a3c127cd9f760bb94ae77f884dcad42a500615c28e1cf3fd92f
DIST vdr-2.6.1_ttxtsubs_v2.patch 40549 BLAKE2B 525c05b72fa957372cc1ef91428428f664f42d92eebc06fd0b179afbe99e4ecc4919c69cef000cc15c8340c9a2506d38cbf755fd6665cde1708ce17d4320a35f SHA512 590c43e63818de8be9637cb3b32bf3399b82a181ca151d67e2341232669619020ab78ba9934da3a9c58cdb3bac56fc2a332a5838a92ee0851e42c3707726eb49
DIST vdr-menuorg-2.3.x.diff 8852 BLAKE2B 19b98d51a69f52ecda5500f51ef1741a8397953b20c490055eab0393da5f56ff9598c3e1e8ed8b915f5877e08deeb9ba7a9ef8d9356ad3a1fa12e3778869174a SHA512 7b41c3a529858a4953a57f21619ea01864e140cc1755ee0b03caf1c4de41e80c3f805653502bc8d39d02a4dfcddf720acd4a8c8bd91f4871eef31d86e8e915c0
diff --git a/media-video/vdr/files/vdr-2.4.7_gcc11.patch b/media-video/vdr/files/vdr-2.4.7_gcc11.patch
deleted file mode 100644
index 1e37b2f0010c..000000000000
--- a/media-video/vdr/files/vdr-2.4.7_gcc11.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-Fix compile with gcc-11, officially from kls
-
-Signed-off-by: Martin Dummer <martin.dummer@gmx.net>
-
---- a/tools.h 2021/01/19 20:38:28 5.3
-+++ b/tools.h 2021/05/05 15:16:45
-@@ -53,17 +53,15 @@
-
- // In case some plugin needs to use the STL and gets an error message regarding one
- // of these functions, you can #define DISABLE_TEMPLATES_COLLIDING_WITH_STL before
--// including tools.h.
--#if !defined(__STL_CONFIG_H) // for old versions of the STL
--#if !defined(DISABLE_TEMPLATES_COLLIDING_WITH_STL) && !defined(_STL_ALGOBASE_H)
-+// including any VDR header files.
-+#if !defined(DISABLE_TEMPLATES_COLLIDING_WITH_STL)
- template<class T> inline T min(T a, T b) { return a <= b ? a : b; }
- template<class T> inline T max(T a, T b) { return a >= b ? a : b; }
- #endif
- template<class T> inline int sgn(T a) { return a < 0 ? -1 : a > 0 ? 1 : 0; }
--#if !defined(DISABLE_TEMPLATES_COLLIDING_WITH_STL) && !defined(_MOVE_H)
-+#if !defined(DISABLE_TEMPLATES_COLLIDING_WITH_STL)
- template<class T> inline void swap(T &a, T &b) { T t = a; a = b; b = t; }
- #endif
--#endif
-
- template<class T> inline T constrain(T v, T l, T h) { return v < l ? l : v > h ? h : v; }
diff --git a/media-video/vdr/vdr-2.2.0-r6.ebuild b/media-video/vdr/vdr-2.2.0-r6.ebuild
deleted file mode 100644
index 372355cbe09d..000000000000
--- a/media-video/vdr/vdr-2.2.0-r6.ebuild
+++ /dev/null
@@ -1,301 +0,0 @@
-# Copyright 2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit flag-o-matic strip-linguas toolchain-funcs
-
-# Switches supported by extensions-patch
-EXT_PATCH_FLAGS="alternatechannel graphtft naludump permashift pinplugin
- mainmenuhooks menuorg menuselection resumereset ttxtsubs"
-
-# names of the use-flags
-EXT_PATCH_FLAGS_RENAMED=""
-
-# names ext-patch uses internally, here only used for maintainer checks
-EXT_PATCH_FLAGS_RENAMED_EXT_NAME="bidi no_kbd sdnotify"
-
-MY_PV="${PV%_p*}"
-MY_P="${PN}-${MY_PV}"
-S="${WORKDIR}/${MY_P}"
-
-EXT_P="extpng-${P}-gentoo-edition-v1"
-
-DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
-HOMEPAGE="http://www.tvdr.de/"
-SRC_URI="ftp://ftp.tvdr.de/vdr/${MY_P}.tar.bz2
- mirror://gentoo/${EXT_P}.patch.bz2"
-
-LICENSE="GPL-2+"
-SLOT="0"
-KEYWORDS="amd64 ~arm ~arm64 ~ppc x86"
-IUSE="bidi debug keyboard html systemd vanilla ${EXT_PATCH_FLAGS} ${EXT_PATCH_FLAGS_RENAMED}"
-
-COMMON_DEPEND="
- virtual/jpeg:*
- sys-libs/libcap
- >=media-libs/fontconfig-2.4.2
- >=media-libs/freetype-2"
-DEPEND="${COMMON_DEPEND}
- >=virtual/linuxtv-dvb-headers-5.3"
-RDEPEND="${COMMON_DEPEND}
- dev-lang/perl
- >=media-tv/gentoo-vdr-scripts-2.7
- media-fonts/corefonts
- bidi? ( dev-libs/fribidi )
- systemd? ( sys-apps/systemd )"
-BDEPEND="sys-devel/gettext"
-
-CONF_DIR="/etc/vdr"
-CAP_FILE="${S}/capabilities.sh"
-CAPS="# Capabilities of the vdr-executable for use by startscript etc."
-
-pkg_setup() {
- use debug && append-flags -g
-
- PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
-
- tc-export CC CXX AR
-}
-
-add_cap() {
- local arg
- for arg; do
- CAPS="${CAPS}\n${arg}=1"
- done
-}
-
-enable_patch() {
- local arg ARG_UPPER
- for arg; do
- ARG_UPPER=$(echo $arg | tr '[:lower:]' '[:upper:]')
- echo "${ARG_UPPER} = 1" >> Make.config || die "cannot write to Make.config"
-
- # codesnippet to bring the extpng defines into the vdr.pc CXXFLAGS CFLAGS
- echo "-DUSE_${ARG_UPPER}" >> "${T}"/defines.tmp || die "cannot write to defines.tmp"
- cat "${T}"/defines.tmp | tr \\\012 ' ' > "${T}"/defines.IUSE || die "cannot write to defines.tmp"
- export DEFINES_IUSE=$( cat "${T}"/defines.IUSE )
- done
-}
-
-extensions_add_make_conf() {
- # copy all ifdef for extensions-patch to Make.config
- sed -e '1,/need to touch the following:/d' \
- -e '/need to touch the following/,/^$/d' \
- Make.config.template >> Make.config || die "cannot write to Make.config"
-}
-
-extensions_all_defines() {
- # extract all possible settings for extensions-patch
- sed -e '/^#\?[A-Z].*= 1/!d' -e 's/^#\?//' -e 's/ .*//' \
- Make.config.template \
- | sort \
- | tr '[:upper:]' '[:lower:]' || die "error in function extensions_all_defines"
-}
-
-lang_po() {
- LING_PO=$( ls "${S}"/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
-}
-
-src_configure() {
- # support languages, written from right to left
- export "BIDI=$(usex bidi 1 0)"
- # systemd notification support
- export "SDNOTIFY=$(usex systemd 1 0)"
- # with/without keyboard
- export "USE_KBD=$(usex keyboard 1 0)"
-}
-
-src_prepare() {
- # apply maintenance-patches
- ebegin "Changing paths for gentoo"
-
- local DVBDIR="/usr/include"
- local i
- for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
- [[ -d ${i} ]] || continue
- if [[ -f ${i}/linux/dvb/dmx.h ]]; then
- einfo "Found DVB header files in ${i}"
- DVBDIR="${i}"
- break
- fi
- done
-
- # checking for s2api headers
- local api_version
- api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
- api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
-
- if [[ ${api_version:-0} -lt 5*3 ]]; then
- eerror "DVB header files do not contain s2api support or too old for ${P}"
- eerror "You cannot compile VDR against old dvb-header"
- die "DVB headers too old"
- fi
-
- cat > Make.config <<-EOT || die "cannot write to Make.config"
- #
- # Generated by ebuild ${PF}
- #
- PREFIX = /usr
- DVBDIR = ${DVBDIR}
- PLUGINLIBDIR = ${PLUGIN_LIBDIR}
- CONFDIR = ${CONF_DIR}
- VIDEODIR = /var/vdr/video
- LOCDIR = \$(PREFIX)/share/locale
- INCDIR = \$(PREFIX)/include
-
- DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
- INCLUDES += -I\$(DVBDIR)
-
- # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
- # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
- LIBDIR = ${PLUGIN_LIBDIR}
- PCDIR = /usr/$(get_libdir)/pkgconfig
-
- EOT
- eend 0
-
- # wrt bug 586070
- if has_version ">=sys-apps/systemd-230"; then
- sed -e "s:libsystemd-daemon:libsystemd:g" -i Makefile || die "sed libsystemd failed"
- fi
-
- if ! use vanilla; then
-
- # Now apply extensions patch
- eapply "${WORKDIR}/${EXT_P}.patch"
- sed -e 's/PERMASHIFT_V1/PERMASHIFT/g' -i "${S}"/*.[ch] "${S}"/Make.config* || die "sed failed"
-
- # This allows us to start even if some plugin does not exist
- # or is not loadable.
- enable_patch PLUGINMISSING
-
- if [[ -n ${VDR_MAINTAINER_MODE} ]]; then
- einfo "Doing maintainer checks:"
-
- # we do not support these patches
- # (or have them already hard enabled)
- local IGNORE_PATCHES="pluginmissing"
-
- extensions_all_defines > "${T}"/new.IUSE || die "cannot write to new.IUSE"
- echo $EXT_PATCH_FLAGS $EXT_PATCH_FLAGS_RENAMED_EXT_NAME \
- $IGNORE_PATCHES | \
- tr ' ' '\n' |sort > "${T}"/old.IUSE || die "cannot write to old.IUSE"
- local DIFFS=$(diff -u "${T}"/old.IUSE "${T}"/new.IUSE|grep '^[+-][^+-]')
- if [[ -z ${DIFFS} ]]; then
- einfo "EXT_PATCH_FLAGS are up to date."
- else
- ewarn "IUSE differences!"
- local diff
- for diff in $DIFFS; do
- ewarn "$diff"
- done
- fi
- fi
-
- ebegin "Enabling selected patches"
- local flag
- for flag in $EXT_PATCH_FLAGS; do
- use $flag && enable_patch ${flag}
- done
-
- eend 0
-
- extensions_add_make_conf
-
- # add defined use-flags compile options to vdr.pc
- sed -e "s:\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR):\$(CDEFINES) \$(CINCLUDES) \$(HDRDIR) \$(DEFINES_IUSE):" \
- -i Makefile || die "sed fails on Makefile"
-
- ebegin "Make depend"
- emake .dependencies >/dev/null
- eend $? "make depend failed"
-
- eapply "${FILESDIR}/${P}_gcc7extpng.patch"
- fi
-
- eapply "${FILESDIR}/${P}_gentoo.patch"
- eapply "${FILESDIR}/${P}_unsignedtosigned.patch"
- eapply "${FILESDIR}/${P}_glibc-2.24.patch"
- eapply "${FILESDIR}/${P}-jpeg-9c.patch"
- eapply "${FILESDIR}/${P}_glibc-2.31.patch"
-
- # fix some makefile issues
- sed -e "s:ifndef NO_KBD:ifeq (\$(USE_KBD),1):" \
- -e "s:ifdef BIDI:ifeq (\$(BIDI),1):" \
- -e "s:ifdef SDNOTIFY:ifeq (\$(SDNOTIFY),1):" \
- -i "${S}"/Makefile || die "sed fails on Makefile"
-
- eapply_user
-
- add_cap CAP_UTF8
-
- add_cap CAP_IRCTRL_RUNTIME_PARAM \
- CAP_VFAT_RUNTIME_PARAM \
- CAP_CHUID \
- CAP_SHUTDOWN_AUTO_RETRY
-
- echo -e ${CAPS} > "${CAP_FILE}"
-
- # LINGUAS support
- einfo "\n \t VDR supports the LINGUAS values"
-
- lang_po
-
- einfo "\t Please set one of this values in your sytem make.conf"
- einfo "\t LINGUAS=\"${LING_PO}\"\n"
-
- if [[ -z ${LINGUAS} ]]; then
- einfo "\n \t No values in LINGUAS="
- einfo "\t You will get only english text on OSD \n"
- fi
-
- strip-linguas ${LING_PO} en
-}
-
-src_install() {
- # trick makefile not to create a videodir by supplying it with an existing
- # directory
- emake install \
- VIDEODIR="/" \
- DESTDIR="${ED}" install
-
- keepdir "${PLUGIN_LIBDIR}"
-
- # backup for plugins they don't be able to create this dir
- keepdir "${CONF_DIR}"/plugins
-
- if use html; then
- local HTML_DOCS=( *.html )
- fi
-
- local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS )
-
- einstalldocs
-
- insinto /usr/share/vdr
- doins "${CAP_FILE}"
-
- if use alternatechannel; then
- insinto /etc/vdr
- doins "${FILESDIR}"/channel_alternative.conf
- fi
-
- chown -R vdr:vdr "${ED}/${CONF_DIR}" || die "chown failed"
-}
-
-pkg_postinst() {
-
- elog "\n\t---- 15 YEARS ANNIVERSARY EDITON ----\n"
- elog "\tA lot of thanks to Klaus Schmidinger"
- elog "\tfor this nice piece of Software...\n"
-
- elog "It is a good idea to run vdrplugin-rebuild now."
-
- elog "To get nice symbols in OSD we recommend to install"
- elog "\t1. emerge media-fonts/vdrsymbols-ttf"
- elog "\t2. select font VDRSymbolsSans in Setup"
- elog ""
- elog "To get an idea how to proceed now, have a look at our vdr-guide:"
- elog "\thttps://wiki.gentoo.org/wiki/VDR"
-}
diff --git a/media-video/vdr/vdr-2.4.7-r1.ebuild b/media-video/vdr/vdr-2.4.7-r1.ebuild
deleted file mode 100644
index a7db9e18f489..000000000000
--- a/media-video/vdr/vdr-2.4.7-r1.ebuild
+++ /dev/null
@@ -1,209 +0,0 @@
-# Copyright 2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit flag-o-matic strip-linguas toolchain-funcs
-
-DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
-HOMEPAGE="http://www.tvdr.de/"
-SRC_URI="http://git.tvdr.de/?p=vdr.git;a=snapshot;h=refs/tags/${PV};sf=tbz2 -> ${P}.tbz2
- mainmenuhooks? ( http://vdr.websitec.de/download/${PN}/${PN}-2.4.1/${PN}-2.4.1_mainmenuhook-1.0.1.patch.bz2 )
- menuorg? ( https://projects.vdr-developer.org/projects/plg-menuorg/repository/revisions/master/raw/vdr-patch/vdr-menuorg-2.3.x.diff )
- naludump? ( https://www.udo-richter.de/vdr/files/vdr-2.1.5-naludump-0.1.diff )
- pinplugin? ( http://vdr.websitec.de/download/${PN}/vdr-2.4.6/${PN}-2.4.6_pinplugin.patch.bz2 )
- ttxtsubs? ( http://vdr.websitec.de/download/${PN}/vdr-2.4.6/${PN}-2.4.6_ttxtsubs_v2.patch.bz2 )
- permashift? ( http://vdr.websitec.de/download/${PN}/vdr-2.4.6/vdr-2.4-patch-for-permashift.diff.bz2 )"
-
-LICENSE="GPL-2+"
-SLOT="0"
-KEYWORDS="amd64 ~arm ~arm64 ~ppc x86"
-IUSE="bidi debug demoplugins html keyboard mainmenuhooks menuorg naludump permashift pinplugin systemd ttxtsubs verbose"
-
-COMMON_DEPEND="
- virtual/jpeg:*
- sys-libs/libcap
- >=media-libs/fontconfig-2.4.2
- >=media-libs/freetype-2"
-DEPEND="${COMMON_DEPEND}
- >=virtual/linuxtv-dvb-headers-5.3"
-RDEPEND="${COMMON_DEPEND}
- dev-lang/perl
- media-tv/gentoo-vdr-scripts
- media-fonts/corefonts
- bidi? ( dev-libs/fribidi )
- systemd? ( sys-apps/systemd )"
-BDEPEND="sys-devel/gettext"
-
-REQUIRED_USE="pinplugin? ( !mainmenuhooks )
- permashift? ( !naludump !pinplugin )"
-
-CONF_DIR="/etc/vdr"
-CAP_FILE="${S}/capabilities.sh"
-CAPS="# Capabilities of the vdr-executable for use by startscript etc."
-
-pkg_setup() {
- use debug && append-flags -g
-
- PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
-
- # use the corrected DIR /var/lib/vdr/* for acct/{user,group) handling
- if has_version ">=media-tv/gentoo-vdr-scripts-3.0_rc1"; then
- VIDEO_DIR="/var/lib/vdr/video"
- else
- VIDEO_DIR="/var/vdr/video"
- fi
-
- tc-export CC CXX AR
-}
-
-add_cap() {
- local arg
- for arg; do
- CAPS="${CAPS}\n${arg}=1"
- done
-}
-
-lang_po() {
- LING_PO=$( ls "${S}"/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
-}
-
-src_configure() {
- # support languages, written from right to left
- export "BIDI=$(usex bidi 1 0)"
- # systemd notification support
- export "SDNOTIFY=$(usex systemd 1 0)"
- # with/without keyboard
- export "USE_KBD=$(usex keyboard 1 0)"
- # detailed compile output for debug
- export "VERBOSE=$(usex verbose 1 0)"
-}
-
-src_prepare() {
- # apply maintenance-patches
- ebegin "Changing paths for gentoo"
-
- local DVBDIR=/usr/include
- local i
- for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
- [[ -d ${i} ]] || continue
- if [[ -f ${i}/linux/dvb/dmx.h ]]; then
- einfo "Found DVB header files in ${i}"
- DVBDIR=${i}
- break
- fi
- done
-
- # checking for s2api headers
- local api_version
- api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
- api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
-
- if [[ ${api_version:-0} -lt 5*3 ]]; then
- eerror "DVB header files do not contain s2api support or too old for ${P}"
- eerror "You cannot compile VDR against old dvb-header"
- die "DVB headers too old"
- fi
-
- cat > Make.config <<-EOT || die "cannot write to Make.config"
- #
- # Generated by ebuild ${PF}
- #
- PREFIX = /usr
- DVBDIR = ${DVBDIR}
- PLUGINLIBDIR = ${PLUGIN_LIBDIR}
- CONFDIR = ${CONF_DIR}
- ARGSDIR = \$(CONFDIR)/conf.d
- VIDEODIR = ${VIDEO_DIR}
- LOCDIR = \$(PREFIX)/share/locale
- INCDIR = \$(PREFIX)/include
-
- DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
- INCLUDES += -I\$(DVBDIR)
-
- # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
- # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
- LIBDIR = ${PLUGIN_LIBDIR}
- PCDIR = /usr/$(get_libdir)/pkgconfig
-
- EOT
- eend 0
-
- eapply "${FILESDIR}/${PN}-2.4.6_gentoo.patch"
- use demoplugins || eapply "${FILESDIR}/vdr-2.4_remove_plugins.patch"
- eapply "${FILESDIR}/${PN}-2.4.6_makefile-variables.patch"
-
- # fix clang/LLVM compile
- eapply "${FILESDIR}/${PN}-2.4.6_clang.patch"
-
- # fix gcc-11 compile
- eapply "${FILESDIR}/${P}_gcc11.patch"
-
- use naludump && eapply "${DISTDIR}/${PN}-2.1.5-naludump-0.1.diff"
- use permashift && eapply "${WORKDIR}/${PN}-2.4-patch-for-permashift.diff"
- use pinplugin && eapply "${WORKDIR}/${PN}-2.4.6_pinplugin.patch"
- use ttxtsubs && eapply "${WORKDIR}/${PN}-2.4.6_ttxtsubs_v2.patch"
- use menuorg && eapply "${DISTDIR}/vdr-menuorg-2.3.x.diff"
- use mainmenuhooks && eapply "${WORKDIR}/${PN}-2.4.1_mainmenuhook-1.0.1.patch"
-
- add_cap CAP_UTF8 \
- CAP_IRCTRL_RUNTIME_PARAM \
- CAP_VFAT_RUNTIME_PARAM \
- CAP_CHUID \
- CAP_SHUTDOWN_AUTO_RETRY
-
- echo -e ${CAPS} > "${CAP_FILE}" || die "cannot write to CAP_FILE"
-
- # LINGUAS support
- einfo "\n \t VDR supports the LINGUAS values"
-
- lang_po
-
- einfo "\t Please set one of this values in your sytem make.conf"
- einfo "\t LINGUAS=\"${LING_PO}\"\n"
-
- if [[ -z ${LINGUAS} ]]; then
- einfo "\n \t No values in LINGUAS="
- einfo "\t You will get only english text on OSD \n"
- fi
-
- strip-linguas ${LING_PO} en
-
- default
-}
-
-src_install() {
- # trick the makefile to not create a VIDEODIR by supplying it with an
- # existing directory
- emake VIDEODIR="/" DESTDIR="${ED}" install
-
- keepdir "${PLUGIN_LIBDIR}"
-
- # backup for plugins they don't be able to create this dir
- keepdir "${CONF_DIR}/plugins"
-
- if use html; then
- local HTML_DOCS=( *.html )
- fi
- local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS UPDATE-2* )
- einstalldocs
-
- insinto /usr/share/vdr
- doins "${CAP_FILE}"
-
- fowners vdr:vdr "${CONF_DIR}" -R
-}
-
-pkg_postinst() {
- elog "Please read the /usr/share/doc/${PF}/UPDATE-2.4"
- elog "for major changes in this version\n"
-
- elog "It is a good idea to run vdrplugin-rebuild now.\n"
-
- elog "To get nice symbols in OSD we recommend to install"
- elog "\t1. emerge media-fonts/vdrsymbols-ttf"
- elog "\t2. select font VDRSymbolsSans in Setup\n"
-
- elog "To get an idea how to proceed now, have a look at our vdr-guide:"
- elog "\thttps://wiki.gentoo.org/wiki/VDR"
-}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/
@ 2024-06-01 21:34 Florian Schmaus
0 siblings, 0 replies; 15+ messages in thread
From: Florian Schmaus @ 2024-06-01 21:34 UTC (permalink / raw
To: gentoo-commits
commit: 414d47fcc592694c79ff74520fb221e45468bf1c
Author: Martin Dummer <martin.dummer <AT> gmx <DOT> net>
AuthorDate: Sat Jun 1 17:59:38 2024 +0000
Commit: Florian Schmaus <flow <AT> gentoo <DOT> org>
CommitDate: Sat Jun 1 21:33:39 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=414d47fc
media-video/vdr: drop 2.6.4
Signed-off-by: Martin Dummer <martin.dummer <AT> gmx.net>
Signed-off-by: Florian Schmaus <flow <AT> gentoo.org>
media-video/vdr/Manifest | 2 -
media-video/vdr/files/vdr-2.4.6_gentoo.patch | 66 ---------
media-video/vdr/vdr-2.6.4.ebuild | 199 ---------------------------
3 files changed, 267 deletions(-)
diff --git a/media-video/vdr/Manifest b/media-video/vdr/Manifest
index bddcc07e66bd..555b931f72c5 100644
--- a/media-video/vdr/Manifest
+++ b/media-video/vdr/Manifest
@@ -1,7 +1,5 @@
DIST extpng-vdr-2.2.0-gentoo-edition-v1.patch.bz2 34664 BLAKE2B 81b68ebe0ef4588c3676f0b7a2c766d8d4d4f754a987b3be5868f3c6eff9158d4cea8e492ca81df535e637dbdc5baff638d1fafb4163e9d9a2d0125aba17e2e1 SHA512 16d6fbb8201f003dfe653b6a49424b794d7e697e27ad6f2383dbe17b76712ea5a3da88a676900b84d75ff7425bf3eb9084d60a89a4598758f482dc1f013f7b3e
DIST vdr-2.2.0.tar.bz2 922708 BLAKE2B 975e07d6d4c5bd13ee92be5d6a1826d6404b0c59e20fa2e30689b185a61e02d54782ad528e6a4f15e0d36806b30bcf48aa336d63adb3604e78056ff318e0fd2c SHA512 183f58133915c6c0fe8ec2b88becbcb2a36418210e6dcf7931053d3771d727c3581593f9eb5c9693abf39e22e728f7b41c42079cd704610c3636ec05134ea93d
-DIST vdr-2.6.4.tbz2 944257 BLAKE2B 09f2867d84ad6ee722e37cd3f77160ba4d976c25e46394a50ecd53b22da2269a3988e5aaf07eb741aaf0c957e9a001b15767b61eb6b1169206b4434d3885dc2f SHA512 2e69b67c82dd9dd1473c8776524b3888944957d4c6d7cf8f7713de4935819853dc481f04a87936bba8b1f56d9f3d8018f0820a3b1505bec2fceea6863e5d3776
-DIST vdr-2.6.4_ttxtsubs_v2.patch 40549 BLAKE2B 525c05b72fa957372cc1ef91428428f664f42d92eebc06fd0b179afbe99e4ecc4919c69cef000cc15c8340c9a2506d38cbf755fd6665cde1708ce17d4320a35f SHA512 590c43e63818de8be9637cb3b32bf3399b82a181ca151d67e2341232669619020ab78ba9934da3a9c58cdb3bac56fc2a332a5838a92ee0851e42c3707726eb49
DIST vdr-2.6.6.tbz2 946758 BLAKE2B 22ad6d0d4048347ff16a48ad137900f32dda7adfc7fb54bb1501f14cfc426185f942ffa4997de1e0318ca8c6b67a7dfc48d49b30bfda9367d7337b2d601544fc SHA512 4e798d3e39be0e851ec2e7f7cc563b070c3aa9438165a6aab8fcfc1cee5d7255cdc7dd4f6d4c4c84be770223491a9660bb41874e7b4d1ae504bbb16fe11f2a71
DIST vdr-2.6.6_ttxtsubs_v2.patch 40549 BLAKE2B 525c05b72fa957372cc1ef91428428f664f42d92eebc06fd0b179afbe99e4ecc4919c69cef000cc15c8340c9a2506d38cbf755fd6665cde1708ce17d4320a35f SHA512 590c43e63818de8be9637cb3b32bf3399b82a181ca151d67e2341232669619020ab78ba9934da3a9c58cdb3bac56fc2a332a5838a92ee0851e42c3707726eb49
DIST vdr-menuorg-2.3.x.diff 8852 BLAKE2B 19b98d51a69f52ecda5500f51ef1741a8397953b20c490055eab0393da5f56ff9598c3e1e8ed8b915f5877e08deeb9ba7a9ef8d9356ad3a1fa12e3778869174a SHA512 7b41c3a529858a4953a57f21619ea01864e140cc1755ee0b03caf1c4de41e80c3f805653502bc8d39d02a4dfcddf720acd4a8c8bd91f4871eef31d86e8e915c0
diff --git a/media-video/vdr/files/vdr-2.4.6_gentoo.patch b/media-video/vdr/files/vdr-2.4.6_gentoo.patch
deleted file mode 100644
index 6ecd2ccfd436..000000000000
--- a/media-video/vdr/files/vdr-2.4.6_gentoo.patch
+++ /dev/null
@@ -1,66 +0,0 @@
-this patch will disable some handling in the core Makefile
-as we use for Linux FHS a different handling in gentoo
-demoplugins from core vdr install disabled
-support from Linguas variable
-
-Signed-off-by: Joerg Bornkessel <hd_brummy@gentoo.org> 2021/Feb/11
-diff -Naur vdr-2.4.6.orig/Makefile vdr-2.4.6/Makefile
---- vdr-2.4.6.orig/Makefile 2020-06-27 11:13:04.000000000 +0200
-+++ vdr-2.4.6/Makefile 2020-08-08 18:16:02.519719542 +0200
-@@ -193,7 +193,7 @@
-
- PODIR = po
- LOCALEDIR = locale
--I18Npo = $(wildcard $(PODIR)/*.po)
-+I18Npo = $(foreach dir,$(LINGUAS),$(wildcard $(PODIR)/$(dir)*.po))
- I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file))))
- I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr.mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file))))))
- I18Npot = $(PODIR)/vdr.pot
-@@ -220,7 +220,7 @@
-
- install-i18n: i18n
- @mkdir -p $(DESTDIR)$(LOCDIR)
-- cp -r $(LOCALEDIR)/* $(DESTDIR)$(LOCDIR)
-+ @(cd $(LOCALEDIR); for linguas in $(LINGUAS); do [ "$$linguas" = "en" ] && continue; cp -r --parents $$linguas* $(DESTDIR)$(LOCDIR); done)
-
- # The 'include' directory (for plugins):
-
-@@ -294,12 +294,11 @@
-
- install-dirs:
- @mkdir -p $(DESTDIR)$(VIDEODIR)
-- @mkdir -p $(DESTDIR)$(CONFDIR)
- @mkdir -p $(DESTDIR)$(ARGSDIR)
-- @mkdir -p $(DESTDIR)$(CACHEDIR)
- @mkdir -p $(DESTDIR)$(RESDIR)
-
- install-conf: install-dirs
-+ @mkdir -p $(DESTDIR)$(CONFDIR)
- @cp -pn *.conf $(DESTDIR)$(CONFDIR)
-
- # Documentation:
-@@ -307,9 +306,9 @@
- install-doc:
- @mkdir -p $(DESTDIR)$(MANDIR)/man1
- @mkdir -p $(DESTDIR)$(MANDIR)/man5
-- @gzip -c vdr.1 > $(DESTDIR)$(MANDIR)/man1/vdr.1.gz
-- @gzip -c vdr.5 > $(DESTDIR)$(MANDIR)/man5/vdr.5.gz
-- @gzip -c svdrpsend.1 > $(DESTDIR)$(MANDIR)/man1/svdrpsend.1.gz
-+ @cp vdr.1 $(DESTDIR)$(MANDIR)/man1/
-+ @cp vdr.5 $(DESTDIR)$(MANDIR)/man5/
-+ @cp svdrpsend.1 $(DESTDIR)$(MANDIR)/man1/
-
- # Plugins:
-
-@@ -326,8 +325,9 @@
- # Includes:
-
- install-includes: include-dir
-- @mkdir -p $(DESTDIR)$(INCDIR)
-- @cp -pLR include/vdr include/libsi $(DESTDIR)$(INCDIR)
-+ @mkdir -p $(DESTDIR)$(INCDIR)/vdr $(DESTDIR)$(INCDIR)/vdr/libsi
-+ @cp -pLR include/vdr $(DESTDIR)$(INCDIR)
-+ @cp -pLR include/libsi Make.config $(DESTDIR)$(INCDIR)/vdr
-
- # pkg-config file:
-
diff --git a/media-video/vdr/vdr-2.6.4.ebuild b/media-video/vdr/vdr-2.6.4.ebuild
deleted file mode 100644
index 2381f57f8276..000000000000
--- a/media-video/vdr/vdr-2.6.4.ebuild
+++ /dev/null
@@ -1,199 +0,0 @@
-# Copyright 2021-2024 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit flag-o-matic strip-linguas toolchain-funcs user-info
-
-DESCRIPTION="Video Disk Recorder - turns a pc into a powerful set top box for DVB"
-HOMEPAGE="http://www.tvdr.de/"
-SRC_URI="http://git.tvdr.de/?p=vdr.git;a=snapshot;h=refs/tags/${PV};sf=tbz2 -> ${P}.tbz2
- menuorg? ( https://github.com/vdr-projects/vdr-plugin-menuorg/raw/master/vdr-patch/vdr-menuorg-2.3.x.diff )
- ttxtsubs? ( https://md11.it.cx/download/${PN}/${P}_ttxtsubs_v2.patch )"
-
-LICENSE="GPL-2+"
-SLOT="0"
-KEYWORDS="amd64 ~arm ~arm64 ~ppc x86"
-IUSE="bidi debug demoplugins html keyboard mainmenuhooks menuorg naludump permashift pinplugin systemd ttxtsubs verbose"
-
-COMMON_DEPEND="
- acct-group/vdr
- acct-user/vdr
- media-libs/fontconfig
- media-libs/freetype
- media-libs/libjpeg-turbo:=
- sys-libs/libcap"
-DEPEND="${COMMON_DEPEND}
- sys-kernel/linux-headers"
-RDEPEND="${COMMON_DEPEND}
- dev-lang/perl
- media-tv/gentoo-vdr-scripts
- media-fonts/corefonts
- bidi? ( dev-libs/fribidi )
- systemd? ( sys-apps/systemd )"
-BDEPEND="
- sys-devel/gettext
- virtual/pkgconfig"
-
-REQUIRED_USE="permashift? ( !naludump !pinplugin )"
-
-CONF_DIR="/etc/vdr"
-CAP_FILE="${S}/capabilities.sh"
-CAPS="# Capabilities of the vdr-executable for use by startscript etc."
-
-pkg_setup() {
- use debug && append-flags -g
-
- PLUGIN_LIBDIR="/usr/$(get_libdir)/vdr/plugins"
- VIDEO_DIR="$(egethome vdr)/video"
-
- tc-export CC CXX AR
-}
-
-add_cap() {
- local arg
- for arg; do
- CAPS="${CAPS}\n${arg}=1"
- done
-}
-
-lang_po() {
- LING_PO=$( ls "${S}"/po | sed -e "s:.po::g" | cut -d_ -f1 | tr \\\012 ' ' )
-}
-
-src_prepare() {
- # apply maintenance-patches
- ebegin "Changing paths for gentoo"
-
- local DVBDIR=/usr/include
- local i
- for i in ${DVB_HEADER_PATH} /usr/include/v4l-dvb-hg /usr/include; do
- [[ -d ${i} ]] || continue
- if [[ -f ${i}/linux/dvb/dmx.h ]]; then
- einfo "Found DVB header files in ${i}"
- DVBDIR=${i}
- break
- fi
- done
-
- # checking for s2api headers
- local api_version
- api_version=$(awk -F' ' '/define DVB_API_VERSION / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
- api_version=${api_version}*$(awk -F' ' '/define DVB_API_VERSION_MINOR / {print $3}' "${DVBDIR}"/linux/dvb/version.h)
-
- if [[ ${api_version:-0} -lt 5*3 ]]; then
- eerror "DVB header files do not contain s2api support or too old for ${P}"
- eerror "You cannot compile VDR against old dvb-header"
- die "DVB headers too old"
- fi
-
- cat > Make.config <<-EOT || die "cannot write to Make.config"
- #
- # Generated by ebuild ${PF}
- #
- PREFIX = /usr
- DVBDIR = ${DVBDIR}
- PLUGINLIBDIR = ${PLUGIN_LIBDIR}
- CONFDIR = ${CONF_DIR}
- ARGSDIR = \$(CONFDIR)/conf.d
- VIDEODIR = ${VIDEO_DIR}
- LOCDIR = \$(PREFIX)/share/locale
- INCDIR = \$(PREFIX)/include
-
- DEFINES += -DCONFDIR=\"\$(CONFDIR)\"
- INCLUDES += -I\$(DVBDIR)
-
- # >=vdr-1.7.36-r1; parameter only used for compiletime on vdr
- # PLUGINLIBDIR (plugin Makefile old) = LIBDIR (plugin Makefile new)
- LIBDIR = ${PLUGIN_LIBDIR}
- PCDIR = /usr/$(get_libdir)/pkgconfig
-
- EOT
- eend 0
-
- eapply "${FILESDIR}/${PN}-2.4.6_gentoo.patch"
- use demoplugins || eapply "${FILESDIR}/vdr-2.4_remove_plugins.patch"
- eapply "${FILESDIR}/${PN}-2.4.6_makefile-variables.patch"
-
- # fix clang/LLVM compile
- eapply "${FILESDIR}/${PN}-2.4.6_clang.patch"
-
- use naludump && eapply "${FILESDIR}/${PN}-2.6.1_naludump.patch"
- use permashift && eapply "${FILESDIR}/${PN}-2.6.1-patch-for-permashift.patch"
- use pinplugin && eapply "${FILESDIR}/${PN}-2.6.1_pinplugin.patch"
- use ttxtsubs && eapply "${DISTDIR}/${P}_ttxtsubs_v2.patch"
- use menuorg && eapply "${DISTDIR}/vdr-menuorg-2.3.x.diff"
- use mainmenuhooks && eapply "${FILESDIR}/${PN}-2.4.1_mainmenuhook-1.0.1.patch"
-
- add_cap CAP_UTF8 \
- CAP_IRCTRL_RUNTIME_PARAM \
- CAP_VFAT_RUNTIME_PARAM \
- CAP_CHUID \
- CAP_SHUTDOWN_AUTO_RETRY
-
- echo -e ${CAPS} > "${CAP_FILE}" || die "cannot write to CAP_FILE"
-
- # LINGUAS support
- einfo "\n \t VDR supports the LINGUAS values"
-
- lang_po
-
- einfo "\t Please set one of this values in your sytem make.conf"
- einfo "\t LINGUAS=\"${LING_PO}\"\n"
-
- if [[ -z ${LINGUAS} ]]; then
- einfo "\n \t No values in LINGUAS="
- einfo "\t You will get only english text on OSD \n"
- fi
-
- strip-linguas ${LING_PO} en
-
- default
-}
-
-src_configure() {
- # support languages, written from right to left
- export "BIDI=$(usex bidi 1 0)"
- # systemd notification support
- export "SDNOTIFY=$(usex systemd 1 0)"
- # with/without keyboard
- export "USE_KBD=$(usex keyboard 1 0)"
- # detailed compile output for debug
- export "VERBOSE=$(usex verbose 1 0)"
-}
-
-src_install() {
- # trick the makefile to not create a VIDEODIR by supplying it with an
- # existing directory
- emake VIDEODIR="/" DESTDIR="${ED}" install
-
- keepdir "${PLUGIN_LIBDIR}"
-
- # backup for plugins they don't be able to create this dir
- keepdir "${CONF_DIR}/plugins"
-
- if use html; then
- local HTML_DOCS=( *.html )
- fi
- local DOCS=( MANUAL INSTALL README* HISTORY CONTRIBUTORS UPDATE-2* )
- einstalldocs
-
- insinto /usr/share/vdr
- doins "${CAP_FILE}"
-
- fowners vdr:vdr "${CONF_DIR}" -R
-}
-
-pkg_postinst() {
- elog "Please read the /usr/share/doc/${PF}/UPDATE-2.4"
- elog "for major changes in this version\n"
-
- elog "It is a good idea to run vdrplugin-rebuild now.\n"
-
- elog "To get nice symbols in OSD we recommend to install"
- elog "\t1. emerge media-fonts/vdrsymbols-ttf"
- elog "\t2. select font VDRSymbolsSans in Setup\n"
-
- elog "To get an idea how to proceed now, have a look at our vdr-guide:"
- elog "\thttps://wiki.gentoo.org/wiki/VDR"
-}
^ permalink raw reply related [flat|nested] 15+ messages in thread
end of thread, other threads:[~2024-06-01 21:34 UTC | newest]
Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-29 10:17 [gentoo-commits] repo/gentoo:master commit in: media-video/vdr/, media-video/vdr/files/ Joerg Bornkessel
-- strict thread matches above, loose matches on Subject: below --
2024-06-01 21:34 Florian Schmaus
2023-01-09 13:28 Joonas Niilola
2022-07-03 8:57 Joonas Niilola
2021-05-06 8:47 Joonas Niilola
2021-05-02 20:33 Jörg Bornkessel
2021-02-11 17:20 Jörg Bornkessel
2020-03-02 20:05 Jörg Bornkessel
2019-12-25 18:26 Jörg Bornkessel
2019-11-17 1:34 David Seifert
2019-07-31 13:55 Andreas Sturmlechner
2019-04-11 22:39 David Seifert
2018-09-14 19:19 Joerg Bornkessel
2018-08-27 13:32 Joerg Bornkessel
2018-01-21 17:55 Joerg Bornkessel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox