fix gmediaserver compile
[openwrt/svn-archive/archive.git] / libs / libtasn1 / Makefile
1 #
2 # Copyright (C) 2006 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=libtasn1
12 PKG_VERSION:=0.2.13
13 PKG_RELEASE:=0
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=ftp://ftp.gnutls.org/pub/gnutls/libtasn1/ \
17 ftp://ftp.gnupg.org/gcrypt/alpha/gnutls/libtasn1/ \
18 http://www.mirrors.wiretapped.net/security/network-security/gnutls/libtasn1/ \
19 ftp://ftp.mirrors.wiretapped.net/pub/security/network-security/gnutls/libtasn1/ \
20 http://josefsson.org/gnutls/releases/libtasn1/
21 PKG_MD5SUM:=d124b11908cfb88883fe71472c25d53a
22 PKG_CAT:=zcat
23
24 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
25 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
26
27 include $(INCLUDE_DIR)/package.mk
28
29 define Package/libtasn1
30 SECTION:=libs
31 CATEGORY:=Libraries
32 TITLE:=An ASN.1 and DER structures manipulation library
33 DESCRIPTION:=\
34 This is a library for Abstract Syntax Notation One (ASN.1) and \\\
35 Distinguish Encoding Rules (DER) manipulation.
36 URL:=ftp://ftp.gnutls.org/pub/gnutls/libtasn1/
37 endef
38
39 define Build/Configure
40 (cd $(PKG_BUILD_DIR); touch \
41 configure.ac \
42 acinclude.m4 \
43 aclocal.m4 \
44 Makefile.in \
45 config.h.in \
46 configure \
47 );
48 $(call Build/Configure/Default, \
49 --enable-shared \
50 --enable-static \
51 )
52 endef
53
54 define Build/Compile
55 $(MAKE) -C $(PKG_BUILD_DIR) \
56 DESTDIR="$(PKG_INSTALL_DIR)" \
57 all install
58 endef
59
60 define Build/InstallDev
61 mkdir -p $(STAGING_DIR)/usr/bin
62 $(CP) $(PKG_INSTALL_DIR)/usr/bin/libtasn1-config $(STAGING_DIR)/usr/bin/
63 mkdir -p $(STAGING_DIR)/usr/include
64 $(CP) $(PKG_INSTALL_DIR)/usr/include/libtasn1.h $(STAGING_DIR)/usr/include/
65 mkdir -p $(STAGING_DIR)/usr/lib
66 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtasn1.{a,so*} $(STAGING_DIR)/usr/lib/
67 mkdir -p $(STAGING_DIR)/usr/share/aclocal
68 $(CP) $(PKG_INSTALL_DIR)/usr/share/aclocal/libtasn1.m4 $(STAGING_DIR)/usr/share/aclocal/
69 endef
70
71 define Build/UninstallDev
72 rm -rf \
73 $(STAGING_DIR)/usr/bin/libtasn1-config \
74 $(STAGING_DIR)/usr/include/libtasn1.h \
75 $(STAGING_DIR)/usr/lib/libtasn1.{a,so*} \
76 $(STAGING_DIR)/usr/share/aclocal/libtasn1.m4
77 endef
78
79 define Package/libtasn1/install
80 $(INSTALL_DIR) $(1)/usr/lib
81 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtasn1.so.* $(1)/usr/lib/
82 endef
83
84 $(eval $(call BuildPackage,libtasn1))