1 |
commit: 46aa079fc5c778a517af846385b728a26e4dd99d |
2 |
Author: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Sep 27 21:19:00 2018 +0000 |
4 |
Commit: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Sep 27 21:20:40 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=46aa079f |
7 |
|
8 |
dev-libs/beecrypt: tweak for icu-61, bug #666542 |
9 |
|
10 |
On icu-61 built failures look like: |
11 |
include/beecrypt/c++/lang/String.h:76:17: |
12 |
error: ‘UnicodeString’ does not name a type |
13 |
|
14 |
ICU-61 moved all names into icu:: space. |
15 |
|
16 |
The fix is to add 'using icu::<symbol>'. |
17 |
|
18 |
Reported-by: Juergen Rose |
19 |
Closes: https://bugs.gentoo.org/666542 |
20 |
Package-Manager: Portage-2.3.50, Repoman-2.3.11 |
21 |
|
22 |
dev-libs/beecrypt/beecrypt-4.2.1-r5.ebuild | 98 ++++++++++++++++++++++ |
23 |
.../beecrypt/files/beecrypt-4.2.1-icu-61.patch | 51 +++++++++++ |
24 |
2 files changed, 149 insertions(+) |
25 |
|
26 |
diff --git a/dev-libs/beecrypt/beecrypt-4.2.1-r5.ebuild b/dev-libs/beecrypt/beecrypt-4.2.1-r5.ebuild |
27 |
new file mode 100644 |
28 |
index 00000000000..564e81f5799 |
29 |
--- /dev/null |
30 |
+++ b/dev-libs/beecrypt/beecrypt-4.2.1-r5.ebuild |
31 |
@@ -0,0 +1,98 @@ |
32 |
+# Copyright 1999-2018 Gentoo Authors |
33 |
+# Distributed under the terms of the GNU General Public License v2 |
34 |
+ |
35 |
+EAPI=6 |
36 |
+ |
37 |
+PYTHON_COMPAT=( python2_7 ) |
38 |
+ |
39 |
+inherit autotools flag-o-matic java-pkg-opt-2 python-single-r1 |
40 |
+ |
41 |
+DESCRIPTION="General-purpose cryptography library" |
42 |
+HOMEPAGE="https://sourceforge.net/projects/beecrypt/" |
43 |
+SRC_URI="mirror://sourceforge/beecrypt/${P}.tar.gz" |
44 |
+ |
45 |
+LICENSE="GPL-2 LGPL-2" |
46 |
+SLOT="0" |
47 |
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos" |
48 |
+IUSE="+threads java cxx python static-libs doc" |
49 |
+REQUIRED_USE="cxx? ( threads ) |
50 |
+ python? ( ${PYTHON_REQUIRED_USE} )" |
51 |
+ |
52 |
+COMMON_DEPEND="!<app-arch/rpm-4.2.1 |
53 |
+ cxx? ( >=dev-libs/icu-6.1:= ) |
54 |
+ python? ( ${PYTHON_DEPS} )" |
55 |
+ |
56 |
+DEPEND="${COMMON_DEPEND} |
57 |
+ java? ( >=virtual/jdk-1.4 ) |
58 |
+ doc? ( app-doc/doxygen |
59 |
+ virtual/latex-base |
60 |
+ dev-texlive/texlive-fontsextra |
61 |
+ )" |
62 |
+RDEPEND="${COMMON_DEPEND} |
63 |
+ java? ( >=virtual/jre-1.4 )" |
64 |
+ |
65 |
+DOCS=( BUGS README BENCHMARKS NEWS ) |
66 |
+PATCHES=( |
67 |
+ "${FILESDIR}"/${P}-build-system.patch |
68 |
+ "${FILESDIR}"/${P}-gcc-4.7.patch |
69 |
+ |
70 |
+ # Fixes bug 596904 |
71 |
+ "${FILESDIR}"/${P}-c++11-allow-throw-in-destructors.patch |
72 |
+ "${FILESDIR}"/${P}-cast-uchar.patch #618676 |
73 |
+ |
74 |
+ "${FILESDIR}"/${P}-icu-61.patch |
75 |
+) |
76 |
+ |
77 |
+pkg_setup() { |
78 |
+ use python && python-single-r1_pkg_setup |
79 |
+ java-pkg-opt-2_pkg_setup |
80 |
+} |
81 |
+ |
82 |
+src_prepare() { |
83 |
+ default |
84 |
+ eautoreconf |
85 |
+} |
86 |
+ |
87 |
+src_configure() { |
88 |
+ # ICU needs char16_t support now |
89 |
+ # bug 649548 |
90 |
+ append-cxxflags -std=c++14 |
91 |
+ |
92 |
+ # cplusplus needs threads support |
93 |
+ ac_cv_java_include=$(use java && java-pkg_get-jni-cflags) \ |
94 |
+ econf \ |
95 |
+ --disable-expert-mode \ |
96 |
+ $(use_enable static-libs static) \ |
97 |
+ $(use_enable threads) \ |
98 |
+ $(use_with python python "${PYTHON}") \ |
99 |
+ $(use_with cxx cplusplus) \ |
100 |
+ $(use_with java) |
101 |
+} |
102 |
+ |
103 |
+src_compile() { |
104 |
+ default |
105 |
+ |
106 |
+ if use doc; then |
107 |
+ pushd include/beecrypt >/dev/null || die |
108 |
+ doxygen || die "doxygen failed" |
109 |
+ popd >/dev/null || die |
110 |
+ HTML_DOCS=( docs/html/*.{css,html,js,png} ) |
111 |
+ fi |
112 |
+} |
113 |
+ |
114 |
+src_test() { |
115 |
+ export BEECRYPT_CONF_FILE="${T}/beecrypt-test.conf" |
116 |
+ echo "provider.1=${S}/c++/provider/.libs/base.so" > "${BEECRYPT_CONF_FILE}" || die |
117 |
+ emake check bench |
118 |
+} |
119 |
+ |
120 |
+src_install() { |
121 |
+ default |
122 |
+ |
123 |
+ if use python; then |
124 |
+ rm -f "${D%/}$(python_get_sitedir)"/_bc.*a || die |
125 |
+ fi |
126 |
+ if ! use static-libs; then |
127 |
+ find "${D}" -name '*.la' -delete || die |
128 |
+ fi |
129 |
+} |
130 |
|
131 |
diff --git a/dev-libs/beecrypt/files/beecrypt-4.2.1-icu-61.patch b/dev-libs/beecrypt/files/beecrypt-4.2.1-icu-61.patch |
132 |
new file mode 100644 |
133 |
index 00000000000..68845f612d9 |
134 |
--- /dev/null |
135 |
+++ b/dev-libs/beecrypt/files/beecrypt-4.2.1-icu-61.patch |
136 |
@@ -0,0 +1,51 @@ |
137 |
+On icu-61 built failures look like: |
138 |
+ include/beecrypt/c++/lang/String.h:76:17: |
139 |
+ error: ‘UnicodeString’ does not name a type |
140 |
+ |
141 |
+ICU-61 moved all names into icu:: space. |
142 |
+ |
143 |
+The fix is to add 'using icu::<symbol>'. |
144 |
+ |
145 |
+Reported-by: Juergen Rose |
146 |
+Bug: https://bugs.gentoo.org/666542 |
147 |
+--- a/c++/beeyond/DHIESParameterSpec.cxx |
148 |
++++ b/c++/beeyond/DHIESParameterSpec.cxx |
149 |
+@@ -36,2 +36,4 @@ using std::auto_ptr; |
150 |
+ #include <unicode/numfmt.h> |
151 |
++using icu::RegexPattern; |
152 |
++using icu::RegexMatcher; |
153 |
+ |
154 |
+--- a/c++/crypto/Cipher.cxx |
155 |
++++ b/c++/crypto/Cipher.cxx |
156 |
+@@ -30,2 +30,4 @@ using beecrypt::security::Security; |
157 |
+ #include <unicode/ustream.h> |
158 |
++using icu::RegexMatcher; |
159 |
++using icu::RegexPattern; |
160 |
+ |
161 |
+--- a/c++/lang/Integer.cxx |
162 |
++++ b/c++/lang/Integer.cxx |
163 |
+@@ -29,2 +29,5 @@ using beecrypt::lang::String; |
164 |
+ #include <unicode/numfmt.h> |
165 |
++using icu::Formattable; |
166 |
++using icu::NumberFormat; |
167 |
++ |
168 |
+ |
169 |
+--- a/c++/lang/Long.cxx |
170 |
++++ b/c++/lang/Long.cxx |
171 |
+@@ -29,2 +29,4 @@ using beecrypt::lang::String; |
172 |
+ #include <unicode/numfmt.h> |
173 |
++using icu::Formattable; |
174 |
++using icu::NumberFormat; |
175 |
+ |
176 |
+--- a/c++/util/Date.cxx |
177 |
++++ b/c++/util/Date.cxx |
178 |
+@@ -28,2 +28,3 @@ |
179 |
+ #include <unicode/datefmt.h> |
180 |
++using icu::DateFormat; |
181 |
+ |
182 |
+--- a/include/beecrypt/c++/lang/String.h |
183 |
++++ b/include/beecrypt/c++/lang/String.h |
184 |
+@@ -41,2 +41,3 @@ using beecrypt::bytearray; |
185 |
+ #include <unicode/unistr.h> |
186 |
++using icu::UnicodeString; |
187 |
+ |