From 15485a5e06121f644b9eb9cc228ce3c77b22330d Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Mon, 24 Dec 2012 10:39:00 +0100 Subject: [PATCH] Version 1.7.34 VDR developer version 1.7.34 is now available at ftp://ftp.tvdr.de/vdr/Developer/vdr-1.7.34.tar.bz2 A 'diff' against the previous version is available at ftp://ftp.tvdr.de/vdr/Developer/vdr-1.7.33-1.7.34.diff and a helper patch for plugin Makefiles can be found at ftp://ftp.tvdr.de/vdr/Developer/vdr-1.7.33-pluginmakefile.diff MD5 checksums: 55d9aba62563efe39ee040e987f7023c vdr-1.7.34.tar.bz2 019ba806b263f7054dbd0da8956ea73b vdr-1.7.33-1.7.34.diff 6c2b8efe5eead6822f006bc867ccb324 vdr-1.7.33-pluginmakefile.diff WARNING: ======== This is a developer version. Even though I use it in my productive environment. I strongly recommend that you only use it under controlled conditions and for testing and debugging. IMPORTANT: ========== This version comes with revised versions of the Makefiles for VDR itself and all of its standard plugins. As a result of this, existing plugins will no longer build with this version of VDR, unless their Makefiles are properly adapted. To do so, please follow the instructions given below. There is also a generic patch (see below) that might help you update your plugin's Makefile. If you do want to build this version of VDR with plugins that don't have their Makefiles adapted yet, you can simply copy the Makefile, Make.global and Make.config (if applicable) files from a previous version of VDR into this source and use them. Note, though, that you cannot mix old and new Makefiles. All Makefiles for VDR and all plugins must be either old or new! PLEASE GIVE THE PLUGIN DEVELOPERS SOME TIME TO ADAPT THEIR MAKEFILES ACCORDINGLY. AFTER ALL, IT'S CHRISTMAS, SO THEY PROBABLY HAVE BETTER THINGS TO DO THAN SIT AT THEIR COMPUTERS ;-). From the HISTORY file: - Changed the type of the TimerMatch parameter in cSkinDisplayMenu::SetItemEvent() from 'int' to 'eTimerEvent' (reported by Christoph Haubrich). - Updated the Estonian OSD texts (thanks to Arthur Konovalov). - Fixed cOsd::GetBitmap() to always return NULL if a non-exising area is requested. - Added several missing "`ls $^`" in the calls to xgettext in plugin Makefiles and the "newplugin" script. - Fixed setting the --package-name and --package-version options in the calls to xgettext in several plugin Makefiles. - Added "-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE" to the DEFINES in the Makefile (somehow got lost from Make.config.template in version 1.7.13). - Removed some redundancy in the Makefile/Make.global/Make.config mechanism (suggested by Christopher Reimer). The file Make.global is no longer used, and plugin Makefiles don't include the file Make.config any more. Instead they now retrieve all necessary information through calls to pkg-config. - The plugin Makefiles now have a separate 'install' target (suggested by Christopher Reimer). In order to still allow the normal building of VDR (with all plugins in its ./PLUGINS/src subdirectory, the plugin libraries in ./PLUGINS/lib and the i18n files in ./locale) the VDR Makefile checks the settings of LIBDIR and LOCDIR when building the plugins from within the VDR source directory. If these macros have their default values, then the 'install' targets of the plugins' Makefiles are called. Otherwise the 'all' targets are called and the plugins are merely built, and will have to be installed by a call to 'make install-plugins'. This now also allows a user to copy a plugin source to any directory, change into that directory and do 'make' and 'make install' to have the plugin installed to wherever the local installation of VDR expects them. - Plugin Makefiles now use DESTDIR and the 'install' program (thanks to Christopher Reimer). - Due to the changes to the plugin Makefiles, existing plugins will not build with this version of VDR any more. You can either use the new 'newplugin' script to generate a dummy plugin directory and use the Makefile from there (adapting it to your particular plugin), or apply the patch from ftp://ftp.tvdr.de/vdr/Developer/vdr-1.7.33-pluginmakefile.diff to your Makefile to make the necessary changes (see comments in that file for details). - Added the new menu categories mcChannelEdit, mcTimerEdit, mcScheduleNow, mcScheduleNext, mcRecordingInfo, mcPluginSetup, mcSetupOsd, mcSetupEpg, mcSetupDvb, mcSetupLnb, mcSetupCam, mcSetupRecord, mcSetupReplay, mcSetupMisc and mcSetupPlugins. - Updated the Italian OSD texts (thanks to Diego Pierotto). - Fixed replay stuttering close to the end of an ongoing recording (reported by Andreas Regel). - Fixed cIndexFile::GetNextIFrame() to properly handle the case where the very last frame is an I-frame (which normally shouldn't occur). - Fixed replaying ongoing recordings from other VDR instances. --- CONTRIBUTORS | 7 ++ HISTORY | 47 +++++++++++- Make.config.template | 18 ++--- Make.global | 17 ----- Makefile | 79 ++++++++++++--------- PLUGINS/src/dvbhddevice/Makefile | 73 ++++++++++--------- PLUGINS/src/dvbhddevice/libhdffcmd/Makefile | 18 +---- PLUGINS/src/dvbhddevice/po/de_DE.po | 2 +- PLUGINS/src/dvbhddevice/po/fi_FI.po | 2 +- PLUGINS/src/dvbhddevice/po/it_IT.po | 2 +- PLUGINS/src/dvbsddevice/Makefile | 77 +++++++------------- PLUGINS/src/epgtableid0/Makefile | 77 +++++++------------- PLUGINS/src/hello/Makefile | 66 ++++++++--------- PLUGINS/src/hello/po/ca_ES.po | 6 +- PLUGINS/src/hello/po/cs_CZ.po | 6 +- PLUGINS/src/hello/po/da_DK.po | 6 +- PLUGINS/src/hello/po/de_DE.po | 6 +- PLUGINS/src/hello/po/el_GR.po | 6 +- PLUGINS/src/hello/po/es_ES.po | 6 +- PLUGINS/src/hello/po/et_EE.po | 6 +- PLUGINS/src/hello/po/fi_FI.po | 6 +- PLUGINS/src/hello/po/fr_FR.po | 6 +- PLUGINS/src/hello/po/hr_HR.po | 6 +- PLUGINS/src/hello/po/hu_HU.po | 6 +- PLUGINS/src/hello/po/it_IT.po | 6 +- PLUGINS/src/hello/po/lt_LT.po | 6 +- PLUGINS/src/hello/po/nl_NL.po | 6 +- PLUGINS/src/hello/po/nn_NO.po | 6 +- PLUGINS/src/hello/po/pl_PL.po | 6 +- PLUGINS/src/hello/po/pt_PT.po | 6 +- PLUGINS/src/hello/po/ro_RO.po | 6 +- PLUGINS/src/hello/po/ru_RU.po | 6 +- PLUGINS/src/hello/po/sk_SK.po | 6 +- PLUGINS/src/hello/po/sl_SI.po | 6 +- PLUGINS/src/hello/po/sv_SE.po | 6 +- PLUGINS/src/hello/po/tr_TR.po | 6 +- PLUGINS/src/hello/po/zh_CN.po | 6 +- PLUGINS/src/osddemo/Makefile | 48 +++++++------ PLUGINS/src/pictures/Makefile | 69 +++++++++--------- PLUGINS/src/pictures/po/de_DE.po | 6 +- PLUGINS/src/pictures/po/fi_FI.po | 6 +- PLUGINS/src/pictures/po/fr_FR.po | 6 +- PLUGINS/src/pictures/po/it_IT.po | 6 +- PLUGINS/src/pictures/po/lt_LT.po | 6 +- PLUGINS/src/pictures/po/ru_RU.po | 6 +- PLUGINS/src/pictures/po/sk_SK.po | 6 +- PLUGINS/src/rcu/Makefile | 77 +++++++------------- PLUGINS/src/servicedemo/Makefile | 41 +++++------ PLUGINS/src/skincurses/Makefile | 69 +++++++++--------- PLUGINS/src/skincurses/po/de_DE.po | 6 +- PLUGINS/src/skincurses/po/fi_FI.po | 6 +- PLUGINS/src/skincurses/po/it_IT.po | 6 +- PLUGINS/src/skincurses/po/lt_LT.po | 6 +- PLUGINS/src/skincurses/po/ru_RU.po | 6 +- PLUGINS/src/skincurses/po/sk_SK.po | 6 +- PLUGINS/src/status/Makefile | 48 +++++++------ PLUGINS/src/svdrpdemo/Makefile | 48 +++++++------ config.h | 10 +-- libsi/Makefile | 17 +---- menu.c | 19 +++-- menuitems.c | 3 +- newplugin | 70 +++++++++--------- osd.c | 6 +- po/ar.po | 3 - po/ca_ES.po | 3 - po/cs_CZ.po | 3 - po/da_DK.po | 3 - po/de_DE.po | 3 - po/el_GR.po | 3 - po/es_ES.po | 3 - po/et_EE.po | 55 +++++++------- po/fi_FI.po | 3 - po/fr_FR.po | 3 - po/hr_HR.po | 3 - po/hu_HU.po | 3 - po/it_IT.po | 27 ++++--- po/lt_LT.po | 3 - po/mk_MK.po | 3 - po/nl_NL.po | 3 - po/nn_NO.po | 3 - po/pl_PL.po | 3 - po/pt_PT.po | 3 - po/ro_RO.po | 3 - po/ru_RU.po | 3 - po/sk_SK.po | 3 - po/sl_SI.po | 3 - po/sr_SR.po | 3 - po/sv_SE.po | 3 - po/tr_TR.po | 3 - po/uk_UA.po | 3 - po/zh_CN.po | 3 - recording.c | 74 +++++-------------- recording.h | 7 +- skins.h | 36 +++++++++- 94 files changed, 691 insertions(+), 818 deletions(-) delete mode 100644 Make.global diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 46a4c62b..d21f8844 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -1453,6 +1453,7 @@ Andreas Regel for making cDevice::AddPid() store the stream type of the given pid for adding cFont::FontName() and cFont::Size() for writing the dvbhddevice plugin + for reporting replay stuttering close to the end of an ongoing recording Thomas Bergwinkl for fixing the validity check for channel IDs, because some providers use TIDs @@ -2321,6 +2322,8 @@ Christoph Haubrich for suggesting to check for NULL in cOsd::AddPixmap() for making modified editing marks be written to disk whenever the replay progress display gets hidden + for reporting a wrong type ('int' vs. 'eTimerEvent') in the declaration of + cSkinDisplayMenu::SetItemEvent() Pekka Mauno for fixing cSchedule::GetFollowingEvent() in case there is currently no present @@ -2807,6 +2810,10 @@ Christopher Reimer for reporting a problem with external Dolby Digital processing via the '-a' option in live mode and with TS recordings for contributing to a patch that implements FHS support + for suggesting to remove some redundancy in the Makefile/Make.global/Make.config + mechanism + for suggesting to give the plugin Makefiles a separate 'install' target + for making plugin Makefiles use DESTDIR and the 'install' program Stefan Huskamp for suggesting to make entering characters via the number keys diff --git a/HISTORY b/HISTORY index 51d0681a..5b4513dd 100644 --- a/HISTORY +++ b/HISTORY @@ -7342,8 +7342,8 @@ Video Disk Recorder Revision History 2012-12-08: Version 1.7.33 - In order to be able to play TS recordings from other sources, in which there is - more than one PMT PID in the PAT, 'int cPatPmtParser::PatPmt(void)' has been changed - to 'bool cPatPmtParser::IsPatPmt(int Pid)'. + more than one PMT PID in the PAT, 'int cPatPmtParser::PmtPid(void)' has been changed + to 'bool cPatPmtParser::IsPmtPid(int Pid)'. - Fixed learning remote control keys with the LCARS skin. - Updated the Macedonian OSD texts (thanks to Dimitar Petrovski). - Fixed getting only non-video packets in cCuttingThread::GetPendingPackets() (reported @@ -7416,3 +7416,46 @@ Video Disk Recorder Revision History SetItemRecording() of the cSkinDisplayMenu class can be reimplemented by skin plugins to display these items in a more elaborate way than just a simple line of text. + +2012-12-24: Version 1.7.34 + +- Changed the type of the TimerMatch parameter in cSkinDisplayMenu::SetItemEvent() from + 'int' to 'eTimerEvent' (reported by Christoph Haubrich). +- Updated the Estonian OSD texts (thanks to Arthur Konovalov). +- Fixed cOsd::GetBitmap() to always return NULL if a non-exising area is requested. +- Added several missing "`ls $^`" in the calls to xgettext in plugin Makefiles and the + "newplugin" script. +- Fixed setting the --package-name and --package-version options in the calls to + xgettext in several plugin Makefiles. +- Added "-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE" to the + DEFINES in the Makefile (somehow got lost from Make.config.template in version 1.7.13). +- Removed some redundancy in the Makefile/Make.global/Make.config mechanism (suggested + by Christopher Reimer). The file Make.global is no longer used, and plugin Makefiles + don't include the file Make.config any more. Instead they now retrieve all necessary + information through calls to pkg-config. +- The plugin Makefiles now have a separate 'install' target (suggested by Christopher + Reimer). In order to still allow the normal building of VDR (with all plugins in its + ./PLUGINS/src subdirectory, the plugin libraries in ./PLUGINS/lib and the i18n files in + ./locale) the VDR Makefile checks the settings of LIBDIR and LOCDIR when building the + plugins from within the VDR source directory. If these macros have their default values, + then the 'install' targets of the plugins' Makefiles are called. Otherwise the 'all' + targets are called and the plugins are merely built, and will have to be installed by a + call to 'make install-plugins'. This now also allows a user to copy a plugin source to + any directory, change into that directory and do 'make' and 'make install' to have the + plugin installed to wherever the local installation of VDR expects them. +- Plugin Makefiles now use DESTDIR and the 'install' program (thanks to Christopher Reimer). +- Due to the changes to the plugin Makefiles, existing plugins will not build with this + version of VDR any more. You can either use the new 'newplugin' script to generate a + dummy plugin directory and use the Makefile from there (adapting it to your particular + plugin), or apply the patch from + ftp://ftp.tvdr.de/vdr/Developer/vdr-1.7.33-pluginmakefile.diff + to your Makefile to make the necessary changes (see comments in that file for details). +- Added the new menu categories mcChannelEdit, mcTimerEdit, mcScheduleNow, mcScheduleNext, + mcRecordingInfo, mcPluginSetup, mcSetupOsd, mcSetupEpg, mcSetupDvb, mcSetupLnb, + mcSetupCam, mcSetupRecord, mcSetupReplay, mcSetupMisc and mcSetupPlugins. +- Updated the Italian OSD texts (thanks to Diego Pierotto). +- Fixed replay stuttering close to the end of an ongoing recording (reported by Andreas + Regel). +- Fixed cIndexFile::GetNextIFrame() to properly handle the case where the very last frame + is an I-frame (which normally shouldn't occur). +- Fixed replaying ongoing recordings from other VDR instances. diff --git a/Make.config.template b/Make.config.template index 08f9ece8..a2cc6976 100644 --- a/Make.config.template +++ b/Make.config.template @@ -6,7 +6,7 @@ # See the main source file 'vdr.c' for copyright information and # how to reach the author. # -# $Id: Make.config.template 2.10 2012/10/09 10:32:32 kls Exp $ +# $Id: Make.config.template 2.12 2012/12/22 10:54:47 kls Exp $ ### The C compiler and options: @@ -14,12 +14,10 @@ CC = gcc CFLAGS = -g -O3 -Wall CXX = g++ -CXXFLAGS = -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses +CXXFLAGS = $(CFLAGS) -Werror=overloaded-virtual -Wno-parentheses -ifdef PLUGIN CFLAGS += -fPIC CXXFLAGS += -fPIC -endif # Use 'make M32=1 ...' to build a 32-bit version of VDR on a 64-bit machine: ifdef M32 @@ -29,15 +27,16 @@ endif ### The directory environment: -PREFIX = $(DESTDIR)/usr/local +PREFIX = /usr/local #DVBDIR = /usr/src/v4l-dvb/linux MANDIR = $(PREFIX)/man BINDIR = $(PREFIX)/bin # By default locale and plugin files are built under the source directory: -LOCDIR = ./locale -PLUGINDIR = ./PLUGINS -PLUGINLIBDIR = $(PLUGINDIR)/lib +INCDIR = $(CWD)/include +LOCDIR = $(CWD)/locale +PLUGINDIR = $(CWD)/PLUGINS +LIBDIR = $(PLUGINDIR)/lib # By default VDR requires only one single directory to operate: VIDEODIR = /video # Activate the following line to build VDR according to the FHS ("File system Hierarchy Standard"): @@ -47,8 +46,9 @@ VIDEODIR = /srv/vdr/video CONFDIR = /var/lib/vdr CACHEDIR = /var/cache/vdr RESDIR = $(PREFIX)/share/vdr +INCDIR = $(PREFIX)/include LOCDIR = $(PREFIX)/share/locale -PLUGINLIBDIR = $(PREFIX)/lib/vdr +LIBDIR = $(PREFIX)/lib/vdr endif ### The remote control: diff --git a/Make.global b/Make.global deleted file mode 100644 index 3b927228..00000000 --- a/Make.global +++ /dev/null @@ -1,17 +0,0 @@ -# -# Strictly necessary Makefile options for the Video Disk Recorder -# -# See the main source file 'vdr.c' for copyright information and -# how to reach the author. -# -# $Id: Make.global 1.1 2010/02/06 14:54:12 kls Exp $ - -# Plugins need to be compiled with position independent code, otherwise linking -# VDR against it will fail. - -ifdef PLUGIN -CFLAGS += -fPIC -CXXFLAGS += -fPIC -endif - -DEFINES += -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE diff --git a/Makefile b/Makefile index e165ee88..de48e376 100644 --- a/Makefile +++ b/Makefile @@ -4,28 +4,39 @@ # See the main source file 'vdr.c' for copyright information and # how to reach the author. # -# $Id: Makefile 2.30 2012/10/09 08:32:25 kls Exp $ +# $Id: Makefile 2.36 2012/12/23 11:28:13 kls Exp $ .DELETE_ON_ERROR: +# Compiler flags: + CC ?= gcc CFLAGS ?= -g -O3 -Wall CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses +CXXFLAGS ?= $(CFLAGS) -Werror=overloaded-virtual -Wno-parentheses +CFLAGS += -fPIC +CXXFLAGS += -fPIC + +CDEFINES = -D_GNU_SOURCE +CDEFINES += -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE + +# Directories: + +CWD := $(shell pwd) LSIDIR = ./libsi DESTDIR ?= PREFIX ?= /usr/local MANDIR ?= $(PREFIX)/share/man BINDIR ?= $(PREFIX)/bin -INCDIR ?= $(PREFIX)/include -LOCDIR ?= ./locale +INCDIR ?= $(CWD)/include +LOCDIR ?= $(CWD)/locale LIBS = -ljpeg -lpthread -ldl -lcap -lrt $(shell pkg-config --libs freetype2 fontconfig) INCLUDES ?= $(shell pkg-config --cflags freetype2 fontconfig) -PLUGINDIR= ./PLUGINS -PLUGINLIBDIR= $(PLUGINDIR)/lib +PLUGINDIR= $(CWD)/PLUGINS +LIBDIR = $(PLUGINDIR)/lib # By default VDR requires only one single directory to operate: VIDEODIR = /video @@ -36,7 +47,6 @@ DOXYFILE = Doxyfile PCDIR ?= $(firstword $(subst :, , ${PKG_CONFIG_PATH}:$(shell pkg-config --variable=pc_path pkg-config):$(PREFIX)/lib/pkgconfig)) -include Make.global -include Make.config SILIB = $(LSIDIR)/libsi.a @@ -48,6 +58,8 @@ OBJS = audio.o channels.o ci.o config.o cutter.o device.o diseqc.o dvbdevice.o d skinclassic.o skinlcars.o skins.o skinsttng.o sourceparams.o sources.o spu.o status.o svdrp.o themes.o thread.o\ timers.o tools.o transfer.o vdr.o videodir.o +DEFINES += $(CDEFINES) + ifndef NO_KBD DEFINES += -DREMOTE_KBD endif @@ -66,14 +78,11 @@ endif LIRC_DEVICE ?= /var/run/lirc/lircd DEFINES += -DLIRC_DEVICE=\"$(LIRC_DEVICE)\" - -DEFINES += -D_GNU_SOURCE - DEFINES += -DVIDEODIR=\"$(VIDEODIR)\" DEFINES += -DCONFDIR=\"$(CONFDIR)\" DEFINES += -DCACHEDIR=\"$(CACHEDIR)\" DEFINES += -DRESDIR=\"$(RESDIR)\" -DEFINES += -DPLUGINDIR=\"$(PLUGINLIBDIR)\" +DEFINES += -DPLUGINDIR=\"$(LIBDIR)\" DEFINES += -DLOCDIR=\"$(LOCDIR)\" # Default values for directories: @@ -87,7 +96,7 @@ RESDIRDEF = $(firstword $(RESDIR) $(CONFDIRDEF)) 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 vdr.pc +all: vdr i18n plugins # Implicit rules: @@ -106,27 +115,27 @@ $(DEPFILE): Makefile # The main program: vdr: $(OBJS) $(SILIB) - $(CXX) $(CXXFLAGS) -rdynamic $(LDFLAGS) $(OBJS) $(LIBS) $(LIBDIRS) $(SILIB) -o vdr + $(CXX) $(CXXFLAGS) -rdynamic $(LDFLAGS) $(OBJS) $(LIBS) $(SILIB) -o vdr # The libsi library: $(SILIB): - $(MAKE) -C $(LSIDIR) all + $(MAKE) --no-print-directory -C $(LSIDIR) CXXFLAGS="$(CXXFLAGS)" DEFINES="$(CDEFINES)" all # pkg-config file: -vdr.pc: Makefile Make.global +.PHONY: vdr.pc +vdr.pc: @echo "bindir=$(BINDIR)" > $@ - @echo "includedir=$(INCDIR)" >> $@ @echo "configdir=$(CONFDIRDEF)" >> $@ @echo "videodir=$(VIDEODIR)" >> $@ @echo "cachedir=$(CACHEDIRDEF)" >> $@ @echo "resdir=$(RESDIRDEF)" >> $@ - @echo "plugindir=$(PLUGINLIBDIR)" >> $@ - @echo "localedir=$(LOCDIR)" >> $@ + @echo "libdir=$(LIBDIR)" >> $@ + @echo "locdir=$(LOCDIR)" >> $@ @echo "apiversion=$(APIVERSION)" >> $@ - @echo "cflags=$(CXXFLAGS) $(DEFINES) -I\$${includedir}" >> $@ - @echo "plugincflags=\$${cflags} -fPIC" >> $@ + @echo "cflags=$(CFLAGS) $(CDEFINES) -I$(INCDIR)" >> $@ + @echo "cxxflags=$(CXXFLAGS) $(CDEFINES) -I$(INCDIR)" >> $@ @echo "" >> $@ @echo "Name: VDR" >> $@ @echo "Description: Video Disk Recorder" >> $@ @@ -157,7 +166,7 @@ $(I18Nmsgs): $(LOCALEDIR)/%/LC_MESSAGES/vdr.mo: $(PODIR)/%.mo cp $< $@ .PHONY: i18n -i18n: $(I18Nmsgs) +i18n: $(I18Nmsgs) $(I18Npot) install-i18n: @mkdir -p $(DESTDIR)$(LOCDIR) @@ -173,23 +182,27 @@ include-dir: # Plugins: -plugins: include-dir +plugins: include-dir vdr.pc @failed="";\ noapiv="";\ for i in `ls $(PLUGINDIR)/src | grep -v '[^a-z0-9]'`; do\ - echo "Plugin $$i:";\ + echo "*** Plugin $$i:";\ if ! grep -q "\$$(LIBDIR)/.*\$$(APIVERSION)" "$(PLUGINDIR)/src/$$i/Makefile" ; then\ echo "ERROR: plugin $$i doesn't honor APIVERSION - not compiled!";\ noapiv="$$noapiv $$i";\ continue;\ fi;\ - $(MAKE) -C "$(PLUGINDIR)/src/$$i" all || failed="$$failed $$i";\ + target=all;\ + if [ "$(LIBDIR)" == "$(CWD)/PLUGINS/lib" ] && [ "$(LOCDIR)" == "$(CWD)/locale" ]; then\ + target=install;\ + fi;\ + $(MAKE) --no-print-directory -C "$(PLUGINDIR)/src/$$i" VDRDIR=$(CWD) $$target || failed="$$failed $$i";\ done;\ if [ -n "$$noapiv" ] ; then echo; echo "*** plugins without APIVERSION:$$noapiv"; echo; fi;\ if [ -n "$$failed" ] ; then echo; echo "*** failed plugins:$$failed"; echo; exit 1; fi clean-plugins: - @for i in `ls $(PLUGINDIR)/src | grep -v '[^a-z0-9]'`; do $(MAKE) -C "$(PLUGINDIR)/src/$$i" clean; done + @for i in `ls $(PLUGINDIR)/src | grep -v '[^a-z0-9]'`; do $(MAKE) --no-print-directory -C "$(PLUGINDIR)/src/$$i" clean; done @-rm -f $(PLUGINDIR)/lib/lib*-*.so.$(APIVERSION) # Install the files: @@ -225,8 +238,9 @@ install-doc: # Plugins: install-plugins: plugins - @mkdir -p $(DESTDIR)$(PLUGINLIBDIR) - @cp --remove-destination $(PLUGINDIR)/lib/lib*-*.so.$(APIVERSION) $(DESTDIR)$(PLUGINLIBDIR) + @for i in `ls $(PLUGINDIR)/src | grep -v '[^a-z0-9]'`; do\ + $(MAKE) --no-print-directory -C "$(PLUGINDIR)/src/$$i" VDRDIR=$(CWD) DESTDIR=$(DESTDIR) install;\ + done # Includes: @@ -253,9 +267,10 @@ srcdoc: # Housekeeping: clean: - $(MAKE) -C $(LSIDIR) clean - -rm -f $(OBJS) $(DEPFILE) vdr vdr.pc core* *~ - -rm -rf $(LOCALEDIR) $(PODIR)/*.mo $(PODIR)/*.pot - -rm -rf include - -rm -rf srcdoc + @$(MAKE) --no-print-directory -C $(LSIDIR) clean + @-rm -f $(OBJS) $(DEPFILE) vdr vdr.pc core* *~ + @-rm -rf $(LOCALEDIR) $(PODIR)/*.mo $(PODIR)/*.pot + @-rm -rf include + @-rm -rf srcdoc CLEAN: clean +distclean: clean-plugins clean diff --git a/PLUGINS/src/dvbhddevice/Makefile b/PLUGINS/src/dvbhddevice/Makefile index ad502965..ef6ef516 100644 --- a/PLUGINS/src/dvbhddevice/Makefile +++ b/PLUGINS/src/dvbhddevice/Makefile @@ -1,53 +1,50 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 1.13 2012/03/11 15:34:00 kls Exp $ +# $Id: Makefile 1.19 2012/12/23 10:01:00 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# IMPORTANT: the presence of this macro is important for the Make.config -# file. So it must be defined, even if it is not used here! -# + PLUGIN = dvbhddevice ### The version number of this plugin (taken from the main source file): VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +LOCDIR = $(DESTDIR)$(call PKGCFG,locdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = $(PLUGIN)-$(VERSION) PACKAGE = vdr-$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -55,7 +52,7 @@ OBJS = $(PLUGIN).o dvbhdffdevice.o hdffcmd.o hdffosd.o menu.o setup.o ### The main target: -all: libvdr-$(PLUGIN).so i18n +all: $(SOFILE) i18n ### Implicit rules: @@ -74,34 +71,39 @@ $(DEPFILE): Makefile ### Internationalization (I18N): PODIR = po -LOCALEDIR = $(VDRDIR)/locale I18Npo = $(wildcard $(PODIR)/*.po) -I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) +I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file)))) +I18Nmsgs = $(addprefix $(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) I18Npot = $(PODIR)/$(PLUGIN).pot %.mo: %.po msgfmt -c -o $@ $< $(I18Npot): $(wildcard *.c) - xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=VDR --package-version=$(VDRVERSION) --msgid-bugs-address='' -o $@ `ls $^` + xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=vdr-$(PLUGIN) --package-version=$(VERSION) --msgid-bugs-address='' -o $@ `ls $^` %.po: $(I18Npot) - msgmerge -U --no-wrap --no-location --backup=none -q $@ $< + msgmerge -U --no-wrap --no-location --backup=none -q -N $@ $< @touch $@ -$(I18Nmsgs): $(LOCALEDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo - @mkdir -p $(dir $@) - cp $< $@ +$(I18Nmsgs): $(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo + install -D -m644 $< $@ .PHONY: i18n -i18n: $(I18Nmsgs) $(I18Npot) +i18n: $(I18Nmo) $(I18Npot) + +install-i18n: $(I18Nmsgs) ### Targets: -libvdr-$(PLUGIN).so: $(OBJS) libhdffcmd - $(MAKE) -C libhdffcmd all +$(SOFILE): $(OBJS) libhdffcmd + @$(MAKE) --no-print-directory -C libhdffcmd all $(CXX) $(CXXFLAGS) -shared $(OBJS) libhdffcmd/libhdffcmd.a -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +install-lib: $(SOFILE) + install -D $^ $(LIBDIR)/$^.$(APIVERSION) + +install: install-lib install-i18n dist: $(I18Npo) clean @-rm -rf $(TMPDIR)/$(ARCHIVE) @@ -112,5 +114,6 @@ dist: $(I18Npo) clean @echo Distribution package created as $(PACKAGE).tgz clean: - @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ $(PODIR)/*.mo $(PODIR)/*.pot - $(MAKE) -C libhdffcmd clean + @-rm -f $(PODIR)/*.mo $(PODIR)/*.pot + @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ + @-$(MAKE) --no-print-directory -C libhdffcmd clean diff --git a/PLUGINS/src/dvbhddevice/libhdffcmd/Makefile b/PLUGINS/src/dvbhddevice/libhdffcmd/Makefile index babe79b2..216cdbad 100644 --- a/PLUGINS/src/dvbhddevice/libhdffcmd/Makefile +++ b/PLUGINS/src/dvbhddevice/libhdffcmd/Makefile @@ -24,29 +24,17 @@ CFLAGS ?= -g -O2 -fPIC -Wall AR ?= ar ARFLAGS ?= r -### The directory environment: - -VDRDIR ?= ../../../.. - -### Make sure that necessary options are included: - -include $(VDRDIR)/Make.global - -### Allow user defined options to overwrite defaults: - --include $(VDRDIR)/Make.config - ### Implicit rules: %.o: %.c $(CC) $(CFLAGS) -c $(DEFINES) $(INCLUDES) $< -# Dependencies: +### Dependencies: MAKEDEP = $(CC) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(LIB_OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -62,7 +50,7 @@ $(LIB_SHARED): $(LIB_OBJS) ln -sf $(LIB_SHARED) $(LIB_NAME).so clean: - rm -f $(LIB_OBJS) $(DEPFILE) $(LIB_STATIC) $(LIB_NAME)*.so + @-rm -f $(LIB_OBJS) $(DEPFILE) $(LIB_STATIC) $(LIB_NAME)*.so install: $(LIB_SHARED) chown root $(LIB_SHARED) diff --git a/PLUGINS/src/dvbhddevice/po/de_DE.po b/PLUGINS/src/dvbhddevice/po/de_DE.po index b263f08a..f884567d 100644 --- a/PLUGINS/src/dvbhddevice/po/de_DE.po +++ b/PLUGINS/src/dvbhddevice/po/de_DE.po @@ -5,7 +5,7 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR \n" +"Project-Id-Version: vdr-dvbhddevice 0.0.4\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2012-11-13 20:08+0100\n" "PO-Revision-Date: 2011-04-25 21:44+0200\n" diff --git a/PLUGINS/src/dvbhddevice/po/fi_FI.po b/PLUGINS/src/dvbhddevice/po/fi_FI.po index a971773f..579e8292 100644 --- a/PLUGINS/src/dvbhddevice/po/fi_FI.po +++ b/PLUGINS/src/dvbhddevice/po/fi_FI.po @@ -5,7 +5,7 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR \n" +"Project-Id-Version: vdr-dvbhddevice 0.0.4\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2012-11-13 20:08+0100\n" "PO-Revision-Date: 2011-04-25 21:44+0200\n" diff --git a/PLUGINS/src/dvbhddevice/po/it_IT.po b/PLUGINS/src/dvbhddevice/po/it_IT.po index 56b987a2..0718ba72 100644 --- a/PLUGINS/src/dvbhddevice/po/it_IT.po +++ b/PLUGINS/src/dvbhddevice/po/it_IT.po @@ -5,7 +5,7 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR\n" +"Project-Id-Version: vdr-dvbhddevice 0.0.4\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2012-11-13 20:08+0100\n" "PO-Revision-Date: 2011-07-10 00:23+0100\n" diff --git a/PLUGINS/src/dvbsddevice/Makefile b/PLUGINS/src/dvbsddevice/Makefile index 1e7b5dde..44517744 100644 --- a/PLUGINS/src/dvbsddevice/Makefile +++ b/PLUGINS/src/dvbsddevice/Makefile @@ -1,53 +1,49 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 1.9 2012/03/11 15:34:02 kls Exp $ +# $Id: Makefile 1.15 2012/12/23 10:01:12 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# IMPORTANT: the presence of this macro is important for the Make.config -# file. So it must be defined, even if it is not used here! -# + PLUGIN = dvbsddevice ### The version number of this plugin (taken from the main source file): VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = $(PLUGIN)-$(VERSION) PACKAGE = vdr-$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -55,7 +51,7 @@ OBJS = $(PLUGIN).o dvbsdffdevice.o dvbsdffosd.o ### The main target: -all: libvdr-$(PLUGIN).so i18n +all: $(SOFILE) ### Implicit rules: @@ -71,38 +67,17 @@ $(DEPFILE): Makefile -include $(DEPFILE) -### Internationalization (I18N): - -PODIR = po -LOCALEDIR = $(VDRDIR)/locale -I18Npo = $(wildcard $(PODIR)/*.po) -I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) -I18Npot = $(PODIR)/$(PLUGIN).pot - -%.mo: %.po - msgfmt -c -o $@ $< - -$(I18Npot): $(wildcard *.c) - xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=VDR --package-version=$(VDRVERSION) --msgid-bugs-address='' -o $@ `ls $^` - -%.po: $(I18Npot) - msgmerge -U --no-wrap --no-location --backup=none -q $@ $< - @touch $@ - -$(I18Nmsgs): $(LOCALEDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo - @mkdir -p $(dir $@) - cp $< $@ - -.PHONY: i18n -i18n: $(I18Nmsgs) $(I18Npot) - ### Targets: -libvdr-$(PLUGIN).so: $(OBJS) +$(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) -dist: $(I18Npo) clean +install-lib: $(SOFILE) + install -D $^ $(LIBDIR)/$^.$(APIVERSION) + +install: install-lib + +dist: clean @-rm -rf $(TMPDIR)/$(ARCHIVE) @mkdir $(TMPDIR)/$(ARCHIVE) @cp -a * $(TMPDIR)/$(ARCHIVE) @@ -111,4 +86,4 @@ dist: $(I18Npo) clean @echo Distribution package created as $(PACKAGE).tgz clean: - @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ $(PODIR)/*.mo $(PODIR)/*.pot + @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ diff --git a/PLUGINS/src/epgtableid0/Makefile b/PLUGINS/src/epgtableid0/Makefile index 78bf3e78..48b6b6ea 100644 --- a/PLUGINS/src/epgtableid0/Makefile +++ b/PLUGINS/src/epgtableid0/Makefile @@ -1,53 +1,49 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 1.2 2012/03/11 15:34:04 kls Exp $ +# $Id: Makefile 1.8 2012/12/23 10:01:40 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# IMPORTANT: the presence of this macro is important for the Make.config -# file. So it must be defined, even if it is not used here! -# + PLUGIN = epgtableid0 ### The version number of this plugin (taken from the main source file): VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = $(PLUGIN)-$(VERSION) PACKAGE = vdr-$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -55,7 +51,7 @@ OBJS = $(PLUGIN).o ### The main target: -all: libvdr-$(PLUGIN).so i18n +all: $(SOFILE) ### Implicit rules: @@ -71,38 +67,17 @@ $(DEPFILE): Makefile -include $(DEPFILE) -### Internationalization (I18N): - -PODIR = po -LOCALEDIR = $(VDRDIR)/locale -I18Npo = $(wildcard $(PODIR)/*.po) -I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) -I18Npot = $(PODIR)/$(PLUGIN).pot - -%.mo: %.po - msgfmt -c -o $@ $< - -$(I18Npot): $(wildcard *.c) - xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=vdr-$(PLUGIN) --package-version=$(VERSION) --msgid-bugs-address='' -o $@ $^ - -%.po: $(I18Npot) - msgmerge -U --no-wrap --no-location --backup=none -q $@ $< - @touch $@ - -$(I18Nmsgs): $(LOCALEDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo - @mkdir -p $(dir $@) - cp $< $@ - -.PHONY: i18n -i18n: $(I18Nmsgs) $(I18Npot) - ### Targets: -libvdr-$(PLUGIN).so: $(OBJS) +$(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) -dist: $(I18Npo) clean +install-lib: $(SOFILE) + install -D $^ $(LIBDIR)/$^.$(APIVERSION) + +install: install-lib + +dist: clean @-rm -rf $(TMPDIR)/$(ARCHIVE) @mkdir $(TMPDIR)/$(ARCHIVE) @cp -a * $(TMPDIR)/$(ARCHIVE) @@ -111,4 +86,4 @@ dist: $(I18Npo) clean @echo Distribution package created as $(PACKAGE).tgz clean: - @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ $(PODIR)/*.mo $(PODIR)/*.pot + @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ diff --git a/PLUGINS/src/hello/Makefile b/PLUGINS/src/hello/Makefile index cdf63401..4cfcae83 100644 --- a/PLUGINS/src/hello/Makefile +++ b/PLUGINS/src/hello/Makefile @@ -1,53 +1,50 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.9 2012/03/11 15:34:06 kls Exp $ +# $Id: Makefile 2.15 2012/12/23 10:03:51 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# IMPORTANT: the presence of this macro is important for the Make.config -# file. So it must be defined, even if it is not used here! -# + PLUGIN = hello ### The version number of this plugin (taken from the main source file): VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +LOCDIR = $(DESTDIR)$(call PKGCFG,locdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = $(PLUGIN)-$(VERSION) PACKAGE = vdr-$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -55,7 +52,7 @@ OBJS = $(PLUGIN).o ### The main target: -all: libvdr-$(PLUGIN).so i18n +all: $(SOFILE) i18n ### Implicit rules: @@ -74,33 +71,38 @@ $(DEPFILE): Makefile ### Internationalization (I18N): PODIR = po -LOCALEDIR = $(VDRDIR)/locale I18Npo = $(wildcard $(PODIR)/*.po) -I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) +I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file)))) +I18Nmsgs = $(addprefix $(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) I18Npot = $(PODIR)/$(PLUGIN).pot %.mo: %.po msgfmt -c -o $@ $< $(I18Npot): $(wildcard *.c) - xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=VDR --package-version=$(VDRVERSION) --msgid-bugs-address='' -o $@ `ls $^` + xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=vdr-$(PLUGIN) --package-version=$(VERSION) --msgid-bugs-address='' -o $@ `ls $^` %.po: $(I18Npot) - msgmerge -U --no-wrap --no-location --backup=none -q $@ $< + msgmerge -U --no-wrap --no-location --backup=none -q -N $@ $< @touch $@ -$(I18Nmsgs): $(LOCALEDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo - @mkdir -p $(dir $@) - cp $< $@ +$(I18Nmsgs): $(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo + install -D -m644 $< $@ .PHONY: i18n -i18n: $(I18Nmsgs) +i18n: $(I18Nmo) $(I18Npot) + +install-i18n: $(I18Nmsgs) ### Targets: -libvdr-$(PLUGIN).so: $(OBJS) +$(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +install-lib: $(SOFILE) + install -D $^ $(LIBDIR)/$^.$(APIVERSION) + +install: install-lib install-i18n dist: $(I18Npo) clean @-rm -rf $(TMPDIR)/$(ARCHIVE) diff --git a/PLUGINS/src/hello/po/ca_ES.po b/PLUGINS/src/hello/po/ca_ES.po index 24e09efc..8efe5318 100644 --- a/PLUGINS/src/hello/po/ca_ES.po +++ b/PLUGINS/src/hello/po/ca_ES.po @@ -7,9 +7,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Jordi Vil \n" "Language-Team: Catalan \n" diff --git a/PLUGINS/src/hello/po/cs_CZ.po b/PLUGINS/src/hello/po/cs_CZ.po index af184b37..f4fe8a51 100644 --- a/PLUGINS/src/hello/po/cs_CZ.po +++ b/PLUGINS/src/hello/po/cs_CZ.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Vladimr Brta \n" "Language-Team: Czech \n" diff --git a/PLUGINS/src/hello/po/da_DK.po b/PLUGINS/src/hello/po/da_DK.po index 6c1647ee..1fda5d08 100644 --- a/PLUGINS/src/hello/po/da_DK.po +++ b/PLUGINS/src/hello/po/da_DK.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Mogens Elneff \n" "Language-Team: Danish \n" diff --git a/PLUGINS/src/hello/po/de_DE.po b/PLUGINS/src/hello/po/de_DE.po index 1536f1b3..c3e35f6b 100644 --- a/PLUGINS/src/hello/po/de_DE.po +++ b/PLUGINS/src/hello/po/de_DE.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Klaus Schmidinger \n" "Language-Team: German \n" diff --git a/PLUGINS/src/hello/po/el_GR.po b/PLUGINS/src/hello/po/el_GR.po index ce921ee0..03bab929 100644 --- a/PLUGINS/src/hello/po/el_GR.po +++ b/PLUGINS/src/hello/po/el_GR.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Dimitrios Dimitrakos \n" "Language-Team: Greek \n" diff --git a/PLUGINS/src/hello/po/es_ES.po b/PLUGINS/src/hello/po/es_ES.po index 292f6524..1b87045b 100644 --- a/PLUGINS/src/hello/po/es_ES.po +++ b/PLUGINS/src/hello/po/es_ES.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Ruben Nunez Francisco \n" "Language-Team: Spanish \n" diff --git a/PLUGINS/src/hello/po/et_EE.po b/PLUGINS/src/hello/po/et_EE.po index 3cf2247d..c3d9bda6 100644 --- a/PLUGINS/src/hello/po/et_EE.po +++ b/PLUGINS/src/hello/po/et_EE.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Arthur Konovalov \n" "Language-Team: Estonian \n" diff --git a/PLUGINS/src/hello/po/fi_FI.po b/PLUGINS/src/hello/po/fi_FI.po index a106a8b0..b8256b54 100644 --- a/PLUGINS/src/hello/po/fi_FI.po +++ b/PLUGINS/src/hello/po/fi_FI.po @@ -8,9 +8,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Rolf Ahrenberg \n" "Language-Team: Finnish \n" diff --git a/PLUGINS/src/hello/po/fr_FR.po b/PLUGINS/src/hello/po/fr_FR.po index 335df752..aed37e22 100644 --- a/PLUGINS/src/hello/po/fr_FR.po +++ b/PLUGINS/src/hello/po/fr_FR.po @@ -8,9 +8,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Nicolas Huillard \n" "Language-Team: French \n" diff --git a/PLUGINS/src/hello/po/hr_HR.po b/PLUGINS/src/hello/po/hr_HR.po index c88e8328..40305de3 100644 --- a/PLUGINS/src/hello/po/hr_HR.po +++ b/PLUGINS/src/hello/po/hr_HR.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2008-03-17 19:52+0100\n" "Last-Translator: Adrian Caval \n" "Language-Team: Croatian \n" diff --git a/PLUGINS/src/hello/po/hu_HU.po b/PLUGINS/src/hello/po/hu_HU.po index 5b9f207d..ae344c11 100644 --- a/PLUGINS/src/hello/po/hu_HU.po +++ b/PLUGINS/src/hello/po/hu_HU.po @@ -6,9 +6,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Istvan Koenigsberger , Guido Josten \n" "Language-Team: Hungarian \n" diff --git a/PLUGINS/src/hello/po/it_IT.po b/PLUGINS/src/hello/po/it_IT.po index 7ef310a8..e56e4999 100644 --- a/PLUGINS/src/hello/po/it_IT.po +++ b/PLUGINS/src/hello/po/it_IT.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2008-01-27 20:11+0100\n" "Last-Translator: Diego Pierotto \n" "Language-Team: Italian \n" diff --git a/PLUGINS/src/hello/po/lt_LT.po b/PLUGINS/src/hello/po/lt_LT.po index 0ade0bd8..773e14a8 100644 --- a/PLUGINS/src/hello/po/lt_LT.po +++ b/PLUGINS/src/hello/po/lt_LT.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.7.10\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2009-12-08 12:18+0200\n" "Last-Translator: Valdemaras Pipiras \n" "Language-Team: Lithuanian \n" diff --git a/PLUGINS/src/hello/po/nl_NL.po b/PLUGINS/src/hello/po/nl_NL.po index 4dff540c..29b0dadf 100644 --- a/PLUGINS/src/hello/po/nl_NL.po +++ b/PLUGINS/src/hello/po/nl_NL.po @@ -7,9 +7,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Maarten Wisse \n" "Language-Team: Dutch \n" diff --git a/PLUGINS/src/hello/po/nn_NO.po b/PLUGINS/src/hello/po/nn_NO.po index c566f531..0277104c 100644 --- a/PLUGINS/src/hello/po/nn_NO.po +++ b/PLUGINS/src/hello/po/nn_NO.po @@ -6,9 +6,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Truls Slevigen \n" "Language-Team: Norwegian Nynorsk \n" diff --git a/PLUGINS/src/hello/po/pl_PL.po b/PLUGINS/src/hello/po/pl_PL.po index e7aedf2f..34d38de3 100644 --- a/PLUGINS/src/hello/po/pl_PL.po +++ b/PLUGINS/src/hello/po/pl_PL.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Michael Rakowski \n" "Language-Team: Polish \n" diff --git a/PLUGINS/src/hello/po/pt_PT.po b/PLUGINS/src/hello/po/pt_PT.po index dd0be173..fcefd52e 100644 --- a/PLUGINS/src/hello/po/pt_PT.po +++ b/PLUGINS/src/hello/po/pt_PT.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Paulo Lopes \n" "Language-Team: Portuguese \n" diff --git a/PLUGINS/src/hello/po/ro_RO.po b/PLUGINS/src/hello/po/ro_RO.po index a5eb16a5..248e9c06 100644 --- a/PLUGINS/src/hello/po/ro_RO.po +++ b/PLUGINS/src/hello/po/ro_RO.po @@ -6,9 +6,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Lucian Muresan \n" "Language-Team: Romanian \n" diff --git a/PLUGINS/src/hello/po/ru_RU.po b/PLUGINS/src/hello/po/ru_RU.po index ee94c929..18dcd0f0 100644 --- a/PLUGINS/src/hello/po/ru_RU.po +++ b/PLUGINS/src/hello/po/ru_RU.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Vyacheslav Dikonov \n" "Language-Team: Russian \n" diff --git a/PLUGINS/src/hello/po/sk_SK.po b/PLUGINS/src/hello/po/sk_SK.po index b8ba7753..e3875aff 100644 --- a/PLUGINS/src/hello/po/sk_SK.po +++ b/PLUGINS/src/hello/po/sk_SK.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2009-09-30 09:48+0100\n" "Last-Translator: Milan Hrala \n" "Language-Team: Slovak \n" diff --git a/PLUGINS/src/hello/po/sl_SI.po b/PLUGINS/src/hello/po/sl_SI.po index bbcf6b97..504586aa 100644 --- a/PLUGINS/src/hello/po/sl_SI.po +++ b/PLUGINS/src/hello/po/sl_SI.po @@ -6,9 +6,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Matjaz Thaler \n" "Language-Team: Slovenian \n" diff --git a/PLUGINS/src/hello/po/sv_SE.po b/PLUGINS/src/hello/po/sv_SE.po index 4b4909fc..3ccd4240 100644 --- a/PLUGINS/src/hello/po/sv_SE.po +++ b/PLUGINS/src/hello/po/sv_SE.po @@ -6,9 +6,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-11 12:34+0200\n" "Last-Translator: Tomas Prybil \n" "Language-Team: Swedish \n" diff --git a/PLUGINS/src/hello/po/tr_TR.po b/PLUGINS/src/hello/po/tr_TR.po index a8705dac..3215b1fb 100644 --- a/PLUGINS/src/hello/po/tr_TR.po +++ b/PLUGINS/src/hello/po/tr_TR.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2008-05-12 22:34:4800\n" "Last-Translator: Oktay Yolgeen \n" "Language-Team: Turkish \n" diff --git a/PLUGINS/src/hello/po/zh_CN.po b/PLUGINS/src/hello/po/zh_CN.po index 7793ed29..6d7aa569 100644 --- a/PLUGINS/src/hello/po/zh_CN.po +++ b/PLUGINS/src/hello/po/zh_CN.po @@ -8,9 +8,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-hello 0.2.5\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2009-01-23 09:48+0800\n" "Last-Translator: senin\n" "Language-Team: Chinese (simplified) \n" diff --git a/PLUGINS/src/osddemo/Makefile b/PLUGINS/src/osddemo/Makefile index 68a236b5..3ef4fdc3 100644 --- a/PLUGINS/src/osddemo/Makefile +++ b/PLUGINS/src/osddemo/Makefile @@ -1,51 +1,49 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.5 2012/03/11 15:34:08 kls Exp $ +# $Id: Makefile 2.11 2012/12/23 10:04:05 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# + PLUGIN = osddemo ### The version number of this plugin (taken from the main source file): VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = $(PLUGIN)-$(VERSION) PACKAGE = vdr-$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -53,14 +51,14 @@ OBJS = $(PLUGIN).o ### The main target: -all: libvdr-$(PLUGIN).so +all: $(SOFILE) ### Implicit rules: %.o: %.c $(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) $< -# Dependencies: +### Dependencies: MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies @@ -71,9 +69,13 @@ $(DEPFILE): Makefile ### Targets: -libvdr-$(PLUGIN).so: $(OBJS) +$(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +install-lib: $(SOFILE) + install -D $^ $(LIBDIR)/$^.$(APIVERSION) + +install: install-lib dist: clean @-rm -rf $(TMPDIR)/$(ARCHIVE) diff --git a/PLUGINS/src/pictures/Makefile b/PLUGINS/src/pictures/Makefile index cee95efb..516cb857 100644 --- a/PLUGINS/src/pictures/Makefile +++ b/PLUGINS/src/pictures/Makefile @@ -1,53 +1,50 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.9 2012/03/11 15:34:10 kls Exp $ +# $Id: Makefile 2.15 2012/12/23 10:04:13 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# IMPORTANT: the presence of this macro is important for the Make.config -# file. So it must be defined, even if it is not used here! -# + PLUGIN = pictures ### The version number of this plugin (taken from the main source file): VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +LOCDIR = $(DESTDIR)$(call PKGCFG,locdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = $(PLUGIN)-$(VERSION) PACKAGE = vdr-$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -55,7 +52,7 @@ OBJS = $(PLUGIN).o entry.o menu.o player.o ### The main target: -all: libvdr-$(PLUGIN).so i18n +all: $(SOFILE) i18n ### Implicit rules: @@ -74,33 +71,38 @@ $(DEPFILE): Makefile ### Internationalization (I18N): PODIR = po -LOCALEDIR = $(VDRDIR)/locale I18Npo = $(wildcard $(PODIR)/*.po) -I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) +I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file)))) +I18Nmsgs = $(addprefix $(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) I18Npot = $(PODIR)/$(PLUGIN).pot %.mo: %.po msgfmt -c -o $@ $< $(I18Npot): $(wildcard *.c) - xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=VDR --package-version=$(VDRVERSION) --msgid-bugs-address='' -o $@ `ls $^` + xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=vdr-$(PLUGIN) --package-version=$(VERSION) --msgid-bugs-address='' -o $@ `ls $^` %.po: $(I18Npot) - msgmerge -U --no-wrap --no-location --backup=none -q $@ $< + msgmerge -U --no-wrap --no-location --backup=none -q -N $@ $< @touch $@ -$(I18Nmsgs): $(LOCALEDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo - @mkdir -p $(dir $@) - cp $< $@ +$(I18Nmsgs): $(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo + install -D -m644 $< $@ .PHONY: i18n -i18n: $(I18Nmsgs) $(I18Npot) +i18n: $(I18Nmo) $(I18Npot) + +install-i18n: $(I18Nmsgs) ### Targets: -libvdr-$(PLUGIN).so: $(OBJS) +$(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +install-lib: $(SOFILE) + install -D $^ $(LIBDIR)/$^.$(APIVERSION) + +install: install-lib install-i18n dist: $(I18Npo) clean @-rm -rf $(TMPDIR)/$(ARCHIVE) @@ -111,4 +113,5 @@ dist: $(I18Npo) clean @echo Distribution package created as $(PACKAGE).tgz clean: - @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ $(PODIR)/*.mo $(PODIR)/*.pot + @-rm -f $(PODIR)/*.mo $(PODIR)/*.pot + @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ diff --git a/PLUGINS/src/pictures/po/de_DE.po b/PLUGINS/src/pictures/po/de_DE.po index f31fa076..2f777727 100644 --- a/PLUGINS/src/pictures/po/de_DE.po +++ b/PLUGINS/src/pictures/po/de_DE.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-pictures 0.1.3\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 12:57+0100\n" "PO-Revision-Date: 2008-01-12 17:41+0100\n" "Last-Translator: Klaus Schmidinger \n" "Language-Team: German \n" diff --git a/PLUGINS/src/pictures/po/fi_FI.po b/PLUGINS/src/pictures/po/fi_FI.po index 0a175967..3ac5ed7d 100644 --- a/PLUGINS/src/pictures/po/fi_FI.po +++ b/PLUGINS/src/pictures/po/fi_FI.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-pictures 0.1.3\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 12:57+0100\n" "PO-Revision-Date: 2008-01-12 17:41+0100\n" "Last-Translator: Rolf Ahrenberg \n" "Language-Team: Finnish \n" diff --git a/PLUGINS/src/pictures/po/fr_FR.po b/PLUGINS/src/pictures/po/fr_FR.po index c6289d15..36bca8c5 100644 --- a/PLUGINS/src/pictures/po/fr_FR.po +++ b/PLUGINS/src/pictures/po/fr_FR.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-pictures 0.1.3\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 12:57+0100\n" "PO-Revision-Date: 2008-01-12 17:41+0100\n" "Last-Translator: Patrice Staudt \n" "Language-Team: French \n" diff --git a/PLUGINS/src/pictures/po/it_IT.po b/PLUGINS/src/pictures/po/it_IT.po index f3858db0..0eddf515 100644 --- a/PLUGINS/src/pictures/po/it_IT.po +++ b/PLUGINS/src/pictures/po/it_IT.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-pictures 0.1.3\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 12:57+0100\n" "PO-Revision-Date: 2008-01-27 20:22+0100\n" "Last-Translator: Diego Pierotto \n" "Language-Team: Italian \n" diff --git a/PLUGINS/src/pictures/po/lt_LT.po b/PLUGINS/src/pictures/po/lt_LT.po index 9d877acc..26c244bb 100644 --- a/PLUGINS/src/pictures/po/lt_LT.po +++ b/PLUGINS/src/pictures/po/lt_LT.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.7.10\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-pictures 0.1.3\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 12:57+0100\n" "PO-Revision-Date: 2009-12-08 12:41+0100\n" "Last-Translator: Valdemaras Pipiras , 2009\n" "Language-Team: Lithuanian \n" diff --git a/PLUGINS/src/pictures/po/ru_RU.po b/PLUGINS/src/pictures/po/ru_RU.po index 6d38639e..869c91be 100644 --- a/PLUGINS/src/pictures/po/ru_RU.po +++ b/PLUGINS/src/pictures/po/ru_RU.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-pictures 0.1.3\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 12:57+0100\n" "PO-Revision-Date: 2008-03-14 00:45+0100\n" "Last-Translator: Alexander Gross \n" "Language-Team: Russian \n" diff --git a/PLUGINS/src/pictures/po/sk_SK.po b/PLUGINS/src/pictures/po/sk_SK.po index 340aad1e..afc69a03 100644 --- a/PLUGINS/src/pictures/po/sk_SK.po +++ b/PLUGINS/src/pictures/po/sk_SK.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-15 15:08+0200\n" +"Project-Id-Version: vdr-pictures 0.1.3\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 12:57+0100\n" "PO-Revision-Date: 2009-09-30 12:54+0100\n" "Last-Translator: Milan Hrala \n" "Language-Team: Slovak \n" diff --git a/PLUGINS/src/rcu/Makefile b/PLUGINS/src/rcu/Makefile index 170490aa..d1b162ae 100644 --- a/PLUGINS/src/rcu/Makefile +++ b/PLUGINS/src/rcu/Makefile @@ -1,53 +1,49 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 1.2 2012/03/11 15:34:12 kls Exp $ +# $Id: Makefile 1.8 2012/12/23 10:04:15 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# IMPORTANT: the presence of this macro is important for the Make.config -# file. So it must be defined, even if it is not used here! -# + PLUGIN = rcu ### The version number of this plugin (taken from the main source file): VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = $(PLUGIN)-$(VERSION) PACKAGE = vdr-$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -55,7 +51,7 @@ OBJS = $(PLUGIN).o ### The main target: -all: libvdr-$(PLUGIN).so i18n +all: $(SOFILE) ### Implicit rules: @@ -71,38 +67,17 @@ $(DEPFILE): Makefile -include $(DEPFILE) -### Internationalization (I18N): - -PODIR = po -LOCALEDIR = $(VDRDIR)/locale -I18Npo = $(wildcard $(PODIR)/*.po) -I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) -I18Npot = $(PODIR)/$(PLUGIN).pot - -%.mo: %.po - msgfmt -c -o $@ $< - -$(I18Npot): $(wildcard *.c) - xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=vdr-$(PLUGIN) --package-version=$(VERSION) --msgid-bugs-address='' -o $@ $^ - -%.po: $(I18Npot) - msgmerge -U --no-wrap --no-location --backup=none -q $@ $< - @touch $@ - -$(I18Nmsgs): $(LOCALEDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo - @mkdir -p $(dir $@) - cp $< $@ - -.PHONY: i18n -i18n: $(I18Nmsgs) $(I18Npot) - ### Targets: -libvdr-$(PLUGIN).so: $(OBJS) +$(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) -dist: $(I18Npo) clean +install-lib: $(SOFILE) + install -D $^ $(LIBDIR)/$^.$(APIVERSION) + +install: install-lib + +dist: clean @-rm -rf $(TMPDIR)/$(ARCHIVE) @mkdir $(TMPDIR)/$(ARCHIVE) @cp -a * $(TMPDIR)/$(ARCHIVE) @@ -111,4 +86,4 @@ dist: $(I18Npo) clean @echo Distribution package created as $(PACKAGE).tgz clean: - @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ $(PODIR)/*.mo $(PODIR)/*.pot + @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ diff --git a/PLUGINS/src/servicedemo/Makefile b/PLUGINS/src/servicedemo/Makefile index 941aaff6..dfe05a40 100644 --- a/PLUGINS/src/servicedemo/Makefile +++ b/PLUGINS/src/servicedemo/Makefile @@ -1,13 +1,12 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.5 2012/03/11 15:34:13 kls Exp $ +# $Id: Makefile 2.9 2012/12/23 10:04:16 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# -PLUGIN = servicedemo # dummy name for Make.config + PLUGIN1 = svccli PLUGIN2 = svcsvr @@ -15,28 +14,22 @@ PLUGIN2 = svcsvr VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN1).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: @@ -45,9 +38,9 @@ PACKAGE = vdr-$(ARCHIVE) ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -62,7 +55,7 @@ all: libvdr-$(PLUGIN1).so libvdr-$(PLUGIN2).so %.o: %.c $(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) $< -# Dependencies: +### Dependencies: MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies @@ -75,11 +68,13 @@ $(DEPFILE): Makefile libvdr-$(PLUGIN1).so: $(PLUGIN1).o $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(PLUGIN1).o -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) libvdr-$(PLUGIN2).so: $(PLUGIN2).o $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(PLUGIN2).o -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +install: libvdr-$(PLUGIN1).so libvdr-$(PLUGIN2).so + install -D libvdr-$(PLUGIN1).so $(LIBDIR)/libvdr-$(PLUGIN1).so.$(APIVERSION) + install -D libvdr-$(PLUGIN2).so $(LIBDIR)/libvdr-$(PLUGIN2).so.$(APIVERSION) dist: clean @-rm -rf $(TMPDIR)/$(ARCHIVE) diff --git a/PLUGINS/src/skincurses/Makefile b/PLUGINS/src/skincurses/Makefile index b43518b6..63be8bb4 100644 --- a/PLUGINS/src/skincurses/Makefile +++ b/PLUGINS/src/skincurses/Makefile @@ -1,53 +1,50 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.9 2012/03/11 15:34:18 kls Exp $ +# $Id: Makefile 2.15 2012/12/23 10:04:18 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# IMPORTANT: the presence of this macro is important for the Make.config -# file. So it must be defined, even if it is not used here! -# + PLUGIN = skincurses ### The version number of this plugin (taken from the main source file): VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +LOCDIR = $(DESTDIR)$(call PKGCFG,locdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = $(PLUGIN)-$(VERSION) PACKAGE = vdr-$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -55,7 +52,7 @@ OBJS = $(PLUGIN).o ### The main target: -all: libvdr-$(PLUGIN).so i18n +all: $(SOFILE) i18n ### Implicit rules: @@ -74,33 +71,38 @@ $(DEPFILE): Makefile ### Internationalization (I18N): PODIR = po -LOCALEDIR = $(VDRDIR)/locale I18Npo = $(wildcard $(PODIR)/*.po) -I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) +I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file)))) +I18Nmsgs = $(addprefix $(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) I18Npot = $(PODIR)/$(PLUGIN).pot %.mo: %.po msgfmt -c -o $@ $< $(I18Npot): $(wildcard *.c) - xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=VDR --package-version=$(VDRVERSION) --msgid-bugs-address='' -o $@ `ls $^` + xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=vdr-$(PLUGIN) --package-version=$(VERSION) --msgid-bugs-address='' -o $@ `ls $^` %.po: $(I18Npot) - msgmerge -U --no-wrap --no-location --backup=none -q $@ $< + msgmerge -U --no-wrap --no-location --backup=none -q -N $@ $< @touch $@ -$(I18Nmsgs): $(LOCALEDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo - @mkdir -p $(dir $@) - cp $< $@ +$(I18Nmsgs): $(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo + install -D -m644 $< $@ .PHONY: i18n -i18n: $(I18Nmsgs) $(I18Npot) +i18n: $(I18Nmo) $(I18Npot) + +install-i18n: $(I18Nmsgs) ### Targets: -libvdr-$(PLUGIN).so: $(OBJS) +$(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -lncursesw -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +install-lib: $(SOFILE) + install -D $^ $(LIBDIR)/$^.$(APIVERSION) + +install: install-lib install-i18n dist: $(I18Npo) clean @-rm -rf $(TMPDIR)/$(ARCHIVE) @@ -111,4 +113,5 @@ dist: $(I18Npo) clean @echo Distribution package created as $(PACKAGE).tgz clean: - @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ $(PODIR)/*.mo $(PODIR)/*.pot + @-rm -f $(PODIR)/*.mo $(PODIR)/*.pot + @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ diff --git a/PLUGINS/src/skincurses/po/de_DE.po b/PLUGINS/src/skincurses/po/de_DE.po index bff2411a..cecf74b5 100644 --- a/PLUGINS/src/skincurses/po/de_DE.po +++ b/PLUGINS/src/skincurses/po/de_DE.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-21 14:36+0200\n" +"Project-Id-Version: vdr-skincurses 0.1.12\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-15 16:07+0200\n" "Last-Translator: Klaus Schmidinger \n" "Language-Team: German \n" diff --git a/PLUGINS/src/skincurses/po/fi_FI.po b/PLUGINS/src/skincurses/po/fi_FI.po index c123a0b1..e8bb5c20 100644 --- a/PLUGINS/src/skincurses/po/fi_FI.po +++ b/PLUGINS/src/skincurses/po/fi_FI.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-21 14:36+0200\n" +"Project-Id-Version: vdr-skincurses 0.1.12\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2007-08-14 20:48+0300\n" "Last-Translator: Rolf Ahrenberg \n" "Language-Team: Finnish \n" diff --git a/PLUGINS/src/skincurses/po/it_IT.po b/PLUGINS/src/skincurses/po/it_IT.po index 5cecb65c..b7a8e688 100644 --- a/PLUGINS/src/skincurses/po/it_IT.po +++ b/PLUGINS/src/skincurses/po/it_IT.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-21 14:36+0200\n" +"Project-Id-Version: vdr-skincurses 0.1.12\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2008-01-27 20:35+0100\n" "Last-Translator: Diego Pierotto \n" "Language-Team: Italian \n" diff --git a/PLUGINS/src/skincurses/po/lt_LT.po b/PLUGINS/src/skincurses/po/lt_LT.po index 16d2698c..3b3e1e10 100644 --- a/PLUGINS/src/skincurses/po/lt_LT.po +++ b/PLUGINS/src/skincurses/po/lt_LT.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.7.12\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-21 14:36+0200\n" +"Project-Id-Version: vdr-skincurses 0.1.12\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2010-02-22 18:18+0200\n" "Last-Translator: Valdemaras Pipiras \n" "Language-Team: Lithuanian \n" diff --git a/PLUGINS/src/skincurses/po/ru_RU.po b/PLUGINS/src/skincurses/po/ru_RU.po index b550f29c..fe049953 100644 --- a/PLUGINS/src/skincurses/po/ru_RU.po +++ b/PLUGINS/src/skincurses/po/ru_RU.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-21 14:36+0200\n" +"Project-Id-Version: vdr-skincurses 0.1.12\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2008-03-14 00:21+0100\n" "Last-Translator: Alexander Gross \n" "Language-Team: Russian \n" diff --git a/PLUGINS/src/skincurses/po/sk_SK.po b/PLUGINS/src/skincurses/po/sk_SK.po index e362f8e9..0426c70b 100644 --- a/PLUGINS/src/skincurses/po/sk_SK.po +++ b/PLUGINS/src/skincurses/po/sk_SK.po @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: VDR 1.6.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-05-21 14:36+0200\n" +"Project-Id-Version: vdr-skincurses 0.1.12\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-18 14:04+0100\n" "PO-Revision-Date: 2009-09-30 12:52+0100\n" "Last-Translator: Milan Hrala \n" "Language-Team: Slovak \n" diff --git a/PLUGINS/src/status/Makefile b/PLUGINS/src/status/Makefile index dd46ba69..fc8ef9eb 100644 --- a/PLUGINS/src/status/Makefile +++ b/PLUGINS/src/status/Makefile @@ -1,51 +1,49 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.5 2012/03/11 15:34:20 kls Exp $ +# $Id: Makefile 2.10 2012/12/23 10:04:43 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# + PLUGIN = status ### The version number of this plugin (taken from the main source file): VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = $(PLUGIN)-$(VERSION) PACKAGE = vdr-$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -53,14 +51,14 @@ OBJS = $(PLUGIN).o ### The main target: -all: libvdr-$(PLUGIN).so +all: $(SOFILE) ### Implicit rules: %.o: %.c $(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) $< -# Dependencies: +### Dependencies: MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies @@ -71,9 +69,13 @@ $(DEPFILE): Makefile ### Targets: -libvdr-$(PLUGIN).so: $(OBJS) +$(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +install-lib: $(SOFILE) + install -D $^ $(LIBDIR)/$^.$(APIVERSION) + +install: install-lib dist: clean @-rm -rf $(TMPDIR)/$(ARCHIVE) diff --git a/PLUGINS/src/svdrpdemo/Makefile b/PLUGINS/src/svdrpdemo/Makefile index 5109b297..84eba02d 100644 --- a/PLUGINS/src/svdrpdemo/Makefile +++ b/PLUGINS/src/svdrpdemo/Makefile @@ -1,51 +1,49 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.5 2012/03/11 15:34:22 kls Exp $ +# $Id: Makefile 2.10 2012/12/23 10:04:47 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# + PLUGIN = svdrpdemo ### The version number of this plugin (taken from the main source file): VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell pkg-config --variable=$(1) vdr || pkg-config --variable=$(1) ../../../vdr.pc)) +LIBDIR = $(DESTDIR)$(call PKGCFG,libdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include $(VDRDIR)/Make.global +export CFLAGS = $(call PKGCFG,cflags) +export CXXFLAGS = $(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include $(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION = $(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = $(PLUGIN)-$(VERSION) PACKAGE = vdr-$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' ### The object files (add further files here): @@ -53,14 +51,14 @@ OBJS = $(PLUGIN).o ### The main target: -all: libvdr-$(PLUGIN).so +all: $(SOFILE) ### Implicit rules: %.o: %.c $(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) $< -# Dependencies: +### Dependencies: MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies @@ -71,9 +69,13 @@ $(DEPFILE): Makefile ### Targets: -libvdr-$(PLUGIN).so: $(OBJS) +$(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ - @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +install-lib: $(SOFILE) + install -D $^ $(LIBDIR)/$^.$(APIVERSION) + +install: install-lib dist: clean @-rm -rf $(TMPDIR)/$(ARCHIVE) diff --git a/config.h b/config.h index 5c962fb3..3624d9dc 100644 --- a/config.h +++ b/config.h @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: config.h 2.57 2012/12/05 11:33:20 kls Exp $ + * $Id: config.h 2.58 2012/12/11 09:59:16 kls Exp $ */ #ifndef __CONFIG_H @@ -22,13 +22,13 @@ // VDR's own version number: -#define VDRVERSION "1.7.33" -#define VDRVERSNUM 10733 // Version * 10000 + Major * 100 + Minor +#define VDRVERSION "1.7.34" +#define VDRVERSNUM 10734 // Version * 10000 + Major * 100 + Minor // The plugin API's version number: -#define APIVERSION "1.7.33" -#define APIVERSNUM 10733 // Version * 10000 + Major * 100 + Minor +#define APIVERSION "1.7.34" +#define APIVERSNUM 10734 // Version * 10000 + Major * 100 + Minor // When loading plugins, VDR searches them by their APIVERSION, which // may be smaller than VDRVERSION in case there have been no changes to diff --git a/libsi/Makefile b/libsi/Makefile index 9d2d40dd..dff5ca9c 100644 --- a/libsi/Makefile +++ b/libsi/Makefile @@ -1,27 +1,16 @@ # # Makefile for a libsi # -# $Id: Makefile 2.3 2012/01/18 12:31:40 kls Exp $ +# $Id: Makefile 2.4 2012/12/18 13:35:54 kls Exp $ -### The C++ compiler and options: +### The archiver options: -CXX ?= g++ -CXXFLAGS ?= -O2 -g -Wall -Woverloaded-virtual AR ?= ar ARFLAGS ?= ru RANLIB ?= ranlib -include ../Make.global -include ../Make.config -### The directory environment: - -INCLUDES += - -DEFINES += - -LIBS += - ### The object files (add further files here): OBJS = util.o si.o section.o descriptor.o @@ -31,7 +20,7 @@ OBJS = util.o si.o section.o descriptor.o %.o: %.c $(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) $< -# Dependencies: +### Dependencies: MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies diff --git a/menu.c b/menu.c index e2d34ed4..6c278b55 100644 --- a/menu.c +++ b/menu.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: menu.c 2.71 2012/12/07 13:48:15 kls Exp $ + * $Id: menu.c 2.72 2012/12/21 11:11:14 kls Exp $ */ #include "menu.h" @@ -172,7 +172,7 @@ public: cMenuEditChannel::cMenuEditChannel(cChannel *Channel, bool New) :cOsdMenu(tr("Edit channel"), 16) { - SetMenuCategory(mcChannel); + SetMenuCategory(mcChannelEdit); channel = Channel; sourceParam = NULL; *name = 0; @@ -878,7 +878,7 @@ eOSState cMenuFolder::ProcessKey(eKeys Key) cMenuEditTimer::cMenuEditTimer(cTimer *Timer, bool New) :cOsdMenu(tr("Edit timer"), 12) { - SetMenuCategory(mcTimer); + SetMenuCategory(mcTimerEdit); file = NULL; day = firstday = NULL; timer = Timer; @@ -1378,7 +1378,7 @@ const cEvent *cMenuWhatsOn::scheduleEvent = NULL; cMenuWhatsOn::cMenuWhatsOn(const cSchedules *Schedules, bool Now, int CurrentChannelNr) :cOsdMenu(Now ? tr("What's on now?") : tr("What's on next?"), CHNUMWIDTH, CHNAMWIDTH, 6, 4) { - SetMenuCategory(mcSchedule); + SetMenuCategory(Now ? mcScheduleNow : mcScheduleNext); now = Now; helpKeys = -1; timerState = 0; @@ -2120,7 +2120,7 @@ public: cMenuRecording::cMenuRecording(const cRecording *Recording, bool WithButtons) :cOsdMenu(tr("Recording info")) { - SetMenuCategory(mcRecording); + SetMenuCategory(mcRecordingInfo); recording = Recording; withButtons = WithButtons; if (withButtons) @@ -2534,6 +2534,7 @@ public: cMenuSetupOSD::cMenuSetupOSD(void) { + SetMenuCategory(mcSetupOsd); osdLanguageIndex = I18nCurrentLanguage(); numSkins = Skins.Count(); skinIndex = originalSkinIndex = Skins.Current()->Index(); @@ -2683,6 +2684,7 @@ public: cMenuSetupEPG::cMenuSetupEPG(void) { + SetMenuCategory(mcSetupEpg); for (numLanguages = 0; numLanguages < I18nLanguages()->Size() && data.EPGLanguages[numLanguages] >= 0; numLanguages++) ; originalNumLanguages = numLanguages; @@ -2779,6 +2781,7 @@ public: cMenuSetupDVB::cMenuSetupDVB(void) { + SetMenuCategory(mcSetupDvb); for (numAudioLanguages = 0; numAudioLanguages < I18nLanguages()->Size() && data.AudioLanguages[numAudioLanguages] >= 0; numAudioLanguages++) ; for (numSubtitleLanguages = 0; numSubtitleLanguages < I18nLanguages()->Size() && data.SubtitleLanguages[numSubtitleLanguages] >= 0; numSubtitleLanguages++) @@ -2924,6 +2927,7 @@ public: cMenuSetupLNB::cMenuSetupLNB(void) :satCableNumbers(MAXDEVICES) { + SetMenuCategory(mcSetupLnb); satCableNumbers.FromString(data.DeviceBondings); SetSection(tr("LNB")); Setup(); @@ -3025,6 +3029,7 @@ public: cMenuSetupCAM::cMenuSetupCAM(void) { + SetMenuCategory(mcSetupCam); SetSection(tr("CAM")); SetCols(15); SetHasHotkeys(); @@ -3103,6 +3108,7 @@ public: cMenuSetupRecord::cMenuSetupRecord(void) { + SetMenuCategory(mcSetupRecord); pauseKeyHandlingTexts[0] = tr("do not pause live video"); pauseKeyHandlingTexts[1] = tr("confirm pause live video"); pauseKeyHandlingTexts[2] = tr("pause live video"); @@ -3139,6 +3145,7 @@ public: cMenuSetupReplay::cMenuSetupReplay(void) { + SetMenuCategory(mcSetupReplay); SetSection(tr("Replay")); Add(new cMenuEditBoolItem(tr("Setup.Replay$Multi speed mode"), &data.MultiSpeedMode)); Add(new cMenuEditBoolItem(tr("Setup.Replay$Show replay mode"), &data.ShowReplayMode)); @@ -3164,6 +3171,7 @@ public: cMenuSetupMisc::cMenuSetupMisc(void) { + SetMenuCategory(mcSetupMisc); SetSection(tr("Miscellaneous")); Add(new cMenuEditIntItem( tr("Setup.Miscellaneous$Min. event timeout (min)"), &data.MinEventTimeout)); Add(new cMenuEditIntItem( tr("Setup.Miscellaneous$Min. user inactivity (min)"), &data.MinUserInactivity)); @@ -3203,6 +3211,7 @@ public: cMenuSetupPlugins::cMenuSetupPlugins(void) { + SetMenuCategory(mcSetupPlugins); SetSection(tr("Plugins")); SetHasHotkeys(); for (int i = 0; ; i++) { diff --git a/menuitems.c b/menuitems.c index 416c2beb..63f75898 100644 --- a/menuitems.c +++ b/menuitems.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: menuitems.c 2.14 2012/04/08 11:20:37 kls Exp $ + * $Id: menuitems.c 2.15 2012/12/23 13:44:05 kls Exp $ */ #include "menuitems.h" @@ -1152,6 +1152,7 @@ eOSState cMenuSetupPage::ProcessKey(eKeys Key) void cMenuSetupPage::SetPlugin(cPlugin *Plugin) { + SetMenuCategory(mcPluginSetup); plugin = Plugin; SetSection(cString::sprintf("%s '%s'", tr("Plugin"), plugin->Name())); } diff --git a/newplugin b/newplugin index 59a9435c..a7bd5fcb 100755 --- a/newplugin +++ b/newplugin @@ -12,7 +12,7 @@ # See the main source file 'vdr.c' for copyright information and # how to reach the author. # -# $Id: newplugin 2.8 2012/03/11 15:34:26 kls Exp $ +# $Id: newplugin 2.14 2012/12/23 10:05:22 kls Exp $ $PLUGIN_NAME = $ARGV[0] || die "Usage: newplugin \n"; @@ -65,48 +65,45 @@ $MAKEFILE = qq # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. # By default the main source file also carries this name. -# IMPORTANT: the presence of this macro is important for the Make.config -# file. So it must be defined, even if it is not used here! -# + PLUGIN = $PLUGIN_NAME ### The version number of this plugin (taken from the main source file): VERSION = \$(shell grep 'static const char \\*VERSION *=' \$(PLUGIN).c | awk '{ print \$\$6 }' | sed -e 's/[";]//g') -### The C++ compiler and options: - -CXX ?= g++ -CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses - ### The directory environment: -VDRDIR ?= ../../.. -LIBDIR ?= ../../lib +# Use package data if installed...otherwise assume we're under the VDR source directory: +PKGCFG = \$(if \$(VDRDIR),\$(shell pkg-config --variable=\$(1) \$(VDRDIR)/vdr.pc),\$(shell pkg-config --variable=\$(1) vdr || pkg-config --variable=\$(1) ../../../vdr.pc)) +LIBDIR = \$(DESTDIR)\$(call PKGCFG,libdir) +LOCDIR = \$(DESTDIR)\$(call PKGCFG,locdir) +# TMPDIR ?= /tmp -### Make sure that necessary options are included: +### The compiler options: -include \$(VDRDIR)/Make.global +export CFLAGS = \$(call PKGCFG,cflags) +export CXXFLAGS = \$(call PKGCFG,cxxflags) -### Allow user defined options to overwrite defaults: +### The version number of VDR's plugin API: --include \$(VDRDIR)/Make.config - -### The version number of VDR's plugin API (taken from VDR's "config.h"): - -APIVERSION = \$(shell sed -ne '/define APIVERSION/s/^.*"\\(.*\\)".*\$\$/\\1/p' \$(VDRDIR)/config.h) +APIVERSION = \$(call PKGCFG,apiversion) ### The name of the distribution archive: ARCHIVE = \$(PLUGIN)-\$(VERSION) PACKAGE = vdr-\$(ARCHIVE) +### The name of the shared object file: + +SOFILE = libvdr-\$(PLUGIN).so + ### Includes and Defines (add further entries here): -INCLUDES += -I\$(VDRDIR)/include +INCLUDES += -DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"\$(PLUGIN)"' +DEFINES += -DPLUGIN_NAME_I18N='"\$(PLUGIN)"' ### The object files (add further files here): @@ -114,7 +111,7 @@ OBJS = \$(PLUGIN).o ### The main target: -all: libvdr-\$(PLUGIN).so i18n +all: \$(SOFILE) i18n ### Implicit rules: @@ -133,33 +130,38 @@ DEPFILE = .dependencies ### Internationalization (I18N): PODIR = po -LOCALEDIR = \$(VDRDIR)/locale I18Npo = \$(wildcard \$(PODIR)/*.po) -I18Nmsgs = \$(addprefix \$(LOCALEDIR)/, \$(addsuffix /LC_MESSAGES/vdr-\$(PLUGIN).mo, \$(notdir \$(foreach file, \$(I18Npo), \$(basename \$(file)))))) +I18Nmo = \$(addsuffix .mo, \$(foreach file, \$(I18Npo), \$(basename \$(file)))) +I18Nmsgs = \$(addprefix \$(LOCDIR)/, \$(addsuffix /LC_MESSAGES/vdr-\$(PLUGIN).mo, \$(notdir \$(foreach file, \$(I18Npo), \$(basename \$(file)))))) I18Npot = \$(PODIR)/\$(PLUGIN).pot %.mo: %.po msgfmt -c -o \$\@ \$< \$(I18Npot): \$(wildcard *.c) - xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=vdr-\$(PLUGIN) --package-version=\$(VERSION) --msgid-bugs-address='' -o \$\@ \$^ + xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=vdr-\$(PLUGIN) --package-version=\$(VERSION) --msgid-bugs-address='' -o \$\@ `ls \$^` %.po: \$(I18Npot) - msgmerge -U --no-wrap --no-location --backup=none -q \$\@ \$< + msgmerge -U --no-wrap --no-location --backup=none -q -N \$\@ \$< \@touch \$\@ -\$(I18Nmsgs): \$(LOCALEDIR)/%/LC_MESSAGES/vdr-\$(PLUGIN).mo: \$(PODIR)/%.mo - \@mkdir -p \$(dir \$@) - cp \$< \$\@ +\$(I18Nmsgs): \$(LOCDIR)/%/LC_MESSAGES/vdr-\$(PLUGIN).mo: \$(PODIR)/%.mo + install -D -m644 \$< \$\@ .PHONY: i18n -i18n: \$(I18Nmsgs) \$(I18Npot) +i18n: \$(I18Nmo) \$(I18Npot) + +install-i18n: \$(I18Nmsgs) ### Targets: -libvdr-\$(PLUGIN).so: \$(OBJS) +\$(SOFILE): \$(OBJS) \$(CXX) \$(CXXFLAGS) \$(LDFLAGS) -shared \$(OBJS) -o \$\@ - \@cp --remove-destination \$\@ \$(LIBDIR)/\$\@.\$(APIVERSION) + +install-lib: \$(SOFILE) + install -D \$^ \$(LIBDIR)/\$^.\$(APIVERSION) + +install: install-lib install-i18n dist: \$(I18Npo) clean \@-rm -rf \$(TMPDIR)/\$(ARCHIVE) @@ -170,7 +172,8 @@ dist: \$(I18Npo) clean \@echo Distribution package created as \$(PACKAGE).tgz clean: - \@-rm -f \$(OBJS) \$(DEPFILE) *.so *.tgz core* *~ \$(PODIR)/*.mo \$(PODIR)/*.pot + \@-rm -f \$(PODIR)/*.mo \$(PODIR)/*.pot + \@-rm -f \$(OBJS) \$(DEPFILE) *.so *.tgz core* *~ }; $MAIN = qq @@ -349,4 +352,3 @@ sub CreateFile print FILE $Content; close(FILE); } - diff --git a/osd.c b/osd.c index d82a27bc..75f13f4b 100644 --- a/osd.c +++ b/osd.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: osd.c 2.32 2012/06/09 14:37:24 kls Exp $ + * $Id: osd.c 2.33 2012/12/15 11:16:41 kls Exp $ */ #include "osd.h" @@ -1683,9 +1683,7 @@ void cOsd::SetAntiAliasGranularity(uint FixedColors, uint BlendColors) cBitmap *cOsd::GetBitmap(int Area) { - if (isTrueColor) - Area = 0; // returns the dummy bitmap - return Area < numBitmaps ? bitmaps[Area] : NULL; + return Area < numBitmaps ? (isTrueColor ? bitmaps[0] : bitmaps[Area]) : NULL; } cPixmap *cOsd::CreatePixmap(int Layer, const cRect &ViewPort, const cRect &DrawPort) diff --git a/po/ar.po b/po/ar.po index 43b1c659..946cc663 100644 --- a/po/ar.po +++ b/po/ar.po @@ -1418,6 +1418,3 @@ msgstr "القرص الصلب" msgid "free" msgstr "مساحة حرة" - -#~ msgid "Error while accessing recording!" -#~ msgstr "حدث خطاء عند محاولة الوصول لتسجيلات" diff --git a/po/ca_ES.po b/po/ca_ES.po index ea4dc9d6..437542fd 100644 --- a/po/ca_ES.po +++ b/po/ca_ES.po @@ -1392,6 +1392,3 @@ msgstr "Disc" msgid "free" msgstr "lliure" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Error a l'accedir a la gravaci!" diff --git a/po/cs_CZ.po b/po/cs_CZ.po index 2facfbdd..b0d5b7d1 100644 --- a/po/cs_CZ.po +++ b/po/cs_CZ.po @@ -1391,6 +1391,3 @@ msgstr "Disk" msgid "free" msgstr "volno" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Chyba při přístupu k nahrávkám!" diff --git a/po/da_DK.po b/po/da_DK.po index cbe950ff..6ca6c86a 100644 --- a/po/da_DK.po +++ b/po/da_DK.po @@ -1389,6 +1389,3 @@ msgstr "Disk" msgid "free" msgstr "fri" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Fejl ved lsning af optagelse!" diff --git a/po/de_DE.po b/po/de_DE.po index 1177d937..5476d9c7 100644 --- a/po/de_DE.po +++ b/po/de_DE.po @@ -1389,6 +1389,3 @@ msgstr "Disk" msgid "free" msgstr "frei" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Fehler beim Ansprechen der Aufzeichnung!" diff --git a/po/el_GR.po b/po/el_GR.po index 05f9e71d..bf8933ec 100644 --- a/po/el_GR.po +++ b/po/el_GR.po @@ -1389,6 +1389,3 @@ msgstr " msgid "free" msgstr "" - -#~ msgid "Error while accessing recording!" -#~ msgstr " !" diff --git a/po/es_ES.po b/po/es_ES.po index 9885f84d..6a6f4e42 100644 --- a/po/es_ES.po +++ b/po/es_ES.po @@ -1390,6 +1390,3 @@ msgstr "Disco" msgid "free" msgstr "libre" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Error al acceder a la grabacin!" diff --git a/po/et_EE.po b/po/et_EE.po index d9b0d77b..1d342366 100644 --- a/po/et_EE.po +++ b/po/et_EE.po @@ -23,7 +23,7 @@ msgid "Channel not available!" msgstr "Kanal ei ole kättesaadav!" msgid "Can't start Transfer Mode!" -msgstr "Siirderežiimi start nurjus!" +msgstr "Siirderežiimi start ebaõnnestus!" msgid "off" msgstr "väljas" @@ -411,7 +411,7 @@ msgid "Key$Info" msgstr "Info" msgid "Key$Play/Pause" -msgstr "" +msgstr "Start/Paus" msgid "Key$Play" msgstr "Start" @@ -748,7 +748,7 @@ msgid "Recording is being edited - really delete?" msgstr "Salvestust on muudetud - kas kustutada?" msgid "Error while deleting recording!" -msgstr "Salvestuse kustutamine nurjus!" +msgstr "Salvestuse kustutamine ebaõnnestus!" msgid "Recording commands" msgstr "Salvestuse käsud" @@ -850,16 +850,16 @@ msgid "Setup.OSD$Number keys for characters" msgstr "Teksti sisestamine numbriklahvidega" msgid "Setup.OSD$Color key 0" -msgstr "" +msgstr "Värviklahv 0" msgid "Setup.OSD$Color key 1" -msgstr "" +msgstr "Värviklahv 1" msgid "Setup.OSD$Color key 2" -msgstr "" +msgstr "Värviklahv 2" msgid "Setup.OSD$Color key 3" -msgstr "" +msgstr "Värviklahv 3" msgid "EPG" msgstr "EPG" @@ -930,7 +930,7 @@ msgid "Setup.DVB$Primary DVB interface" msgstr "Esmane DVB seade" msgid "Setup.DVB$Standard compliance" -msgstr "" +msgstr "Standardivastavavus" msgid "Setup.DVB$Video format" msgstr "TV külgsuhe" @@ -1018,7 +1018,7 @@ msgid "CAM is in use - really reset?" msgstr "CAM on kasutuses - taaskäivitada?" msgid "Can't reset CAM!" -msgstr "CAM mooduli taaskäivitus nurjus!" +msgstr "CAM mooduli taaskäivitus ebaõnnestus!" msgid "do not pause live video" msgstr "mitte peatada" @@ -1078,16 +1078,16 @@ msgid "Setup.Recording$Instant rec. time (min)" msgstr "Kiirsalvestuse kestus (min)" msgid "Setup.Recording$present event" -msgstr "" +msgstr "hetkesündmus" msgid "Setup.Recording$Max. video file size (MB)" msgstr "Maks. failisuurus (MB)" msgid "Setup.Recording$Split edited files" -msgstr "Failide jupitamine" +msgstr "Redigeeritud failide tükeldamine" msgid "Setup.Recording$Delete timeshift recording" -msgstr "Kustutada ajanihke salvestus" +msgstr "Ajanihke salvestuse kustutamine" msgid "Replay" msgstr "Taasesitus" @@ -1102,10 +1102,10 @@ msgid "Setup.Replay$Show remaining time" msgstr "Järelejäänud aja kuvamine" msgid "Setup.Replay$Progress display time (s)" -msgstr "" +msgstr "Edenemiseriba kuvamise aeg (s)" msgid "Setup.Replay$Pause replay when setting mark" -msgstr "" +msgstr "Taasesituse peatamine markeri seadmisel" msgid "Setup.Replay$Resume ID" msgstr "Jätkamise ID" @@ -1141,7 +1141,7 @@ msgid "Setup.Miscellaneous$Channels wrap" msgstr "Kanalite ringkerimine" msgid "Setup.Miscellaneous$Show channel names with source" -msgstr "" +msgstr "Kanalinimed allikaga" msgid "Setup.Miscellaneous$Emergency exit" msgstr "Hädaväljumine" @@ -1220,10 +1220,10 @@ msgid "No editing marks defined!" msgstr "Redigeerimise markerid puuduvad!" msgid "No editing sequences defined!" -msgstr "" +msgstr "Redigeerimise järjestus puudub!" msgid "Can't start editing process!" -msgstr "Redigeerimise start nurjus!" +msgstr "Redigeerimise start ebaõnnestus!" msgid "Editing process started" msgstr "Redigeerimine käivitatud" @@ -1265,10 +1265,10 @@ msgid "Index file regeneration complete" msgstr "Indeksfaili regenereerimine lõpetatud" msgid "Index file regeneration failed!" -msgstr "" +msgstr "Indeksfaili regenereerimine ebaõnnestus!" msgid "Can't shutdown - option '-s' not given!" -msgstr "Väljalülitamine nurjus - '-s' parameeter puudub!" +msgstr "Väljalülitamine ebaõnnestus - '-s' parameeter puudub!" msgid "Editing - shut down anyway?" msgstr "Redigeerimine aktiive - lülitada välja?" @@ -1304,22 +1304,22 @@ msgid "Classic VDR" msgstr "Classic VDR" msgid "DISK" -msgstr "" +msgstr "KETAS" msgid "LOAD" -msgstr "" +msgstr "KOORMUS" msgid "TIMERS" -msgstr "" +msgstr "TAIMERID" msgid "DEVICES" -msgstr "" +msgstr "SEADMED" msgid "LIVE" -msgstr "" +msgstr "LIVE" msgid "PLAY" -msgstr "" +msgstr "ESITUS" msgid "ST:TNG Panels" msgstr "ST:TNG Panels" @@ -1372,7 +1372,7 @@ msgid "Switching primary DVB..." msgstr "Esmase DVB seadme ümberlülitus..." msgid "Editing process failed!" -msgstr "Redigeerimine nurjus" +msgstr "Redigeerimine ebaõnnestus!" msgid "Editing process finished" msgstr "Redigeerimine lõpetatud" @@ -1389,6 +1389,3 @@ msgstr "Ketas" msgid "free" msgstr "vaba" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Salvestuse taasesitus nurjus!" diff --git a/po/fi_FI.po b/po/fi_FI.po index 0dd0d59c..9a9fa747 100644 --- a/po/fi_FI.po +++ b/po/fi_FI.po @@ -1392,6 +1392,3 @@ msgstr "Levy" msgid "free" msgstr "vapaana" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Tallenteen toistaminen epäonnistui!" diff --git a/po/fr_FR.po b/po/fr_FR.po index 0ded14e5..55983d40 100644 --- a/po/fr_FR.po +++ b/po/fr_FR.po @@ -1395,6 +1395,3 @@ msgstr "Disque" msgid "free" msgstr "restant" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Impossible d'accder l'enregistrement" diff --git a/po/hr_HR.po b/po/hr_HR.po index c7c65711..b7b2d4f4 100644 --- a/po/hr_HR.po +++ b/po/hr_HR.po @@ -1391,6 +1391,3 @@ msgstr "Disk" msgid "free" msgstr "slobodno" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Greka pri pristupanju snimke!" diff --git a/po/hu_HU.po b/po/hu_HU.po index 19aec438..919d3b2d 100644 --- a/po/hu_HU.po +++ b/po/hu_HU.po @@ -1393,6 +1393,3 @@ msgstr "Lemez" msgid "free" msgstr "szabad" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Hiba a felvtel hozzfrsnl" diff --git a/po/it_IT.po b/po/it_IT.po index 6d0bd7c9..8df7150f 100644 --- a/po/it_IT.po +++ b/po/it_IT.po @@ -12,7 +12,7 @@ msgstr "" "Project-Id-Version: VDR 1.6.0\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2012-12-07 14:59+0100\n" -"PO-Revision-Date: 2012-06-06 22:50+0100\n" +"PO-Revision-Date: 2012-12-22 19:00+0100\n" "Last-Translator: Diego Pierotto \n" "Language-Team: Italian \n" "Language: it\n" @@ -418,7 +418,7 @@ msgid "Key$Info" msgstr "Info" msgid "Key$Play/Pause" -msgstr "" +msgstr "Riproduci/Pausa" msgid "Key$Play" msgstr "Riproduci" @@ -857,16 +857,16 @@ msgid "Setup.OSD$Number keys for characters" msgstr "Tasti numerici per i caratteri" msgid "Setup.OSD$Color key 0" -msgstr "" +msgstr "Tasto colore 0" msgid "Setup.OSD$Color key 1" -msgstr "" +msgstr "Tasto colore 1" msgid "Setup.OSD$Color key 2" -msgstr "" +msgstr "Tasto colore 2" msgid "Setup.OSD$Color key 3" -msgstr "" +msgstr "Tasto colore 3" msgid "EPG" msgstr "Guida programmi EPG" @@ -1085,7 +1085,7 @@ msgid "Setup.Recording$Instant rec. time (min)" msgstr "Durata reg. immediata (min)" msgid "Setup.Recording$present event" -msgstr "" +msgstr "evento attuale" msgid "Setup.Recording$Max. video file size (MB)" msgstr "Dim. massima file video (MB)" @@ -1109,10 +1109,10 @@ msgid "Setup.Replay$Show remaining time" msgstr "Mostra tempo rimanente" msgid "Setup.Replay$Progress display time (s)" -msgstr "" +msgstr "Mostra tempo elaborazione (s)" msgid "Setup.Replay$Pause replay when setting mark" -msgstr "" +msgstr "Pausa riproduzione durante impostazione segni" msgid "Setup.Replay$Resume ID" msgstr "ID di ripristino" @@ -1148,7 +1148,7 @@ msgid "Setup.Miscellaneous$Channels wrap" msgstr "Riavvolgimento canali" msgid "Setup.Miscellaneous$Show channel names with source" -msgstr "" +msgstr "Mostra nomi canali con la sorgente" msgid "Setup.Miscellaneous$Emergency exit" msgstr "Uscita di emergenza" @@ -1227,7 +1227,7 @@ msgid "No editing marks defined!" msgstr "Nessun marcatore di modifica definito!" msgid "No editing sequences defined!" -msgstr "" +msgstr "Nessuna sequenza di modifica definita!" msgid "Can't start editing process!" msgstr "Impossibile avviare il processo di modifica!" @@ -1272,7 +1272,7 @@ msgid "Index file regeneration complete" msgstr "Rigenerazione file indice completata" msgid "Index file regeneration failed!" -msgstr "" +msgstr "Rigenerazione file indice fallita!" msgid "Can't shutdown - option '-s' not given!" msgstr "Impossibile spegnere - parametro '-s' non assegnato!" @@ -1396,6 +1396,3 @@ msgstr "Disco" msgid "free" msgstr "disponibili" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Errore accesso alla registrazione!" diff --git a/po/lt_LT.po b/po/lt_LT.po index d2edb6ec..931900ff 100644 --- a/po/lt_LT.po +++ b/po/lt_LT.po @@ -1389,6 +1389,3 @@ msgstr "Diskas" msgid "free" msgstr "laisva" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Klaida atidarant įrašą!" diff --git a/po/mk_MK.po b/po/mk_MK.po index 8a6dc585..b7570b66 100644 --- a/po/mk_MK.po +++ b/po/mk_MK.po @@ -1390,6 +1390,3 @@ msgstr "Диск" msgid "free" msgstr "слободен" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Грешка при пристап до снимката!" diff --git a/po/nl_NL.po b/po/nl_NL.po index 958411c0..a7dbadf1 100644 --- a/po/nl_NL.po +++ b/po/nl_NL.po @@ -1393,6 +1393,3 @@ msgstr "Schijf" msgid "free" msgstr "vrij" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Fout bij lezen opname!" diff --git a/po/nn_NO.po b/po/nn_NO.po index 2aa373e0..aeeb0bb4 100644 --- a/po/nn_NO.po +++ b/po/nn_NO.po @@ -1390,6 +1390,3 @@ msgstr "Disk" msgid "free" msgstr "ledig" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Feil under lesing av opptak!" diff --git a/po/pl_PL.po b/po/pl_PL.po index 0e6f0981..c4e36d78 100644 --- a/po/pl_PL.po +++ b/po/pl_PL.po @@ -1390,6 +1390,3 @@ msgstr "Dysk" msgid "free" msgstr "wolnego" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Bld podczas dostpu do nagrania!" diff --git a/po/pt_PT.po b/po/pt_PT.po index e1327692..44f10359 100644 --- a/po/pt_PT.po +++ b/po/pt_PT.po @@ -1390,6 +1390,3 @@ msgstr "Disco" msgid "free" msgstr "livre" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Erro a aceder s gravaes!" diff --git a/po/ro_RO.po b/po/ro_RO.po index d5d64210..ffdb44c8 100644 --- a/po/ro_RO.po +++ b/po/ro_RO.po @@ -1392,6 +1392,3 @@ msgstr "Disc" msgid "free" msgstr "liber" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Eroare la accesarea înregistrării" diff --git a/po/ru_RU.po b/po/ru_RU.po index 892cfe78..42bdcc92 100644 --- a/po/ru_RU.po +++ b/po/ru_RU.po @@ -1390,6 +1390,3 @@ msgstr " msgid "free" msgstr "" - -#~ msgid "Error while accessing recording!" -#~ msgstr " !" diff --git a/po/sk_SK.po b/po/sk_SK.po index 48d882b5..118747a6 100644 --- a/po/sk_SK.po +++ b/po/sk_SK.po @@ -1389,6 +1389,3 @@ msgstr "Disk" msgid "free" msgstr "volne" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Chyba pri prstupe k nahrvkam!" diff --git a/po/sl_SI.po b/po/sl_SI.po index 75514bce..d3ef84c6 100644 --- a/po/sl_SI.po +++ b/po/sl_SI.po @@ -1390,6 +1390,3 @@ msgstr "Disk" msgid "free" msgstr "prosto" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Napaka pri dostopu do posnetka!" diff --git a/po/sr_SR.po b/po/sr_SR.po index 51196479..0a73f121 100644 --- a/po/sr_SR.po +++ b/po/sr_SR.po @@ -1416,6 +1416,3 @@ msgstr "Disk" msgid "free" msgstr "slobodno" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Greka prilikom pristupa snimanju!" diff --git a/po/sv_SE.po b/po/sv_SE.po index 067adf55..3c496468 100644 --- a/po/sv_SE.po +++ b/po/sv_SE.po @@ -1392,6 +1392,3 @@ msgstr "Disk" msgid "free" msgstr "ledigt" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Inspelningen gr inte att lsa!" diff --git a/po/tr_TR.po b/po/tr_TR.po index 78177e75..8b83d5fb 100644 --- a/po/tr_TR.po +++ b/po/tr_TR.po @@ -1389,6 +1389,3 @@ msgstr "Disk" msgid "free" msgstr "bo" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Kayt okuma hatas!" diff --git a/po/uk_UA.po b/po/uk_UA.po index edc5a7c8..21ef7901 100644 --- a/po/uk_UA.po +++ b/po/uk_UA.po @@ -1389,6 +1389,3 @@ msgstr "Диск" msgid "free" msgstr "вільно" - -#~ msgid "Error while accessing recording!" -#~ msgstr "Помилка доступу до запису!" diff --git a/po/zh_CN.po b/po/zh_CN.po index 73e84fd4..a03396e1 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po @@ -1392,6 +1392,3 @@ msgstr "硬盘已使用" msgid "free" msgstr "可录像时间" - -#~ msgid "Error while accessing recording!" -#~ msgstr "存取录像错误!" diff --git a/recording.c b/recording.c index 87ca8efe..ca50f433 100644 --- a/recording.c +++ b/recording.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: recording.c 2.78 2012/12/06 09:35:13 kls Exp $ + * $Id: recording.c 2.81 2012/12/23 15:11:28 kls Exp $ */ #include "recording.h" @@ -1666,7 +1666,8 @@ void cIndexFileGenerator::Action(void) #define INDEXFILESUFFIX "/index" // The maximum time to wait before giving up while catching up on an index file: -#define MAXINDEXCATCHUP 8 // seconds +#define MAXINDEXCATCHUP 8 // number of retries +#define INDEXCATCHUPWAIT 100 // milliseconds struct tIndexPes { uint32_t offset; @@ -1693,9 +1694,6 @@ struct tIndexTs { #define INDEXFILECHECKINTERVAL 500 // ms between checks for existence of the regenerated index file #define INDEXFILETESTINTERVAL 10 // ms between tests for the size of the index file in case of pausing live video -cMutex cIndexFile::indexListMutex; -cVector cIndexFile::indexList; - cIndexFile::cIndexFile(const char *FileName, bool Record, bool IsPesRecording, bool PauseLive) :resumeFile(FileName, IsPesRecording) { @@ -1776,13 +1774,10 @@ cIndexFile::cIndexFile(const char *FileName, bool Record, bool IsPesRecording, b LOG_ERROR_STR(*fileName); } } - if (Record) - AddToIndexList(this); } cIndexFile::~cIndexFile() { - RemoveFromIndexList(this); if (f >= 0) close(f); free(index); @@ -1824,14 +1819,11 @@ bool cIndexFile::CatchUp(int Index) // returns true unless something really goes wrong, so that 'index' becomes NULL if (index && f >= 0) { cMutexLock MutexLock(&mutex); - for (int i = 0; i <= MAXINDEXCATCHUP && (Index < 0 || Index > last); i++) { + // Note that CatchUp() is triggered even if Index is 'last' (and thus valid). + // This is done to make absolutely sure we don't miss any data at the very end. + for (int i = 0; i <= MAXINDEXCATCHUP && (Index < 0 || Index >= last); i++) { struct stat buf; if (fstat(f, &buf) == 0) { - if (!IsInIndexList(this)) { - close(f); - f = -1; - break; - } int newLast = int(buf.st_size / sizeof(tIndexTs) - 1); if (newLast > last) { int NewSize = size; @@ -1869,9 +1861,9 @@ bool cIndexFile::CatchUp(int Index) } else LOG_ERROR_STR(*fileName); - if (Index <= last) + if (Index < last) break; - cCondWait::SleepMs(1000); + cCondWait::SleepMs(INDEXCATCHUPWAIT); } } return index != NULL; @@ -1937,15 +1929,16 @@ int cIndexFile::GetNextIFrame(int Index, bool Forward, uint16_t *FileNumber, off *FileNumber = index[Index].number; *FileOffset = index[Index].offset; if (Length) { - // all recordings end with a non-independent frame, so the following should be safe: - uint16_t fn = index[Index + 1].number; - off_t fo = index[Index + 1].offset; - if (fn == *FileNumber) - *Length = int(fo - *FileOffset); - else { - esyslog("ERROR: 'I' frame at end of file #%d", *FileNumber); - *Length = -1; + if (Index < last) { + uint16_t fn = index[Index + 1].number; + off_t fo = index[Index + 1].offset; + if (fn == *FileNumber) + *Length = int(fo - *FileOffset); + else + *Length = -1; // this means "everything up to EOF" (the buffer's Read function will act accordingly) } + else + *Length = -1; } return Index; } @@ -2025,39 +2018,6 @@ int cIndexFile::GetLength(const char *FileName, bool IsPesRecording) return -1; } -void cIndexFile::AddToIndexList(const cIndexFile *IndexFile) -{ - cMutexLock MutexLock(&indexListMutex); - for (int i = 0; i < indexList.Size(); i++) { - if (!indexList[i]) { - indexList[i] = IndexFile; - return; - } - } - indexList.Append(IndexFile); -} - -void cIndexFile::RemoveFromIndexList(const cIndexFile *IndexFile) -{ - cMutexLock MutexLock(&indexListMutex); - for (int i = 0; i < indexList.Size(); i++) { - if (indexList[i] == IndexFile) { - indexList[i] = NULL; - return; - } - } -} - -bool cIndexFile::IsInIndexList(const cIndexFile *IndexFile) -{ - cMutexLock MutexLock(&indexListMutex); - for (int i = 0; i < indexList.Size(); i++) { - if (indexList[i] && !strcmp(indexList[i]->fileName, IndexFile->fileName)) - return true; - } - return false; -} - bool GenerateIndex(const char *FileName) { if (DirectoryOk(FileName)) { diff --git a/recording.h b/recording.h index 9ae9b1ec..f555024c 100644 --- a/recording.h +++ b/recording.h @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: recording.h 2.40 2012/11/13 11:43:59 kls Exp $ + * $Id: recording.h 2.41 2012/12/23 15:11:53 kls Exp $ */ #ifndef __RECORDING_H @@ -292,11 +292,6 @@ private: cResumeFile resumeFile; cIndexFileGenerator *indexFileGenerator; cMutex mutex; - static cMutex indexListMutex; - static cVector indexList; - static void AddToIndexList(const cIndexFile *IndexFile); - static void RemoveFromIndexList(const cIndexFile *IndexFile); - static bool IsInIndexList(const cIndexFile *IndexFile); void ConvertFromPes(tIndexTs *IndexTs, int Count); void ConvertToPes(tIndexTs *IndexTs, int Count); bool CatchUp(int Index = -1); diff --git a/skins.h b/skins.h index 25061268..c9750b82 100644 --- a/skins.h +++ b/skins.h @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: skins.h 2.7 2012/12/07 17:18:44 kls Exp $ + * $Id: skins.h 2.9 2012/12/21 11:09:13 kls Exp $ */ #ifndef __SKINS_H @@ -73,7 +73,37 @@ public: */ }; -enum eMenuCategory { mcUndefined = -1, mcUnknown = 0, mcMain, mcSchedule, mcChannel, mcTimer, mcRecording, mcPlugin, mcSetup, mcCommand, mcEvent, mcText, mcFolder, mcCam }; +enum eMenuCategory { + mcUndefined = -1, + mcUnknown = 0, + mcMain, + mcSchedule, + mcScheduleNow, + mcScheduleNext, + mcChannel, + mcChannelEdit, + mcTimer, + mcTimerEdit, + mcRecording, + mcRecordingInfo, + mcPlugin, + mcPluginSetup, + mcSetup, + mcSetupOsd, + mcSetupEpg, + mcSetupDvb, + mcSetupLnb, + mcSetupCam, + mcSetupRecord, + mcSetupReplay, + mcSetupMisc, + mcSetupPlugins, + mcCommand, + mcEvent, + mcText, + mcFolder, + mcCam + }; class cSkinDisplayMenu : public cSkinDisplay { ///< This class implements the general purpose menu display, which is @@ -153,7 +183,7 @@ public: ///< this function will be first called for the old current item ///< with Current set to false, and then for the new current item ///< with Current set to true. - virtual bool SetItemEvent(const cEvent *Event, int Index, bool Current, bool Selectable, const cChannel *Channel, bool WithDate, int TimerMatch) { return false; } + virtual bool SetItemEvent(const cEvent *Event, int Index, bool Current, bool Selectable, const cChannel *Channel, bool WithDate, eTimerMatch TimerMatch) { return false; } ///< Sets the item at the given Index to Event. See SetItem() for more information. ///< If a derived skin class implements this function, it can display an Event item ///< in a more elaborate way than just a simple line of text.