/[gentoo-x86]/dev-libs/tntnet/tntnet-2.0-r1.ebuild
Gentoo

Contents of /dev-libs/tntnet/tntnet-2.0-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Mon Jun 4 16:38:22 2012 UTC (2 years, 6 months ago) by idl0r
Branch: MAIN
Changes since 1.3: +2 -2 lines
Version bump. Fix dependencies.

(Portage version: 2.2.0_alpha109/cvs/Linux x86_64)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/dev-libs/tntnet/tntnet-2.0-r1.ebuild,v 1.3 2012/05/04 18:35:48 jdhore Exp $
4
5 EAPI="3"
6
7 inherit autotools eutils
8
9 DESCRIPTION="Modular, multithreaded webapplicationserver extensible with C++"
10 HOMEPAGE="http://www.tntnet.org/index.hms"
11 SRC_URI="http://www.tntnet.org/download/${P}.tar.gz"
12
13 LICENSE="LGPL-2.1"
14 SLOT="0"
15 KEYWORDS="~amd64 ~sparc ~x86"
16 IUSE="cgi doc examples gnutls server sdk ssl"
17
18 RDEPEND="=dev-libs/cxxtools-2.0*
19 sys-libs/zlib[minizip]
20 ssl? (
21 gnutls? (
22 >=net-libs/gnutls-1.2.0
23 dev-libs/libgcrypt
24 )
25 !gnutls? ( dev-libs/openssl )
26 )"
27 DEPEND="${RDEPEND}
28 virtual/pkgconfig
29 examples? ( app-arch/zip )"
30
31 src_prepare() {
32 # Both fixed in the next release
33 epatch "${FILESDIR}/${P}-as-needed.patch"
34 epatch "${FILESDIR}/${P}-gnutls.patch"
35 epatch "${FILESDIR}"/${P}-zlib-minizip.patch
36 rm framework/common/{ioapi,unzip}.[ch] || die
37
38 eautoreconf
39
40 sed -i -e 's:@localstatedir@:/var:' etc/tntnet/tntnet.conf.in || die
41 }
42
43 src_configure() {
44 local myconf=""
45
46 # Prefer gnutls above SSL
47 if use gnutls; then
48 einfo "Using gnutls for ssl support."
49 myconf="${myconf} --with-ssl=gnutls"
50 elif use ssl; then
51 einfo "Using openssl for ssl support."
52 myconf="${myconf} --with-ssl=openssl"
53 else
54 myconf="${myconf} --with-ssl=no"
55 fi
56
57 # demos/examples depend upon sdk
58 if use examples && ! use sdk; then
59 myconf="${myconf} --with-sdk"
60 fi
61
62 econf \
63 $(use_with examples demos) \
64 $(use_with sdk) \
65 $(use_with cgi) \
66 $(use_with server) \
67 ${myconf}
68 }
69
70 src_install() {
71 emake DESTDIR="${D}" install || die
72
73 dodoc AUTHORS ChangeLog README TODO
74 if use doc; then
75 dodoc doc/*.pdf || die
76 fi
77
78 if use examples; then
79 cd "${S}/sdk/demos"
80 emake clean
81 rm -rf .deps */.deps .libs */.libs
82 cd "${S}"
83
84 insinto /usr/share/doc/${PF}/examples
85 doins -r sdk/demos/* || die
86 fi
87
88 if use server; then
89 rm -f "${D}/etc/init.d/tntnet"
90 newinitd "${FILESDIR}/tntnet.initd" tntnet
91 fi
92 }

  ViewVC Help
Powered by ViewVC 1.1.20