OSDN Git Service

libnftnl: add fullcone expression support
[immortalwrt/immortalwrt.git] / package / libs / libnftnl / Makefile
1 #
2 # Copyright (C) 2014 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
10 PKG_NAME:=libnftnl
11 PKG_VERSION:=1.2.1
12 PKG_RELEASE:=$(AUTORELEASE)
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
15 PKG_SOURCE_URL:=https://netfilter.org/projects/$(PKG_NAME)/files
16 PKG_HASH:=7508a5c414fab13e3cb3ce8262d0ce4f02c1590a8e4f8628ab497b5b4585937c
17
18 PKG_MAINTAINER:=Steven Barth <steven@midlink.org>
19 PKG_LICENSE:=GPL-2.0-or-later
20 PKG_LICENSE_FILES:=COPYING
21
22 PKG_FIXUP:=autoreconf
23 PKG_INSTALL:=1
24 PKG_BUILD_PARALLEL:=1
25
26 include $(INCLUDE_DIR)/package.mk
27
28 DISABLE_NLS:=
29
30 define Package/libnftnl
31   SECTION:=libs
32   CATEGORY:=Libraries
33   DEPENDS:=+libmnl
34   TITLE:=Low-level netlink library for the nf_tables subsystem
35   URL:=http://www.netfilter.org/projects/libnftnl
36   ABI_VERSION:=11
37 endef
38
39 define Package/libnftnl/description
40  libnftnl is a userspace library providing a low-level netlink
41  programming interface (API) to the in-kernel nf_tables subsystem.
42 endef
43
44 TARGET_CFLAGS += $(FPIC) -flto
45 TARGET_LDFLAGS += -flto
46
47 CONFIGURE_ARGS += \
48         --enable-static \
49         --enable-shared
50
51 define Build/InstallDev
52         $(INSTALL_DIR) $(1)/usr/include/libnftnl
53         $(CP) \
54                 $(PKG_INSTALL_DIR)/usr/include/libnftnl/*.h \
55                 $(1)/usr/include/libnftnl/
56
57         $(INSTALL_DIR) $(1)/usr/lib
58         $(CP) \
59                 $(PKG_INSTALL_DIR)/usr/lib/libnftnl.{so*,a,la} \
60                 $(1)/usr/lib/
61
62         $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
63         $(CP) \
64                 $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libnftnl.pc \
65                 $(1)/usr/lib/pkgconfig/
66 endef
67
68 define Package/libnftnl/install
69         $(INSTALL_DIR) $(1)/usr/lib
70         $(CP) \
71                 $(PKG_INSTALL_DIR)/usr/lib/libnftnl.so.* \
72                 $(1)/usr/lib/
73 endef
74
75 $(eval $(call BuildPackage,libnftnl))