summaryrefslogtreecommitdiff
path: root/dev-libs/iksemel
diff options
context:
space:
mode:
Diffstat (limited to 'dev-libs/iksemel')
-rw-r--r--dev-libs/iksemel/Manifest6
-rw-r--r--dev-libs/iksemel/files/iksemel-1.3-gnutls-2.8.patch16
-rw-r--r--dev-libs/iksemel/files/iksemel-1.4-gnutls-3.4.patch38
-rw-r--r--dev-libs/iksemel/files/iksemel-1.4-ikstack.patch35
-rw-r--r--dev-libs/iksemel/iksemel-1.4-r1.ebuild44
-rw-r--r--dev-libs/iksemel/metadata.xml9
6 files changed, 148 insertions, 0 deletions
diff --git a/dev-libs/iksemel/Manifest b/dev-libs/iksemel/Manifest
new file mode 100644
index 000000000000..1a28f40f0f26
--- /dev/null
+++ b/dev-libs/iksemel/Manifest
@@ -0,0 +1,6 @@
+AUX iksemel-1.3-gnutls-2.8.patch 488 BLAKE2B 7834ca7b056b44534cc1c3301c9b58b66035c7d20e0f1e2c1f23ec6ec2d227ab4914c4c16c555e33fe9a5d39d6171864229071048d0ca9a93273b84e6c25c65e SHA512 6b2d4f71f5da6da8dcdd9f6a8921129d2f2bc71e6eb0c331d74784ced1bc3a0fb974ff1e0342f93d8ba3b4217b72ade15b1bc4015d2f2486aa86ca75549a1a42
+AUX iksemel-1.4-gnutls-3.4.patch 1656 BLAKE2B 83d8e5f2e5aa7fca4721e35be46ee08cbaf8f6ab66be86e1d01766c567fbf8762ed7e7d13d729afc2b44b460e0fddcc9474e61af3c81fd2696fbe1ed71f57c1f SHA512 305990e760218b1ce59e55aefb31126174f6a8066b9ef20ed3073332ad4e925871709e4c5b52d1e3fcde7b2fc9776dfd3f74a763e897cba4eb45657d3946d518
+AUX iksemel-1.4-ikstack.patch 955 BLAKE2B 62223a269c7079fe40a0b835c1a6d2a34d0dd9b3424ae45e0f14712d388547321e66cbce2763bb73065ed53df626a572e6a72d4550e85801e3390a5a61dde7ca SHA512 d97dc724c9b41983e91889e742d604ad9cf752536b012c13a5667c59baa1f5467dc02e7e390e4eba02475e5c994484428c26079351f8e9450b7de14e08eb0cbd
+DIST iksemel-1.4.tar.gz 515581 BLAKE2B a0e9b8dc6f9dadc04d17d2952034b56c4665c7a9c0549bfb52e3adfbc7fb6af17d1b0de978835081e0d39c8200e41d5528f6b3e1dbf51a4fae160f59d5c474fe SHA512 902e326647b63a5e58b1c396a401bdd136ad01ecabca81b543c0ed76ebd8d2110377015fec1be09551b92651ee093e480fa37aa2186f7791147f29e0933852cc
+EBUILD iksemel-1.4-r1.ebuild 893 BLAKE2B 13a4ca3121c7337093c9694009b0491072626c281194f571dac61bd44d2d29f9372a44df5933941f3131649d50682e0612554749f6caba08925d33a2f6c863fb SHA512 1eee495e88774df647b8604e52801b6a229de535fae9599d686d93f6512fec381c4f7766f9235476e16f346ac6d22c62d970372bbe7a5e0160e738cdea7e8a0c
+MISC metadata.xml 301 BLAKE2B e3de81d61c491692f64943d6478ab64332cccceac5947b522a6d6b62127217792205e16c2ea9d04de150772b3337a38793a79e950500b43e837f309651cbcd6f SHA512 91ac21f435ad0c2943e17058fec736cb0371690f38427302eb360a284b48017841b807cf5f6f13c6c837af9d1c330dc9a7980ff77a5699e2efe399b01ca840c0
diff --git a/dev-libs/iksemel/files/iksemel-1.3-gnutls-2.8.patch b/dev-libs/iksemel/files/iksemel-1.3-gnutls-2.8.patch
new file mode 100644
index 000000000000..48d19cf9ccfb
--- /dev/null
+++ b/dev-libs/iksemel/files/iksemel-1.3-gnutls-2.8.patch
@@ -0,0 +1,16 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -45,7 +45,12 @@
+ AC_CHECK_FUNCS(getopt_long)
+ AC_CHECK_FUNCS(getaddrinfo)
+
+-AM_PATH_LIBGNUTLS(,AC_DEFINE(HAVE_GNUTLS,,"Use libgnutls"))
++AC_ARG_WITH([gnutls],
++ [AS_HELP_STRING([--with-gnutls],
++ [Enable use of GnuTLS])])
++if test "$with_gnutls" != "no"; then
++ PKG_CHECK_MODULES(LIBGNUTLS, gnutls, AC_DEFINE(HAVE_GNUTLS,,"Use libgnutls"))
++fi
+
+ dnl Check -Wall flag of GCC
+ if test "x$GCC" = "xyes"; then
diff --git a/dev-libs/iksemel/files/iksemel-1.4-gnutls-3.4.patch b/dev-libs/iksemel/files/iksemel-1.4-gnutls-3.4.patch
new file mode 100644
index 000000000000..bf09e17a8ae7
--- /dev/null
+++ b/dev-libs/iksemel/files/iksemel-1.4-gnutls-3.4.patch
@@ -0,0 +1,38 @@
+Last-Update: 2015-10-28
+Bug-Upstream: https://github.com/meduketto/iksemel/issues/48
+Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=803204
+From: Marc Dequènes (duck) <duck@duckcorp.org>
+Description: fix security problem (and compatibility problem with servers rejecting low grade ciphers).
+
+--- a/src/stream.c
++++ b/src/stream.c
+@@ -62,13 +62,9 @@
+
+ static int
+ handshake (struct stream_data *data)
+ {
+- const int protocol_priority[] = { GNUTLS_TLS1, GNUTLS_SSL3, 0 };
+- const int kx_priority[] = { GNUTLS_KX_RSA, 0 };
+- const int cipher_priority[] = { GNUTLS_CIPHER_3DES_CBC, GNUTLS_CIPHER_ARCFOUR, 0};
+- const int comp_priority[] = { GNUTLS_COMP_ZLIB, GNUTLS_COMP_NULL, 0 };
+- const int mac_priority[] = { GNUTLS_MAC_SHA, GNUTLS_MAC_MD5, 0 };
++ const char *priority_string = "SECURE256:+SECURE192:-VERS-TLS-ALL:+VERS-TLS1.2";
+ int ret;
+
+ if (gnutls_global_init () != 0)
+ return IKS_NOMEM;
+@@ -79,13 +75,9 @@
+ if (gnutls_init (&data->sess, GNUTLS_CLIENT) != 0) {
+ gnutls_certificate_free_credentials (data->cred);
+ return IKS_NOMEM;
+ }
+- gnutls_protocol_set_priority (data->sess, protocol_priority);
+- gnutls_cipher_set_priority(data->sess, cipher_priority);
+- gnutls_compression_set_priority(data->sess, comp_priority);
+- gnutls_kx_set_priority(data->sess, kx_priority);
+- gnutls_mac_set_priority(data->sess, mac_priority);
++ gnutls_priority_set_direct(data->sess, priority_string, NULL);
+ gnutls_credentials_set (data->sess, GNUTLS_CRD_CERTIFICATE, data->cred);
+
+ gnutls_transport_set_push_function (data->sess, (gnutls_push_func) tls_push);
+ gnutls_transport_set_pull_function (data->sess, (gnutls_pull_func) tls_pull);
diff --git a/dev-libs/iksemel/files/iksemel-1.4-ikstack.patch b/dev-libs/iksemel/files/iksemel-1.4-ikstack.patch
new file mode 100644
index 000000000000..0dff76b409da
--- /dev/null
+++ b/dev-libs/iksemel/files/iksemel-1.4-ikstack.patch
@@ -0,0 +1,35 @@
+From 3095fe8c9686de79509fd49db5e8f39fe6c52f43 Mon Sep 17 00:00:00 2001
+From: Alon Bar-Lev <alon.barlev@gmail.com>
+Date: Wed, 22 Mar 2017 12:14:33 +0200
+Subject: [PATCH] fix alignment issue in ikstack
+
+tst-ikstack
+=================
+
+ikstack bug, addr 0x100357b4 should be a multiply of 8
+FAIL tst-ikstack (exit status: 1)
+
+Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
+---
+ src/ikstack.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/src/ikstack.c b/src/ikstack.c
+index bed4656..814a91c 100644
+--- a/src/ikstack.c
++++ b/src/ikstack.c
+@@ -88,9 +88,11 @@ iks_stack_alloc (ikstack *s, size_t size)
+ if (size < MIN_ALLOC_SIZE) size = MIN_ALLOC_SIZE;
+ if (size & ALIGN_MASK) size = ALIGN (size);
+
++ size += DEFAULT_ALIGNMENT; /* to enable alignment of space */
+ c = find_space (s, s->meta, size);
+ if (!c) return NULL;
+ mem = c->data + c->used;
++ mem = (void *)ALIGN((char *)mem - (char *)0);
+ c->used += size;
+ return mem;
+ }
+--
+2.10.2
+
diff --git a/dev-libs/iksemel/iksemel-1.4-r1.ebuild b/dev-libs/iksemel/iksemel-1.4-r1.ebuild
new file mode 100644
index 000000000000..9865b314e4a5
--- /dev/null
+++ b/dev-libs/iksemel/iksemel-1.4-r1.ebuild
@@ -0,0 +1,44 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit autotools
+
+DESCRIPTION="eXtensible Markup Language parser library designed for Jabber applications"
+HOMEPAGE="https://github.com/meduketto/iksemel"
+SRC_URI="https://${PN}.googlecode.com/files/${P}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="amd64 ppc ~ppc64 x86 ~x86-fbsd"
+IUSE="ssl static-libs"
+
+RDEPEND="ssl? ( net-libs/gnutls:= )"
+DEPEND="${RDEPEND}
+ ssl? ( virtual/pkgconfig )"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-1.3-gnutls-2.8.patch
+ "${FILESDIR}"/${PN}-1.4-gnutls-3.4.patch
+ "${FILESDIR}"/${PN}-1.4-ikstack.patch
+)
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+src_configure() {
+ econf \
+ $(use_with ssl gnutls) \
+ $(use_enable static-libs static)
+}
+
+src_install() {
+ default
+ dodoc HACKING
+
+ # package installs .pc files
+ find "${D}" -name '*.la' -delete || die
+}
diff --git a/dev-libs/iksemel/metadata.xml b/dev-libs/iksemel/metadata.xml
new file mode 100644
index 000000000000..0d3b06fcb7e5
--- /dev/null
+++ b/dev-libs/iksemel/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <!-- maintainer-needed -->
+ <upstream>
+ <remote-id type="google-code">iksemel</remote-id>
+ <remote-id type="github">meduketto/iksemel</remote-id>
+ </upstream>
+</pkgmetadata>