procd: make mDNS TXT record parsing more solid
[openwrt/openwrt.git] / package / libs / libmnl / Makefile
1 #
2 # Copyright (C) 2011-2012 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:=libmnl
11 PKG_VERSION:=1.0.5
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
15 PKG_SOURCE_URL:= \
16 http://www.netfilter.org/projects/libmnl/files \
17 ftp://ftp.netfilter.org/pub/libmnl
18 PKG_HASH:=274b9b919ef3152bfb3da3a13c950dd60d6e2bcd54230ffeca298d03b40d0525
19
20 PKG_MAINTAINER:=Jo-Philipp Wich <jo@mein.io>
21
22 PKG_FIXUP:=autoreconf
23 PKG_INSTALL:=1
24 PKG_LICENSE:=LGPL-2.1+
25
26 include $(INCLUDE_DIR)/package.mk
27
28 define Package/libmnl
29 SECTION:=libs
30 CATEGORY:=Libraries
31 TITLE:=Minimalistic user-space library for Netlink
32 URL:=http://www.netfilter.org/projects/libmnl/
33 ABI_VERSION:=0
34 endef
35
36 define Package/libmnl/description
37 libmnl is a minimalistic user-space library oriented to Netlink developers.
38 There are a lot of common tasks in parsing, validating, constructing of
39 both the Netlink header and TLVs that are repetitive and easy to get wrong.
40 This library aims to provide simple helpers that allows you to re-use code
41 and to avoid re-inventing the wheel. The main features of this library are:
42 .
43 * Small: the shared library requires around 30KB for an x86-based computer.
44 .
45 * Simple: this library avoids complexity and elaborated abstractions that
46 tend to hide Netlink details.
47 .
48 * Easy to use: the library simplifies the work for Netlink-wise developers.
49 It provides functions to make socket handling, message building, validating,
50 parsing and sequence tracking, easier.
51 .
52 * Easy to re-use: you can use the library to build your own abstraction layer
53 on top of this library.
54 .
55 * Decoupling: the interdependency of the main bricks that compose the library
56 is reduced, i.e. the library provides many helpers, but the programmer is not
57 forced to use them.
58 endef
59
60 CONFIGURE_ARGS+= \
61 --enable-shared \
62 --enable-static \
63
64 define Build/InstallDev
65 $(INSTALL_DIR) $(1)/usr/include
66 $(CP) $(PKG_INSTALL_DIR)/usr/include/libmnl $(1)/usr/include/
67 $(INSTALL_DIR) $(1)/usr/lib
68 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libmnl.{a,so*} $(1)/usr/lib/
69 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
70 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libmnl.pc $(1)/usr/lib/pkgconfig/
71 endef
72
73 define Package/libmnl/install
74 $(INSTALL_DIR) $(1)/usr/lib
75 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libmnl.so.* $(1)/usr/lib/
76 endef
77
78 $(eval $(call BuildPackage,libmnl))