Root/package/network/utils/ipset/Makefile

1 
2# Copyright (C) 2009-2012 OpenWrt.org
3#
4# This is free software, licensed under the GNU General Public License v2.
5# See /LICENSE for more information.
6#
7#
8include $(TOPDIR)/rules.mk
9include $(INCLUDE_DIR)/kernel.mk
10
11PKG_NAME:=ipset
12PKG_VERSION:=6.11
13PKG_RELEASE:=2
14
15PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16PKG_SOURCE_URL:=http://ipset.netfilter.org
17PKG_MD5SUM:=bfcc92e30a0fcf10ae6e7c4affa03c84
18
19PKG_MAINTAINER:=Jo-Philipp Wich <jow@openwrt.org>
20
21PKG_FIXUP:=autoreconf
22PKG_INSTALL:=1
23
24include $(INCLUDE_DIR)/package.mk
25
26define Package/ipset/Default
27  DEPENDS:= @(!(TARGET_ps3||TARGET_pxcab)||BROKEN)
28endef
29
30define Package/ipset
31$(call Package/ipset/Default)
32  SECTION:=net
33  CATEGORY:=Network
34  DEPENDS+= +iptables-mod-ipset +kmod-ipt-ipset +libmnl
35  TITLE:=IPset administration utility
36  URL:=http://ipset.netfilter.org/
37endef
38
39CONFIGURE_ARGS += \
40    --with-kbuild="$(LINUX_DIR)"
41
42MAKE_FLAGS += \
43    ARCH="$(LINUX_KARCH)"
44
45IPSET_MODULES:= \
46    ipset/ip_set \
47    ipset/ip_set_bitmap_ip \
48    ipset/ip_set_bitmap_ipmac \
49    ipset/ip_set_bitmap_port \
50    ipset/ip_set_hash_ip \
51    ipset/ip_set_hash_ipport \
52    ipset/ip_set_hash_ipportip \
53    ipset/ip_set_hash_ipportnet \
54    ipset/ip_set_hash_net \
55    ipset/ip_set_hash_netiface \
56    ipset/ip_set_hash_netport \
57    ipset/ip_set_list_set \
58    xt_set \
59
60define Build/Compile
61    $(call Build/Compile/Default)
62    $(call Build/Compile/Default,modules)
63endef
64
65define Package/ipset/install
66    $(INSTALL_DIR) $(1)/usr/sbin
67    $(CP) $(PKG_INSTALL_DIR)/usr/sbin/ipset $(1)/usr/sbin/
68    $(INSTALL_DIR) $(1)/usr/lib
69    $(CP) $(PKG_INSTALL_DIR)/usr/lib/libipset*.so* $(1)/usr/lib/
70endef
71
72define KernelPackage/ipt-ipset
73$(call Package/ipset/Default)
74  SUBMENU:=Netfilter Extensions
75  TITLE:=IPset netfilter modules
76  DEPENDS+= +kmod-ipt-core +kmod-nfnetlink
77  FILES:=$(foreach mod,$(IPSET_MODULES),$(PKG_BUILD_DIR)/kernel/net/netfilter/$(mod).ko)
78  AUTOLOAD:=$(call AutoLoad,49,$(notdir $(IPSET_MODULES)))
79endef
80
81$(eval $(call BuildPackage,ipset))
82$(eval $(call KernelPackage,ipt-ipset))
83

Archive Download this file



interactive