diff options
| author | Jürgen Schmitz <vdr@dolze.de> | 2004-03-03 20:15:00 +0100 |
|---|---|---|
| committer | Jürgen Schmitz <vdr@dolze.de> | 2004-03-03 20:15:00 +0100 |
| commit | 03b56d7b7969e9fbec4cbcb3ad273bc9d1de9311 (patch) | |
| tree | 1c3e041e9641abb65ec69bb996584f75d43a9551 /Makefile | |
| download | vdr-plugin-tvonscreen-03b56d7b7969e9fbec4cbcb3ad273bc9d1de9311.tar.gz vdr-plugin-tvonscreen-03b56d7b7969e9fbec4cbcb3ad273bc9d1de9311.tar.bz2 | |
Version 0.5.0
Diffstat (limited to 'Makefile')
| -rw-r--r-- | Makefile | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..cf3c817 --- /dev/null +++ b/Makefile @@ -0,0 +1,83 @@ +# +# Makefile for a Video Disk Recorder plugin +# +# $Id: Makefile,v 1.2 2004/03/03 00:22:47 schmitzj 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 = tvonscreen + +### 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 -O2 -Wall -Woverloaded-virtual + +### The directory environment: + +DVBDIR = ../../../../DVB +VDRDIR = ../../.. +LIBDIR = ../../lib +TMPDIR = /tmp + +### Allow user defined options to overwrite defaults: + +-include $(VDRDIR)/Make.config + +### 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) +PACKAGE = vdr-$(ARCHIVE) + +### Includes and Defines (add further entries here): + +INCLUDES += -I$(VDRDIR)/include -I$(DVBDIR)/include + +DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' -D_GNU_SOURCE + +### The object files (add further files here): + +OBJS = $(PLUGIN).o i18n.o magazine.o anyfont.o + +### Implicit rules: + +%.o: %.c + $(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) $< + +# Dependencies: + +MAKEDEP = g++ -MM -MG +DEPFILE = .dependencies +$(DEPFILE): Makefile + @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@ + +-include $(DEPFILE) + +### Targets: + +all: libvdr-$(PLUGIN).so + +libvdr-$(PLUGIN).so: $(OBJS) + $(CXX) $(CXXFLAGS) -shared $(OBJS) -o $@ + @cp $@ $(LIBDIR)/$@.$(VDRVERSION) + +dist: clean + @-rm -rf $(TMPDIR)/$(ARCHIVE) + @mkdir $(TMPDIR)/$(ARCHIVE) + @cp -a * $(TMPDIR)/$(ARCHIVE) + @rm -rf `find $(TMPDIR)/$(ARCHIVE) -name CVS -print` + @tar czf $(PACKAGE).tar.gz -C $(TMPDIR) $(ARCHIVE) + @-rm -rf $(TMPDIR)/$(ARCHIVE) + @echo Distribution package created as $(PACKAGE).tgz + +clean: + @-rm -f $(OBJS) $(DEPFILE) *.so *.tar.gz core* *~ |
