Gentoo Archives: gentoo-commits

From: Aaron Bauman <bman@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-cpp/commoncpp2/, dev-cpp/commoncpp2/files/
Date: Fri, 22 Feb 2019 23:36:47
Message-Id: 1550878588.88ff70ab3b857a8e6aa63061028d8475b63816bc.bman@gentoo
1 commit: 88ff70ab3b857a8e6aa63061028d8475b63816bc
2 Author: Stefan Strogin <stefan.strogin <AT> gmail <DOT> com>
3 AuthorDate: Wed Feb 20 21:37:45 2019 +0000
4 Commit: Aaron Bauman <bman <AT> gentoo <DOT> org>
5 CommitDate: Fri Feb 22 23:36:28 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=88ff70ab
7
8 dev-cpp/commoncpp2: add patch for openssl-1.1 and libressl support
9
10 SSLv3_client_method() is deprecated in openssl-1.1 and libressl.
11 They suggest to use SSLv23_client_method.
12
13 Closes: https://bugs.gentoo.org/674416
14 Package-Manager: Portage-2.3.61, Repoman-2.3.12
15 Signed-off-by: Stefan Strogin <stefan.strogin <AT> gmail.com>
16 Closes: https://github.com/gentoo/gentoo/pull/11120
17 Signed-off-by: Aaron Bauman <bman <AT> gentoo.org>
18
19 dev-cpp/commoncpp2/commoncpp2-1.8.1-r4.ebuild | 73 +++++++++++++++++++++++++++
20 dev-cpp/commoncpp2/files/1.8.1-libressl.patch | 15 ++++++
21 2 files changed, 88 insertions(+)
22
23 diff --git a/dev-cpp/commoncpp2/commoncpp2-1.8.1-r4.ebuild b/dev-cpp/commoncpp2/commoncpp2-1.8.1-r4.ebuild
24 new file mode 100644
25 index 00000000000..f5f40d898c1
26 --- /dev/null
27 +++ b/dev-cpp/commoncpp2/commoncpp2-1.8.1-r4.ebuild
28 @@ -0,0 +1,73 @@
29 +# Copyright 1999-2019 Gentoo Authors
30 +# Distributed under the terms of the GNU General Public License v2
31 +
32 +EAPI=6
33 +
34 +inherit autotools eutils
35 +
36 +DESCRIPTION="C++ library offering portable support for system-related services"
37 +SRC_URI="mirror://gnu/commoncpp/${P}.tar.gz"
38 +HOMEPAGE="https://www.gnu.org/software/commoncpp/"
39 +LICENSE="GPL-2"
40 +SLOT="0"
41 +KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
42 +IUSE="debug doc examples ipv6 gnutls ssl static-libs"
43 +
44 +RDEPEND="
45 + sys-libs/zlib
46 + ssl? (
47 + gnutls? (
48 + dev-libs/libgcrypt:0=
49 + net-libs/gnutls:=
50 + )
51 + !gnutls? ( dev-libs/openssl:0= )
52 + )"
53 +DEPEND="${RDEPEND}
54 + doc? ( >=app-doc/doxygen-1.3.6 )"
55 +
56 +HTML_DOCS=()
57 +
58 +PATCHES=(
59 + "${FILESDIR}/1.8.1-configure_detect_netfilter.patch"
60 + "${FILESDIR}/1.8.0-glibc212.patch"
61 + "${FILESDIR}/1.8.1-autoconf-update.patch"
62 + "${FILESDIR}/1.8.1-fix-buffer-overflow.patch"
63 + "${FILESDIR}/1.8.1-parallel-build.patch"
64 + "${FILESDIR}/1.8.1-libgcrypt.patch"
65 + "${FILESDIR}/1.8.1-fix-c++14.patch"
66 + "${FILESDIR}/1.8.1-gnutls-3.4.patch"
67 + "${FILESDIR}/1.8.1-libressl.patch" # bug 674416
68 +)
69 +
70 +pkg_setup() {
71 + use doc && HTML_DOCS+=( doc/html/. )
72 +}
73 +
74 +src_prepare() {
75 + default
76 + eautoreconf
77 +}
78 +
79 +src_configure() {
80 + use ssl && local myconf=( $(usex gnutls '--with-gnutls' '--with-openssl') )
81 +
82 + econf \
83 + $(use_enable debug) \
84 + $(use_with ipv6) \
85 + $(use_enable static-libs static) \
86 + $(use_with doc doxygen) \
87 + "${myconf[@]}"
88 +}
89 +
90 +src_install () {
91 + default
92 + prune_libtool_files
93 +
94 + dodoc COPYING.addendum
95 +
96 + if use examples; then
97 + docinto examples
98 + dodoc demo/{*.cpp,*.h,*.xml,README}
99 + docompress -x /usr/share/doc/${PF}/examples
100 + fi
101 +}
102
103 diff --git a/dev-cpp/commoncpp2/files/1.8.1-libressl.patch b/dev-cpp/commoncpp2/files/1.8.1-libressl.patch
104 new file mode 100644
105 index 00000000000..9779a53d8fa
106 --- /dev/null
107 +++ b/dev-cpp/commoncpp2/files/1.8.1-libressl.patch
108 @@ -0,0 +1,15 @@
109 +Upstream-Status: Submitted [bug-commoncpp@×××.org]
110 +
111 +diff --git a/src/ssl.cpp b/src/ssl.cpp
112 +index 5bf526d..3cd7040 100644
113 +--- a/src/ssl.cpp
114 ++++ b/src/ssl.cpp
115 +@@ -386,7 +386,7 @@ bool SSLStream::getSession(void)
116 + if(so == INVALID_SOCKET)
117 + return false;
118 +
119 +- ctx = SSL_CTX_new(SSLv3_client_method());
120 ++ ctx = SSL_CTX_new(SSLv23_client_method());
121 + if(!ctx) {
122 + SSL_CTX_free(ctx);
123 + return false;