Fix exec permission on /etc/init.d/S60nfsd
[openwrt.git] / package / gnutls / Makefile
1 # $Id$
2
3 include $(TOPDIR)/rules.mk
4
5 PKG_NAME:=gnutls
6 PKG_VERSION:=1.0.25
7 PKG_RELEASE:=0
8 PKG_MD5SUM:=3585b5b204135e51e0efc9084b3e028b
9
10 PKG_SOURCE_URL:=ftp://ftp.gnutls.org/pub/gnutls/ \
11 ftp://ftp.gnupg.org/gcrypt/alpha/gnutls/ \
12 http://www.mirrors.wiretapped.net/security/network-security/gnutls/ \
13 ftp://ftp.mirrors.wiretapped.net/pub/security/network-security/gnutls/ \
14 http://josefsson.org/gnutls/releases/
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_CAT:=zcat
17
18 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
19 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
20
21 include $(TOPDIR)/package/rules.mk
22
23 $(eval $(call PKG_template,LIBGNUTLS,libgnutls,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
24 $(eval $(call PKG_template,GNUTLS_UTILS,gnutls-utils,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
25 $(eval $(call PKG_template,LIBGNUTLS_OPENSSL,libgnutls-openssl,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
26
27 $(PKG_BUILD_DIR)/.configured:
28 (cd $(PKG_BUILD_DIR); rm -rf config.{cache,status} ; \
29 touch configure.in ; \
30 touch acinclude.m4 ; \
31 touch aclocal.m4 ; \
32 touch Makefile.in ; \
33 touch config.h.in ; \
34 touch configure ; \
35 $(TARGET_CONFIGURE_OPTS) \
36 CFLAGS="$(TARGET_CFLAGS)" \
37 CPPFLAGS="-I$(STAGING_DIR)/usr/include" \
38 LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
39 ./configure \
40 --target=$(GNU_TARGET_NAME) \
41 --host=$(GNU_TARGET_NAME) \
42 --build=$(GNU_HOST_NAME) \
43 --program-prefix="" \
44 --program-suffix="" \
45 --prefix=/usr \
46 --exec-prefix=/usr \
47 --bindir=/usr/bin \
48 --datadir=/usr/share \
49 --includedir=/usr/include \
50 --infodir=/usr/share/info \
51 --libdir=/usr/lib \
52 --libexecdir=/usr/lib \
53 --localstatedir=/var \
54 --mandir=/usr/share/man \
55 --sbindir=/usr/sbin \
56 --sysconfdir=/etc \
57 $(DISABLE_NLS) \
58 $(DISABLE_LARGEFILE) \
59 --enable-shared \
60 --enable-static \
61 --disable-rpath \
62 --disable-srp-authentication \
63 --disable-anon-authentication \
64 --disable-openpgp-authentication \
65 --with-libgcrypt-prefix="$(STAGING_DIR)/usr" \
66 --with-libopencdk-prefix="$(STAGING_DIR)/usr" \
67 --with-libtasn1-prefix="$(STAGING_DIR)/usr" \
68 --with-included-libcfg \
69 --without-zlib \
70 --without-lzo \
71 );
72 touch $@
73
74 $(PKG_BUILD_DIR)/.built:
75 rm -rf $(PKG_INSTALL_DIR)
76 mkdir -p $(PKG_INSTALL_DIR)
77 $(MAKE) -C $(PKG_BUILD_DIR) \
78 DESTDIR="$(PKG_INSTALL_DIR)" \
79 all install
80 touch $@
81
82 $(IPKG_LIBGNUTLS):
83 install -m0755 -d $(IDIR_LIBGNUTLS)/usr/lib
84 cp -fpR $(PKG_INSTALL_DIR)/usr/lib/libgnutls{,-extra}.so.* $(IDIR_LIBGNUTLS)/usr/lib/
85 $(RSTRIP) $(IDIR_LIBGNUTLS)
86 $(IPKG_BUILD) $(IDIR_LIBGNUTLS) $(PACKAGE_DIR)
87
88 $(IPKG_LIBGNUTLS_OPENSSL):
89 install -m0755 -d $(IDIR_LIBGNUTLS_OPENSSL)/usr/lib
90 cp -fpR $(PKG_INSTALL_DIR)/usr/lib/libgnutls-openssl.so.* $(IDIR_LIBGNUTLS_OPENSSL)/usr/lib/
91 $(RSTRIP) $(IDIR_LIBGNUTLS_OPENSSL)
92 $(IPKG_BUILD) $(IDIR_LIBGNUTLS_OPENSSL) $(PACKAGE_DIR)
93
94 $(IPKG_GNUTLS_UTILS):
95 install -m0755 -d $(IDIR_GNUTLS_UTILS)/usr/bin
96 cp -fpR $(PKG_INSTALL_DIR)/usr/bin/certtool $(IDIR_GNUTLS_UTILS)/usr/bin/
97 cp -fpR $(PKG_INSTALL_DIR)/usr/bin/gnutls-{cli,serv} $(IDIR_GNUTLS_UTILS)/usr/bin/
98 $(RSTRIP) $(IDIR_GNUTLS_UTILS)
99 $(IPKG_BUILD) $(IDIR_GNUTLS_UTILS) $(PACKAGE_DIR)
100
101 $(STAGING_DIR)/usr/lib/libgnutls.so: $(PKG_BUILD_DIR)/.built
102 mkdir -p $(STAGING_DIR)/usr/bin
103 cp -fpR $(PKG_INSTALL_DIR)/usr/bin/libgnutls{,-extra}-config $(STAGING_DIR)/usr/bin/
104 mkdir -p $(STAGING_DIR)/usr/include
105 cp -fpR $(PKG_INSTALL_DIR)/usr/include/gnutls $(STAGING_DIR)/usr/include/
106 mkdir -p $(STAGING_DIR)/usr/lib
107 cp -fpR $(PKG_INSTALL_DIR)/usr/lib/libgnutls{,-extra,-openssl}.{a,so*} $(STAGING_DIR)/usr/lib/
108 mkdir -p $(STAGING_DIR)/usr/lib/pkgconfig
109 cp -fpR $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/gnutls{,-extra}.pc $(STAGING_DIR)/usr/lib/pkgconfig/
110 mkdir -p $(STAGING_DIR)/usr/share/aclocal
111 cp -fpR $(PKG_INSTALL_DIR)/usr/share/aclocal/libgnutls{,-extra}.m4 $(STAGING_DIR)/usr/share/aclocal/
112 touch $@
113
114 install-dev: $(STAGING_DIR)/usr/lib/libgnutls.so
115
116 uninstall-dev:
117 rm -rf \
118 $(STAGING_DIR)/usr/bin/libgnutls{,-extra}-config \
119 $(STAGING_DIR)/usr/include/gnutls \
120 $(STAGING_DIR)/usr/lib/libgnutls{,-extra,-openssl}.{a,so*} \
121 $(STAGING_DIR)/usr/lib/pkgconfig/gnutls{,-extra}.pc \
122 $(STAGING_DIR)/usr/share/aclocal/libgnutls{,-extra}.m4 \
123
124 compile: install-dev
125
126 clean: uninstall-dev
127
128 mostlyclean:
129 make -C $(PKG_BUILD_DIR) clean
130 rm -f $(PKG_BUILD_DIR)/.built
This page took 0.047735 seconds and 5 git commands to generate.