[packages] darkstat: update to 3.0.713, use PKG_INSTALL and Build/Compile/Default...
[packages.git] / libs / libnfnetlink / Makefile
1 #
2 # Copyright (C) 2007-2010 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:=libnfnetlink
11 PKG_VERSION:=1.0.0
12 PKG_RELEASE:=2
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
15 PKG_SOURCE_URL:= \
16         http://www.netfilter.org/projects/libnfnetlink/files/ \
17         ftp://ftp.netfilter.org/pub/libnfnetlink/ \
18         http://mirrors.evolva.ro/netfilter.org/libnfnetlink/
19 PKG_MD5SUM:=016fdec8389242615024c529acc1adb8
20
21 PKG_FIXUP:=libtool
22 PKG_INSTALL:=1
23
24 include $(INCLUDE_DIR)/package.mk
25
26 define Package/libnfnetlink
27   SECTION:=libs
28   CATEGORY:=Libraries
29   DEPENDS:=@LINUX_2_6
30   TITLE:=A low-level library for netfilter related kernel/userspace communication
31   URL:=http://netfilter.org/projects/libnfnetlink/
32 endef
33
34 define Package/libnfnetlink/description
35  libnfnetlink is is the low-level library for netfilter related kernel/userspace communication.
36  It provides a generic messaging infrastructure for in-kernel netfilter subsystems
37  (such as nfnetlink_log, nfnetlink_queue, nfnetlink_conntrack) and their respective users
38  and/or management tools in userspace.
39 endef
40
41 TARGET_CFLAGS += $(FPIC)
42
43 CONFIGURE_ARGS += \
44         --enable-static \
45         --enable-shared
46
47 define Build/InstallDev
48         $(INSTALL_DIR) $(1)/usr/include/libnfnetlink
49         $(CP) \
50                 $(PKG_INSTALL_DIR)/usr/include/libnfnetlink/{libnfnetlink,linux_nfnetlink,linux_nfnetlink_compat}.h \
51                 $(1)/usr/include/libnfnetlink/
52         $(INSTALL_DIR) $(1)/usr/lib
53         $(CP) \
54                 $(PKG_INSTALL_DIR)/usr/lib/libnfnetlink.{a,so*} \
55                 $(1)/usr/lib/
56         $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
57         $(CP) \
58                 $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libnfnetlink.pc \
59                 $(1)/usr/lib/pkgconfig/
60 endef
61
62 define Package/libnfnetlink/install
63         $(INSTALL_DIR) $(1)/usr/lib
64         $(CP) \
65                 $(PKG_INSTALL_DIR)/usr/lib/libnfnetlink.so.* \
66                 $(1)/usr/lib/
67 endef
68
69 $(eval $(call BuildPackage,libnfnetlink))