From 586819755b4dbfdffdc8a725ab7c0f86095b8489 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 15 Sep 2018 17:37:09 +0100 Subject: gentoo resync : 15.09.2018 --- media-video/vdr/Manifest | 6 +- .../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 -------------- media-video/vdr/vdr-2.2.0-r3.ebuild | 4 +- 5 files changed, 3 insertions(+), 1171 deletions(-) delete mode 100644 media-video/vdr/files/vdr-2.0.7_systemd_argsdir.patch delete mode 100644 media-video/vdr/files/vdr-2.0.7_systemd_argsdir_vanilla.patch delete mode 100644 media-video/vdr/vdr-2.0.7.ebuild (limited to 'media-video/vdr') diff --git a/media-video/vdr/Manifest b/media-video/vdr/Manifest index adfac42f5263..ef70502c51d7 100644 --- a/media-video/vdr/Manifest +++ b/media-video/vdr/Manifest @@ -1,7 +1,5 @@ AUX channel_alternative.conf 332 BLAKE2B ec01e5109ecff9c2cf218d89ae9498809f45774a5fd4d5ba103dae957c038d5227e5a300c4ef0db4d418717776ee82e35676dc7e6d0dcdfdaf4195284c803c3e SHA512 738de5d5d99b54a516f41683834509b477590732db4e00b13b2f26e22c7349cb8517965a21251c08d29b0f368b2bb3fa64a1de71da09ffbedc5a401314a0eb5d AUX vdr-2.0.6_gentoo.patch 2255 BLAKE2B 36b8f013e363990f831d7d5216eeefe79caba9dbba531e1ec5452dc2c8ec49c7047be236b30fbf299f5167e86f5ed59775e59e9aca9babde5bbfc4bd751bf502 SHA512 7bb087d2f362e28700a6f22b2649bd61742a7967344f0132abaaa2ae30d4aef3e9a7afd06d80d2a4a97248abfa273cb5d7e20e419c8409a5a83744fd043fb7e9 -AUX vdr-2.0.7_systemd_argsdir.patch 14827 BLAKE2B b2c8eedd695f761a718d295c83cc53d8da55679c8c46f261326e2e67707f9af65b51dfa8cbe96a86ddd34c216580fdeb5b3e33adcf01f825b0c8ffd7a4374d99 SHA512 f0510d27d4b5ff2bbc3f400e5e8e4aae165f665bc7455742e12ebe6f9c6e46985b2ac9fd4089fd3c33c71d975afe73a6e9e089fc6fd9f226c5d53e3fe0553317 -AUX vdr-2.0.7_systemd_argsdir_vanilla.patch 14825 BLAKE2B 930955b2e80fa5a6c9ee24e89f3b980f7c4acded4c114cc78528d2afefa74dbdf4e0a6b41c968fcbba15943a3b91fecdebec725a9ae426f241e775893cbc369b SHA512 1270abaca1bed4a1dfc7756aaa9d1e3b17c5f35b69f3ff333988192ceddb10bbe03aa1973f878537d750b92a0a277213de193f98d6f113a2f447e342867639f3 AUX vdr-2.2.0-r2_gentoo.patch 2578 BLAKE2B f40bd2dadb802285eb229219b2c9e2966073d37cbb6233a309589d22dd875e4457bd4a66f37aba3e0dc679960d310ee718d1bf2d72112c2dbed89a53ca234330 SHA512 46e447fabdfa38dd164dae5aacc932933595f0a068b8c60b19e9aba635c1d4b7cdf368af9e5544933f0ec64550bb685b2705f39ebffba5b1a66897e27bca6ef1 AUX vdr-2.2.0_gcc7extpng.patch 705 BLAKE2B da34652e596d39c3a8c210a6034c2c2aba6649f9cd5e194f00a0ed21f3d2b67de68c560a4e6d2e927a262152a1998c5c279e4451248a918a757adc543a4eab03 SHA512 1f319f71c3819d82e83f68979f2876d7169d086c161939c105cd15d2107e68cbc95cda09e7e883a74e6c95c7db5b0dc58eb92662833732c180250322413ac85b AUX vdr-2.2.0_gentoo.patch 2322 BLAKE2B 7a7a2357bcefe53e251ed3a5b6b1cee1b85c76597c14746236671f044b5a7a5644bd1788e12499588aab87d7c342952c8b55e3a32868299e8c055983a2224b81 SHA512 c6953a7fb77717fdaa8ca05550496e25f4bc60d91c13ed0fb23d27e1a1ec433ec2d5cfb019717cf09eb7b67c9ebb91664b1b731dc28bc4f25e815871f6de0bc7 @@ -10,10 +8,8 @@ AUX vdr-2.2.0_unsignedtosigned.patch 5237 BLAKE2B 21c3eddc9e5684337be332ae22c97b 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 EBUILD vdr-2.0.6-r1.ebuild 6921 BLAKE2B bb5925105f29a4ac9d303459adc3742f3b817a352bb575271c20ce5565a3edb980bd89306ee978cfa398c38be4ae8f75cdf253b1fe6526f7384488cd1a917ab9 SHA512 10997c095cb8af5f0ffa00e07247a790cb038f42a9705a4e6b2e5ca715431dd51749dc5faf9beadf899a4170d9e01de92ff61cf1cdf6e21fe87e6dd60afab07b -EBUILD vdr-2.0.7.ebuild 7275 BLAKE2B ebe4497429f1a08314d80736f5f88ee58c0cb8df65f6930eb1de65b907cc713b29f06a46ac98cab330af24ea137ccbd47392a93d22db9d79395e5f29518489d8 SHA512 c43dd5e9d776ff640eb04b3064f77ead2931194642eb2b541a0add7e3df1c4d6291bfcf4996a450af5a4e979566ae6b374f4cbe20dca71e797fea29bdf5d8520 EBUILD vdr-2.2.0-r1.ebuild 7538 BLAKE2B fabc149e2174c9ba75bea2b3e560e1e8ad1a79ac31933162d31908843971d9529eb7cd63fc1e5adf0c025e3bfcbde914eab5e64314f60dffaa781001dc0b7e3e SHA512 641e41abcabaae613a2d6f0a6ba55194b04ee412ed48461869dc0e4c705a02bb7cfe7ae9c64cc7efadfd3a4ed9dd7a06661874bbbbf3a5e213269899a6b6d572 -EBUILD vdr-2.2.0-r3.ebuild 7697 BLAKE2B 54b9bcbb607313e222cb5c3d784b3a08008b18e812c0d9ae6db664adab54c321e12b36ccccb8418016b89a02f24e2d94b6de4114e858c09b84ed7337b1dd7f6b SHA512 bee1097c7dbf79833e3fc6b0276c113ca8f05275c0353f30221cfe6a31217bd256f16ab731342c30cd21b9f1decb24fd1ca15f40ae74e4caa7561f8cc983d1c3 +EBUILD vdr-2.2.0-r3.ebuild 7638 BLAKE2B bdaf7b1db55325b3ac4adae95079a78e859043f1644c986e065ba38fb46a63f0594d52c2ff4e07ffb37c8ead72a6e902e4007c955dc831a99f03c1c947ff7ca9 SHA512 fb7dce28351be1c777a93e98b40fc1dde6fc74ee393015c58535048220440caa53781d46184c546f619f6d294a7ebfb01cb42b76b255d7a787b3c5366d11b012 MISC metadata.xml 2164 BLAKE2B 1976e2e6090ee6bddcc008794c4ffcc6ae656ab46d1ca459d01a6dd5b7736387d53af03f72685c4e9237ea04bb4f86da49ef9af7f7e1707b038b6a87ae9028c0 SHA512 b960e1d56205787e2c2f6334835b7d9f28fbd283850e2e7af6427a25a590719b7832cc2dcbd94b4ecf3e983fb846909d6b66cfadda89e5b8bcbc469a91651d24 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 de9f4b90163f..000000000000 --- 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 . -+ * -+ * $Id$ -+ */ -+ -+#include "args.h" -+#include -+ -+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 . -+ * -+ * $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 - #include -+#ifdef SDNOTIFY -+#include -+#endif - #include - #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 - #include - #include -+#ifdef SDNOTIFY -+#include -+#endif - #include - #include -+#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 f7bae16fdd40..000000000000 --- 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 . -+ * -+ * $Id$ -+ */ -+ -+#include "args.h" -+#include -+ -+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 . -+ * -+ * $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 - #include -+#ifdef SDNOTIFY -+#include -+#endif - #include - #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 - #include - #include -+#ifdef SDNOTIFY -+#include -+#endif - #include - #include -+#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 f5d9d5ed815d..000000000000 --- 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" -} diff --git a/media-video/vdr/vdr-2.2.0-r3.ebuild b/media-video/vdr/vdr-2.2.0-r3.ebuild index 1da9aad71f86..ff3911ffe097 100644 --- a/media-video/vdr/vdr-2.2.0-r3.ebuild +++ b/media-video/vdr/vdr-2.2.0-r3.ebuild @@ -213,13 +213,13 @@ src_prepare() { ebegin "Make depend" emake .dependencies >/dev/null eend $? "make depend failed" + + eapply "${FILESDIR}/${P}_gcc7extpng.patch" fi 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" - eapply "${FILESDIR}/${P}_gcc7extpng.patch" # fix some makefile issues sed -e "s:ifndef NO_KBD:ifeq (\$(USE_KBD),1):" \ -- cgit v1.2.3