diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2013-01-06 18:48:29 +0100 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2013-01-06 18:48:29 +0100 |
commit | 188fe74c8a1c917179baaf9d296c6d4eedf22c6f (patch) | |
tree | 61d769b7d8c6348490cea7ef536de9ca6a0b6dde | |
parent | 36dfa5cb8f667c3f92d870977afcb6a1cfb91efe (diff) | |
download | vdr-188fe74c8a1c917179baaf9d296c6d4eedf22c6f.tar.gz vdr-188fe74c8a1c917179baaf9d296c6d4eedf22c6f.tar.bz2 |
Modified the Makefiles, by default VDR is now built according to the FHS
-rw-r--r-- | HISTORY | 13 | ||||
-rw-r--r-- | INSTALL | 29 | ||||
-rw-r--r-- | Make.config.template | 54 | ||||
-rw-r--r-- | Makefile | 171 | ||||
-rw-r--r-- | PLUGINS/src/dvbsddevice/Makefile | 8 | ||||
-rw-r--r-- | PLUGINS/src/epgtableid0/Makefile | 8 | ||||
-rw-r--r-- | PLUGINS/src/hello/Makefile | 14 | ||||
-rw-r--r-- | PLUGINS/src/osddemo/Makefile | 8 | ||||
-rw-r--r-- | PLUGINS/src/pictures/Makefile | 14 | ||||
-rw-r--r-- | PLUGINS/src/rcu/Makefile | 8 | ||||
-rw-r--r-- | PLUGINS/src/servicedemo/Makefile | 10 | ||||
-rw-r--r-- | PLUGINS/src/skincurses/Makefile | 14 | ||||
-rw-r--r-- | PLUGINS/src/status/Makefile | 8 | ||||
-rw-r--r-- | PLUGINS/src/svdrpdemo/Makefile | 8 | ||||
-rwxr-xr-x | newplugin | 14 |
15 files changed, 207 insertions, 174 deletions
@@ -7494,10 +7494,21 @@ Video Disk Recorder Revision History use it. - Added maximum SNR value for PCTV Systems PCTV 73ESE (thanks to Cedric Dewijs). -2013-01-03: Version 1.7.36 +2013-01-06: Version 1.7.36 - Added maximum SNR value for PCTV Systems nanoStick T2 290e (thanks to Antti Hartikainen). - Added a remark indicating that the coordinates of Rect in a call to cDevice::CanScaleVideo() are in the range of the width and height returned by GetOsdSize() (suggested by Reinhard Nissl). +- Modified the Makefiles (thanks to Christopher Reimer). + By default VDR is now built according to the FHS ("File system Hierarchy Standard"), + and a plain "make" in the VDR source directory just builds everything, but doesn't + copy it to ./PLUGINS/lib and ./locale any more. You can use a Make.config file + (copied from Make.config.template) and set the parameter LCLBLD=1 to have everything + built and installed under the VDR source tree (as was the default in previous + versions). If you already have your own Make.config file, you may want to copy the + new Make.config.template and adapt it to your needs. If you don't want VDR's data + files to be spread around your system according to the FHS, you can set the + parameter ONEDIR=1 (using Make.config) to have all files in one /video directory as + before. @@ -311,7 +311,7 @@ This program must be given to VDR with the '-a' option, as in The video data directory: ------------------------- -All recordings are written into directories below "/video". Please +All recordings are written into directories below "/srv/vdr/video". Please make sure this directory exists, and that the user who runs the 'vdr' program has read and write access to that directory. If you prefer a different location for your video files, you can use @@ -331,12 +331,12 @@ same basic name and must end with a numeric part, which starts at 0 for the main directory and has increasing values for the rest of the directories. For example - /video0 - /video1 - /video2 + /srv/vdr/video0 + /srv/vdr/video1 + /srv/vdr/video2 would be a setup with three directories. You can use more than one -numeric digit, and the directories need not be directly under '/': +numeric digit: /mnt/MyVideos/vdr.00 /mnt/MyVideos/vdr.01 @@ -351,7 +351,7 @@ with the name of the basic directory when running 'vdr': vdr -v /video0 -Note that you should not copy any non-VDR files into the /videoX directories, +Note that you should not copy any non-VDR files into the video directory, since this might cause a lot of unnecessary disk access when VDR cleans up those directories and there is a large number of files and/or subdirectories in there. If you have a large disk that you want to use for VDR's video data as @@ -375,9 +375,11 @@ Configuration files: There are several configuration files that hold information about channels, remote control keys, timers etc. By default these files are -assumed to be located in the video directory, but a different directory -can be used with the '-c' option. Plugins assume their configuration files -in a subdirectory called "plugins" of this directory. +spread around the system according to the FHS ("File system Hierarchy Standard"). +If you prefer to have VDR built to run locally under the VDR source tree, +you can copy the file Make.config.template to Make.config and set the parameter +LCLBLD=1. If you also want to have all data files under one single directory, +set ONEDIR=1 in Make.config. For starters just copy all *.conf files from the VDR directory into your video directory. @@ -396,15 +398,6 @@ As a starting point you can copy the 'channels.conf' file that comes with the VDR archive into your video directory (or into your config directory, respectively, in case you have redirected it with the -c option). -If you prefer to have your system set up according to the FHS -("File system Hierarchy Standard") and thus have your files spread -all over the place ;-), you can do this by copying the file Make.config.template -to Make.config in the VDR source directory, and activating the line - -#USEFHS = 1 - -in that file. - Setting up DiSEqC: ------------------ diff --git a/Make.config.template b/Make.config.template index 4bf8db57..34a049b5 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.14 2012/12/28 09:55:22 kls Exp $ +# $Id: Make.config.template 2.15 2013/01/06 18:48:29 kls Exp $ ### The C compiler and options: @@ -14,48 +14,56 @@ CC = gcc CFLAGS = -g -O3 -Wall CXX = g++ -CXXFLAGS = $(CFLAGS) -Werror=overloaded-virtual -Wno-parentheses - -CFLAGS += -fPIC +CXXFLAGS = -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses # Use 'make M32=1 ...' to build a 32-bit version of VDR on a 64-bit machine: ifdef M32 CFLAGS += -m32 +CXXFLAGS += -m32 endif ### The directory environment: -PREFIX = /usr/local -#DVBDIR = /usr/src/v4l-dvb/linux -MANDIR = $(PREFIX)/man -BINDIR = $(PREFIX)/bin - # Use this if you want to have a central place where you configure compile time # parameters for plugins: #PLGCFG = /etc/vdr/plugins.conf -# By default locale and plugin files are built under the source directory: -INCDIR = $(CWD)/include +# Use 'make LCLBLD=1' to build locale and plugin files under the source directory: +ifdef LCLBLD LOCDIR = $(CWD)/locale PLUGINDIR = $(CWD)/PLUGINS +ifndef PLUGIN # don't overwrite for plugins with old makefiles LIBDIR = $(PLUGINDIR)/lib -# By default VDR requires only one single directory to operate: +endif +HDRDIR = $(CWD)/include +endif + +# Use 'make ONEDIR=1' to have all data in one single directory: +ifdef ONEDIR VIDEODIR = /video -# Activate the following line to build VDR according to the FHS ("File system Hierarchy Standard"): -#USEFHS = 1 -ifdef USEFHS -VIDEODIR = /srv/vdr/video -CONFDIR = /var/lib/vdr -CACHEDIR = /var/cache/vdr -RESDIR = $(PREFIX)/share/vdr -INCDIR = $(PREFIX)/include -LOCDIR = $(PREFIX)/share/locale -LIBDIR = $(PREFIX)/lib/vdr +CACHEDIR = $(VIDEODIR) +CONFDIR = $(VIDEODIR) +RESDIR = $(VIDEODIR) endif +# Other directories: + +#PREFIX = /usr/local +#BINDIR = $(PREFIX)/bin +#DVBDIR = /usr/src/v4l-dvb/linux +#MANDIR = $(PREFIX)/man +#INCDIR = $(PREFIX)/include +#PCDIR = $(PREFIX)/lib/pkgconfig + ### The remote control: LIRC_DEVICE = /var/run/lirc/lircd -## Define if you want vdr to not run as root +### Define if you want vdr to not run as root: #VDR_USER = vdr + +### Fallback for plugins with old makefiles: +ifdef PLUGIN +CFLAGS += -fPIC +CXXFLAGS += -fPIC +endif @@ -4,7 +4,7 @@ # See the main source file 'vdr.c' for copyright information and # how to reach the author. # -# $Id: Makefile 2.47 2012/12/30 11:18:18 kls Exp $ +# $Id: Makefile 2.48 2013/01/06 18:45:33 kls Exp $ .DELETE_ON_ERROR: @@ -14,45 +14,55 @@ CC ?= gcc CFLAGS ?= -g -O3 -Wall CXX ?= g++ -CXXFLAGS ?= $(CFLAGS) -Werror=overloaded-virtual -Wno-parentheses - -CFLAGS += -fPIC +CXXFLAGS ?= -g -O3 -Wall -Werror=overloaded-virtual -Wno-parentheses CDEFINES = -D_GNU_SOURCE CDEFINES += -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE +LIBS = -ljpeg -lpthread -ldl -lcap -lrt $(shell pkg-config --libs freetype2 fontconfig) +INCLUDES ?= $(shell pkg-config --cflags freetype2 fontconfig) + # Directories: -CWD = . -LSIDIR = ./libsi -DESTDIR ?= -PREFIX ?= /usr/local -MANDIR ?= $(PREFIX)/share/man -BINDIR ?= $(PREFIX)/bin -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) +CWD ?= $(shell pwd) +LSIDIR ?= $(CWD)/libsi +PLUGINDIR ?= $(CWD)/PLUGINS -PLUGINDIR= $(CWD)/PLUGINS -LIBDIR = $(PLUGINDIR)/lib +DESTDIR ?= +VIDEODIR ?= /srv/vdr/video +CONFDIR ?= /var/lib/vdr +CACHEDIR ?= /var/cache/vdr -# By default VDR requires only one single directory to operate: -VIDEODIR = /video -# See Make.config.template if you want to build VDR according to the FHS ("File system Hierarchy Standard") +PREFIX ?= /usr/local +BINDIR ?= $(PREFIX)/bin +INCDIR ?= $(PREFIX)/include +LIBDIR ?= $(PREFIX)/lib/vdr +LOCDIR ?= $(PREFIX)/share/locale +MANDIR ?= $(PREFIX)/share/man +PCDIR ?= $(PREFIX)/lib/pkgconfig +RESDIR ?= $(PREFIX)/share/vdr -DOXYGEN ?= /usr/bin/doxygen -DOXYFILE = Doxyfile +# Source documentation -PCDIR ?= $(firstword $(subst :, , ${PKG_CONFIG_PATH}:$(shell pkg-config --variable=pc_path pkg-config):$(PREFIX)/lib/pkgconfig)) +DOXYGEN ?= /usr/bin/doxygen +DOXYFILE = Doxyfile + +# User configuration -include Make.config +# Mandatory compiler flags: + +CFLAGS += -fPIC +CXXFLAGS += -fPIC + +# Common include files: + ifdef DVBDIR -CFLAGS += -I$(DVBDIR) +CINCLUDES += -I$(DVBDIR) endif -UP3 = $(if $(findstring "$(LIBDIR)-$(LOCDIR)","$(CWD)/PLUGINS/lib-$(CWD)/locale"),../../../,) +# Object files SILIB = $(LSIDIR)/libsi.a @@ -63,8 +73,12 @@ 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) +DEFINES += $(CDEFINES) +INCLUDES += $(CINCLUDES) +ifdef HDRDIR +HDRDIR := -I$(HDRDIR) +endif ifndef NO_KBD DEFINES += -DREMOTE_KBD endif @@ -90,12 +104,6 @@ DEFINES += -DRESDIR=\"$(RESDIR)\" DEFINES += -DPLUGINDIR=\"$(LIBDIR)\" DEFINES += -DLOCDIR=\"$(LOCDIR)\" -# Default values for directories: - -CONFDIRDEF = $(firstword $(CONFDIR) $(VIDEODIR)) -CACHEDIRDEF = $(firstword $(CACHEDIR) $(VIDEODIR)) -RESDIRDEF = $(firstword $(RESDIR) $(CONFDIRDEF)) - # The version numbers of VDR and the plugin API (taken from VDR's "config.h"): VDRVERSION = $(shell sed -ne '/define VDRVERSION/s/^.*"\(.*\)".*$$/\1/p' config.h) @@ -133,16 +141,16 @@ $(SILIB): vdr.pc: @echo "bindir=$(BINDIR)" > $@ @echo "mandir=$(MANDIR)" >> $@ - @echo "configdir=$(CONFDIRDEF)" >> $@ + @echo "configdir=$(CONFDIR)" >> $@ @echo "videodir=$(VIDEODIR)" >> $@ - @echo "cachedir=$(CACHEDIRDEF)" >> $@ - @echo "resdir=$(RESDIRDEF)" >> $@ - @echo "libdir=$(UP3)$(LIBDIR)" >> $@ - @echo "locdir=$(UP3)$(LOCDIR)" >> $@ + @echo "cachedir=$(CACHEDIR)" >> $@ + @echo "resdir=$(RESDIR)" >> $@ + @echo "libdir=$(LIBDIR)" >> $@ + @echo "locdir=$(LOCDIR)" >> $@ @echo "plgcfg=$(PLGCFG)" >> $@ @echo "apiversion=$(APIVERSION)" >> $@ - @echo "cflags=$(CFLAGS) $(CDEFINES) -I$(UP3)$(INCDIR)" >> $@ - @echo "cxxflags=$(CXXFLAGS) $(CDEFINES) -I$(UP3)$(INCDIR)" >> $@ + @echo "cflags=$(CFLAGS) $(CDEFINES) $(CINCLUDES) $(HDRDIR)" >> $@ + @echo "cxxflags=$(CXXFLAGS) $(CDEFINES) $(CINCLUDES) $(HDRDIR)" >> $@ @echo "" >> $@ @echo "Name: VDR" >> $@ @echo "Description: Video Disk Recorder" >> $@ @@ -155,6 +163,7 @@ vdr.pc: PODIR = po LOCALEDIR = locale I18Npo = $(wildcard $(PODIR)/*.po) +I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file)))) I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr.mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) I18Npot = $(PODIR)/vdr.pot @@ -169,15 +178,14 @@ $(I18Npot): $(wildcard *.c) @touch $@ $(I18Nmsgs): $(LOCALEDIR)/%/LC_MESSAGES/vdr.mo: $(PODIR)/%.mo - @mkdir -p $(dir $@) - cp $< $@ + install -D -m644 $< $@ .PHONY: i18n -i18n: $(I18Nmsgs) $(I18Npot) +i18n: $(I18Nmsgs) install-i18n: @mkdir -p $(DESTDIR)$(LOCDIR) - @(cd $(LOCALEDIR); cp -r --parents * $(DESTDIR)$(LOCDIR)) + cp -r $(LOCALEDIR)/* $(DESTDIR)$(LOCDIR) # The 'include' directory (for plugins): @@ -192,45 +200,54 @@ include-dir: plugins: include-dir vdr.pc @failed="";\ noapiv="";\ + oldmakefile="";\ for i in `ls $(PLUGINDIR)/src | grep -v '[^a-z0-9]'`; do\ echo "*** Plugin $$i:";\ + # No APIVERSION: Skip\ 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;\ - newmakefile=`grep "PKGCFG" "$(PLUGINDIR)/src/$$i/Makefile"`;\ - if [ -z "$$newmakefile" ]; then\ - echo "********************************************************************";\ - echo "* Your plugin \"$$i\" is using an old Makefile!";\ - echo "* While this currently still works, it is strongly recommended";\ - echo "* that you convert that Makefile to the new style used since";\ - echo "* VDR version 1.7.35. Support for old style Makefiles may be dropped";\ - echo "* in future versions of VDR.";\ - echo "********************************************************************";\ - $(MAKE) --no-print-directory -C "$(PLUGINDIR)/src/$$i" CXXFLAGS="$(CXXFLAGS)" VDRDIR=$(UP3) LIBDIR=../../lib all || failed="$$failed $$i";\ - else\ - target=all;\ - if [ "$(LIBDIR)" = "$(CWD)/PLUGINS/lib" ] && [ "$(LOCDIR)" = "$(CWD)/locale" ]; then\ - target="install";\ - fi;\ - includes=;\ - if [ "$(INCDIR)" != "$(CWD)/include" ]; then\ - includes="INCLUDES=-I$(UP3)/include";\ + # Old Makefile\ + if ! grep -q "PKGCFG" "$(PLUGINDIR)/src/$$i/Makefile" ; then\ + echo "WARNING: plugin $$i is using an old Makefile!";\ + oldmakefile="$$oldmakefile $$i";\ + $(MAKE) --no-print-directory -C "$(PLUGINDIR)/src/$$i" CFLAGS="$(CFLAGS) $(CDEFINES) $(CINCLUDES)" CXXFLAGS="$(CXXFLAGS) $(CDEFINES) $(CINCLUDES)" LIBDIR="$(PLUGINDIR)/lib" VDRDIR="$(CWD)" all || failed="$$failed $$i";\ + continue;\ + fi;\ + # New Makefile\ + INCLUDES="-I$(CWD)/include"\ + $(MAKE) --no-print-directory -C "$(PLUGINDIR)/src/$$i" VDRDIR="$(CWD)" || failed="$$failed $$i";\ + if [ -n "$(LCLBLD)" ] ; then\ + (cd $(PLUGINDIR)/src/$$i; for l in libvdr-*.so; do install $$l $(LIBDIR)/$$l.$(APIVERSION); done);\ + if [ -d $(PLUGINDIR)/src/$$i/po ]; then\ + for l in `ls $(PLUGINDIR)/src/$$i/po/*.mo`; do\ + install -D -m644 $$l $(LOCDIR)/`basename $$l | cut -d. -f1`/LC_MESSAGES/vdr-$$i.mo;\ + done;\ fi;\ - $(MAKE) --no-print-directory -C "$(PLUGINDIR)/src/$$i" VDRDIR=$(UP3) $$includes $$target || failed="$$failed $$i";\ fi;\ done;\ + # Conclusion\ if [ -n "$$noapiv" ] ; then echo; echo "*** plugins without APIVERSION:$$noapiv"; echo; fi;\ + if [ -n "$$oldmakefile" ] ; then\ + echo; echo "*** plugins with old Makefile:$$oldmakefile"; echo;\ + echo "**********************************************************************";\ + echo "*** While this currently still works, it is strongly recommended";\ + echo "*** that you convert old Makefiles to the new style used since";\ + echo "*** VDR version 1.7.36. Support for old style Makefiles may be dropped";\ + echo "*** in future versions of VDR.";\ + 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) --no-print-directory -C "$(PLUGINDIR)/src/$$i" clean; done @-rm -f $(PLUGINDIR)/lib/lib*-*.so.$(APIVERSION) -# Install the files: +# Install the files (note that 'install-pc' must be first!): -install: install-bin install-dirs install-conf install-doc install-plugins install-i18n install-includes install-pc +install: install-pc install-bin install-dirs install-conf install-doc install-plugins install-i18n install-includes # VDR binary: @@ -242,13 +259,12 @@ install-bin: vdr install-dirs: @mkdir -p $(DESTDIR)$(VIDEODIR) - @mkdir -p $(DESTDIR)$(CONFDIRDEF) - @mkdir -p $(DESTDIR)$(CACHEDIRDEF) - @mkdir -p $(DESTDIR)$(RESDIRDEF) + @mkdir -p $(DESTDIR)$(CONFDIR) + @mkdir -p $(DESTDIR)$(CACHEDIR) + @mkdir -p $(DESTDIR)$(RESDIR) install-conf: - @cp -n *.conf $(DESTDIR)$(CONFDIRDEF) - + @cp -n *.conf $(DESTDIR)$(CONFDIR) # Documentation: @@ -261,9 +277,14 @@ install-doc: # Plugins: install-plugins: plugins - @for i in `ls $(PLUGINDIR)/src | grep -v '[^a-z0-9]'`; do\ - $(MAKE) --no-print-directory -C "$(PLUGINDIR)/src/$$i" VDRDIR=$(UP3) DESTDIR=$(DESTDIR) install;\ - done + @-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 + @if [ -d $(PLUGINDIR)/lib ] ; then\ + for i in `find $(PLUGINDIR)/lib -name 'lib*-*.so.$(APIVERSION)'`; do\ + install -D $$i $(DESTDIR)$(LIBDIR);\ + done;\ + fi # Includes: @@ -274,10 +295,10 @@ install-includes: include-dir # pkg-config file: install-pc: vdr.pc - if [ -n "$(PCDIR)" ] ; then \ - mkdir -p $(DESTDIR)$(PCDIR) ; \ - cp vdr.pc $(DESTDIR)$(PCDIR) ; \ - fi + if [ -n "$(PCDIR)" ] ; then\ + mkdir -p $(DESTDIR)$(PCDIR) ;\ + cp vdr.pc $(DESTDIR)$(PCDIR) ;\ + fi # Source documentation: diff --git a/PLUGINS/src/dvbsddevice/Makefile b/PLUGINS/src/dvbsddevice/Makefile index a18a57cc..ed727e41 100644 --- a/PLUGINS/src/dvbsddevice/Makefile +++ b/PLUGINS/src/dvbsddevice/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 1.18 2012/12/29 10:28:45 kls Exp $ +# $Id: Makefile 1.19 2013/01/06 10:19:53 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -17,7 +17,7 @@ VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ pri # 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) +LIBDIR = $(call PKGCFG,libdir) PLGCFG = $(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -68,7 +68,7 @@ all: $(SOFILE) MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -78,7 +78,7 @@ $(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ install-lib: $(SOFILE) - install -D $^ $(LIBDIR)/$^.$(APIVERSION) + install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION) install: install-lib diff --git a/PLUGINS/src/epgtableid0/Makefile b/PLUGINS/src/epgtableid0/Makefile index 91aae7f3..84cc6263 100644 --- a/PLUGINS/src/epgtableid0/Makefile +++ b/PLUGINS/src/epgtableid0/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 1.11 2012/12/29 10:28:58 kls Exp $ +# $Id: Makefile 1.12 2013/01/06 10:19:53 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -17,7 +17,7 @@ VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ pri # 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) +LIBDIR = $(call PKGCFG,libdir) PLGCFG = $(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -68,7 +68,7 @@ all: $(SOFILE) MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -78,7 +78,7 @@ $(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ install-lib: $(SOFILE) - install -D $^ $(LIBDIR)/$^.$(APIVERSION) + install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION) install: install-lib diff --git a/PLUGINS/src/hello/Makefile b/PLUGINS/src/hello/Makefile index b729122b..08380d32 100644 --- a/PLUGINS/src/hello/Makefile +++ b/PLUGINS/src/hello/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.16 2012/12/28 10:09:20 kls Exp $ +# $Id: Makefile 2.17 2013/01/06 10:19:53 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -17,8 +17,8 @@ VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ pri # 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) +LIBDIR = $(call PKGCFG,libdir) +LOCDIR = $(call PKGCFG,locdir) PLGCFG = $(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -69,7 +69,7 @@ all: $(SOFILE) i18n MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -78,7 +78,7 @@ $(DEPFILE): Makefile PODIR = po I18Npo = $(wildcard $(PODIR)/*.po) I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file)))) -I18Nmsgs = $(addprefix $(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) +I18Nmsgs = $(addprefix $(DESTDIR)$(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) I18Npot = $(PODIR)/$(PLUGIN).pot %.mo: %.po @@ -91,7 +91,7 @@ $(I18Npot): $(wildcard *.c) msgmerge -U --no-wrap --no-location --backup=none -q -N $@ $< @touch $@ -$(I18Nmsgs): $(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo +$(I18Nmsgs): $(DESTDIR)$(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo install -D -m644 $< $@ .PHONY: i18n @@ -105,7 +105,7 @@ $(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ install-lib: $(SOFILE) - install -D $^ $(LIBDIR)/$^.$(APIVERSION) + install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION) install: install-lib install-i18n diff --git a/PLUGINS/src/osddemo/Makefile b/PLUGINS/src/osddemo/Makefile index 2d24485e..f3bab4ae 100644 --- a/PLUGINS/src/osddemo/Makefile +++ b/PLUGINS/src/osddemo/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.14 2012/12/29 10:29:04 kls Exp $ +# $Id: Makefile 2.15 2013/01/06 10:19:53 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -17,7 +17,7 @@ VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ pri # 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) +LIBDIR = $(call PKGCFG,libdir) PLGCFG = $(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -68,7 +68,7 @@ all: $(SOFILE) MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -78,7 +78,7 @@ $(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ install-lib: $(SOFILE) - install -D $^ $(LIBDIR)/$^.$(APIVERSION) + install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION) install: install-lib diff --git a/PLUGINS/src/pictures/Makefile b/PLUGINS/src/pictures/Makefile index 71377c9c..b3a55f27 100644 --- a/PLUGINS/src/pictures/Makefile +++ b/PLUGINS/src/pictures/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.16 2012/12/28 10:09:29 kls Exp $ +# $Id: Makefile 2.17 2013/01/06 10:19:53 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -17,8 +17,8 @@ VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ pri # 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) +LIBDIR = $(call PKGCFG,libdir) +LOCDIR = $(call PKGCFG,locdir) PLGCFG = $(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -69,7 +69,7 @@ all: $(SOFILE) i18n MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -78,7 +78,7 @@ $(DEPFILE): Makefile PODIR = po I18Npo = $(wildcard $(PODIR)/*.po) I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file)))) -I18Nmsgs = $(addprefix $(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) +I18Nmsgs = $(addprefix $(DESTDIR)$(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) I18Npot = $(PODIR)/$(PLUGIN).pot %.mo: %.po @@ -91,7 +91,7 @@ $(I18Npot): $(wildcard *.c) msgmerge -U --no-wrap --no-location --backup=none -q -N $@ $< @touch $@ -$(I18Nmsgs): $(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo +$(I18Nmsgs): $(DESTDIR)$(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo install -D -m644 $< $@ .PHONY: i18n @@ -105,7 +105,7 @@ $(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ install-lib: $(SOFILE) - install -D $^ $(LIBDIR)/$^.$(APIVERSION) + install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION) install: install-lib install-i18n diff --git a/PLUGINS/src/rcu/Makefile b/PLUGINS/src/rcu/Makefile index db0818cc..1dacf002 100644 --- a/PLUGINS/src/rcu/Makefile +++ b/PLUGINS/src/rcu/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 1.11 2012/12/29 10:29:09 kls Exp $ +# $Id: Makefile 1.12 2013/01/06 10:19:53 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -17,7 +17,7 @@ VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ pri # 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) +LIBDIR = $(call PKGCFG,libdir) PLGCFG = $(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -68,7 +68,7 @@ all: $(SOFILE) MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -78,7 +78,7 @@ $(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ install-lib: $(SOFILE) - install -D $^ $(LIBDIR)/$^.$(APIVERSION) + install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION) install: install-lib diff --git a/PLUGINS/src/servicedemo/Makefile b/PLUGINS/src/servicedemo/Makefile index df4e372b..ea57fd07 100644 --- a/PLUGINS/src/servicedemo/Makefile +++ b/PLUGINS/src/servicedemo/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.12 2012/12/29 10:29:15 kls Exp $ +# $Id: Makefile 2.13 2013/01/06 10:19:53 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -18,7 +18,7 @@ VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN1).c | awk '{ pr # 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) +LIBDIR = $(call PKGCFG,libdir) PLGCFG = $(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -65,7 +65,7 @@ all: libvdr-$(PLUGIN1).so libvdr-$(PLUGIN2).so MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -78,8 +78,8 @@ libvdr-$(PLUGIN2).so: $(PLUGIN2).o $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(PLUGIN2).o -o $@ install-lib: 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) + install -D libvdr-$(PLUGIN1).so $(DESTDIR)$(LIBDIR)/libvdr-$(PLUGIN1).so.$(APIVERSION) + install -D libvdr-$(PLUGIN2).so $(DESTDIR)$(LIBDIR)/libvdr-$(PLUGIN2).so.$(APIVERSION) install: install-lib diff --git a/PLUGINS/src/skincurses/Makefile b/PLUGINS/src/skincurses/Makefile index 6ba4d252..bc5bbc48 100644 --- a/PLUGINS/src/skincurses/Makefile +++ b/PLUGINS/src/skincurses/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.16 2012/12/28 10:09:36 kls Exp $ +# $Id: Makefile 2.17 2013/01/06 10:19:53 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -17,8 +17,8 @@ VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ pri # 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) +LIBDIR = $(call PKGCFG,libdir) +LOCDIR = $(call PKGCFG,locdir) PLGCFG = $(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -69,7 +69,7 @@ all: $(SOFILE) i18n MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -78,7 +78,7 @@ $(DEPFILE): Makefile PODIR = po I18Npo = $(wildcard $(PODIR)/*.po) I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file)))) -I18Nmsgs = $(addprefix $(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) +I18Nmsgs = $(addprefix $(DESTDIR)$(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) I18Npot = $(PODIR)/$(PLUGIN).pot %.mo: %.po @@ -91,7 +91,7 @@ $(I18Npot): $(wildcard *.c) msgmerge -U --no-wrap --no-location --backup=none -q -N $@ $< @touch $@ -$(I18Nmsgs): $(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo +$(I18Nmsgs): $(DESTDIR)$(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo install -D -m644 $< $@ .PHONY: i18n @@ -105,7 +105,7 @@ $(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -lncursesw -o $@ install-lib: $(SOFILE) - install -D $^ $(LIBDIR)/$^.$(APIVERSION) + install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION) install: install-lib install-i18n diff --git a/PLUGINS/src/status/Makefile b/PLUGINS/src/status/Makefile index 9635a5d0..31d2cc9a 100644 --- a/PLUGINS/src/status/Makefile +++ b/PLUGINS/src/status/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.13 2012/12/29 10:29:20 kls Exp $ +# $Id: Makefile 2.14 2013/01/06 10:19:53 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -17,7 +17,7 @@ VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ pri # 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) +LIBDIR = $(call PKGCFG,libdir) PLGCFG = $(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -68,7 +68,7 @@ all: $(SOFILE) MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -78,7 +78,7 @@ $(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ install-lib: $(SOFILE) - install -D $^ $(LIBDIR)/$^.$(APIVERSION) + install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION) install: install-lib diff --git a/PLUGINS/src/svdrpdemo/Makefile b/PLUGINS/src/svdrpdemo/Makefile index d40e483c..92255391 100644 --- a/PLUGINS/src/svdrpdemo/Makefile +++ b/PLUGINS/src/svdrpdemo/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile 2.13 2012/12/29 10:29:24 kls Exp $ +# $Id: Makefile 2.14 2013/01/06 10:19:53 kls Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -17,7 +17,7 @@ VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ pri # 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) +LIBDIR = $(call PKGCFG,libdir) PLGCFG = $(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -68,7 +68,7 @@ all: $(SOFILE) MAKEDEP = $(CXX) -MM -MG DEPFILE = .dependencies $(DEPFILE): Makefile - @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ -include $(DEPFILE) @@ -78,7 +78,7 @@ $(SOFILE): $(OBJS) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) -o $@ install-lib: $(SOFILE) - install -D $^ $(LIBDIR)/$^.$(APIVERSION) + install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION) install: install-lib @@ -12,7 +12,7 @@ # See the main source file 'vdr.c' for copyright information and # how to reach the author. # -# $Id: newplugin 2.15 2012/12/28 09:52:29 kls Exp $ +# $Id: newplugin 2.16 2013/01/06 12:22:25 kls Exp $ $PLUGIN_NAME = $ARGV[0] || die "Usage: newplugin <name>\n"; @@ -76,8 +76,8 @@ VERSION = \$(shell grep 'static const char \\*VERSION *=' \$(PLUGIN).c | awk '{ # 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) +LIBDIR = \$(call PKGCFG,libdir) +LOCDIR = \$(call PKGCFG,locdir) PLGCFG = \$(call PKGCFG,plgcfg) # TMPDIR ?= /tmp @@ -128,7 +128,7 @@ all: \$(SOFILE) i18n MAKEDEP = \$(CXX) -MM -MG DEPFILE = .dependencies \$(DEPFILE): Makefile - \@\$(MAKEDEP) \$(DEFINES) \$(INCLUDES) \$(OBJS:%.o=%.c) > \$\@ + \@\$(MAKEDEP) \$(CXXFLAGS) \$(DEFINES) \$(INCLUDES) \$(OBJS:%.o=%.c) > \$\@ -include \$(DEPFILE) @@ -137,7 +137,7 @@ DEPFILE = .dependencies PODIR = po I18Npo = \$(wildcard \$(PODIR)/*.po) I18Nmo = \$(addsuffix .mo, \$(foreach file, \$(I18Npo), \$(basename \$(file)))) -I18Nmsgs = \$(addprefix \$(LOCDIR)/, \$(addsuffix /LC_MESSAGES/vdr-\$(PLUGIN).mo, \$(notdir \$(foreach file, \$(I18Npo), \$(basename \$(file)))))) +I18Nmsgs = \$(addprefix \$(DESTDIR)\$(LOCDIR)/, \$(addsuffix /LC_MESSAGES/vdr-\$(PLUGIN).mo, \$(notdir \$(foreach file, \$(I18Npo), \$(basename \$(file)))))) I18Npot = \$(PODIR)/\$(PLUGIN).pot %.mo: %.po @@ -150,7 +150,7 @@ I18Npot = \$(PODIR)/\$(PLUGIN).pot msgmerge -U --no-wrap --no-location --backup=none -q -N \$\@ \$< \@touch \$\@ -\$(I18Nmsgs): \$(LOCDIR)/%/LC_MESSAGES/vdr-\$(PLUGIN).mo: \$(PODIR)/%.mo +\$(I18Nmsgs): \$(DESTDIR)\$(LOCDIR)/%/LC_MESSAGES/vdr-\$(PLUGIN).mo: \$(PODIR)/%.mo install -D -m644 \$< \$\@ .PHONY: i18n @@ -164,7 +164,7 @@ install-i18n: \$(I18Nmsgs) \$(CXX) \$(CXXFLAGS) \$(LDFLAGS) -shared \$(OBJS) -o \$\@ install-lib: \$(SOFILE) - install -D \$^ \$(LIBDIR)/\$^.\$(APIVERSION) + install -D \$^ \$(DESTDIR)\$(LIBDIR)/\$^.\$(APIVERSION) install: install-lib install-i18n |