git: b5daf80a266a - main - databases/mysql80-*: Update to latest release 8.0.30

From: Jochen Neumeister <joneum_at_FreeBSD.org>
Date: Thu, 15 Sep 2022 14:35:26 UTC
The branch main has been updated by joneum:

URL: https://cgit.FreeBSD.org/ports/commit/?id=b5daf80a266a031ac1299ec2107f53dac3f2c722

commit b5daf80a266a031ac1299ec2107f53dac3f2c722
Author:     Jochen Neumeister <joneum@FreeBSD.org>
AuthorDate: 2022-09-15 14:24:48 +0000
Commit:     Jochen Neumeister <joneum@FreeBSD.org>
CommitDate: 2022-09-15 14:34:27 +0000

    databases/mysql80-*: Update to latest release 8.0.30
    
    PR:     265468
    
    Bugs Fixed:
    - InnoDB: A TRUNCATE TABLE operation failed to remove data dictionary entries for columns that were dropped using ALGORITHM=INSTANT.
    - InnoDB: An incorrect nullable column calculation on tables with instantly added columns caused data to be interpreted incorrectly
    - InnoDB: The read_2_bytes() function in the InnoDB sources, which reads bytes from the log buffer, returned a null pointer.
    - Replication: The COUNT_TRANSACTIONS_REMOTE_IN_APPLIER_QUEUE column in the Performance Schema table replication_group_member_stats could persistently show transactions related to view change events (View_change_log_event) that had already been applied. These events are queued in the Group Replication applier channel but applied in the Group Replication recovery channel, causing a race condition that could result in the counter decrement being lost. The increment of the count now takes place at a more suitable point, and the counter for COUNT_TRANSACTIONS_REMOTE_IN_APPLIER_QUEUE is also now set to zero when the applier is not busy.
    - Debug MySQL binaries can now be built using -0g and -fno-inline.
    
    See full Changelog here: https://dev.mysql.com/doc/relnotes/mysql/8.0/en/news-8-0-30.html
    
    Sponsored by:   Netzkommune GmbH
---
 databases/mysql80-client/pkg-plist                 | 170 -------------------
 databases/mysql80-server/Makefile                  |   3 +-
 databases/mysql80-server/distinfo                  |   6 +-
 .../mysql80-server/files/patch-CMakeLists.txt      |  48 +++---
 .../mysql80-server/files/patch-cmake_ssl.cmake     |  36 ++--
 .../files/patch-include_CMakeLists.txt             | 185 ---------------------
 .../mysql80-server/files/patch-include_violite.h   |  14 --
 .../mysql80-server/files/patch-mysys_my__md5.cc    |  12 --
 ...ork_xcom__network__provider__ssl_native__lib.cc |  20 ---
 .../patch-plugin_x_client_xconnection__impl.cc     |  33 ----
 ...-router_src_harness_src_tls__server__context.cc |  12 --
 .../files/patch-scripts_CMakeLists.txt             |  12 +-
 .../files/patch-sql-common_client.cc               |  18 --
 databases/mysql80-server/files/patch-sql_mysqld.cc |  19 +--
 .../mysql80-server/files/patch-sql_sys__vars.cc    |  49 +-----
 .../files/patch-vio_viosslfactories.cc             |  45 +----
 databases/mysql80-server/pkg-plist                 |   1 +
 17 files changed, 67 insertions(+), 616 deletions(-)

diff --git a/databases/mysql80-client/pkg-plist b/databases/mysql80-client/pkg-plist
index 8398d01b5847..217691d18f1e 100644
--- a/databases/mysql80-client/pkg-plist
+++ b/databases/mysql80-client/pkg-plist
@@ -14,189 +14,19 @@ bin/mysqlshow
 bin/mysqlslap
 bin/perror
 @comment bin/zlib_decompress
-include/mysql/add_with_saturate.h
-include/mysql/caching_sha2_passwordopt-longopts.h
-include/mysql/caching_sha2_passwordopt-vars.h
-include/mysql/compression.h
-include/mysql/keyring_operations_helper.h
-include/mysql/manifest.h
-include/mysql/mem_root_deque.h
-include/mysql/memory_debugging.h
-include/mysql/my_basename.h
-include/mysql/my_checksum.h
-include/mysql/my_getpwnam.h
-include/mysql/my_hostname.h
-include/mysql/my_rcu_lock.h
-include/mysql/mysql_async.h
-include/mysql/pfs_data_lock_provider.h
-include/mysql/pfs_system_provider.h
-include/mysql/pfs_tls_channel_provider.h
-include/mysql/unhex.h
-include/mysql/unsafe_string_append.h
-include/mysql/base64.h
-include/mysql/big_endian.h
-include/mysql/c_string_less.h
-include/mysql/crypt_genhash_impl.h
-include/mysql/decimal.h
-include/mysql/depth_first_search.h
-include/mysql/dur_prop.h
 include/mysql/errmsg.h
 include/mysql/field_types.h
-include/mysql/ft_global.h
-include/mysql/heap.h
-include/mysql/integer_digits.h
-include/mysql/keycache.h
-include/mysql/lex_string.h
-include/mysql/lf.h
-include/mysql/little_endian.h
-include/mysql/m_ctype.h
-include/mysql/m_string.h
-include/mysql/map_helpers.h
-include/mysql/mf_wcomp.h
-include/mysql/mutex_lock.h
-include/mysql/my_aes.h
-include/mysql/my_alloc.h
-include/mysql/my_atomic.h
-include/mysql/my_base.h
-include/mysql/my_bit.h
-include/mysql/my_bitmap.h
-include/mysql/my_byteorder.h
-include/mysql/my_check_opt.h
 include/mysql/my_command.h
-include/mysql/my_compare.h
-include/mysql/my_compiler.h
 include/mysql/my_compress.h
-include/mysql/my_dbug.h
-include/mysql/my_default.h
-include/mysql/my_dir.h
-include/mysql/my_double2ulonglong.h
-include/mysql/my_getopt.h
-include/mysql/my_hash_combine.h
-include/mysql/my_icp.h
-include/mysql/my_inttypes.h
-include/mysql/my_io.h
 include/mysql/my_list.h
-include/mysql/my_loglevel.h
-include/mysql/my_macros.h
-include/mysql/my_md5.h
-include/mysql/my_md5_size.h
-include/mysql/my_murmur3.h
-include/mysql/my_pointer_arithmetic.h
-include/mysql/my_psi_config.h
-include/mysql/my_rapidjson_size_t.h
-include/mysql/my_rdtsc.h
-include/mysql/my_rnd.h
-include/mysql/my_sharedlib.h
-include/mysql/my_shm_defaults.h
-include/mysql/my_sqlcommand.h
-include/mysql/my_stacktrace.h
-include/mysql/my_sys.h
-include/mysql/my_systime.h
-include/mysql/my_table_map.h
-include/mysql/my_thread.h
-include/mysql/my_thread_local.h
-include/mysql/my_thread_os_id.h
-include/mysql/my_time.h
-include/mysql/my_timer.h
-include/mysql/my_tree.h
-include/mysql/my_uctype.h
-include/mysql/my_user.h
-include/mysql/my_xml.h
-include/mysql/myisam.h
-include/mysql/myisammrg.h
-include/mysql/myisampack.h
 include/mysql/mysql.h
-include/mysql/mysql/client_authentication.h
 include/mysql/mysql/client_plugin.h
-include/mysql/mysql/client_plugin.h.pp
-include/mysql/mysql/com_data.h
-include/mysql/mysql/group_replication_priv.h
-include/mysql/mysql/innodb_priv.h
-include/mysql/mysql/mysql_lex_string.h
-include/mysql/mysql/plugin.h
-include/mysql/mysql/plugin_audit.h
-include/mysql/mysql/plugin_audit.h.pp
-include/mysql/mysql/plugin_auth.h
-include/mysql/mysql/plugin_auth.h.pp
 include/mysql/mysql/plugin_auth_common.h
-include/mysql/mysql/plugin_ftparser.h
-include/mysql/mysql/plugin_ftparser.h.pp
-include/mysql/mysql/plugin_group_replication.h
-include/mysql/mysql/plugin_keyring.h
-include/mysql/mysql/plugin_keyring.h.pp
-include/mysql/mysql/plugin_query_rewrite.h
-include/mysql/mysql/plugin_trace.h
-include/mysql/mysql/plugin_validate_password.h
-include/mysql/mysql/service_command.h
-include/mysql/mysql/service_locking.h
-include/mysql/mysql/service_my_plugin_log.h
-include/mysql/mysql/service_mysql_alloc.h
-include/mysql/mysql/service_mysql_keyring.h
-include/mysql/mysql/service_mysql_password_policy.h
-include/mysql/mysql/service_mysql_string.h
-include/mysql/mysql/service_parser.h
-include/mysql/mysql/service_plugin_registry.h
-include/mysql/mysql/service_rpl_transaction_ctx.h
-include/mysql/mysql/service_rpl_transaction_write_set.h
-include/mysql/mysql/service_rules_table.h
-include/mysql/mysql/service_security_context.h
-include/mysql/mysql/service_srv_session.h
-include/mysql/mysql/service_srv_session_info.h
-include/mysql/mysql/service_ssl_wrapper.h
-include/mysql/mysql/service_thd_alloc.h
-include/mysql/mysql/service_thd_engine_lock.h
-include/mysql/mysql/service_thd_wait.h
-include/mysql/mysql/service_thread_scheduler.h
-include/mysql/mysql/services.h
-include/mysql/mysql/services.h.pp
-include/mysql/mysql/thread_pool_priv.h
-include/mysql/mysql/thread_type.h
 include/mysql/mysql/udf_registration_types.h
 include/mysql/mysql_com.h
-include/mysql/mysql_com_server.h
 include/mysql/mysql_time.h
 include/mysql/mysql_version.h
 include/mysql/mysqld_error.h
-include/mysql/mysys_err.h
-include/mysql/password.h
-include/mysql/pfs_cond_provider.h
-include/mysql/pfs_error_provider.h
-include/mysql/pfs_file_provider.h
-include/mysql/pfs_idle_provider.h
-include/mysql/pfs_memory_provider.h
-include/mysql/pfs_metadata_provider.h
-include/mysql/pfs_mutex_provider.h
-include/mysql/pfs_rwlock_provider.h
-include/mysql/pfs_socket_provider.h
-include/mysql/pfs_stage_provider.h
-include/mysql/pfs_statement_provider.h
-include/mysql/pfs_table_provider.h
-include/mysql/pfs_thread_provider.h
-include/mysql/pfs_transaction_provider.h
-include/mysql/prealloced_array.h
-include/mysql/print_version.h
-include/mysql/priority_queue.h
-include/mysql/rwlock_scoped_lock.h
-include/mysql/scope_guard.h
-include/mysql/service_versions.h
-include/mysql/sha1.h
-include/mysql/sha2.h
-include/mysql/sql_chars.h
-include/mysql/sql_common.h
-include/mysql/sql_string.h
-include/mysql/sslopt-case.h
-include/mysql/sslopt-longopts.h
-include/mysql/sslopt-vars.h
-include/mysql/tables_contained_in.h
-include/mysql/template_utils.h
-include/mysql/thr_cond.h
-include/mysql/thr_lock.h
-include/mysql/thr_mutex.h
-include/mysql/thr_rwlock.h
-include/mysql/typelib.h
-include/mysql/varlen_sort.h
-include/mysql/violite.h
-include/mysql/welcome_copyright_notice.h
 lib/mysql/libmysqlclient.a
 lib/mysql/libmysqlclient.so
 lib/mysql/libmysqlclient.so.21
diff --git a/databases/mysql80-server/Makefile b/databases/mysql80-server/Makefile
index 2fc8786b8846..7a5197a771be 100644
--- a/databases/mysql80-server/Makefile
+++ b/databases/mysql80-server/Makefile
@@ -1,5 +1,5 @@
 PORTNAME?=		mysql
-PORTVERSION=		8.0.29
+PORTVERSION=		8.0.30
 PORTREVISION?=		0
 CATEGORIES=		databases
 MASTER_SITES=		MYSQL/MySQL-8.0
@@ -85,7 +85,6 @@ CMAKE_ARGS+=	-DINSTALL_LAYOUT=FREEBSD \
 		-DWITH_LZ4=system \
 		-DWITH_ICU=system \
 		-DWITH_CURL=system \
-		-DWITH_ZLIB=system \
 		-DWITH_ZSTD=system \
 		-DWITH_PROTOBUF=system \
 		-DWITH_SSL=system \
diff --git a/databases/mysql80-server/distinfo b/databases/mysql80-server/distinfo
index 33a7799c04a9..b9e632e8a536 100644
--- a/databases/mysql80-server/distinfo
+++ b/databases/mysql80-server/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1651315615
-SHA256 (mysql-boost-8.0.29.tar.gz) = fd34a84c65fc7b15609d55b1f5d128c4d5543a6b95fa638569c3277c5c7bb048
-SIZE (mysql-boost-8.0.29.tar.gz) = 327770349
+TIMESTAMP = 1659818963
+SHA256 (mysql-boost-8.0.30.tar.gz) = c331ac7a68099a2116097acbb14fd331423d486fe47ce0e346925111b44df69c
+SIZE (mysql-boost-8.0.30.tar.gz) = 332772783
diff --git a/databases/mysql80-server/files/patch-CMakeLists.txt b/databases/mysql80-server/files/patch-CMakeLists.txt
index e977c8863cc0..625e0bac005c 100644
--- a/databases/mysql80-server/files/patch-CMakeLists.txt
+++ b/databases/mysql80-server/files/patch-CMakeLists.txt
@@ -1,6 +1,6 @@
---- CMakeLists.txt.orig	2021-12-17 16:07:27 UTC
+--- CMakeLists.txt.orig	2022-07-06 21:36:34 UTC
 +++ CMakeLists.txt
-@@ -1665,7 +1665,7 @@ IF(LINUX AND KNOWN_CUSTOM_LIBRARIES)
+@@ -1819,7 +1819,7 @@ IF(LINUX AND KNOWN_CUSTOM_LIBRARIES)
  ENDIF()
  
  IF(WITH_AUTHENTICATION_LDAP)
@@ -9,23 +9,35 @@
      # LDAP / SASL / KERBEROS / SSL must all be "system" or "custom", not a mix.
      IF(WITH_LDAP STREQUAL "system" OR
          WITH_SASL STREQUAL "system" OR
-@@ -1714,10 +1714,10 @@ IF(WITH_AUTHENTICATION_KERBEROS)
+@@ -1868,6 +1868,7 @@ IF(WITH_AUTHENTICATION_KERBEROS)
    ENDIF()
  ENDIF()
  
--# Add system/bundled editline.
--MYSQL_CHECK_EDITLINE()
- # Add libevent
--MYSQL_CHECK_LIBEVENT()
++IF(NOT WITHOUT_TOOLS)
+ # Add system/bundled editline.
+ MYSQL_CHECK_EDITLINE()
+ SET(EDITLINE_WARN_GIVEN)
+@@ -1878,7 +1879,9 @@ IF(EDITLINE_WARN_GIVEN)
+     "You can use -DWITH_EDITLINE=bundled instead."
+     )
+ ENDIF()
++ENDIF(NOT WITHOUT_TOOLS)
+ 
 +IF(NOT WITHOUT_SERVER)
-+  MYSQL_CHECK_LIBEVENT()
-+ENDIF()
+ # Add libevent
+ MYSQL_CHECK_LIBEVENT()
+ SET(LIBEVENT_WARN_GIVEN)
+@@ -1889,6 +1892,7 @@ IF(LIBEVENT_WARN_GIVEN)
+     "You can use -DWITH_LIBEVENT=bundled instead."
+     )
+ ENDIF()
++ENDIF(NOT WITHOUT_SERVER)
+ 
  # Add lz4 library
  MYSQL_CHECK_LZ4()
- # Add icu library
-@@ -1917,7 +1917,9 @@ ADD_CUSTOM_TARGET(plugin_all)
- # Utility target to build every target added with MYSQL_ADD_COMPONENT.
- ADD_CUSTOM_TARGET(component_all)
+@@ -2142,7 +2146,9 @@ ADD_CUSTOM_TARGET(clang_tidy_prerequisites)
+ ADD_DEPENDENCIES(clang_tidy_prerequisites protobuf_generated_all)
+ ADD_DEPENDENCIES(clang_tidy_prerequisites GenError)
  
 -ADD_SUBDIRECTORY(include)
 +IF(NOT WITHOUT_CLIENTLIBS)
@@ -34,14 +46,12 @@
  ADD_SUBDIRECTORY(strings)
  ADD_SUBDIRECTORY(vio)
  ADD_SUBDIRECTORY(mysys)
-@@ -1962,12 +1964,17 @@ IF(WITH_UNIT_TESTS)
+@@ -2187,12 +2193,15 @@ IF(WITH_UNIT_TESTS)
    ADD_SUBDIRECTORY(unittest/mytap/t)
  ENDIF()
  
 -ADD_SUBDIRECTORY(client)
 +IF(NOT WITHOUT_TOOLS)
-+  # Add system/bundled editline
-+  MYSQL_CHECK_EDITLINE()
 +  ADD_SUBDIRECTORY(client)
 +ENDIF(NOT WITHOUT_TOOLS)
 +
@@ -54,7 +64,7 @@
    ADD_SUBDIRECTORY(testclients)
    ADD_SUBDIRECTORY(sql)
  ENDIF()
-@@ -2020,11 +2027,11 @@ ENDIF()
+@@ -2247,11 +2256,11 @@ ENDIF()
  # scripts/mysql_config depends on client and server targets loaded above.
  # It is referenced by some of the directories below, so we insert it here.
  ADD_SUBDIRECTORY(scripts)
@@ -67,7 +77,7 @@
    IF(WITH_INTERNAL)
      ADD_SUBDIRECTORY(internal)
    ENDIF()
-@@ -2134,6 +2141,7 @@ IF(PACK_SEPARATE_COMPONENTS)
+@@ -2361,6 +2370,7 @@ IF(PACK_SEPARATE_COMPONENTS)
    SET(CPACK_COMPONENTS_GROUPING IGNORE)
  ENDIF()
  
@@ -75,7 +85,7 @@
  IF(UNIX)
    INSTALL(FILES
      Docs/mysql.info
-@@ -2168,6 +2176,7 @@ IF(NOT INSTALL_LAYOUT MATCHES "RPM")
+@@ -2395,6 +2405,7 @@ IF(NOT INSTALL_LAYOUT MATCHES "RPM")
      PATTERN "sp-imp-spec.txt" EXCLUDE
      PATTERN "README.build" EXCLUDE
    )
diff --git a/databases/mysql80-server/files/patch-cmake_ssl.cmake b/databases/mysql80-server/files/patch-cmake_ssl.cmake
index 9643e476f4eb..e7688d6e50ad 100644
--- a/databases/mysql80-server/files/patch-cmake_ssl.cmake
+++ b/databases/mysql80-server/files/patch-cmake_ssl.cmake
@@ -1,29 +1,23 @@
---- cmake/ssl.cmake.orig	2021-12-17 16:07:27 UTC
+--- cmake/ssl.cmake.orig	2022-07-06 21:36:34 UTC
 +++ cmake/ssl.cmake
-@@ -211,7 +211,7 @@ MACRO (MYSQL_CHECK_SSL)
-       # Encoded as MNNFFPPS: major minor fix patch status
-       FILE(STRINGS "${OPENSSL_INCLUDE_DIR}/openssl/opensslv.h"
-         OPENSSL_VERSION_NUMBER
--        REGEX "^#[ ]*define[\t ]+OPENSSL_VERSION_NUMBER[\t ]+0x[0-9].*"
-+        REGEX "^#[\t ]*define[\t ]+OPENSSL_VERSION_NUMBER[\t ]+0x[0-9].*"
-         )
-       STRING(REGEX REPLACE
-         "^.*OPENSSL_VERSION_NUMBER[\t ]+0x([0-9]).*$" "\\1"
-@@ -226,13 +226,14 @@ MACRO (MYSQL_CHECK_SSL)
-         OPENSSL_FIX_VERSION "${OPENSSL_VERSION_NUMBER}"
-         )
+@@ -142,7 +142,7 @@ MACRO(FIND_OPENSSL_VERSION)
+     # Encoded as MNNFFPPS: major minor fix patch status
+     FILE(STRINGS "${OPENSSL_INCLUDE_DIR}/openssl/opensslv.h"
+       OPENSSL_VERSION_NUMBER
+-      REGEX "^#[ ]*define[\t ]+OPENSSL_VERSION_NUMBER[\t ]+0x[0-9].*"
++      REGEX "^#[\t ]*define[\t ]+OPENSSL_VERSION_NUMBER[\t ]+0x[0-9].*"
+       )
+     STRING(REGEX REPLACE
+       "^.*OPENSSL_VERSION_NUMBER[\t ]+0x([0-9]).*$" "\\1"
+@@ -380,8 +380,9 @@ MACRO (MYSQL_CHECK_SSL)
+         "Not a supported openssl version in WITH_SSL=${WITH_SSL}.")
      ENDIF()
--    IF("${OPENSSL_MAJOR_VERSION}.${OPENSSL_MINOR_VERSION}.${OPENSSL_FIX_VERSION}" VERSION_GREATER "1.1.0")
+ 
+-    IF("${OPENSSL_MAJOR_MINOR_FIX_VERSION}" VERSION_GREATER "1.1.0")
 -       ADD_DEFINITIONS(-DHAVE_TLSv13)
 +    CHECK_SYMBOL_EXISTS(TLS1_3_VERSION "openssl/tls1.h" HAVE_TLS1_3_VERSION)
 +    IF(HAVE_TLS1_3_VERSION)
 +       #ADD_DEFINITIONS(-DHAVE_TLSv13)
      ENDIF()
+ 
      IF(OPENSSL_INCLUDE_DIR AND
-        OPENSSL_LIBRARY   AND
-        CRYPTO_LIBRARY      AND
--       OPENSSL_MAJOR_VERSION STREQUAL "1"
-+       OPENSSL_MAJOR_VERSION VERSION_GREATER_EQUAL "1"
-       )
-       SET(OPENSSL_FOUND TRUE)
-       FIND_PROGRAM(OPENSSL_EXECUTABLE openssl
diff --git a/databases/mysql80-server/files/patch-include_CMakeLists.txt b/databases/mysql80-server/files/patch-include_CMakeLists.txt
deleted file mode 100644
index 96f88d8593aa..000000000000
--- a/databases/mysql80-server/files/patch-include_CMakeLists.txt
+++ /dev/null
@@ -1,185 +0,0 @@
---- include/CMakeLists.txt.orig	2021-09-28 11:46:34 UTC
-+++ include/CMakeLists.txt
-@@ -37,10 +37,182 @@ SET(HEADERS
-   ${CMAKE_CURRENT_BINARY_DIR}/mysql_version.h
-   ${CMAKE_CURRENT_BINARY_DIR}/mysqld_error.h
-   field_types.h
-+  add_with_saturate.h
-+  base64.h
-+  big_endian.h
-+  c_string_less.h
-+  caching_sha2_passwordopt-longopts.h
-+  caching_sha2_passwordopt-vars.h
-+  compression.h
-+  crypt_genhash_impl.h
-+  decimal.h
-+  depth_first_search.h
-+  dur_prop.h
-+  ft_global.h
-+  heap.h
-+  integer_digits.h
-+  keycache.h
-+  keyring_operations_helper.h
-+  lex_string.h
-+  lf.h
-+  little_endian.h
-+  m_ctype.h
-+  m_string.h
-+  manifest.h
-+  map_helpers.h
-+  mem_root_deque.h
-+  memory_debugging.h
-+  mf_wcomp.h
-+  mutex_lock.h
-+  my_aes.h
-+  my_alloc.h
-+  my_atomic.h
-+  my_base.h
-+  my_basename.h
-+  my_bit.h
-+  my_bitmap.h
-+  my_byteorder.h
-+  my_check_opt.h
-+  my_checksum.h
-+  my_compare.h
-+  my_compiler.h
-+  my_dbug.h
-+  my_default.h
-+  my_dir.h
-+  my_double2ulonglong.h
-+  my_getopt.h
-+  my_getpwnam.h
-+  my_hash_combine.h
-+  my_hostname.h
-+  my_icp.h
-+  my_inttypes.h
-+  my_io.h
-+  my_loglevel.h
-+  my_macros.h
-+  my_md5_size.h
-+  my_md5.h
-+  my_murmur3.h
-+  my_pointer_arithmetic.h
-+  my_psi_config.h
-+  my_rapidjson_size_t.h
-+  my_rcu_lock.h
-+  my_rdtsc.h
-+  my_rnd.h
-+  my_sharedlib.h
-+  my_shm_defaults.h
-+  my_sqlcommand.h
-+  my_stacktrace.h
-+  my_sys.h
-+  my_systime.h
-+  my_table_map.h
-+  my_thread_local.h
-+  my_thread_os_id.h
-+  my_thread.h
-+  my_time.h
-+  my_timer.h
-+  my_tree.h
-+  my_uctype.h
-+  my_user.h
-+  my_xml.h
-+  myisam.h
-+  myisammrg.h
-+  myisampack.h
-+  mysql_async.h
-+  mysql_com_server.h
-+  mysys_err.h
-+  password.h
-+  pfs_cond_provider.h
-+  pfs_data_lock_provider.h
-+  pfs_error_provider.h
-+  pfs_file_provider.h
-+  pfs_idle_provider.h
-+  pfs_memory_provider.h
-+  pfs_metadata_provider.h
-+  pfs_mutex_provider.h
-+  pfs_rwlock_provider.h
-+  pfs_socket_provider.h
-+  pfs_stage_provider.h
-+  pfs_statement_provider.h
-+  pfs_system_provider.h
-+  pfs_table_provider.h
-+  pfs_thread_provider.h
-+  pfs_tls_channel_provider.h
-+  pfs_transaction_provider.h
-+  prealloced_array.h
-+  print_version.h
-+  priority_queue.h
-+  rwlock_scoped_lock.h
-+  scope_guard.h
-+  service_versions.h
-+  sha1.h
-+  sha2.h
-+  sql_chars.h
-+  sql_common.h
-+  sql_string.h
-+  sslopt-case.h
-+  sslopt-longopts.h
-+  sslopt-vars.h
-+  tables_contained_in.h
-+  template_utils.h
-+  thr_cond.h
-+  thr_lock.h
-+  thr_mutex.h
-+  thr_rwlock.h
-+  typelib.h
-+  unhex.h
-+  unsafe_string_append.h
-+  varlen_sort.h
-+  violite.h
-+  welcome_copyright_notice.h
- )
- SET(HEADERS_MYSQL_DIR
-   mysql/client_plugin.h
-   mysql/plugin_auth_common.h
-+  mysql/udf_registration_types.h
-+  mysql/client_authentication.h
-+  mysql/client_plugin.h.pp
-+  mysql/com_data.h
-+  mysql/group_replication_priv.h
-+  mysql/innodb_priv.h
-+  mysql/mysql_lex_string.h
-+  mysql/plugin.h
-+  mysql/plugin_audit.h
-+  mysql/plugin_audit.h.pp
-+  mysql/plugin_auth.h
-+  mysql/plugin_auth.h.pp
-+  mysql/plugin_auth_common.h
-+  mysql/plugin_ftparser.h
-+  mysql/plugin_ftparser.h.pp
-+  mysql/plugin_group_replication.h
-+  mysql/plugin_keyring.h
-+  mysql/plugin_keyring.h.pp
-+  mysql/plugin_query_rewrite.h
-+  mysql/plugin_trace.h
-+  mysql/plugin_validate_password.h
-+  mysql/service_command.h
-+  mysql/service_locking.h
-+  mysql/service_my_plugin_log.h
-+  mysql/service_mysql_alloc.h
-+  mysql/service_mysql_keyring.h
-+  mysql/service_mysql_password_policy.h
-+  mysql/service_mysql_string.h
-+  mysql/service_parser.h
-+  mysql/service_plugin_registry.h
-+  mysql/service_rpl_transaction_ctx.h
-+  mysql/service_rpl_transaction_write_set.h
-+  mysql/service_rules_table.h
-+  mysql/service_security_context.h
-+  mysql/service_srv_session.h
-+  mysql/service_srv_session_info.h
-+  mysql/service_ssl_wrapper.h
-+  mysql/service_thd_alloc.h
-+  mysql/service_thd_engine_lock.h
-+  mysql/service_thd_wait.h
-+  mysql/service_thread_scheduler.h
-+  mysql/services.h
-+  mysql/services.h.pp
-+  mysql/thread_pool_priv.h
-+  mysql/thread_type.h
-   mysql/udf_registration_types.h
- )
- 
diff --git a/databases/mysql80-server/files/patch-include_violite.h b/databases/mysql80-server/files/patch-include_violite.h
deleted file mode 100644
index 00065b6ea59c..000000000000
--- a/databases/mysql80-server/files/patch-include_violite.h
+++ /dev/null
@@ -1,14 +0,0 @@
---- include/violite.h.orig	2021-12-17 16:07:27 UTC
-+++ include/violite.h
-@@ -268,9 +268,11 @@ struct st_VioSSLFd *new_VioSSLConnectorFd(
- 
- long process_tls_version(const char *tls_version);
- 
-+#ifndef LIBRESSL_VERSION_NUMBER
- int set_fips_mode(const uint fips_mode, char *err_string);
- 
- uint get_fips_mode();
-+#endif
- 
- int test_ssl_fips_mode(char *err_string);
- 
diff --git a/databases/mysql80-server/files/patch-mysys_my__md5.cc b/databases/mysql80-server/files/patch-mysys_my__md5.cc
deleted file mode 100644
index 56986ec7f9b0..000000000000
--- a/databases/mysql80-server/files/patch-mysys_my__md5.cc
+++ /dev/null
@@ -1,12 +0,0 @@
---- mysys/my_md5.cc.orig	2019-09-20 08:30:51 UTC
-+++ mysys/my_md5.cc
-@@ -56,7 +56,9 @@ static void my_md5_hash(unsigned char *digest, unsigne
- int compute_md5_hash(char *digest, const char *buf, int len) {
-   int retval = 0;
-   int fips_mode = 0;
-+#ifndef LIBRESSL_VERSION_NUMBER
-   fips_mode = FIPS_mode();
-+#endif /* LIBRESSL_VERSION_NUMBER */
-   /* If fips mode is ON/STRICT restricted method calls will result into abort,
-    * skipping call. */
-   if (fips_mode == 0) {
diff --git a/databases/mysql80-server/files/patch-plugin_group_replication_libmysqlgcs_src_bindings_xcom_xcom_network_xcom__network__provider__ssl_native__lib.cc b/databases/mysql80-server/files/patch-plugin_group_replication_libmysqlgcs_src_bindings_xcom_xcom_network_xcom__network__provider__ssl_native__lib.cc
deleted file mode 100644
index bb1eb42d99aa..000000000000
--- a/databases/mysql80-server/files/patch-plugin_group_replication_libmysqlgcs_src_bindings_xcom_xcom_network_xcom__network__provider__ssl_native__lib.cc
+++ /dev/null
@@ -1,20 +0,0 @@
---- plugin/group_replication/libmysqlgcs/src/bindings/xcom/xcom/network/xcom_network_provider_ssl_native_lib.cc.orig	2022-02-20 15:21:13.279471000 -0800
-+++ plugin/group_replication/libmysqlgcs/src/bindings/xcom/xcom/network/xcom_network_provider_ssl_native_lib.cc	2022-02-20 15:22:02.451078000 -0800
-@@ -318,6 +318,7 @@
- 
- #define OPENSSL_ERROR_LENGTH 512
- static int configure_ssl_fips_mode(const int fips_mode) {
-+#ifndef LIBRESSL_VERSION_NUMBER
-   int rc = -1;
-   int fips_mode_old = -1;
-   char err_string[OPENSSL_ERROR_LENGTH] = {'\0'};
-@@ -338,6 +339,9 @@
-   }
- EXIT:
-   return rc;
-+# else
-+  return -1;
-+# endif
- }
- 
- static int configure_ssl_ca(SSL_CTX *ssl_ctx, const char *ca_file,
diff --git a/databases/mysql80-server/files/patch-plugin_x_client_xconnection__impl.cc b/databases/mysql80-server/files/patch-plugin_x_client_xconnection__impl.cc
deleted file mode 100644
index ecd596100e6b..000000000000
--- a/databases/mysql80-server/files/patch-plugin_x_client_xconnection__impl.cc
+++ /dev/null
@@ -1,33 +0,0 @@
---- plugin/x/client/xconnection_impl.cc.orig	2021-12-17 16:07:27 UTC
-+++ plugin/x/client/xconnection_impl.cc
-@@ -618,6 +618,7 @@ XError Connection_impl::get_ssl_error(const int error_
-   return XError(CR_SSL_CONNECTION_ERROR, buffer);
- }
- 
-+#ifndef LIBRESSL_VERSION_NUMBER
- /**
-   Set fips mode in openssl library,
-   When we set fips mode ON/STRICT, it will perform following operations:
-@@ -657,6 +658,7 @@ int set_fips_mode(const uint32_t fips_mode,
- EXIT:
-   return rc;
- }
-+#endif
- 
- XError Connection_impl::activate_tls() {
-   if (nullptr == m_vio) return get_socket_error(SOCKET_ECONNRESET);
-@@ -667,12 +669,14 @@ XError Connection_impl::activate_tls() {
-   if (!m_context->m_ssl_config.is_configured())
-     return XError{CR_SSL_CONNECTION_ERROR, ER_TEXT_TLS_NOT_CONFIGURATED, true};
- 
-+#ifndef LIBRESSL_VERSION_NUMBER
-   char err_string[OPENSSL_ERROR_LENGTH] = {'\0'};
-   if (set_fips_mode(
-           static_cast<uint32_t>(m_context->m_ssl_config.m_ssl_fips_mode),
-           err_string) != 1) {
-     return XError{CR_SSL_CONNECTION_ERROR, err_string, true};
-   }
-+#endif
-   auto ssl_ctx_flags = process_tls_version(
-       details::null_when_empty(m_context->m_ssl_config.m_tls_version));
- 
diff --git a/databases/mysql80-server/files/patch-router_src_harness_src_tls__server__context.cc b/databases/mysql80-server/files/patch-router_src_harness_src_tls__server__context.cc
deleted file mode 100644
index e7498ecbfb8a..000000000000
--- a/databases/mysql80-server/files/patch-router_src_harness_src_tls__server__context.cc
+++ /dev/null
@@ -1,12 +0,0 @@
---- router/src/harness/src/tls_server_context.cc.orig	2021-12-17 16:07:27 UTC
-+++ router/src/harness/src/tls_server_context.cc
-@@ -169,7 +169,8 @@ stdx::expected<void, std::error_code> TlsServerContext
-     }
- 
-   } else {
--#if OPENSSL_VERSION_NUMBER >= ROUTER_OPENSSL_VERSION(1, 1, 0)
-+#if OPENSSL_VERSION_NUMBER >= ROUTER_OPENSSL_VERSION(1, 1, 0) && \
-+    !defined(LIBRESSL_VERSION_NUMBER)
-     dh2048.reset(DH_get_2048_256());
- #else
-     /*
diff --git a/databases/mysql80-server/files/patch-scripts_CMakeLists.txt b/databases/mysql80-server/files/patch-scripts_CMakeLists.txt
index 74acb1291d88..d927dbe6a864 100644
--- a/databases/mysql80-server/files/patch-scripts_CMakeLists.txt
+++ b/databases/mysql80-server/files/patch-scripts_CMakeLists.txt
@@ -1,15 +1,15 @@
---- scripts/CMakeLists.txt.orig	2021-12-17 16:07:27 UTC
+--- scripts/CMakeLists.txt.orig	2022-07-06 21:36:34 UTC
 +++ scripts/CMakeLists.txt
-@@ -323,6 +323,8 @@ MACRO(EXTRACT_LINK_LIBRARIES target var)
-         GET_FILENAME_COMPONENT(lib "${lib}" NAME_WE)
-         STRING(REGEX REPLACE "^lib" "" lib "${lib}")
+@@ -332,6 +332,8 @@ MACRO(EXTRACT_LINK_LIBRARIES target var)
+           SET(${var} "${${var}}-L${dir} " )
+         ENDIF()
          SET(${var} "${${var}}-l${lib} " )
 +        ELSEIF(lib STREQUAL "-pthread")
 +          SET(${var} "${${var}}-pthread " )
        ELSE()
          SET(${var} "${${var}}-l${lib} " )
        ENDIF()
-@@ -396,7 +398,7 @@ ELSE()
+@@ -405,7 +407,7 @@ ELSE()
      ${CMAKE_CURRENT_BINARY_DIR}/${PKGCONFIG_FILE}
      ESCAPE_QUOTES @ONLY)
  
@@ -18,7 +18,7 @@
      MESSAGE(STATUS "INSTALL ${PKGCONFIG_FILE} ${INSTALL_PKGCONFIGDIR}")
      INSTALL(FILES
        ${CMAKE_CURRENT_BINARY_DIR}/${PKGCONFIG_FILE}
-@@ -409,23 +411,28 @@ ELSE()
+@@ -418,23 +420,28 @@ ELSE()
    # mysqld_safe used in mtr even for systemd platforms
    IF(WITH_SYSTEMD)
      SET(BIN_SCRIPTS
diff --git a/databases/mysql80-server/files/patch-sql-common_client.cc b/databases/mysql80-server/files/patch-sql-common_client.cc
deleted file mode 100644
index b01beea3686b..000000000000
--- a/databases/mysql80-server/files/patch-sql-common_client.cc
+++ /dev/null
@@ -1,18 +0,0 @@
---- sql-common/client.cc.orig	2021-12-17 16:07:27 UTC
-+++ sql-common/client.cc
-@@ -8301,6 +8301,7 @@ int STDCALL mysql_options(MYSQL *mysql, enum mysql_opt
-         return 1;
-       break;
-     case MYSQL_OPT_SSL_FIPS_MODE: {
-+#if !defined(LIBRESSL_VERSION_NUMBER)
-       char ssl_err_string[OPENSSL_ERROR_LENGTH] = {'\0'};
-       ENSURE_EXTENSIONS_PRESENT(&mysql->options);
-       mysql->options.extension->ssl_fips_mode =
-@@ -8313,6 +8314,7 @@ int STDCALL mysql_options(MYSQL *mysql, enum mysql_opt
-             "Set Fips mode ON/STRICT failed, detail: '%s'.", ssl_err_string);
-         return 1;
-       }
-+#endif
-     } break;
-     case MYSQL_OPT_SSL_MODE:
-       ENSURE_EXTENSIONS_PRESENT(&mysql->options);
diff --git a/databases/mysql80-server/files/patch-sql_mysqld.cc b/databases/mysql80-server/files/patch-sql_mysqld.cc
index a8eccb94f647..484af751b704 100644
--- a/databases/mysql80-server/files/patch-sql_mysqld.cc
+++ b/databases/mysql80-server/files/patch-sql_mysqld.cc
@@ -1,6 +1,6 @@
---- sql/mysqld.cc.orig	2021-12-17 16:07:27 UTC
+--- sql/mysqld.cc.orig	2022-07-06 21:36:34 UTC
 +++ sql/mysqld.cc
-@@ -5285,7 +5285,7 @@ static int init_thread_environment() {
+@@ -5299,7 +5299,7 @@ static int init_thread_environment() {
  
  static PSI_memory_key key_memory_openssl = PSI_NOT_INSTRUMENTED;
  
@@ -9,18 +9,3 @@
  #define FILE_LINE_ARGS
  #else
  #define FILE_LINE_ARGS , const char *, int
-@@ -5316,12 +5316,14 @@ static void init_ssl() {
- }
- 
- static int init_ssl_communication() {
-+#ifndef LIBRESSL_VERSION_NUMBER
-   char ssl_err_string[OPENSSL_ERROR_LENGTH] = {'\0'};
-   int ret_fips_mode = set_fips_mode(opt_ssl_fips_mode, ssl_err_string);
-   if (ret_fips_mode != 1) {
-     LogErr(ERROR_LEVEL, ER_SSL_FIPS_MODE_ERROR, ssl_err_string);
-     return 1;
-   }
-+#endif /* LIBRESSL_VERSION_NUMBER */
-   if (TLS_channel::singleton_init(&mysql_main, mysql_main_channel, opt_use_ssl,
-                                   &server_main_callback, opt_initialize))
-     return 1;
diff --git a/databases/mysql80-server/files/patch-sql_sys__vars.cc b/databases/mysql80-server/files/patch-sql_sys__vars.cc
index 3bee6a98fbad..39f72484c0bd 100644
--- a/databases/mysql80-server/files/patch-sql_sys__vars.cc
+++ b/databases/mysql80-server/files/patch-sql_sys__vars.cc
@@ -1,6 +1,6 @@
---- sql/sys_vars.cc.orig	2021-12-17 16:07:27 UTC
+--- sql/sys_vars.cc.orig	2022-07-06 21:36:34 UTC
 +++ sql/sys_vars.cc
-@@ -1977,7 +1977,7 @@ static Sys_var_ulong Sys_connect_timeout(
+@@ -2039,7 +2039,7 @@ static Sys_var_ulong Sys_connect_timeout(
      "The number of seconds the mysqld server is waiting for a connect "
      "packet before responding with 'Bad handshake'",
      GLOBAL_VAR(connect_timeout), CMD_LINE(REQUIRED_ARG),
@@ -9,7 +9,7 @@
  
  static Sys_var_ulong Sys_information_schema_stats_expiry(
      "information_schema_stats_expiry",
-@@ -3093,7 +3093,7 @@ static Sys_var_ulong Sys_net_read_timeout(
+@@ -3189,7 +3189,7 @@ static Sys_var_ulong Sys_net_read_timeout(
      "Number of seconds to wait for more data from a connection before "
      "aborting the read",
      SESSION_VAR(net_read_timeout), CMD_LINE(REQUIRED_ARG),
@@ -18,7 +18,7 @@
      NO_MUTEX_GUARD, NOT_IN_BINLOG, ON_CHECK(nullptr),
      ON_UPDATE(fix_net_read_timeout));
  
-@@ -3114,7 +3114,7 @@ static Sys_var_ulong Sys_net_write_timeout(
+@@ -3210,7 +3210,7 @@ static Sys_var_ulong Sys_net_write_timeout(
      "Number of seconds to wait for a block to be written to a connection "
      "before aborting the write",
      SESSION_VAR(net_write_timeout), CMD_LINE(REQUIRED_ARG),
@@ -27,44 +27,3 @@
      NO_MUTEX_GUARD, NOT_IN_BINLOG, ON_CHECK(nullptr),
      ON_UPDATE(fix_net_write_timeout));
  
-@@ -4876,6 +4876,7 @@ static Sys_var_ulong Sys_max_execution_time(
-     HINT_UPDATEABLE SESSION_VAR(max_execution_time), CMD_LINE(REQUIRED_ARG),
-     VALID_RANGE(0, ULONG_MAX), DEFAULT(0), BLOCK_SIZE(1));
- 
-+#ifndef LIBRESSL_VERSION_NUMBER
- static bool update_fips_mode(sys_var *, THD *, enum_var_type) {
-   char ssl_err_string[OPENSSL_ERROR_LENGTH] = {'\0'};
-   if (set_fips_mode(opt_ssl_fips_mode, ssl_err_string) != 1) {
-@@ -4887,14 +4888,30 @@ static bool update_fips_mode(sys_var *, THD *, enum_va
-   }
- }
- 
-+#endif
-+
-+#if defined(LIBRESSL_VERSION_NUMBER)
-+static const char *ssl_fips_mode_names[] = {"OFF", 0};
-+#else
- static const char *ssl_fips_mode_names[] = {"OFF", "ON", "STRICT", nullptr};
-+#endif
- static Sys_var_enum Sys_ssl_fips_mode(
-     "ssl_fips_mode",
-     "SSL FIPS mode (applies only for OpenSSL); "
--    "permitted values are: OFF, ON, STRICT",
-+#ifndef LIBRESSL_VERSION_NUMBER
-+     "permitted values are: OFF, ON, STRICT",
-+#else
-+    "permitted values are: OFF",
-+#endif
-     GLOBAL_VAR(opt_ssl_fips_mode), CMD_LINE(REQUIRED_ARG, OPT_SSL_FIPS_MODE),
-     ssl_fips_mode_names, DEFAULT(0), NO_MUTEX_GUARD, NOT_IN_BINLOG,
--    ON_CHECK(nullptr), ON_UPDATE(update_fips_mode), nullptr);
-+    ON_CHECK(NULL),
-+#ifndef LIBRESSL_VERSION_NUMBER
-+    ON_UPDATE(update_fips_mode),
-+#else
-+    ON_UPDATE(NULL),
-+#endif
-+    NULL);
- 
- static Sys_var_bool Sys_auto_generate_certs(
-     "auto_generate_certs",
diff --git a/databases/mysql80-server/files/patch-vio_viosslfactories.cc b/databases/mysql80-server/files/patch-vio_viosslfactories.cc
index 2e0fb5d55fe6..2882353d79f0 100644
--- a/databases/mysql80-server/files/patch-vio_viosslfactories.cc
+++ b/databases/mysql80-server/files/patch-vio_viosslfactories.cc
@@ -1,5 +1,5 @@
---- vio/viosslfactories.cc.orig	2021-12-17 08:07:27.000000000 -0800
-+++ vio/viosslfactories.cc	2022-02-20 11:48:11.223957000 -0800
+--- vio/viosslfactories.cc.orig	2022-07-06 21:36:34 UTC
++++ vio/viosslfactories.cc
 @@ -40,6 +40,7 @@
  #include "vio/vio_priv.h"
  
@@ -8,40 +8,7 @@
  
  #if OPENSSL_VERSION_NUMBER < 0x10002000L
  #include <openssl/ec.h>
-@@ -472,6 +473,7 @@
-   }
- }
- 
-+#ifndef LIBRESSL_VERSION_NUMBER
- /**
-   Set fips mode in openssl library,
-   When we set fips mode ON/STRICT, it will perform following operations:
-@@ -525,6 +527,7 @@
-   @returns openssl current fips mode
- */
- uint get_fips_mode() { return FIPS_mode(); }
-+#endif
- 
- /**
-   Toggle FIPS mode, to see whether it is available with the current SSL library.
-@@ -532,6 +535,7 @@
-   @retval non-zero: FIPS is supported.
- */
- int test_ssl_fips_mode(char *err_string) {
-+#ifndef LIBRESSL_VERSION_NUMBER
-   int ret = FIPS_mode_set(FIPS_mode() == 0 ? 1 : 0);
-   unsigned long err = (ret == 0) ? ERR_get_error() : 0;
- 
-@@ -539,13 +543,16 @@
-     ERR_error_string_n(err, err_string, OPENSSL_ERROR_LENGTH - 1);
-   }
-   return ret;
-+#else
-+  return 0;
-+#endif
- }
- 
- long process_tls_version(const char *tls_version) {
+@@ -484,7 +485,7 @@ long process_tls_version(const char *tls_version) {
    const char *separator = ",";
    char *token, *lasts = nullptr;
  
@@ -50,7 +17,7 @@
    const char *tls_version_name_list[] = {"TLSv1.2", "TLSv1.3"};
    const char ctx_flag_default[] = "TLSv1.2,TLSv1.3";
    const long tls_ctx_list[] = {SSL_OP_NO_TLSv1_2, SSL_OP_NO_TLSv1_3};
-@@ -623,7 +630,7 @@
+@@ -559,7 +560,7 @@ static struct st_VioSSLFd *new_VioSSLFd(
    ssl_ctx_options = (ssl_ctx_options | ssl_ctx_flags) &
                      (SSL_OP_NO_SSLv2 | SSL_OP_NO_SSLv3 | SSL_OP_NO_TLSv1 |
                       SSL_OP_NO_TLSv1_1 | SSL_OP_NO_TLSv1_2
@@ -59,7 +26,7 @@
                       | SSL_OP_NO_TLSv1_3
  #endif /* HAVE_TLSv13 */
                       | SSL_OP_NO_TICKET);
-@@ -632,7 +639,7 @@
+@@ -568,7 +569,7 @@ static struct st_VioSSLFd *new_VioSSLFd(
      return nullptr;
  
    if (!(ssl_fd->ssl_context = SSL_CTX_new(is_client ?
@@ -68,7 +35,7 @@
                                                      TLS_client_method()
                                                      : TLS_server_method()
  #else  /* HAVE_TLSv13 */
-@@ -647,7 +654,7 @@
+@@ -583,7 +584,7 @@ static struct st_VioSSLFd *new_VioSSLFd(
      return nullptr;
    }
  
diff --git a/databases/mysql80-server/pkg-plist b/databases/mysql80-server/pkg-plist
index 4be66c332d9f..53ba6300271c 100644
--- a/databases/mysql80-server/pkg-plist
+++ b/databases/mysql80-server/pkg-plist
@@ -61,6 +61,7 @@ lib/mysql/mysqlrouter/routing.so
 lib/mysql/plugin/adt_null.so
 lib/mysql/plugin/auth.so
 lib/mysql/plugin/auth_test_plugin.so
*** 4 LINES SKIPPED ***