summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEray Aslan <eras@gentoo.org>2012-10-16 10:59:22 +0000
committerEray Aslan <eras@gentoo.org>2012-10-16 10:59:22 +0000
commite6347d684ce76ad7d3d716448a35a36ba2dd63aa (patch)
tree741efeae9271bf33db62e642e71bf1bed237c170 /mail-client/cone
parentnet-im/gajim: Fix for broken test, #434818 (diff)
downloadgentoo-2-e6347d684ce76ad7d3d716448a35a36ba2dd63aa.tar.gz
gentoo-2-e6347d684ce76ad7d3d716448a35a36ba2dd63aa.tar.bz2
gentoo-2-e6347d684ce76ad7d3d716448a35a36ba2dd63aa.zip
Fix building with gnutls-3 - bug #421445
(Portage version: 2.2.0_alpha138/cvs/Linux x86_64, signed Manifest commit with key 0x586A3B1F)
Diffstat (limited to 'mail-client/cone')
-rw-r--r--mail-client/cone/ChangeLog9
-rw-r--r--mail-client/cone/cone-0.90-r1.ebuild63
-rw-r--r--mail-client/cone/files/cone-0.90-gnutls3.patch72
3 files changed, 142 insertions, 2 deletions
diff --git a/mail-client/cone/ChangeLog b/mail-client/cone/ChangeLog
index 58ebe1109082..045119905942 100644
--- a/mail-client/cone/ChangeLog
+++ b/mail-client/cone/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for mail-client/cone
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/mail-client/cone/ChangeLog,v 1.47 2012/09/23 08:10:28 phajdan.jr Exp $
+# $Header: /var/cvsroot/gentoo-x86/mail-client/cone/ChangeLog,v 1.48 2012/10/16 10:59:22 eras Exp $
+
+*cone-0.90-r1 (16 Oct 2012)
+
+ 16 Oct 2012; Eray Aslan <eras@gentoo.org> +cone-0.90-r1.ebuild,
+ +files/cone-0.90-gnutls3.patch:
+ Fix building with gnutls-3 - bug #421445
23 Sep 2012; Pawel Hajdan jr <phajdan.jr@gentoo.org> cone-0.90.ebuild:
x86 stable wrt bug #434296
@@ -213,4 +219,3 @@
courier. This has been living in my overlay for awhile, and I've had a few
other people test it. Let me know if you give this a try and it works or
doesn't.
-
diff --git a/mail-client/cone/cone-0.90-r1.ebuild b/mail-client/cone/cone-0.90-r1.ebuild
new file mode 100644
index 000000000000..fb8cf807be75
--- /dev/null
+++ b/mail-client/cone/cone-0.90-r1.ebuild
@@ -0,0 +1,63 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/mail-client/cone/cone-0.90-r1.ebuild,v 1.1 2012/10/16 10:59:22 eras Exp $
+
+EAPI=4
+
+inherit eutils autotools
+
+DESCRIPTION="CONE: COnsole News reader and Emailer"
+HOMEPAGE="http://www.courier-mta.org/cone/"
+SRC_URI="mirror://sourceforge/courier/${P}.tar.bz2"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~sparc ~x86"
+IUSE="crypt fam gnutls idn ipv6 ldap spell"
+
+RDEPEND=">=dev-libs/openssl-0.9.6
+ dev-libs/libxml2
+ sys-libs/ncurses
+ crypt? ( >=app-crypt/gnupg-1.0.4 )
+ fam? ( virtual/fam )
+ gnutls? ( net-libs/gnutls )
+ idn? ( net-dns/libidn )
+ ipv6? ( net-dns/libidn )
+ ldap? ( net-nds/openldap )
+ spell? ( app-text/aspell )"
+DEPEND="${RDEPEND}
+ dev-lang/perl"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${PN}-0.84.20100819-aspell-automagic.patch
+ epatch "${FILESDIR}"/${PN}-0.86-skip-rfc2045-test.patch
+ epatch "${FILESDIR}"/${P}-gnutls3.patch
+
+ # move local macro to m4 and run eautoreconf
+ mkdir "${S}/m4"
+ sed -n -e '/# AC_PROG_SYSCONFTOOL/,+33 p' "${S}"/aclocal.m4 > \
+ m4/sysconftool.m4 || die
+ sed -i -e '/^SUBDIRS/i ACLOCAL_AMFLAGS = -I m4' "${S}"/Makefile.am || die
+ eautoreconf
+}
+
+src_configure() {
+ local myconf
+ if use spell ; then
+ myconf="--with-spellcheck=aspell"
+ else
+ myconf="--with-spellcheck=none"
+ fi
+
+ econf \
+ ${myconf} \
+ $(use_with ldap ldapaddressbook) \
+ $(use_with gnutls) \
+ $(use_with idn libidn) \
+ $(use_with ipv6)
+}
+
+src_install() {
+ default
+ emake DESTDIR="${D}" install-configure
+}
diff --git a/mail-client/cone/files/cone-0.90-gnutls3.patch b/mail-client/cone/files/cone-0.90-gnutls3.patch
new file mode 100644
index 000000000000..23f187bb0182
--- /dev/null
+++ b/mail-client/cone/files/cone-0.90-gnutls3.patch
@@ -0,0 +1,72 @@
+diff --git a/tcpd/configure.in b/tcpd/configure.in
+index 7261515..406914e 100644
+--- a/tcpd/configure.in
++++ b/tcpd/configure.in
+@@ -356,7 +356,7 @@ then
+
+ CPPFLAGS="$save_CPPFLAGS"
+ else
+- have_gnutls="no: pkgconfig --modeversion gnutls failed"
++ have_gnutls="no: pkgconfig --modversion gnutls failed"
+ fi
+ else
+ have_gnutls="no: pkg-config not found"
+@@ -368,7 +368,15 @@ if test "$have_gnutls" = "yes"
+ then
+ LIBCOURIERTLSGNUTLS="libcouriertlsgnutls.la"
+ CPPFLAGS="$CPPFLAGS `$PKGCONFIG --cflags gnutls`"
+- gnutlsdep="`$PKGCONFIG --libs gnutls` -lgnutls-extra"
++ have_gnutls3=no
++ PKG_CHECK_EXISTS([gnutls >= 3.0], [have_gnutls3=yes])
++ if test "x$have_gnutls3" = "xno"
++ then
++ gnutlsdep="`$PKGCONFIG --libs gnutls` -lgnutls-extra"
++ else
++ gnutlsdep="`$PKGCONFIG --libs gnutls`"
++ AC_DEFINE([HAVE_GNUTLS3], [1], [Use GnuTLS3])
++ fi
+ fi
+
+ AC_CHECK_SIZEOF(gnutls_transport_ptr_t,0, [
+diff --git a/tcpd/libcouriergnutls.c b/tcpd/libcouriergnutls.c
+index 4aa4996..ef8cb70 100644
+--- a/tcpd/libcouriergnutls.c
++++ b/tcpd/libcouriergnutls.c
+@@ -9,7 +9,9 @@
+ #include "tlscache.h"
+ #include "soxwrap/soxwrap.h"
+ #include <gnutls/gnutls.h>
++#ifndef HAVE_GNUTLS3
+ #include <gnutls/extra.h>
++#endif
+ #include <gnutls/x509.h>
+ #include <gnutls/openpgp.h>
+ #include <stdio.h>
+@@ -146,7 +148,11 @@ static const struct intmap {
+ { NULL, 0}
+ }, all_comps[]={
+ { "DEFLATE", GNUTLS_COMP_DEFLATE},
++#ifndef HAVE_GNUTLS3
+ { "LZO", GNUTLS_COMP_LZO},
++#else
++ { "ZLIB", GNUTLS_COMP_ZLIB},
++#endif
+ { "NULL", GNUTLS_COMP_NULL},
+ { NULL, 0}
+ }, all_certs[]={
+@@ -408,6 +414,7 @@ ssl_context tls_create(int isserver, const struct tls_info *info)
+ return (NULL);
+ }
+
++#ifndef HAVE_GNUTLS3
+ if (gnutls_global_init_extra() < 0)
+ {
+ gnutls_global_deinit();
+@@ -416,6 +423,7 @@ ssl_context tls_create(int isserver, const struct tls_info *info)
+ errno=EINVAL;
+ return (NULL);
+ }
++#endif
+ }
+
+ if (!(words=splitwords(safe_getenv(p, "TLS_PROTOCOL",