2 # Copyright (C) 2007 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
15 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.bz2
16 PKG_SOURCE_URL
:=http
://josefsson.org
/gnutls
/releases
/ \
17 http
://www.mirrors.wiretapped.net
/security
/network-security
/gnutls
/ \
18 ftp
://ftp.gnutls.org
/pub
/gnutls
/ \
19 ftp
://ftp.gnupg.org
/gcrypt
/alpha
/gnutls
/ \
20 ftp
://ftp.mirrors.wiretapped.net
/pub
/security
/network-security
/gnutls
/
21 PKG_MD5SUM
:=181b2ff554a83e6cf85505ea16699d39
23 include $(INCLUDE_DIR
)/package.mk
25 define Package
/gnutls
/Default
29 URL
:=http
://www.gnu.org
/software
/gnutls
/
32 define Package
/gnutls
/Default
/description
33 GnuTLS is a project that aims to develop a library which provides a
34 secure layer
, over a reliable transport layer. Currently the GnuTLS
35 library implements the proposed standards by the IETF
's TLS working
39 define Package/gnutls-utils
40 $(call Package/gnutls/Default)
43 DEPENDS:=+libgnutls +libgpg-error
47 This package contains some GnuTLS utilities.
50 define Package/libgnutls
51 $(call Package/gnutls/Default)
56 This package contains the GnuTLS shared libraries, needed by other programs.
59 define Package/libgnutls-openssl
60 $(call Package/gnutls/Default)
62 TITLE+= (OpenSSL compat library)
65 This package contains the GnuTLS OpenSSL compatibility layer shared library.
68 define Build/Configure
69 $(call Build/Configure/Default, \
72 --disable-srp-authentication \
73 --with-included-libtasn1=yes \
74 --with-included-libcfg=yes \
75 --without-libopencdk-prefix \
79 $(call libtool_disable_rpath)
83 $(MAKE) -C $(PKG_BUILD_DIR) all
84 $(call libtool_fixup_libdir,$(PKG_INSTALL_DIR))
85 $(MAKE) -C $(PKG_BUILD_DIR) DESTDIR="$(PKG_INSTALL_DIR)" all install
88 define Build/InstallDev
89 mkdir -p $(STAGING_DIR)/usr/bin
90 $(CP) $(PKG_INSTALL_DIR)/usr/bin/libgnutls{,-extra}-config $(STAGING_DIR)/usr/bin/
91 mkdir -p $(STAGING_DIR)/usr/include
92 $(CP) $(PKG_INSTALL_DIR)/usr/include/gnutls $(STAGING_DIR)/usr/include/
93 mkdir -p $(STAGING_DIR)/usr/lib
94 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnutls{,-extra,-openssl}.{a,so*} $(STAGING_DIR)/usr/lib/
95 mkdir -p $(STAGING_DIR)/usr/lib/pkgconfig
96 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/gnutls{,-extra}.pc $(STAGING_DIR)/usr/lib/pkgconfig/
97 $(SED) 's
,-I
$$$${includedir},,g
' $(STAGING_DIR)/usr/lib/pkgconfig/gnutls{,-extra}.pc
98 $(SED) 's
,-L
$$$${libdir},,g
' $(STAGING_DIR)/usr/lib/pkgconfig/gnutls{,-extra}.pc
99 $(SED) "s,"prefix\=/usr",prefix=$(STAGING_DIR)/usr," $(STAGING_DIR)/usr/lib/pkgconfig/gnutls-extra.pc
100 $(SED) "s,"exec_prefix\=/usr",exec_prefix=$(STAGING_DIR)/usr," $(STAGING_DIR)/usr/lib/pkgconfig/gnutls-extra.pc
103 define Build/UninstallDev
104 rm -rf $(STAGING_DIR)/usr/bin/libgnutls{,-extra}-config \
105 $(STAGING_DIR)/usr/include/gnutls \
106 $(STAGING_DIR)/usr/lib/libgnutls{,-extra,-openssl}.{a,so*} \
107 $(STAGING_DIR)/usr/lib/pkgconfig/gnutls{,-extra}.pc \
108 $(STAGING_DIR)/usr/share/aclocal/libgnutls{,-extra}.m4
111 define Package/gnutls-utils/install
112 $(INSTALL_DIR) $(1)/usr/bin
113 $(CP) $(PKG_INSTALL_DIR)/usr/bin/certtool $(1)/usr/bin/
114 $(CP) $(PKG_INSTALL_DIR)/usr/bin/gnutls-{cli,serv} $(1)/usr/bin/
117 define Package/libgnutls/install
118 $(INSTALL_DIR) $(1)/usr/lib
119 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnutls{,-extra}.so.* $(1)/usr/lib/
122 define Package/libgnutls-openssl/install
123 $(INSTALL_DIR) $(1)/usr/lib
124 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnutls-openssl.so.* $(1)/usr/lib/
127 $(eval $(call BuildPackage,gnutls-utils))
128 $(eval $(call BuildPackage,libgnutls))
129 $(eval $(call BuildPackage,libgnutls-openssl))