aboutsummaryrefslogtreecommitdiffstats
path: root/package/network/utils
diff options
context:
space:
mode:
authorAlexandru Ardelean <ardeleanalex@gmail.com>2017-06-20 15:18:11 +0300
committerStijn Tintel <stijn@linux-ipv6.be>2017-07-21 15:12:48 +0200
commitd9f7ae6cdbf798e51bbefc2352b6e9206edefa50 (patch)
tree0ea6bce520b990253f7a5d73b087cecdbd742aef /package/network/utils
parent4c1ce83548abacfeabb75c6e28e8eb450ef10951 (diff)
downloadupstream-d9f7ae6cdbf798e51bbefc2352b6e9206edefa50.tar.gz
upstream-d9f7ae6cdbf798e51bbefc2352b6e9206edefa50.tar.bz2
upstream-d9f7ae6cdbf798e51bbefc2352b6e9206edefa50.zip
ipset: split libipset as a subpackage
Intent is to link against it, and have the option to not install the ipset utility (if needed). One example/use-case is keepalived (from package) feeds, where it would be nice to just depend on a `libipset` (sub)package. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
Diffstat (limited to 'package/network/utils')
-rw-r--r--package/network/utils/ipset/Makefile21
1 files changed, 15 insertions, 6 deletions
diff --git a/package/network/utils/ipset/Makefile b/package/network/utils/ipset/Makefile
index f44c1de232..66a9874055 100644
--- a/package/network/utils/ipset/Makefile
+++ b/package/network/utils/ipset/Makefile
@@ -10,7 +10,7 @@ include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=ipset
PKG_VERSION:=6.32
-PKG_RELEASE:=1
+PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=http://ipset.netfilter.org
@@ -24,7 +24,7 @@ PKG_INSTALL:=1
include $(INCLUDE_DIR)/package.mk
-define Package/ipset
+define Package/ipset/Default
SECTION:=net
CATEGORY:=Network
DEPENDS+= +kmod-ipt-ipset +libmnl
@@ -32,6 +32,15 @@ define Package/ipset
URL:=http://ipset.netfilter.org/
endef
+define Package/ipset
+$(call Package/ipset/Default)
+ DEPENDS+= +libipset
+endef
+
+define Package/libipset
+$(call Package/ipset/Default)
+endef
+
CONFIGURE_ARGS += \
--with-kbuild="$(LINUX_DIR)"
@@ -39,10 +48,6 @@ MAKE_FLAGS += \
ARCH="$(LINUX_KARCH)" \
SHELL="$(BASH)"
-define Build/Compile
- $(call Build/Compile/Default)
-endef
-
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include $(1)/usr/lib $(1)/usr/lib/pkgconfig
$(CP) $(PKG_INSTALL_DIR)/usr/include/libipset $(1)/usr/include/
@@ -53,8 +58,12 @@ endef
define Package/ipset/install
$(INSTALL_DIR) $(1)/usr/sbin
$(CP) $(PKG_INSTALL_DIR)/usr/sbin/ipset $(1)/usr/sbin/
+endef
+
+define Package/libipset/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libipset*.so* $(1)/usr/lib/
endef
$(eval $(call BuildPackage,ipset))
+$(eval $(call BuildPackage,libipset))