Add srtp lib package
[openwrt/svn-archive/archive.git] / libs / srtp / Makefile
1 #
2 # Copyright (C) 2011 OpenWrt.org
3 # Copyright (C) 2011 Victor Seva <linuxmaniac@torreviejawireless.org>
4 #
5 # This is free software, licensed under the GNU General Public License v2.
6 # See /LICENSE for more information.
7 #
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=srtp
11 PKG_VERSION:=1.4.4
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tgz
15 PKG_SOURCE_URL:=@SF/srtp
16 PKG_MD5SUM:=9b449edb011c934ca97009e7e0566d22
17 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
18
19 include $(INCLUDE_DIR)/package.mk
20
21 TARGET_CFLAGS += $(FPIC)
22
23 define Package/libsrtp
24 SECTION:=libs
25 CATEGORY:=Libraries
26 TITLE:=Secure Real-time Transport Protocol (SRTP) library
27 URL:=http://sourceforge.net/projects/srtp
28 MAINTAINER:=Victor Seva <linuxmaniac@torreviejawireless.com>
29 endef
30
31 define Package/libsrtp/description
32 Open-source implementation of the Secure Real-time Transport
33 Protocol (SRTP) originally authored by Cisco Systems, Inc.
34 It is available under a BSD-style license.
35 endef
36
37 define Build/Configure
38 $(call Build/Configure/Default, \
39 --disable-stdout \
40 --enable-syslog \
41 )
42 endef
43
44 define Build/Compile
45 $(MAKE) -C $(PKG_BUILD_DIR) \
46 DESTDIR="$(PKG_INSTALL_DIR)" all install
47 endef
48
49 define Build/InstallDev
50 $(INSTALL_DIR) $(1)/usr/include
51 $(CP) $(PKG_INSTALL_DIR)/usr/include/srtp $(1)/usr/include/
52 $(INSTALL_DIR) $(1)/usr/lib
53 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libsrtp.{a,so*} $(1)/usr/lib/
54 endef
55
56
57 define Package/libsrtp/install
58 $(INSTALL_DIR) $(1)/usr/lib
59 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libsrtp.so.* \
60 $(1)/usr/lib/
61 endef
62
63 $(eval $(call BuildPackage,libsrtp))