1 |
commit: f264ea1ce94e55b2ab539d339c01f62a45133e9c |
2 |
Author: orbea <orbea <AT> riseup <DOT> net> |
3 |
AuthorDate: Sat Jul 2 23:42:00 2022 +0000 |
4 |
Commit: Quentin Retornaz <gentoo <AT> retornaz <DOT> com> |
5 |
CommitDate: Sun Jul 3 17:46:59 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/proj/libressl.git/commit/?id=f264ea1c |
7 |
|
8 |
dev-db/mysqp-connector-c: Remove package |
9 |
|
10 |
Works with libressl-3.5.x and mysql-connector-c-8.0.27::gentoo. |
11 |
|
12 |
Signed-off-by: orbea <orbea <AT> riseup.net> |
13 |
Signed-off-by: Quentin Retornaz <gentoo <AT> retornaz.com> |
14 |
|
15 |
dev-db/mysql-connector-c/Manifest | 1 - |
16 |
...-8.0.18-always-build-decompress-utilities.patch | 34 -- |
17 |
...onnector-c-8.0.19-do-not-install-comp_err.patch | 12 - |
18 |
.../files/mysql-connector-c-8.0.21-libressl.patch | 356 --------------------- |
19 |
...-c-8.0.21-survive-malformed-charset-files.patch | 18 -- |
20 |
...-8.0.22-always-build-decompress-utilities.patch | 22 -- |
21 |
dev-db/mysql-connector-c/metadata.xml | 8 - |
22 |
.../mysql-connector-c-8.0.22.ebuild | 111 ------- |
23 |
8 files changed, 562 deletions(-) |
24 |
|
25 |
diff --git a/dev-db/mysql-connector-c/Manifest b/dev-db/mysql-connector-c/Manifest |
26 |
deleted file mode 100644 |
27 |
index 02cd082..0000000 |
28 |
--- a/dev-db/mysql-connector-c/Manifest |
29 |
+++ /dev/null |
30 |
@@ -1 +0,0 @@ |
31 |
-DIST mysql-boost-8.0.22.tar.gz 285934450 BLAKE2B 1ba0c9bb9a0cb74af4842d3b746f8b690c122cfbf2c6d5201ce95e59a257427a8683dd8d5c2be31dfe9ece4761366c1287fa7b841c45db222725bf76b0639bc6 SHA512 792f2ada93ec67a4679228478c6b798e81d9e9f6d13c7f4977cb7682738a4aae3cb483294edc6b2fde16c3960e51af8786216c063ab500840afd39a609e4b612 |
32 |
|
33 |
diff --git a/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.18-always-build-decompress-utilities.patch b/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.18-always-build-decompress-utilities.patch |
34 |
deleted file mode 100644 |
35 |
index af0b31e..0000000 |
36 |
--- a/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.18-always-build-decompress-utilities.patch |
37 |
+++ /dev/null |
38 |
@@ -1,34 +0,0 @@ |
39 |
---- a/utilities/CMakeLists.txt |
40 |
-+++ b/utilities/CMakeLists.txt |
41 |
-@@ -110,21 +110,16 @@ MYSQL_ADD_EXECUTABLE(perror |
42 |
- DEPENDENCIES GenError |
43 |
- LINK_LIBRARIES mysys |
44 |
- ) |
45 |
--IF(BUILD_BUNDLED_LZ4) |
46 |
-- MYSQL_ADD_EXECUTABLE(lz4_decompress |
47 |
-- lz4_decompress.cc |
48 |
-- COMPONENT Server |
49 |
-- LINK_LIBRARIES ${LZ4_LIBRARY} mysys |
50 |
-- ) |
51 |
--ENDIF() |
52 |
-- |
53 |
--IF(BUILD_BUNDLED_ZLIB OR NOT OPENSSL_EXECUTABLE_HAS_ZLIB) |
54 |
-- MYSQL_ADD_EXECUTABLE(zlib_decompress |
55 |
-- zlib_decompress.cc |
56 |
-- COMPONENT Server |
57 |
-- LINK_LIBRARIES ${ZLIB_LIBRARY} mysys |
58 |
-- ) |
59 |
--ENDIF() |
60 |
-+MYSQL_ADD_EXECUTABLE(lz4_decompress |
61 |
-+ lz4_decompress.cc |
62 |
-+ COMPONENT Server |
63 |
-+ LINK_LIBRARIES ${LZ4_LIBRARY} mysys |
64 |
-+ ) |
65 |
-+MYSQL_ADD_EXECUTABLE(zlib_decompress |
66 |
-+ zlib_decompress.cc |
67 |
-+ COMPONENT Server |
68 |
-+ LINK_LIBRARIES ${ZLIB_LIBRARY} mysys |
69 |
-+ ) |
70 |
- |
71 |
- # All targets below belong to COMPONENT Server and depend on InnoDB. |
72 |
- IF(WITHOUT_SERVER) |
73 |
|
74 |
diff --git a/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.19-do-not-install-comp_err.patch b/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.19-do-not-install-comp_err.patch |
75 |
deleted file mode 100644 |
76 |
index 94329ee..0000000 |
77 |
--- a/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.19-do-not-install-comp_err.patch |
78 |
+++ /dev/null |
79 |
@@ -1,12 +0,0 @@ |
80 |
-diff --git a/utilities/CMakeLists.txt b/utilities/CMakeLists.txt |
81 |
-index c855f8ab..0ebef451 100644 |
82 |
---- a/utilities/CMakeLists.txt |
83 |
-+++ b/utilities/CMakeLists.txt |
84 |
-@@ -27,6 +27,7 @@ IF(NOT CMAKE_CROSSCOMPILING) |
85 |
- comp_err.cc |
86 |
- COMPONENT Server |
87 |
- LINK_LIBRARIES mysys |
88 |
-+ SKIP_INSTALL |
89 |
- ) |
90 |
- ENDIF() |
91 |
- |
92 |
|
93 |
diff --git a/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.21-libressl.patch b/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.21-libressl.patch |
94 |
deleted file mode 100644 |
95 |
index 78f3e78..0000000 |
96 |
--- a/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.21-libressl.patch |
97 |
+++ /dev/null |
98 |
@@ -1,356 +0,0 @@ |
99 |
-From 4aadff7b08f6a69160a44c1742d5a12fb5abc059 Mon Sep 17 00:00:00 2001 |
100 |
-From: Thomas Deutschmann <whissi@g.o> |
101 |
-Date: Thu, 30 Apr 2020 20:01:48 +0200 |
102 |
-Subject: [PATCH 5/5] Add LibreSSL support |
103 |
- |
104 |
-Signed-off-by: Thomas Deutschmann <whissi@g.o> |
105 |
---- |
106 |
- cmake/ssl.cmake | 5 +++-- |
107 |
- mysys/my_md5.cc | 2 ++ |
108 |
- .../bindings/xcom/xcom/xcom_ssl_transport.cc | 6 +++++- |
109 |
- plugin/x/client/xconnection_impl.cc | 4 ++++ |
110 |
- router/src/http/src/tls_client_context.cc | 2 +- |
111 |
- router/src/http/src/tls_context.cc | 9 ++++++-- |
112 |
- router/src/http/src/tls_server_context.cc | 3 ++- |
113 |
- sql-common/client.cc | 2 ++ |
114 |
- sql/mysqld.cc | 4 +++- |
115 |
- sql/sys_vars.cc | 21 +++++++++++++++++-- |
116 |
- vio/viossl.cc | 8 +++---- |
117 |
- vio/viosslfactories.cc | 2 ++ |
118 |
- 12 files changed, 54 insertions(+), 14 deletions(-) |
119 |
- |
120 |
-diff --git a/cmake/ssl.cmake b/cmake/ssl.cmake |
121 |
-index 52feadeaa..3b8332695 100644 |
122 |
---- a/cmake/ssl.cmake |
123 |
-+++ b/cmake/ssl.cmake |
124 |
-@@ -222,13 +222,14 @@ MACRO (MYSQL_CHECK_SSL) |
125 |
- OPENSSL_FIX_VERSION "${OPENSSL_VERSION_NUMBER}" |
126 |
- ) |
127 |
- ENDIF() |
128 |
-- IF("${OPENSSL_MAJOR_VERSION}.${OPENSSL_MINOR_VERSION}.${OPENSSL_FIX_VERSION}" VERSION_GREATER "1.1.0") |
129 |
-+ CHECK_SYMBOL_EXISTS(TLS1_3_VERSION "openssl/tls1.h" HAVE_TLS1_3_VERSION) |
130 |
-+ IF(HAVE_TLS1_3_VERSION) |
131 |
- ADD_DEFINITIONS(-DHAVE_TLSv13) |
132 |
- ENDIF() |
133 |
- IF(OPENSSL_INCLUDE_DIR AND |
134 |
- OPENSSL_LIBRARY AND |
135 |
- CRYPTO_LIBRARY AND |
136 |
-- OPENSSL_MAJOR_VERSION STREQUAL "1" |
137 |
-+ OPENSSL_MAJOR_VERSION VERSION_GREATER_EQUAL "1" |
138 |
- ) |
139 |
- SET(OPENSSL_FOUND TRUE) |
140 |
- FIND_PROGRAM(OPENSSL_EXECUTABLE openssl |
141 |
-diff --git a/mysys/my_md5.cc b/mysys/my_md5.cc |
142 |
-index dea997b25..531696329 100644 |
143 |
---- a/mysys/my_md5.cc |
144 |
-+++ b/mysys/my_md5.cc |
145 |
-@@ -56,7 +56,9 @@ static void my_md5_hash(unsigned char *digest, unsigned const char *buf, |
146 |
- int compute_md5_hash(char *digest, const char *buf, int len) { |
147 |
- int retval = 0; |
148 |
- int fips_mode = 0; |
149 |
-+#ifndef LIBRESSL_VERSION_NUMBER |
150 |
- fips_mode = FIPS_mode(); |
151 |
-+#endif |
152 |
- /* If fips mode is ON/STRICT restricted method calls will result into abort, |
153 |
- * skipping call. */ |
154 |
- if (fips_mode == 0) { |
155 |
-diff --git a/plugin/group_replication/libmysqlgcs/src/bindings/xcom/xcom/xcom_ssl_transport.cc b/plugin/group_replication/libmysqlgcs/src/bindings/xcom/xcom/xcom_ssl_transport.cc |
156 |
-index 8bf63ce14..02f91b44e 100644 |
157 |
---- a/plugin/group_replication/libmysqlgcs/src/bindings/xcom/xcom/xcom_ssl_transport.cc |
158 |
-+++ b/plugin/group_replication/libmysqlgcs/src/bindings/xcom/xcom/xcom_ssl_transport.cc |
159 |
-@@ -325,6 +325,7 @@ error: |
160 |
- return 1; |
161 |
- } |
162 |
- |
163 |
-+#ifndef LIBRESSL_VERSION_NUMBER |
164 |
- #define OPENSSL_ERROR_LENGTH 512 |
165 |
- static int configure_ssl_fips_mode(const uint fips_mode) { |
166 |
- int rc = -1; |
167 |
-@@ -348,6 +349,7 @@ static int configure_ssl_fips_mode(const uint fips_mode) { |
168 |
- EXIT: |
169 |
- return rc; |
170 |
- } |
171 |
-+#endif |
172 |
- |
173 |
- static int configure_ssl_ca(SSL_CTX *ssl_ctx, const char *ca_file, |
174 |
- const char *ca_path) { |
175 |
-@@ -544,10 +546,12 @@ int xcom_init_ssl(const char *server_key_file, const char *server_cert_file, |
176 |
- int verify_server = SSL_VERIFY_NONE; |
177 |
- int verify_client = SSL_VERIFY_NONE; |
178 |
- |
179 |
-+#ifndef LIBRESSL_VERSION_NUMBER |
180 |
- if (configure_ssl_fips_mode(ssl_fips_mode) != 1) { |
181 |
- G_ERROR("Error setting the ssl fips mode"); |
182 |
- goto error; |
183 |
- } |
184 |
-+#endif |
185 |
- |
186 |
- SSL_library_init(); |
187 |
- SSL_load_error_strings(); |
188 |
-@@ -611,7 +615,7 @@ error: |
189 |
- void xcom_cleanup_ssl() { |
190 |
- if (!xcom_use_ssl()) return; |
191 |
- |
192 |
--#if OPENSSL_VERSION_NUMBER < 0x10100000L |
193 |
-+#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER) |
194 |
- ERR_remove_thread_state(0); |
195 |
- #endif /* OPENSSL_VERSION_NUMBER < 0x10100000L */ |
196 |
- } |
197 |
-diff --git a/plugin/x/client/xconnection_impl.cc b/plugin/x/client/xconnection_impl.cc |
198 |
-index 13bc6794e..5223169db 100644 |
199 |
---- a/plugin/x/client/xconnection_impl.cc |
200 |
-+++ b/plugin/x/client/xconnection_impl.cc |
201 |
-@@ -498,6 +498,7 @@ XError Connection_impl::get_ssl_error(const int error_id) { |
202 |
- return XError(CR_SSL_CONNECTION_ERROR, buffer); |
203 |
- } |
204 |
- |
205 |
-+#ifndef LIBRESSL_VERSION_NUMBER |
206 |
- /** |
207 |
- Set fips mode in openssl library, |
208 |
- When we set fips mode ON/STRICT, it will perform following operations: |
209 |
-@@ -537,6 +538,7 @@ int set_fips_mode(const uint32_t fips_mode, |
210 |
- EXIT: |
211 |
- return rc; |
212 |
- } |
213 |
-+#endif |
214 |
- |
215 |
- XError Connection_impl::activate_tls() { |
216 |
- if (nullptr == m_vio) return get_socket_error(SOCKET_ECONNRESET); |
217 |
-@@ -547,12 +549,14 @@ XError Connection_impl::activate_tls() { |
218 |
- if (!m_context->m_ssl_config.is_configured()) |
219 |
- return XError{CR_SSL_CONNECTION_ERROR, ER_TEXT_TLS_NOT_CONFIGURATED, true}; |
220 |
- |
221 |
-+#ifndef LIBRESSL_VERSION_NUMBER |
222 |
- char err_string[OPENSSL_ERROR_LENGTH] = {'\0'}; |
223 |
- if (set_fips_mode( |
224 |
- static_cast<uint32_t>(m_context->m_ssl_config.m_ssl_fips_mode), |
225 |
- err_string) != 1) { |
226 |
- return XError{CR_SSL_CONNECTION_ERROR, err_string, true}; |
227 |
- } |
228 |
-+#endif |
229 |
- auto ssl_ctx_flags = process_tls_version( |
230 |
- details::null_when_empty(m_context->m_ssl_config.m_tls_version)); |
231 |
- |
232 |
-diff --git a/router/src/http/src/tls_client_context.cc b/router/src/http/src/tls_client_context.cc |
233 |
-index 297ceee30..7c1157289 100644 |
234 |
---- a/router/src/http/src/tls_client_context.cc |
235 |
-+++ b/router/src/http/src/tls_client_context.cc |
236 |
-@@ -54,7 +54,7 @@ void TlsClientContext::verify(TlsVerify verify) { |
237 |
- |
238 |
- void TlsClientContext::cipher_suites(const std::string &ciphers) { |
239 |
- // TLSv1.3 ciphers are controlled via SSL_CTX_set_ciphersuites() |
240 |
--#if OPENSSL_VERSION_NUMBER >= ROUTER_OPENSSL_VERSION(1, 1, 1) |
241 |
-+#ifdef TLS1_3_VERSION |
242 |
- if (1 != SSL_CTX_set_ciphersuites(ssl_ctx_.get(), ciphers.c_str())) { |
243 |
- throw TlsError("set-cipher-suites"); |
244 |
- } |
245 |
-diff --git a/router/src/http/src/tls_context.cc b/router/src/http/src/tls_context.cc |
246 |
-index 60ed7e6ca..388ef8f28 100644 |
247 |
---- a/router/src/http/src/tls_context.cc |
248 |
-+++ b/router/src/http/src/tls_context.cc |
249 |
-@@ -91,7 +91,7 @@ static int o11x_version(TlsVersion version) { |
250 |
- return TLS1_1_VERSION; |
251 |
- case TlsVersion::TLS_1_2: |
252 |
- return TLS1_2_VERSION; |
253 |
--#if OPENSSL_VERSION_NUMBER >= ROUTER_OPENSSL_VERSION(1, 1, 1) |
254 |
-+#ifdef TLS1_3_VERSION |
255 |
- case TlsVersion::TLS_1_3: |
256 |
- return TLS1_3_VERSION; |
257 |
- #endif |
258 |
-@@ -120,9 +120,11 @@ void TlsContext::version_range(TlsVersion min_version, TlsVersion max_version) { |
259 |
- switch (min_version) { |
260 |
- default: |
261 |
- // unknown, leave all disabled |
262 |
-+#ifdef TLS1_3_VERSION |
263 |
- // fallthrough |
264 |
- case TlsVersion::TLS_1_3: |
265 |
- opts |= SSL_OP_NO_TLSv1_2; |
266 |
-+#endif |
267 |
- // fallthrough |
268 |
- case TlsVersion::TLS_1_2: |
269 |
- opts |= SSL_OP_NO_TLSv1_1; |
270 |
-@@ -170,8 +172,10 @@ TlsVersion TlsContext::min_version() const { |
271 |
- return TlsVersion::TLS_1_1; |
272 |
- case TLS1_2_VERSION: |
273 |
- return TlsVersion::TLS_1_2; |
274 |
-+#ifdef TLS1_3_VERSION |
275 |
- case TLS1_3_VERSION: |
276 |
- return TlsVersion::TLS_1_3; |
277 |
-+#endif |
278 |
- case 0: |
279 |
- return TlsVersion::AUTO; |
280 |
- default: |
281 |
-@@ -230,7 +234,8 @@ TlsContext::InfoCallback TlsContext::info_callback() const { |
282 |
- } |
283 |
- |
284 |
- int TlsContext::security_level() const { |
285 |
--#if OPENSSL_VERSION_NUMBER >= ROUTER_OPENSSL_VERSION(1, 1, 0) |
286 |
-+#if OPENSSL_VERSION_NUMBER >= ROUTER_OPENSSL_VERSION(1, 1, 0) && \ |
287 |
-+ !defined(LIBRESSL_VERSION_NUMBER) |
288 |
- return SSL_CTX_get_security_level(ssl_ctx_.get()); |
289 |
- #else |
290 |
- return 0; |
291 |
-diff --git a/router/src/http/src/tls_server_context.cc b/router/src/http/src/tls_server_context.cc |
292 |
-index 0f4472419..707d7de86 100644 |
293 |
---- a/router/src/http/src/tls_server_context.cc |
294 |
-+++ b/router/src/http/src/tls_server_context.cc |
295 |
-@@ -167,7 +167,8 @@ void TlsServerContext::init_tmp_dh(const std::string &dh_params) { |
296 |
- } |
297 |
- |
298 |
- } else { |
299 |
--#if OPENSSL_VERSION_NUMBER >= ROUTER_OPENSSL_VERSION(1, 1, 0) |
300 |
-+#if OPENSSL_VERSION_NUMBER >= ROUTER_OPENSSL_VERSION(1, 1, 0) && \ |
301 |
-+ !defined(LIBRESSL_VERSION_NUMBER) |
302 |
- dh2048.reset(DH_get_2048_256()); |
303 |
- #else |
304 |
- /* |
305 |
-diff --git a/sql-common/client.cc b/sql-common/client.cc |
306 |
-index ffb136b5b..8a0c7b834 100644 |
307 |
---- a/sql-common/client.cc |
308 |
-+++ b/sql-common/client.cc |
309 |
-@@ -7766,6 +7766,7 @@ int STDCALL mysql_options(MYSQL *mysql, enum mysql_option option, |
310 |
- return 1; |
311 |
- break; |
312 |
- case MYSQL_OPT_SSL_FIPS_MODE: { |
313 |
-+#if !defined(LIBRESSL_VERSION_NUMBER) |
314 |
- char ssl_err_string[OPENSSL_ERROR_LENGTH] = {'\0'}; |
315 |
- ENSURE_EXTENSIONS_PRESENT(&mysql->options); |
316 |
- mysql->options.extension->ssl_fips_mode = *static_cast<const uint *>(arg); |
317 |
-@@ -7777,6 +7778,7 @@ int STDCALL mysql_options(MYSQL *mysql, enum mysql_option option, |
318 |
- "Set Fips mode ON/STRICT failed, detail: '%s'.", ssl_err_string); |
319 |
- return 1; |
320 |
- } |
321 |
-+#endif |
322 |
- } break; |
323 |
- case MYSQL_OPT_SSL_MODE: |
324 |
- ENSURE_EXTENSIONS_PRESENT(&mysql->options); |
325 |
-diff --git a/sql/mysqld.cc b/sql/mysqld.cc |
326 |
-index 682e8d5ae..96a922d7a 100644 |
327 |
---- a/sql/mysqld.cc |
328 |
-+++ b/sql/mysqld.cc |
329 |
-@@ -5109,7 +5109,7 @@ static int init_thread_environment() { |
330 |
- |
331 |
- static PSI_memory_key key_memory_openssl = PSI_NOT_INSTRUMENTED; |
332 |
- |
333 |
--#if OPENSSL_VERSION_NUMBER < 0x10100000L |
334 |
-+#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER) |
335 |
- #define FILE_LINE_ARGS |
336 |
- #else |
337 |
- #define FILE_LINE_ARGS , const char *, int |
338 |
-@@ -5143,12 +5143,14 @@ static void init_ssl() { |
339 |
- } |
340 |
- |
341 |
- static int init_ssl_communication() { |
342 |
-+#ifndef LIBRESSL_VERSION_NUMBER |
343 |
- char ssl_err_string[OPENSSL_ERROR_LENGTH] = {'\0'}; |
344 |
- int ret_fips_mode = set_fips_mode(opt_ssl_fips_mode, ssl_err_string); |
345 |
- if (ret_fips_mode != 1) { |
346 |
- LogErr(ERROR_LEVEL, ER_SSL_FIPS_MODE_ERROR, ssl_err_string); |
347 |
- return 1; |
348 |
- } |
349 |
-+#endif |
350 |
- if (TLS_channel::singleton_init(&mysql_main, mysql_main_channel, opt_use_ssl, |
351 |
- &server_main_callback, opt_initialize)) |
352 |
- return 1; |
353 |
-diff --git a/sql/sys_vars.cc b/sql/sys_vars.cc |
354 |
-index 5b1a82d2f..4e2dff865 100644 |
355 |
---- a/sql/sys_vars.cc |
356 |
-+++ b/sql/sys_vars.cc |
357 |
-@@ -4474,6 +4474,7 @@ static Sys_var_ulong Sys_max_execution_time( |
358 |
- HINT_UPDATEABLE SESSION_VAR(max_execution_time), CMD_LINE(REQUIRED_ARG), |
359 |
- VALID_RANGE(0, ULONG_MAX), DEFAULT(0), BLOCK_SIZE(1)); |
360 |
- |
361 |
-+#ifndef LIBRESSL_VERSION_NUMBER |
362 |
- static bool update_fips_mode(sys_var *, THD *, enum_var_type) { |
363 |
- char ssl_err_string[OPENSSL_ERROR_LENGTH] = {'\0'}; |
364 |
- if (set_fips_mode(opt_ssl_fips_mode, ssl_err_string) != 1) { |
365 |
-@@ -4484,15 +4485,31 @@ static bool update_fips_mode(sys_var *, THD *, enum_var_type) { |
366 |
- return false; |
367 |
- } |
368 |
- } |
369 |
-+#endif |
370 |
-+ |
371 |
-+#if defined(LIBRESSL_VERSION_NUMBER) |
372 |
-+static const char *ssl_fips_mode_names[] = {"OFF", 0}; |
373 |
-+#else |
374 |
-+static const char *ssl_fips_mode_names[] = {"OFF", "ON", "STRICT", 0}; |
375 |
-+#endif |
376 |
- |
377 |
--static const char *ssl_fips_mode_names[] = {"OFF", "ON", "STRICT", nullptr}; |
378 |
- static Sys_var_enum Sys_ssl_fips_mode( |
379 |
- "ssl_fips_mode", |
380 |
- "SSL FIPS mode (applies only for OpenSSL); " |
381 |
-+#ifndef LIBRESSL_VERSION_NUMBER |
382 |
- "permitted values are: OFF, ON, STRICT", |
383 |
-+#else |
384 |
-+ "permitted values are: OFF", |
385 |
-+#endif |
386 |
- GLOBAL_VAR(opt_ssl_fips_mode), CMD_LINE(REQUIRED_ARG, OPT_SSL_FIPS_MODE), |
387 |
- ssl_fips_mode_names, DEFAULT(0), NO_MUTEX_GUARD, NOT_IN_BINLOG, |
388 |
-- ON_CHECK(nullptr), ON_UPDATE(update_fips_mode), nullptr); |
389 |
-+ ON_CHECK(NULL), |
390 |
-+#ifndef LIBRESSL_VERSION_NUMBER |
391 |
-+ ON_UPDATE(update_fips_mode), |
392 |
-+#else |
393 |
-+ ON_UPDATE(NULL), |
394 |
-+#endif |
395 |
-+ NULL); |
396 |
- |
397 |
- static Sys_var_bool Sys_auto_generate_certs( |
398 |
- "auto_generate_certs", |
399 |
-diff --git a/vio/viossl.cc b/vio/viossl.cc |
400 |
-index 0e9594741..3a589c64b 100644 |
401 |
---- a/vio/viossl.cc |
402 |
-+++ b/vio/viossl.cc |
403 |
-@@ -45,7 +45,7 @@ |
404 |
- BIO_set_callback_ex was added in openSSL 1.1.1 |
405 |
- For older openSSL, use the deprecated BIO_set_callback. |
406 |
- */ |
407 |
--#if OPENSSL_VERSION_NUMBER >= 0x10101000L |
408 |
-+#if OPENSSL_VERSION_NUMBER >= 0x10101000L && !defined(LIBRESSL_VERSION_NUMBER) |
409 |
- #define HAVE_BIO_SET_CALLBACK_EX |
410 |
- #endif |
411 |
- |
412 |
-@@ -634,8 +634,8 @@ static int ssl_do(struct st_VioSSLFd *ptr, Vio *vio, long timeout, |
413 |
- |
414 |
- #if !defined(DBUG_OFF) |
415 |
- { |
416 |
-- STACK_OF(SSL_COMP) *ssl_comp_methods = nullptr; |
417 |
-- ssl_comp_methods = SSL_COMP_get_compression_methods(); |
418 |
-+ STACK_OF(SSL_COMP) *ssl_comp_methods = NULL; |
419 |
-+ ssl_comp_methods = (STACK_OF(SSL_COMP) *)SSL_COMP_get_compression_methods(); |
420 |
- n = sk_SSL_COMP_num(ssl_comp_methods); |
421 |
- DBUG_PRINT("info", ("Available compression methods:\n")); |
422 |
- if (n == 0) |
423 |
-@@ -643,7 +643,7 @@ static int ssl_do(struct st_VioSSLFd *ptr, Vio *vio, long timeout, |
424 |
- else |
425 |
- for (j = 0; j < n; j++) { |
426 |
- SSL_COMP *c = sk_SSL_COMP_value(ssl_comp_methods, j); |
427 |
--#if OPENSSL_VERSION_NUMBER < 0x10100000L |
428 |
-+#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER) |
429 |
- DBUG_PRINT("info", (" %d: %s\n", c->id, c->name)); |
430 |
- #else /* OPENSSL_VERSION_NUMBER < 0x10100000L */ |
431 |
- DBUG_PRINT("info", |
432 |
-diff --git a/vio/viosslfactories.cc b/vio/viosslfactories.cc |
433 |
-index 6c04029cc..f27221463 100644 |
434 |
---- a/vio/viosslfactories.cc |
435 |
-+++ b/vio/viosslfactories.cc |
436 |
-@@ -473,6 +473,7 @@ void ssl_start() { |
437 |
- } |
438 |
- } |
439 |
- |
440 |
-+#ifndef LIBRESSL_VERSION_NUMBER |
441 |
- /** |
442 |
- Set fips mode in openssl library, |
443 |
- When we set fips mode ON/STRICT, it will perform following operations: |
444 |
-@@ -526,6 +527,7 @@ EXIT: |
445 |
- @returns openssl current fips mode |
446 |
- */ |
447 |
- uint get_fips_mode() { return FIPS_mode(); } |
448 |
-+#endif |
449 |
- |
450 |
- long process_tls_version(const char *tls_version) { |
451 |
- const char *separator = ","; |
452 |
--- |
453 |
-2.27.0 |
454 |
- |
455 |
|
456 |
diff --git a/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.21-survive-malformed-charset-files.patch b/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.21-survive-malformed-charset-files.patch |
457 |
deleted file mode 100644 |
458 |
index 72799f0..0000000 |
459 |
--- a/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.21-survive-malformed-charset-files.patch |
460 |
+++ /dev/null |
461 |
@@ -1,18 +0,0 @@ |
462 |
-Description: don't crash on malformed charset files |
463 |
-Origin: https://bugs.launchpad.net/ubuntu/+source/mysql-8.0/+bug/1877504/comments/19 |
464 |
-Bug: https://bugs.launchpad.net/ubuntu/+source/mysql-8.0/+bug/1884809 |
465 |
-Bug: https://bugs.gentoo.org/737002 |
466 |
-Forwarded: workaround, not needed |
467 |
- |
468 |
---- a/mysys/charset.cc |
469 |
-+++ b/mysys/charset.cc |
470 |
-@@ -922,7 +922,7 @@ size_t escape_quotes_for_mysql(CHARSET_I |
471 |
- |
472 |
- void charset_uninit() { |
473 |
- for (CHARSET_INFO *cs : all_charsets) { |
474 |
-- if (cs && cs->coll->uninit) { |
475 |
-+ if (cs && cs->coll && cs->coll->uninit) { |
476 |
- cs->coll->uninit(cs); |
477 |
- } |
478 |
- } |
479 |
- |
480 |
|
481 |
diff --git a/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.22-always-build-decompress-utilities.patch b/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.22-always-build-decompress-utilities.patch |
482 |
deleted file mode 100644 |
483 |
index b0046fd..0000000 |
484 |
--- a/dev-db/mysql-connector-c/files/mysql-connector-c-8.0.22-always-build-decompress-utilities.patch |
485 |
+++ /dev/null |
486 |
@@ -1,22 +0,0 @@ |
487 |
---- a/utilities/CMakeLists.txt |
488 |
-+++ b/utilities/CMakeLists.txt |
489 |
-@@ -123,14 +123,11 @@ MYSQL_ADD_EXECUTABLE(perror |
490 |
- DEPENDENCIES GenError |
491 |
- LINK_LIBRARIES mysys |
492 |
- ) |
493 |
--IF(BUILD_BUNDLED_LZ4) |
494 |
-- MYSQL_ADD_EXECUTABLE(lz4_decompress |
495 |
-- lz4_decompress.cc |
496 |
-- COMPONENT Server |
497 |
-- LINK_LIBRARIES ${LZ4_LIBRARY} mysys |
498 |
-- ) |
499 |
--ENDIF() |
500 |
-- |
501 |
-+MYSQL_ADD_EXECUTABLE(lz4_decompress |
502 |
-+ lz4_decompress.cc |
503 |
-+ COMPONENT Server |
504 |
-+ LINK_LIBRARIES ${LZ4_LIBRARY} mysys |
505 |
-+ ) |
506 |
- MYSQL_ADD_EXECUTABLE(zlib_decompress |
507 |
- zlib_decompress.cc |
508 |
- COMPONENT Server |
509 |
|
510 |
diff --git a/dev-db/mysql-connector-c/metadata.xml b/dev-db/mysql-connector-c/metadata.xml |
511 |
deleted file mode 100644 |
512 |
index 709689b..0000000 |
513 |
--- a/dev-db/mysql-connector-c/metadata.xml |
514 |
+++ /dev/null |
515 |
@@ -1,8 +0,0 @@ |
516 |
-<?xml version="1.0" encoding="UTF-8"?> |
517 |
-<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> |
518 |
-<pkgmetadata> |
519 |
-<maintainer type="project"> |
520 |
- <email>mysql-bugs@g.o</email> |
521 |
- <name>MySQL</name> |
522 |
-</maintainer> |
523 |
-</pkgmetadata> |
524 |
|
525 |
diff --git a/dev-db/mysql-connector-c/mysql-connector-c-8.0.22.ebuild b/dev-db/mysql-connector-c/mysql-connector-c-8.0.22.ebuild |
526 |
deleted file mode 100644 |
527 |
index 22babc5..0000000 |
528 |
--- a/dev-db/mysql-connector-c/mysql-connector-c-8.0.22.ebuild |
529 |
+++ /dev/null |
530 |
@@ -1,111 +0,0 @@ |
531 |
-# Copyright 1999-2021 Gentoo Authors |
532 |
-# Distributed under the terms of the GNU General Public License v2 |
533 |
- |
534 |
-EAPI=7 |
535 |
- |
536 |
-inherit cmake-multilib |
537 |
- |
538 |
-# wrap the config script |
539 |
-MULTILIB_CHOST_TOOLS=( /usr/bin/mysql_config ) |
540 |
- |
541 |
-DESCRIPTION="C client library for MariaDB/MySQL" |
542 |
-HOMEPAGE="https://dev.mysql.com/downloads/" |
543 |
-LICENSE="GPL-2" |
544 |
- |
545 |
-SRC_URI="https://dev.mysql.com/get/Downloads/MySQL-8.0/mysql-boost-${PV}.tar.gz" |
546 |
-KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ppc ppc64 s390 sparc x86" |
547 |
- |
548 |
-SLOT="0/21" |
549 |
-IUSE="ldap static-libs" |
550 |
- |
551 |
-RDEPEND=" |
552 |
- >=app-arch/lz4-0_p131:=[${MULTILIB_USEDEP}] |
553 |
- app-arch/zstd:=[${MULTILIB_USEDEP}] |
554 |
- sys-libs/zlib:=[${MULTILIB_USEDEP}] |
555 |
- ldap? ( dev-libs/cyrus-sasl:=[${MULTILIB_USEDEP}] ) |
556 |
- dev-libs/openssl:0=[${MULTILIB_USEDEP}] |
557 |
- " |
558 |
-DEPEND="${RDEPEND}" |
559 |
- |
560 |
-# Avoid file collisions, #692580 |
561 |
-RDEPEND+=" !<dev-db/mysql-5.6.45-r1" |
562 |
-RDEPEND+=" !=dev-db/mysql-5.7.23*" |
563 |
-RDEPEND+=" !=dev-db/mysql-5.7.24*" |
564 |
-RDEPEND+=" !=dev-db/mysql-5.7.25*" |
565 |
-RDEPEND+=" !=dev-db/mysql-5.7.26-r0" |
566 |
-RDEPEND+=" !=dev-db/mysql-5.7.27-r0" |
567 |
-RDEPEND+=" !<dev-db/percona-server-5.7.26.29-r1" |
568 |
- |
569 |
-DOCS=( README ) |
570 |
- |
571 |
-S="${WORKDIR}/mysql-${PV}" |
572 |
- |
573 |
-PATCHES=( |
574 |
- "${FILESDIR}"/${PN}-8.0.22-always-build-decompress-utilities.patch |
575 |
- "${FILESDIR}"/${PN}-8.0.19-do-not-install-comp_err.patch |
576 |
- "${FILESDIR}"/${PN}-8.0.21-libressl.patch |
577 |
-) |
578 |
- |
579 |
-src_prepare() { |
580 |
- sed -i -e 's/CLIENT_LIBS/CONFIG_CLIENT_LIBS/' "${S}/scripts/CMakeLists.txt" || die |
581 |
- |
582 |
- # All these are for the server only. |
583 |
- # Disable rpm call which would trigger sandbox, #692368 |
584 |
- sed -i \ |
585 |
- -e '/MYSQL_CHECK_LIBEVENT/d' \ |
586 |
- -e '/MYSQL_CHECK_RAPIDJSON/d' \ |
587 |
- -e '/MYSQL_CHECK_ICU/d' \ |
588 |
- -e '/MYSQL_CHECK_EDITLINE/d' \ |
589 |
- -e '/MYSQL_CHECK_CURL/d' \ |
590 |
- -e '/ADD_SUBDIRECTORY(man)/d' \ |
591 |
- -e '/ADD_SUBDIRECTORY(share)/d' \ |
592 |
- -e '/INCLUDE(cmake\/boost/d' \ |
593 |
- -e 's/MY_RPM rpm/MY_RPM rpmNOTEXISTENT/' \ |
594 |
- CMakeLists.txt || die |
595 |
- |
596 |
- # Skip building clients |
597 |
- echo > client/CMakeLists.txt || die |
598 |
- |
599 |
- # Forcefully disable auth plugin |
600 |
- if ! use ldap ; then |
601 |
- sed -i -e '/MYSQL_CHECK_SASL/d' CMakeLists.txt || die |
602 |
- echo > libmysql/authentication_ldap/CMakeLists.txt || die |
603 |
- fi |
604 |
- |
605 |
- cmake-utils_src_prepare |
606 |
-} |
607 |
- |
608 |
-multilib_src_configure() { |
609 |
- local mycmakeargs=( |
610 |
- -DINSTALL_LAYOUT=RPM |
611 |
- -DINSTALL_LIBDIR=$(get_libdir) |
612 |
- -DWITH_DEFAULT_COMPILER_OPTIONS=OFF |
613 |
- -DENABLED_LOCAL_INFILE=ON |
614 |
- -DMYSQL_UNIX_ADDR="${EPREFIX}/run/mysqld/mysqld.sock" |
615 |
- -DWITH_LZ4=system |
616 |
- -DWITH_NUMA=OFF |
617 |
- -DWITH_SSL=system |
618 |
- -DWITH_ZLIB=system |
619 |
- -DWITH_ZSTD=system |
620 |
- -DLIBMYSQL_OS_OUTPUT_NAME=mysqlclient |
621 |
- -DSHARED_LIB_PATCH_VERSION="0" |
622 |
- -DCMAKE_POSITION_INDEPENDENT_CODE=ON |
623 |
- -DWITHOUT_SERVER=ON |
624 |
- ) |
625 |
- cmake-utils_src_configure |
626 |
-} |
627 |
- |
628 |
-multilib_src_install() { |
629 |
- cmake-utils_src_install |
630 |
-} |
631 |
- |
632 |
-multilib_src_install_all() { |
633 |
- doman \ |
634 |
- man/my_print_defaults.1 \ |
635 |
- man/perror.1 \ |
636 |
- man/zlib_decompress.1 |
637 |
- |
638 |
- if ! use static-libs ; then |
639 |
- find "${ED}" -name "*.a" -delete || die |
640 |
- fi |
641 |
-} |