diff -ruN vdr-1.7.27/INSTALL vdr-1.7.27.patched//INSTALL --- vdr-1.7.27/INSTALL 2012-02-27 12:03:14.000000000 +0100 +++ vdr-1.7.27.patched//INSTALL 2012-04-06 09:43:38.590832504 +0200 @@ -375,6 +375,18 @@ VDR archive into your video directory (or into your config directory, respectively, in case you have redirected it with the -c option). +If you prefer to have your system set up according to the FHS +("File system Hierarchy Standard") and thus have all your files spread +around the entire file system, you can do this by adding a Make.config +file with the following settings + +CACHEDIR = /var/cache/vdr +CONFDIR = /var/lib/vdr +LOCDIR = $(PREFIX)/share/locale +PLUGINLIBDIR = $(PREFIX)/lib/vdr +RESDIR = $(PREFIX)/share/vdr +VIDEODIR = /srv/vdr/video0 + Setting up DiSEqC: ------------------ diff -ruN vdr-1.7.27/Make.config.template vdr-1.7.27.patched//Make.config.template --- vdr-1.7.27/Make.config.template 2012-03-20 12:20:13.000000000 +0100 +++ vdr-1.7.27.patched//Make.config.template 2012-04-06 09:43:38.591832504 +0200 @@ -33,6 +33,8 @@ PLUGINLIBDIR = $(PLUGINDIR)/lib VIDEODIR = /video CONFDIR = $(VIDEODIR) +CACHEDIR = $(VIDEODIR) +RESDIR = $(CONFDIR) ### The remote control: diff -ruN vdr-1.7.27/Makefile vdr-1.7.27.patched//Makefile --- vdr-1.7.27/Makefile 2012-03-11 16:33:57.000000000 +0100 +++ vdr-1.7.27.patched//Makefile 2012-04-06 10:06:28.004832504 +0200 @@ -29,6 +29,8 @@ VIDEODIR = /video CONFDIR = $(VIDEODIR) +CACHEDIR = $(VIDEODIR) +RESDIR = $(CONFDIR) DOXYGEN ?= /usr/bin/doxygen DOXYFILE = Doxyfile @@ -71,6 +73,8 @@ DEFINES += -DVIDEODIR=\"$(VIDEODIR)\" DEFINES += -DCONFDIR=\"$(CONFDIR)\" DEFINES += -DPLUGINDIR=\"$(PLUGINLIBDIR)\" +DEFINES += -DCACHEDIR=\"$(CACHEDIR)\" +DEFINES += -DRESDIR=\"$(RESDIR)\" DEFINES += -DLOCDIR=\"$(LOCDIR)\" # The version numbers of VDR and the plugin API (taken from VDR's "config.h"): @@ -112,6 +116,8 @@ @echo "configdir=$(CONFDIR)" >> $@ @echo "videodir=$(VIDEODIR)" >> $@ @echo "plugindir=$(PLUGINLIBDIR)" >> $@ + @echo "cachedir=$(CACHEDIR)" >> $@ + @echo "resdir=$(RESDIR)" >> $@ @echo "localedir=$(LOCDIR)" >> $@ @echo "apiversion=$(APIVERSION)" >> $@ @echo "cflags=$(CXXFLAGS) $(DEFINES) -I\$${includedir}" >> $@ @@ -183,7 +189,7 @@ # Install the files: -install: install-bin install-conf install-doc install-plugins install-i18n install-includes install-pc +install: install-bin install-dirs install-conf install-doc install-plugins install-i18n install-includes install-pc # VDR binary: @@ -193,12 +199,15 @@ # Configuration files: -install-conf: +install-dirs: @mkdir -p $(DESTDIR)$(VIDEODIR) - @if [ ! -d $(DESTDIR)$(CONFDIR) ]; then\ - mkdir -p $(DESTDIR)$(CONFDIR);\ - cp *.conf $(DESTDIR)$(CONFDIR);\ - fi + @mkdir -p $(DESTDIR)$(CONFDIR) + @mkdir -p $(DESTDIR)$(RESDIR) + @mkdir -p $(DESTDIR)$(CACHEDIR) + +install-conf: + @cp *.conf $(DESTDIR)$(CONFDIR) + # Documentation: diff -ruN vdr-1.7.27/PLUGINS.html vdr-1.7.27.patched//PLUGINS.html --- vdr-1.7.27/PLUGINS.html 2012-03-09 10:49:29.000000000 +0100 +++ vdr-1.7.27.patched//PLUGINS.html 2012-04-06 09:43:38.594832504 +0200 @@ -82,7 +82,7 @@
-There may be situations where a plugin requires configuration files of its own, maybe -for data that can't be stored in the simple setup parameters -of VDR, or maybe because it needs to launch other programs that simply need a separate -configuration file. While the plugin is free to store such files anywhere it -sees fit, it might be a good idea to put them in a common place, preferably -where other configuration data already exists. VDR provides the function +There may be situations where a plugin requires own files. While the plugin is +free to store such files anywhere it sees fit, it might be a good idea to put them in a common +place, preferably where such data already exists. +
+configuration files, maybe for data that can't be stored in the simple +setup parameters of VDR, or maybe because it needs to +launch other programs that simply need a separate configuration file. +
+cache files, to store data so that future requests for that data can be served faster. The data +that is stored within a cache might be values that have been computed earlier or duplicates of +original values that are stored elsewhere. +
+resource files, for providing additional files, like pictures, movie clips or channel logos. +
+Threfore VDR provides three functions
const char *ConfigDirectory(const char *PluginName = NULL); |
+
+const char *CacheDirectory(const char *PluginName = NULL); + |
+
+const char *ResourceDirectory(const char *PluginName = NULL); + |
-which returns a string containing the directory that VDR uses for its own configuration -files (defined through the -c option in the call to VDR), extended by +each of these return a string containing the directory that VDR uses for its own +files (defined through the options in the call to VDR), extended by "/plugins". So assuming the VDR configuration directory is /video (the default if no -c or -v option is given), a call to ConfigDirectory() will return /video/plugins. The first call to ConfigDirectory() will automatically make sure that the plugins subdirectory will exist. If, for some reason, this cannot be achieved, NULL -will be returned. +will be returned. The behavoir of CacheDirectory() and ResourceDirectory() +is similar
The additional plugins directory is used to keep files from plugins apart from those of VDR itself, making sure there will be no name clashes. If a plugin -needs only one extra configuration file, it is suggested that this file be named -name.conf, where name shall be the name of the plugin. +needs only one extra file, it is suggested that this file be named name.*, +where name shall be the name of the plugin.
If a plugin needs more than one such file, it is suggested that the plugin stores these in a subdirectory of its own, named after the plugin. To easily get such a name -the ConfigDirectory() function can be given an additional string that will -be appended to the returned directory name, as in +the functions can be given an additional string that will be appended to the returned +directory name, as in
const char *MyConfigDir = ConfigDirectory(Name()); @@ -928,13 +944,13 @@ (or return NULL in case of an error).
|