From 81b1adaec7417ba4d92dde8011c19abc308477d1 Mon Sep 17 00:00:00 2001 From: Antti Ajanki Date: Tue, 9 Nov 2010 22:12:40 +0200 Subject: don't complain about missing $(VDRDIR)/config.h when building the command line tool --- Makefile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index b438130..f9db74b 100644 --- a/Makefile +++ b/Makefile @@ -15,7 +15,7 @@ TMPDIR = /tmp ARCHIVE = webvideo-$(VERSION) PACKAGE = vdr-$(ARCHIVE) -APIVERSION := $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h) +APIVERSION := $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h 2> /dev/null) LIBDIR = $(VDRPLUGINDIR) # Default target compiles everything but does not install anything. @@ -38,8 +38,13 @@ webvi.conf webvi.plugin.conf: %.conf: examples/%.conf sed 's_templatepath = /usr/local/share/webvi/templates_templatepath = $(PREFIX)/share/webvi/templates_g' < $< > $@ $(DESTDIR)$(VDRPLUGINDIR)/libvdr-webvideo.so.$(APIVERSION): vdr-plugin +ifeq ($(APIVERSION),) + @echo "No APIVERSION in $(VDRDIR)/config.h" + @exit 1 +else mkdir -p $(DESTDIR)$(VDRPLUGINDIR) cp -f src/vdr-plugin/libvdr-webvideo.so.$(APIVERSION) $(DESTDIR)$(VDRPLUGINDIR)/libvdr-webvideo.so.$(APIVERSION) +endif install-vdr-plugin: $(DESTDIR)$(VDRPLUGINDIR)/libvdr-webvideo.so.$(APIVERSION) mkdir -p $(DESTDIR)$(VDRLOCALEDIR) -- cgit v1.2.3