summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorAndreas Brachold <vdr07@deltab.de>2006-01-12 19:39:53 +0000
committerAndreas Brachold <vdr07@deltab.de>2006-01-12 19:39:53 +0000
commit35aa768d991d5dadb6b3301b371b0cb8e4747e1d (patch)
tree4a86dbf6579d1bce3a0de128b23f6d2ef3a3436d /Makefile
parente704540374d251d037560673e9373a357959198b (diff)
downloadvdr-plugin-image-35aa768d991d5dadb6b3301b371b0cb8e4747e1d.tar.gz
vdr-plugin-image-35aa768d991d5dadb6b3301b371b0cb8e4747e1d.tar.bz2
- fix build failed without defined FFMDIR
- add exif support (required libexif)
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile91
1 files changed, 56 insertions, 35 deletions
diff --git a/Makefile b/Makefile
index 934f662..3388492 100644
--- a/Makefile
+++ b/Makefile
@@ -1,39 +1,72 @@
#
-# Makefile for a Video Disk Recorder plugin
+# Makefile for Image plugin to VDR
#
-# $Id$
-
-# 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.
+# (C) 2004-2006 Andreas Brachold <anbr at users.berlios.de>
#
-PLUGIN = image
+# This code is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This code is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+# Or, point your browser to http://www.gnu.org/copyleft/gpl.html
-### The version number of this plugin (taken from the main source file):
+# You can change the compile options here or create a Make.config
+# in the VDR directory an set them there.
+
+### uncomment the following line, if you don't have libexif installed
+#WITHOUT_LIBEXIF=1
+
+#FFMDIR = ../../../../ffmpeg
-VERSION = $(shell grep 'static const char \*VERSION *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g')
### The C++ compiler and options:
CXX ?= g++
CXXFLAGS ?= -fPIC -O2 -Wall -Woverloaded-virtual
+###############################################
+###############################################
+#
+# no user configurable options below this point
+#
+###############################################
+###############################################
+
### The directory environment:
DVBDIR = ../../../../DVB
VDRDIR = ../../..
LIBDIR = ../../lib
TMPDIR = /tmp
-#FFMDIR = ../../../../ffmpeg
### Allow user defined options to overwrite defaults:
-include $(VDRDIR)/Make.config
+# 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 = image
+
+### 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 version number of VDR (taken from VDR's "config.h"):
VDRVERSION = $(shell grep 'define VDRVERSION ' $(VDRDIR)/config.h | awk '{ print $$3 }' | sed -e 's/"//g')
+
+
### The name of the distribution archive:
ARCHIVE = $(PLUGIN)-$(VERSION)
@@ -44,15 +77,6 @@ PACKAGE = vdr-$(ARCHIVE)
ifdef FFMDIR
FFMVERSION = $(shell grep "\#define FFMPEG_VERSION_INT " $(FFMDIR)/libavcodec/avcodec.h | \
cut -d "x" -f 2 )
-else
-ifeq (,$(findstring 000,$(FFMVERSION)))
-FFMVERSION = $(shell grep "\#define FFMPEG_VERSION_INT " /usr/include/ffmpeg/avcodec.h 2>/dev/null | \
- cut -d "x" -f 2 )
-endif
-ifeq (,$(findstring 000,$(FFMVERSION)))
-FFMVERSION = $(shell grep "\#define FFMPEG_VERSION_INT " /usr/local/include/ffmpeg/avcodec.h 2>/dev/null | \
- cut -d "x" -f 2 )
-endif
endif
### Includes and Defines (add further entries here):
@@ -75,30 +99,27 @@ endif
endif
LIBS += -lavcodec
-ifneq ($(FFMVERSION),000408)
-LIBS += -lavformat -lavutil
-endif
-
LIBS += -lz
ifdef FFMDIR
DEFINES += -DFFMDIR
endif
+ifndef WITHOUT_LIBEXIF
+ LIBS += -lexif
+ DEFINES += -DHAVE_LIBEXIF
+endif
+
### The object files (add further files here):
-OBJS = ${PLUGIN}.o
-OBJS += i18n.o
-OBJS += data.o
-OBJS += menu.o
-OBJS += data-image.o
-OBJS += menu-image.o
-OBJS += setup-image.o
-OBJS += player-image.o
-OBJS += control-image.o
-OBJS += commands.o
-OBJS += menu-commands.o
-OBJS += list.o
+OBJS = ${PLUGIN}.o i18n.o data.o menu.o data-image.o menu-image.o \
+ setup-image.o player-image.o control-image.o commands.o menu-commands.o \
+ list.o
+
+
+ifndef WITHOUT_LIBEXIF
+ OBJS += exif.o
+endif
### The subdirectories: