###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007 Michael Tremer & Christian Schmidt #
+# Copyright (C) 2007-2012 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = plugin
+VER = 0.9.0
+THISAPP = vdr-vnsiserver3
+DL_FILE = $(THISAPP).tar.xz
-THISAPP = vdr_epgsearch-$(VER)
+DL_FROM = $(URL_IPFIRE)
DIR_APP = $(DIR_SRC)/$(THISAPP)
-PROG = vdr_epgsearch
-PAK_VER = 5
+TARGET = $(DIR_INFO)/$(THISAPP)
+PROG = vdr-vnsiserver3
+PAK_VER = 1
DEPS = "vdr"
+VDR_VER = 1.7.41
+
###############################################################################
# Top-level Rules
###############################################################################
+objects = $(DL_FILE)
+
+$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-install :
+$(DL_FILE)_MD5 = 159a36577ea50d9772fcf5a92ffd38b5
-check :
+install : $(TARGET)
-download :
+check : $(patsubst %,$(DIR_CHK)/%,$(objects))
-md5 :
+download : $(patsubst %,$(DIR_DL)/%,$(objects))
+
+md5 : $(subst %,%_MD5,$(objects))
dist:
- $(PAK)
+ @$(PAK)
+
+###############################################################################
+# Downloading, checking, md5sum
+###############################################################################
+
+$(patsubst %,$(DIR_CHK)/%,$(objects)) :
+ @$(CHECK)
+
+$(patsubst %,$(DIR_DL)/%,$(objects)) :
+ @$(LOAD)
+
+$(subst %,%_MD5,$(objects)) :
+ @$(MD5)
###############################################################################
+# Installation Details
+###############################################################################
+
+$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
+ @$(PREBUILD)
+ @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
+
+ cd $(DIR_APP) && make $(MAKE_TUNING) LIBDIR=. VDRDIR=/usr/lib/vdr \
+ LOCALEDIR=$$(pwd)/locale all
+
+ -mkdir -pv /etc/vdr/plugins/vnsiserver
+ cd $(DIR_APP) && install -m 755 libvdr-vnsiserver.so \
+ /usr/lib/vdr/libvdr-vnsiserver.so.$(VDR_VER)
+ cd $(DIR_APP) && install -m 644 vnsiserver/* /etc/vdr/plugins/vnsiserver
+
+ @rm -rf $(DIR_APP)
+ @$(POSTBUILD)