diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 23 |
1 files changed, 10 insertions, 13 deletions
@@ -3,7 +3,7 @@ # # See the README file for copyright information and how to reach the author. # -# $Id: Makefile 11 2005-10-28 01:00:01Z tom $ +# $Id: Makefile 28 2006-04-25 00:09:14Z tom $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -13,17 +13,16 @@ PLUGIN = sudoku ### The version number of this plugin (taken from the main source file): -VERSION = $(shell grep 'static const char\* VERSION *=' $(PLUGIN).cpp | \ - awk '{ print $$6 }' | sed -e 's/[";]//g') +VERSION = $(shell sed -ne '/static .* VERSION *=/s/^.*"\(.*\)".*$$/\1/p' \ + $(PLUGIN).cpp) ### The C++ compiler and options: CXX ?= g++ -CXXFLAGS ?= -fPIC -O2 -Wall -Woverloaded-virtual +CXXFLAGS ?= -fPIC -g -O2 -Wall -Woverloaded-virtual ### The directory environment: -DVBDIR = ../../../../DVB VDRDIR = ../../.. LIBDIR = ../../lib TMPDIR = /tmp @@ -32,12 +31,10 @@ TMPDIR = /tmp -include $(VDRDIR)/Make.config -### The version number of VDR (taken from VDR's "config.h"): +### The version number of VDR's plugin API (taken from VDR's "config.h"): -VDRVERSION = $(shell grep 'define VDRVERSION ' $(VDRDIR)/config.h | \ - awk '{ print $$3 }' | sed -e 's/"//g') -VDRVERSNUM = $(shell grep 'define VDRVERSNUM ' $(VDRDIR)/config.h | \ - awk '{ print $$3 }') +APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' \ + $(VDRDIR)/config.h) ### The name of the distribution archive: @@ -46,7 +43,7 @@ PACKAGE = vdr-$(ARCHIVE) ### Includes and Defines (add further entries here): -INCLUDES += -I$(VDRDIR)/include -I$(DVBDIR)/include +INCLUDES += -I$(VDRDIR)/include DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' @@ -76,7 +73,7 @@ all: libvdr-$(PLUGIN).so libvdr-$(PLUGIN).so: $(OBJS) $(CXX) $(CXXFLAGS) -shared $(OBJS) -o $@ - @cp $@ $(LIBDIR)/$@.$(VDRVERSION) + @cp $@ $(LIBDIR)/$@.$(APIVERSION) dist: clean @-rm -rf $(TMPDIR)/$(ARCHIVE) @@ -88,7 +85,7 @@ dist: clean @echo Distribution package created as $(PACKAGE).tgz srcdoc: Doxyfile $(OBJS:%.o=%.cpp) $(OBJS:%.o=%.h) - VERSION=$(VERSION) VDRVERSNUM=$(VDRVERSNUM) /usr/bin/doxygen + VERSION=$(VERSION) /usr/bin/doxygen clean: @-rm -f $(OBJS) $(DEPFILE) *.so* *.tgz core* *~ |