florian fff24b0be7 Upgrade miniupnpd to 1.1, thanks Nanard
git-svn-id: svn://svn.openwrt.org/openwrt/packages@11219 3c298f89-4303-0410-b956-a3cf2f4a3e73
2008-05-20 10:06:16 +00:00

51 lines
1.4 KiB
Makefile

#
# Copyright (C) 2006 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
# $Id$
include $(TOPDIR)/rules.mk
PKG_NAME:=miniupnpd
PKG_VERSION:=1.1
PKG_RELEASE:=1
PKG_MD5SUM:=a0f6651476721db9b554668c8c83b151
PKG_SOURCE_URL:=http://miniupnp.free.fr/files
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
include $(INCLUDE_DIR)/package.mk
define Package/miniupnpd
SECTION:=net
CATEGORY:=Network
DEPENDS:=+iptables
TITLE:=Lightweight UPnP daemon
URL:=http://miniupnp.tuxfamily.org/
endef
define Build/Compile
ln -sf $(PKG_BUILD_DIR)/config.h.openwrt $(PKG_BUILD_DIR)/config.h
$(MAKE) -C $(PKG_BUILD_DIR) -f Makefile.openwrt \
$(TARGET_CONFIGURE_OPTS) \
STAGING_DIR="$(STAGING_DIR)" \
CFLAGS="$(TARGET_CFLAGS) -I $(STAGING_DIR)/usr/include" \
LIBS="$(STAGING_DIR)/usr/lib/libiptc.a"
endef
define Package/miniupnpd/install
$(INSTALL_DIR) $(1)/usr/bin $(1)/etc/init.d $(1)/etc/config $(1)/etc/hotplug.d/iface
$(INSTALL_BIN) $(PKG_BUILD_DIR)/miniupnpd $(1)/usr/bin/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/netfilter/*.sh $(1)/usr/bin/
$(INSTALL_BIN) ./files/miniupnpd.init $(1)/etc/init.d/miniupnpd
$(INSTALL_DATA) ./files/upnpd.config $(1)/etc/config/upnpd
$(INSTALL_DATA) ./files/miniupnpd.hotplug $(1)/etc/hotplug.d/iface/20-miniupnpd
endef
$(eval $(call BuildPackage,miniupnpd))