Makefile 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. #
  2. # Copyright (C) 2014-2016 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=libnftnl
  9. PKG_VERSION:=1.0.6
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
  12. PKG_SOURCE_URL:=ftp://ftp.netfilter.org/pub/libnftnl/
  13. PKG_MD5SUM:=6d7f9f161538ca7efd535dcc70caf964
  14. PKG_LICENSE:=GPL-2.0+
  15. PKG_INSTALL:=1
  16. include $(INCLUDE_DIR)/package.mk
  17. define Package/libnftnl
  18. SECTION:=libs
  19. CATEGORY:=Libraries
  20. DEPENDS:=+libmnl
  21. TITLE:=Low-level netlink library for the nf_tables subsystem
  22. URL:=http://www.netfilter.org/projects/libnftnl
  23. endef
  24. define Package/libnftnl/description
  25. libnftnl is a userspace library providing a low-level netlink
  26. programming interface (API) to the in-kernel nf_tables subsystem.
  27. endef
  28. TARGET_CFLAGS += $(FPIC)
  29. CONFIGURE_ARGS += \
  30. --enable-static \
  31. --enable-shared \
  32. --without-json-parsing \
  33. --without-xml-parsing \
  34. define Build/InstallDev
  35. $(INSTALL_DIR) $(1)/usr/include/libnftnl
  36. $(CP) \
  37. $(PKG_INSTALL_DIR)/usr/include/libnftnl/*.h \
  38. $(1)/usr/include/libnftnl/
  39. $(INSTALL_DIR) $(1)/usr/lib
  40. $(CP) \
  41. $(PKG_INSTALL_DIR)/usr/lib/libnftnl.{so*,a,la} \
  42. $(1)/usr/lib/
  43. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  44. $(CP) \
  45. $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libnftnl.pc \
  46. $(1)/usr/lib/pkgconfig/
  47. endef
  48. define Package/libnftnl/install
  49. $(INSTALL_DIR) $(1)/usr/lib
  50. $(CP) \
  51. $(PKG_INSTALL_DIR)/usr/lib/libnftnl.so.* \
  52. $(1)/usr/lib/
  53. endef
  54. $(eval $(call BuildPackage,libnftnl))