1
0

Makefile 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. # Copyright (C) 2009-2012 OpenWrt.org
  2. #
  3. # This is free software, licensed under the GNU General Public License v2.
  4. # See /LICENSE for more information.
  5. #
  6. #
  7. include $(TOPDIR)/rules.mk
  8. include $(INCLUDE_DIR)/kernel.mk
  9. PKG_NAME:=ipset
  10. PKG_VERSION:=7.3
  11. PKG_RELEASE:=1
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
  13. PKG_SOURCE_URL:=http://ipset.netfilter.org
  14. PKG_HASH:=4644c7c5005e90a9b6385d625283eb0b69b34de7192301428665dd909fdaa35a
  15. PKG_MAINTAINER:=Jo-Philipp Wich <jo@mein.io>
  16. PKG_LICENSE:=GPL-2.0
  17. PKG_FIXUP:=autoreconf
  18. PKG_INSTALL:=1
  19. include $(INCLUDE_DIR)/package.mk
  20. define Package/ipset/Default
  21. SECTION:=net
  22. CATEGORY:=Network
  23. DEPENDS+= +kmod-ipt-ipset +libmnl
  24. TITLE:=IPset administration utility
  25. URL:=http://ipset.netfilter.org/
  26. endef
  27. define Package/ipset
  28. $(call Package/ipset/Default)
  29. DEPENDS+= +libipset
  30. endef
  31. define Package/libipset
  32. $(call Package/ipset/Default)
  33. ABI_VERSION:=13
  34. endef
  35. CONFIGURE_ARGS += \
  36. --disable-static \
  37. --with-kbuild="$(LINUX_DIR)"
  38. TARGET_LDFLAGS += -Wl,--gc-sections,--as-needed
  39. MAKE_FLAGS += \
  40. ARCH="$(LINUX_KARCH)" \
  41. SHELL="$(BASH)"
  42. define Build/InstallDev
  43. $(INSTALL_DIR) $(1)/usr/include $(1)/usr/lib $(1)/usr/lib/pkgconfig
  44. $(CP) $(PKG_INSTALL_DIR)/usr/include/libipset $(1)/usr/include/
  45. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libipset.so* $(1)/usr/lib/
  46. $(CP) $(PKG_BUILD_DIR)/lib/libipset.pc $(1)/usr/lib/pkgconfig/
  47. endef
  48. define Package/ipset/install
  49. $(INSTALL_DIR) $(1)/usr/sbin
  50. $(CP) $(PKG_INSTALL_DIR)/usr/sbin/ipset $(1)/usr/sbin/
  51. endef
  52. define Package/libipset/install
  53. $(INSTALL_DIR) $(1)/usr/lib
  54. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libipset*.so.* $(1)/usr/lib/
  55. endef
  56. $(eval $(call BuildPackage,ipset))
  57. $(eval $(call BuildPackage,libipset))