29606f3911dade4ff92d0c520362a17d0a054c30
[feed/telephony.git] / libs / iksemel / 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:=iksemel
11 PKG_VERSION:=1.4
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://iksemel.googlecode.com/files/
16 PKG_MD5SUM:=532e77181694f87ad5eb59435d11c1ca
17
18 PKG_FIXUP:=autoreconf
19
20 PKG_INSTALL:=1
21
22 PKG_LICENSE:=LGPL-2.1
23 PKG_LICENSE_FILES:=COPYING
24 PKG_MAINTAINER:=Jiri Slachta <jiri@slachta.eu>
25
26 include $(INCLUDE_DIR)/package.mk
27
28 define Package/libiksemel
29 SUBMENU:=Telephony
30 SECTION:=libs
31 CATEGORY:=Libraries
32 TITLE:=Iksemel Jabber Library
33 URL:=http://code.google.com/p/iksemel/
34 DEPENDS:= +libgnutls +libtasn1 +libgcrypt +libgpg-error
35 endef
36
37 define Package/libiksemel/description
38 Iksemel is an XML parser library mainly designed for Jabber applications.
39 It provides SAX, DOM, and special Jabber stream APIs. Library is coded
40 in ANSI C except the network code (which is POSIX compatible), thus
41 highly portable.
42 endef
43
44 TARGET_CFLAGS += $(FPIC)
45 TARGET_LDFLAGS += \
46 -Wl,-rpath-link,$(STAGING_DIR)/usr/lib \
47 -lgnutls -lgcrypt -lgpg-error
48
49 define Build/Configure
50 $(call Build/Configure/Default, \
51 --enable-shared \
52 --enable-static \
53 --with-libgnutls-prefix="$(STAGING_DIR)/usr" \
54 , \
55 LIBS="$(TARGET_LDFLAGS)" \
56 )
57 endef
58
59 define Build/InstallDev
60 $(INSTALL_DIR) $(1)/usr/include/
61 $(CP) $(PKG_INSTALL_DIR)/usr/include/iksemel.h $(1)/usr/include/
62
63 $(INSTALL_DIR) $(1)/usr/lib
64 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libiksemel.{a,so*} $(1)/usr/lib/
65
66 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
67 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/iksemel.pc $(1)/usr/lib/pkgconfig/
68 endef
69
70 define Package/libiksemel/install
71 $(INSTALL_DIR) $(1)/usr/lib
72 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libiksemel.so* $(1)/usr/lib/
73 endef
74
75 $(eval $(call BuildPackage,libiksemel))