/[gentoo-x86]/net-libs/gnutls/gnutls-3.3.16-r1.ebuild
Gentoo

Contents of /net-libs/gnutls/gnutls-3.3.16-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations) (download)
Mon Jul 13 19:08:22 2015 UTC (5 years, 4 months ago) by alonbl
Branch: MAIN
CVS Tags: HEAD
Add texinfo dependency and force doc USE as top level doc in configure, bug#554682

(Portage version: 2.2.20/cvs/Linux x86_64, signed Manifest commit with key BF20DC51)

1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-libs/gnutls/gnutls-3.3.16.ebuild,v 1.1 2015/07/12 14:33:50 alonbl Exp $
4
5 EAPI=5
6
7 inherit autotools libtool eutils multilib-minimal versionator
8
9 DESCRIPTION="A TLS 1.2 and SSL 3.0 implementation for the GNU project"
10 HOMEPAGE="http://www.gnutls.org/"
11 SRC_URI="mirror://gnupg/gnutls/v$(get_version_component_range 1-2)/${P}.tar.xz"
12
13 # LGPL-3 for libgnutls library and GPL-3 for libgnutls-extra library.
14 # soon to be relicensed as LGPL-2.1 unless heartbeat extension enabled.
15 LICENSE="GPL-3 LGPL-3"
16 SLOT="0"
17 KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x86-interix ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x86-solaris"
18 IUSE_LINGUAS=" en cs de fi fr it ms nl pl sv uk vi zh_CN"
19 IUSE="+cxx +crywrap dane doc examples guile nls +openssl pkcs11 static-libs test zlib ${IUSE_LINGUAS// / linguas_}"
20 # heartbeat support is not disabled until re-licensing happens fullyf
21
22 # NOTICE: sys-devel/autogen is required at runtime as we
23 # use system libopts
24 RDEPEND=">=dev-libs/libtasn1-3.9[${MULTILIB_USEDEP}]
25 >=dev-libs/nettle-2.7[gmp,${MULTILIB_USEDEP}]
26 >=dev-libs/gmp-5.1.3-r1[${MULTILIB_USEDEP}]
27 sys-devel/autogen
28 crywrap? ( net-dns/libidn )
29 dane? ( >=net-dns/unbound-1.4.20[${MULTILIB_USEDEP}] )
30 guile? ( >=dev-scheme/guile-1.8:*[networking] )
31 nls? ( >=virtual/libintl-0-r1[${MULTILIB_USEDEP}] )
32 pkcs11? ( >=app-crypt/p11-kit-0.20.7[${MULTILIB_USEDEP}] )
33 zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )
34 abi_x86_32? (
35 !<=app-emulation/emul-linux-x86-baselibs-20140508
36 !app-emulation/emul-linux-x86-baselibs[-abi_x86_32(-)]
37 )"
38 DEPEND="${RDEPEND}
39 >=sys-devel/automake-1.11.6
40 >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}]
41 doc? (
42 sys-apps/texinfo
43 dev-util/gtk-doc
44 )
45 nls? ( sys-devel/gettext )
46 test? ( app-misc/datefudge )"
47
48 DOCS=( AUTHORS ChangeLog NEWS README THANKS doc/TODO )
49
50 S="${WORKDIR}/${PN}-$(get_version_component_range 1-3)"
51
52 pkg_setup() {
53 # bug#520818
54 export TZ=UTC
55 }
56
57 src_prepare() {
58 sed -i \
59 -e 's/imagesdir = $(infodir)/imagesdir = $(htmldir)/' \
60 doc/Makefile.am || die
61
62 # force regeneration of autogen-ed files
63 local file
64 for file in $(grep -l AutoGen-ed src/*.c) ; do
65 rm src/$(basename ${file} .c).{c,h} || die
66 done
67
68 # force regeneration of makeinfo files
69 # have no idea why on some system these files are not
70 # accepted as-is, see bug#520818
71 for file in $(grep -l "produced by makeinfo" doc/*.info) ; do
72 rm "${file}" || die
73 done
74
75 # support user patches
76 epatch_user
77
78 eautoreconf
79
80 # Use sane .so versioning on FreeBSD.
81 elibtoolize
82
83 # bug 497472
84 use cxx || epunt_cxx
85 }
86
87 multilib_src_configure() {
88 LINGUAS="${LINGUAS//en/en@boldquot en@quot}"
89
90 # TPM needs to be tested before being enabled
91 # hardware-accell is disabled on OSX because the asm files force
92 # GNU-stack (as doesn't support that) and when that's removed ld
93 # complains about duplicate symbols
94 ECONF_SOURCE=${S} \
95 econf \
96 --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" \
97 --disable-valgrind-tests \
98 --without-included-libtasn1 \
99 --enable-heartbeat-support \
100 $(use_enable cxx) \
101 $(use_enable dane libdane) \
102 $(multilib_native_use_enable doc) \
103 $(multilib_native_use_enable doc gtk-doc) \
104 $(multilib_native_use_enable guile) \
105 $(multilib_native_use_enable crywrap) \
106 $(use_enable nls) \
107 $(use_enable openssl openssl-compatibility) \
108 $(use_enable static-libs static) \
109 $(use_with pkcs11 p11-kit) \
110 $(use_with zlib) \
111 --without-tpm \
112 --with-unbound-root-key-file=/etc/dnssec/root-anchors.txt \
113 $([[ ${CHOST} == *-darwin* ]] && echo --disable-hardware-acceleration)
114
115 if multilib_is_native_abi; then
116 ln -s "${S}"/doc/reference/html doc/reference/html || die
117 fi
118 }
119
120 multilib_src_compile() {
121 if multilib_is_native_abi; then
122 default
123
124 # symlink certtool for use in other ABIs
125 if use test; then
126 ln -s "${BUILD_DIR}"/src "${T}"/native-tools || die
127 fi
128 else
129 emake -C gl
130 emake -C lib
131 emake -C extra
132 use dane && emake -C libdane
133 fi
134 }
135
136 multilib_src_test() {
137 if multilib_is_native_abi; then
138 # parallel testing often fails
139 emake -j1 check
140 else
141 # use native ABI tools
142 ln -s "${T}"/native-tools/{certtool,gnutls-{serv,cli}} \
143 "${BUILD_DIR}"/src/ || die
144
145 emake -C gl -j1 check
146 emake -C tests -j1 check
147 fi
148 }
149
150 multilib_src_install() {
151 if multilib_is_native_abi; then
152 emake DESTDIR="${D}" install
153 else
154 emake -C lib DESTDIR="${D}" install
155 emake -C extra DESTDIR="${D}" install
156 use dane && emake -C libdane DESTDIR="${D}" install
157 fi
158 }
159
160 multilib_src_install_all() {
161 einstalldocs
162 prune_libtool_files --all
163
164 dodoc doc/certtool.cfg
165
166 if use doc; then
167 dohtml doc/gnutls.html
168 else
169 rm -fr "${ED}/usr/share/doc/${PF}/html"
170 fi
171
172 if use examples; then
173 docinto examples
174 dodoc doc/examples/*.c
175 fi
176 }

  ViewVC Help
Powered by ViewVC 1.1.20