ipset: update to 7.1
[openwrt/openwrt.git] / 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 #
8 include $(TOPDIR)/rules.mk
9 include $(INCLUDE_DIR)/kernel.mk
10
11 PKG_NAME:=ipset
12 PKG_VERSION:=7.1
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16 PKG_SOURCE_URL:=http://ipset.netfilter.org
17 PKG_HASH:=7b5eb3b93205c20cdc39e3fc8b6e5f7bb214bf79a7c0c00729dd4a31ce16adc4
18
19 PKG_MAINTAINER:=Jo-Philipp Wich <jo@mein.io>
20 PKG_LICENSE:=GPL-2.0
21
22 PKG_FIXUP:=autoreconf
23 PKG_INSTALL:=1
24
25 include $(INCLUDE_DIR)/package.mk
26
27 define Package/ipset/Default
28 SECTION:=net
29 CATEGORY:=Network
30 DEPENDS+= +kmod-ipt-ipset +libmnl
31 TITLE:=IPset administration utility
32 URL:=http://ipset.netfilter.org/
33 endef
34
35 define Package/ipset
36 $(call Package/ipset/Default)
37 DEPENDS+= +libipset
38 endef
39
40 define Package/libipset
41 $(call Package/ipset/Default)
42 endef
43
44 CONFIGURE_ARGS += \
45 --with-kbuild="$(LINUX_DIR)"
46
47 MAKE_FLAGS += \
48 ARCH="$(LINUX_KARCH)" \
49 SHELL="$(BASH)"
50
51 define Build/InstallDev
52 $(INSTALL_DIR) $(1)/usr/include $(1)/usr/lib $(1)/usr/lib/pkgconfig
53 $(CP) $(PKG_INSTALL_DIR)/usr/include/libipset $(1)/usr/include/
54 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libipset.{a,so*} $(1)/usr/lib/
55 $(CP) $(PKG_BUILD_DIR)/lib/libipset.pc $(1)/usr/lib/pkgconfig/
56 endef
57
58 define Package/ipset/install
59 $(INSTALL_DIR) $(1)/usr/sbin
60 $(CP) $(PKG_INSTALL_DIR)/usr/sbin/ipset $(1)/usr/sbin/
61 endef
62
63 define Package/libipset/install
64 $(INSTALL_DIR) $(1)/usr/lib
65 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libipset*.so* $(1)/usr/lib/
66 endef
67
68 $(eval $(call BuildPackage,ipset))
69 $(eval $(call BuildPackage,libipset))