From 92973eb3c44f4f876eaa22aee4538840ff6d4443 Mon Sep 17 00:00:00 2001 From: Michal Schorm Date: Mon, 31 Mar 2025 13:00:34 +0200 Subject: [PATCH 01/11] Update the license clarification text to reflect the current state Related: RHEL-87738 --- README.mysql-license | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.mysql-license b/README.mysql-license index ceabbcf..8c0dda9 100644 --- a/README.mysql-license +++ b/README.mysql-license @@ -3,7 +3,10 @@ that allow the client libraries to be linked with a non-GPL application, so long as the application is under a license approved by Oracle. For details see -http://www.mysql.com/about/legal/licensing/foss-exception/ +'The Universal FOSS Exception, Version 1.0': + https://oss.oracle.com/licenses/universal-foss-exception/ +A predecessor of that license exception is now deprecated 'FOSS License Exception': + http://www.mysql.com/about/legal/licensing/foss-exception/ Some innobase code from Percona and Google is under BSD license. Some code related to test-suite is under LGPLv2. From 111a259568b425474c90ee85b5ec328f143b879f Mon Sep 17 00:00:00 2001 From: Michal Schorm Date: Thu, 10 Apr 2025 11:15:44 +0200 Subject: [PATCH 02/11] [enhancement] Use %global instead of %define The other occurences are functions that are called with various arguments through the SPECfile. I tried to replace them too, but the resulting logic did not expanded correcly and resulted in various FTI issues. Related: RHEL-87738 --- mysql8.4.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mysql8.4.spec b/mysql8.4.spec index 95dce9e..1949c22 100644 --- a/mysql8.4.spec +++ b/mysql8.4.spec @@ -3,7 +3,7 @@ ExcludeArch: %{ix86} # Name of the package without any prefixes %global majorname mysql %global package_version 8.4.4 -%define majorversion %(echo %{package_version} | cut -d'.' -f1-2 ) +%global majorversion %(echo %{package_version} | cut -d'.' -f1-2 ) %global pkgnamepatch mysql From ce7a3be1da49d8b51390b24e64726131ea640dc1 Mon Sep 17 00:00:00 2001 From: Michal Schorm Date: Mon, 14 Apr 2025 13:14:27 +0200 Subject: [PATCH 03/11] Remove dependnecy on OpenSSL engines, which are deprecated in Fedora Related: RHEL-87738 --- mysql-openssl-engine.patch | 15 --------------- mysql8.4.spec | 6 ------ 2 files changed, 21 deletions(-) delete mode 100644 mysql-openssl-engine.patch diff --git a/mysql-openssl-engine.patch b/mysql-openssl-engine.patch deleted file mode 100644 index 28ced66..0000000 --- a/mysql-openssl-engine.patch +++ /dev/null @@ -1,15 +0,0 @@ -https://fedoraproject.org/wiki/Changes/OpensslDeprecateEngine -https://fedoraproject.org/wiki/Changes/OpensslNoEngine - ---- mysql-8.4.0/plugin/group_replication/libmysqlgcs/src/bindings/xcom/xcom/network/xcom_network_provider_ssl_native_lib.cc 2024-04-10 08:26:28.000000000 +0200 -+++ mysql-8.4.0/plugin/group_replication/libmysqlgcs/src/bindings/xcom/xcom/network/xcom_network_provider_ssl_native_lib.cc_patched 2024-07-18 18:33:26.237771364 +0200 -@@ -50,7 +50,9 @@ - #include "my_compiler.h" - #endif - -+#if !defined(OPENSSL_NO_ENGINE) - #include "openssl/engine.h" -+#endif - - #include "xcom/retry.h" - #include "xcom/task_debug.h" diff --git a/mysql8.4.spec b/mysql8.4.spec index 1949c22..62e81f9 100644 --- a/mysql8.4.spec +++ b/mysql8.4.spec @@ -145,7 +145,6 @@ Patch5: %{pkgnamepatch}-paths.patch Patch51: %{pkgnamepatch}-sharedir.patch Patch52: %{pkgnamepatch}-rpath.patch Patch56: %{pkgnamepatch}-flush-logrotate.patch -Patch57: %{pkgnamepatch}-openssl-engine.patch # Patches taken from boost 1.59 Patch112: boost-1.57.0-mpl-print.patch @@ -176,10 +175,6 @@ BuildRequires: libquadmath-devel %endif BuildRequires: openssl BuildRequires: openssl-devel -%if 0%{?fedora} >= 41 -# Complement of mysql-openssl-engine.patch -BuildRequires: openssl-devel-engine -%endif BuildRequires: perl-interpreter BuildRequires: perl-generators @@ -509,7 +504,6 @@ regression test suite distributed with the MySQL sources. %patch -P51 -p1 %patch -P52 -p1 %patch -P56 -p1 -%patch -P57 -p1 # Patch Boost pushd extra/boost/boost_$(echo %{boost_bundled_version}| tr . _) From 1c7250b9439c7d3fc770c3a9ad8f23ec51154c77 Mon Sep 17 00:00:00 2001 From: Pavol Sloboda Date: Fri, 2 May 2025 17:05:26 +0200 Subject: [PATCH 04/11] Rebase to 8.4.5 Upstream release notes: https://dev.mysql.com/doc/relnotes/mysql/8.4/en/news-8-4-5.html I have ran the extended testsuite during builds on f40-f43 on all architectures in 2 runs (that is 32 individual build logs parsed for the upcoming statistics) These are the statistics of the test results containing the number of times a test has failed and its name, the tests that fail because of a timeout are marked with `-- timed out`. Tests not marked with timeout failed on asserts. These tests are not added to the rh-skipped-test-lists-*.list. The results are split into all architectures together: 12 rpl.rpl_eventlog_psi_memory 12 rpl.rpl_channel_creation_under_replica_load 12 innodb_fts.optimize_big 11 innodb_fts.bug_34846823 -- timed out 10 perfschema.system_events_plugin 8 rpl_gtid.mysqldump_bug33630199 -- timed out 8 perfschema.system_events_component 7 sys_vars.myisam_data_pointer_size_func -- timed out 7 rpl.rpl_parallel_ddl_myisam 7 rpl.rpl_parallel_ddl_innodb 7 parts.partition_reverse_scan_icp -- timed out 7 innodb.multi_value_basic -- timed out 7 innodb.lob_recovery -- timed out 7 federated.federated_server -- timed out 5 rpl_gtid.rpl_perfschema_applier_status_by_worker_gtid_skipped_transaction_mts 3 perfschema.transaction_nested_events 3 innodb_undo.undo_settings 2 x.connection_not_alive 2 perfschema.relaylog The ppc64le architecture (since it had the most amount of failing tests by far and the same tests were failing there almost every time): 8 rpl.rpl_eventlog_psi_memory 8 rpl_gtid.mysqldump_bug33630199 -- timed out 7 sys_vars.myisam_data_pointer_size_func -- timed out 7 rpl.rpl_parallel_ddl_myisam 7 rpl.rpl_parallel_ddl_innodb 7 rpl.rpl_channel_creation_under_replica_load 7 perfschema.system_events_plugin 7 parts.partition_reverse_scan_icp -- timed out 7 innodb.multi_value_basic -- timed out 7 innodb.lob_recovery -- timed out 7 innodb_fts.optimize_big 7 innodb_fts.bug_34846823 -- timed out 7 federated.federated_server -- timed out 6 perfschema.system_events_component 4 rpl_gtid.rpl_perfschema_applier_status_by_worker_gtid_skipped_transaction_mts 2 innodb_undo.undo_settings And other architectures excluding ppc64le: 5 rpl.rpl_channel_creation_under_replica_load 5 innodb_fts.optimize_big 4 rpl.rpl_eventlog_psi_memory 4 innodb_fts.bug_34846823 -- timed out 3 perfschema.transaction_nested_events 3 perfschema.system_events_plugin 2 x.connection_not_alive 2 perfschema.system_events_component 2 perfschema.relaylog 1 rpl_gtid.rpl_perfschema_applier_status_by_worker_gtid_skipped_transaction_mts 1 innodb_undo.undo_settings Related: RHEL-87738 --- mysql8.4.spec | 9 ++++++--- sources | 2 +- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/mysql8.4.spec b/mysql8.4.spec index 62e81f9..32bec2f 100644 --- a/mysql8.4.spec +++ b/mysql8.4.spec @@ -2,7 +2,7 @@ ExcludeArch: %{ix86} # Name of the package without any prefixes %global majorname mysql -%global package_version 8.4.4 +%global package_version 8.4.5 %global majorversion %(echo %{package_version} | cut -d'.' -f1-2 ) %global pkgnamepatch mysql @@ -21,7 +21,7 @@ ExcludeArch: %{ix86} # The last version on which the full testsuite has been run # In case of further rebuilds of that version, don't require full testsuite to be run # run only "main" suite -%global last_tested_version 8.4.4 +%global last_tested_version 8.4.5 # Set to 1 to force run the testsuite even if it was already tested in current version %global force_run_testsuite 0 @@ -104,7 +104,7 @@ ExcludeArch: %{ix86} Name: %{majorname}%{majorversion} Version: %{package_version} -Release: 2%{?with_debug:.debug}%{?dist} +Release: 1%{?with_debug:.debug}%{?dist} Summary: MySQL client programs and shared libraries URL: http://www.mysql.com @@ -1125,6 +1125,9 @@ fi %endif %changelog +* Mon Apr 28 2025 Pavol Sloboda - 8.4.5-1 +- Rebase to 8.4.5 + * Fri Feb 14 2025 Michal Schorm - 8.4.4-2 - Rebuilt diff --git a/sources b/sources index 11ec673..1e98dee 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (mysql-8.4.4.tar.gz) = 21f4d8162f57f63a589e3e5e140f89a8cc61f4c55a77dce4601e76192eb3d3fbeaf3bfb78f91345c517ad36bf4267f33202693cfc24812841c517a24fffcfd12 +SHA512 (mysql-8.4.5.tar.gz) = d5353bbc618fb6ec3658773d834942f5bfd11f6f5d3fb4778aa684b970a6143d5e96919ba2311bfb00faf3882da307c62b9370aca8f41136ec129d5fa06bcf5c From 70be037a81de3610b64d36a8611173e720509904 Mon Sep 17 00:00:00 2001 From: Pavol Sloboda Date: Tue, 13 May 2025 14:36:54 +0200 Subject: [PATCH 05/11] Removed the mysql_plugin from the rm command when building without -client subpackage as mysql_plugin is deprecated from version 5.7.11 and has been removed in version 8.0 therefore it is no longer provided by upstream and it caused build failures when rm could not find it. Related: RHEL-104250 --- mysql8.4.spec | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mysql8.4.spec b/mysql8.4.spec index 32bec2f..aaac2ba 100644 --- a/mysql8.4.spec +++ b/mysql8.4.spec @@ -716,10 +716,10 @@ rm %{buildroot}%{_mandir}/man1/mysql_config.1* %if ! %{with client} rm %{buildroot}%{_bindir}/{mysql,mysql_config_editor,\ -mysql_plugin,mysqladmin,mysqlbinlog,\ +mysqladmin,mysqlbinlog,\ mysqlcheck,mysqldump,mysqlimport,mysqlshow,mysqlslap,my_print_defaults} rm %{buildroot}%{_mandir}/man1/{mysql,mysql_config_editor,\ -mysql_plugin,mysqladmin,mysqlbinlog,\ +mysqladmin,mysqlbinlog,\ mysqlcheck,mysqldump,mysqlimport,mysqlshow,mysqlslap,my_print_defaults}.1* %endif From 509086ab6f0e42e92872042cae1ec72f98b66657 Mon Sep 17 00:00:00 2001 From: Pavol Sloboda Date: Wed, 14 May 2025 15:50:06 +0200 Subject: [PATCH 06/11] Stopped removing the my_print_defaults when client is not built as it is required by the server subpackage thus removing it when the client subpackage is not being built will result in a build failure. Related: RHEL-104250 --- mysql8.4.spec | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mysql8.4.spec b/mysql8.4.spec index aaac2ba..bd539fe 100644 --- a/mysql8.4.spec +++ b/mysql8.4.spec @@ -717,10 +717,10 @@ rm %{buildroot}%{_mandir}/man1/mysql_config.1* %if ! %{with client} rm %{buildroot}%{_bindir}/{mysql,mysql_config_editor,\ mysqladmin,mysqlbinlog,\ -mysqlcheck,mysqldump,mysqlimport,mysqlshow,mysqlslap,my_print_defaults} +mysqlcheck,mysqldump,mysqlimport,mysqlshow,mysqlslap} rm %{buildroot}%{_mandir}/man1/{mysql,mysql_config_editor,\ mysqladmin,mysqlbinlog,\ -mysqlcheck,mysqldump,mysqlimport,mysqlshow,mysqlslap,my_print_defaults}.1* +mysqlcheck,mysqldump,mysqlimport,mysqlshow,mysqlslap}.1* %endif %if %{with config} From 5501d7be555dd4cb9221003c33d3e35c50250f44 Mon Sep 17 00:00:00 2001 From: Michal Schorm Date: Wed, 9 Jul 2025 09:56:19 +0200 Subject: [PATCH 07/11] [Fix for Fedora Change] Fix versioned layout macros - cover both arch and noarch sub-packages - add obsoletes against the older versions to the distribution default version Related: RHEL-104250 --- mysql8.4.spec | 40 ++++++++++++++++++++++++++-------------- 1 file changed, 26 insertions(+), 14 deletions(-) diff --git a/mysql8.4.spec b/mysql8.4.spec index bd539fe..147e942 100644 --- a/mysql8.4.spec +++ b/mysql8.4.spec @@ -104,7 +104,7 @@ ExcludeArch: %{ix86} Name: %{majorname}%{majorversion} Version: %{package_version} -Release: 1%{?with_debug:.debug}%{?dist} +Release: 2%{?with_debug:.debug}%{?dist} Summary: MySQL client programs and shared libraries URL: http://www.mysql.com @@ -265,20 +265,32 @@ Conflicts: %{majorname}%{?1:-%{1}}-any\ # Provide also mysqlX.X if default %if %?mysql_default -%define mysqlX_if_default() %{expand:\ +%define mysqlX_if_default_arched() %{expand:\ +Obsoletes: mysql%{?1:-%{1}} < %{sameevr}\ +Obsoletes: mysql%{majorversion}%{?1:-%{1}} < %{sameevr}\ Provides: mysql%{majorversion}%{?1:-%{1}} = %{sameevr}\ Provides: mysql%{majorversion}%{?1:-%{1}}%{?_isa} = %{sameevr}\ } +%define mysqlX_if_default_noarch() %{expand:\ +Obsoletes: mysql%{?1:-%{1}} < %{sameevr}\ +Obsoletes: mysql%{majorversion}%{?1:-%{1}} < %{sameevr}\ +Provides: mysql%{majorversion}%{?1:-%{1}} = %{sameevr}\ +} %else -%define mysqlX_if_default() %{nil} +%define mysqlX_if_default_arched() %{nil} +%define mysqlX_if_default_noarch() %{nil} %endif -%define add_metadata() %{expand:\ +%define add_metadata_arched() %{expand:\ %conflict_with_other_streams %{**}\ -%mysqlX_if_default %{**}\ +%mysqlX_if_default_arched %{**}\ +} +%define add_metadata_noarch() %{expand:\ +%conflict_with_other_streams %{**}\ +%mysqlX_if_default_noarch %{**}\ } -%add_metadata +%add_metadata_arched %description MySQL is a multi-user, multi-threaded SQL database server. MySQL is a @@ -302,7 +314,7 @@ Requires: %{pkgname}-common = %{sameevr} %{?with_provides_community_mysql:Provides: community-mysql-libs%{?_isa}= %community_mysql_version} %{?with_obsoletes_community_mysql:Obsoletes: community-mysql-libs <= %obsolete_community_mysql_version} -%add_metadata libs +%add_metadata_arched libs %description -n %{pkgname}-libs The mysql-libs package provides the essential shared libraries for any @@ -319,7 +331,7 @@ Summary: The config files required by server and client %{?with_provides_community_mysql:Provides: community-mysql-config%{?_isa} = %community_mysql_version} %{?with_obsoletes_community_mysql:Obsoletes: community-mysql-config <= %obsolete_community_mysql_version} -%add_metadata config +%add_metadata_arched config %description -n %{pkgname}-config The package provides the config file my.cnf and my.cnf.d directory used by any @@ -342,7 +354,7 @@ Requires: %{_sysconfdir}/my.cnf %{?with_obsoletes_community_mysql:Obsoletes: community-mysql-common <= %obsolete_community_mysql_version} # As this package is noarch, it can't use the %%{?_isa} RPM macro -%conflict_with_other_streams common +%add_metadata_noarch common %description -n %{pkgname}-common The mysql-common package provides the essential shared files for any @@ -360,7 +372,7 @@ Requires: %{pkgname}-common = %{sameevr} %{?with_obsoletes_community_mysql:Obsoletes: community-mysql-errmsg <= %obsolete_community_mysql_version} # As this package is noarch, it can't use the %%{?_isa} RPM macro -%conflict_with_other_streams errmsg +%add_metadata_noarch errmsg %description -n %{pkgname}-errmsg The package provides error messages files for the MySQL daemon @@ -409,7 +421,7 @@ Suggests: logrotate %{?with_provides_community_mysql:Provides: community-mysql-server%{?_isa} = %community_mysql_version} %{?with_obsoletes_community_mysql:Obsoletes: community-mysql-server <= %obsolete_community_mysql_version} -%add_metadata server +%add_metadata_arched server %description -n %{pkgname}-server MySQL is a multi-user, multi-threaded SQL database server. MySQL is a @@ -431,7 +443,7 @@ Requires: libzstd-devel %{?with_provides_community_mysql:Provides: community-mysql-devel%{?_isa} = %community_mysql_version} %{?with_obsoletes_community_mysql:Obsoletes: community-mysql-devel <= %obsolete_community_mysql_version} -%add_metadata devel +%add_metadata_arched devel %description -n %{pkgname}-devel MySQL is a multi-user, multi-threaded SQL database server. This @@ -473,7 +485,7 @@ Requires: perl(File::Compare) %{?with_provides_community_mysql:Provides: community-mysql-test%{?_isa} = %community_mysql_version} %{?with_obsoletes_community_mysql:Obsoletes: community-mysql-test <= %obsolete_community_mysql_version} -%add_metadata test +%add_metadata_arched test %description -n %{pkgname}-test MySQL is a multi-user, multi-threaded SQL database server. This @@ -486,7 +498,7 @@ BuildArch: noarch Requires: %{pkgname}-test = %{sameevr} # As this package is noarch, it can't use the %%{?_isa} RPM macro -%conflict_with_other_streams test-data +%add_metadata_noarch test-data %description -n %{pkgname}-test-data MySQL is a multi-user, multi-threaded SQL database server. This From 221864b470667de063d348b1772f021d0d295fcf Mon Sep 17 00:00:00 2001 From: Pavol Sloboda Date: Thu, 24 Jul 2025 14:10:47 +0200 Subject: [PATCH 08/11] Rebase to 8.4.6 Upstream release notes: https://dev.mysql.com/doc/relnotes/mysql/8.4/en/news-8-4-6.html Related: RHEL-104250 --- mysql-paths.patch | 49 +++++++++++++++++------------------------------ mysql8.4.spec | 7 +++++-- sources | 2 +- 3 files changed, 24 insertions(+), 34 deletions(-) diff --git a/mysql-paths.patch b/mysql-paths.patch index d5978b6..e68d8bf 100644 --- a/mysql-paths.patch +++ b/mysql-paths.patch @@ -3,32 +3,21 @@ Software Collections. Removing these hard-coded paths should fix it. Upstream report: https://mariadb.atlassian.net/browse/MDEV-6485 -diff --git a/cmake/install_layout.cmake b/cmake/install_layout.cmake -index 9f7945d8..6734cdfd 100644 ---- a/cmake/install_layout.cmake -+++ b/cmake/install_layout.cmake -@@ -105,7 +105,7 @@ IF(UNIX) - " Choose between ${VALID_INSTALL_LAYOUTS}" ) - ENDIF() - -- SET(SYSCONFDIR "${CMAKE_INSTALL_PREFIX}/etc" -+ SET(SYSCONFDIR "/etc" - CACHE PATH "config directory (for my.cnf)") - MARK_AS_ADVANCED(SYSCONFDIR) +diff -Naur mysql-8.4.6/cmake/install_layout.cmake mysql-8.4.6_patched/cmake/install_layout.cmake +--- mysql-8.4.6/cmake/install_layout.cmake 2025-07-10 16:20:26.000000000 +0200 ++++ mysql-8.4.6_patched/cmake/install_layout.cmake 2025-07-23 09:50:42.278223154 +0200 +@@ -202,6 +202,7 @@ + ELSE() + SET(INSTALL_SBINDIR_RPM "sbin") ENDIF() -@@ -189,6 +189,7 @@ SET(INSTALL_SECURE_FILE_PRIVDIR_TARGZ ${secure_file_priv_path}) - # - SET(INSTALL_BINDIR_RPM "bin") - SET(INSTALL_SBINDIR_RPM "sbin") +SET(INSTALL_SYSCONFDIR_RPM "/etc") # IF(CMAKE_SYSTEM_PROCESSOR IN_LIST KNOWN_64BIT_ARCHITECTURES) SET(INSTALL_LIBDIR_RPM "lib64/mysql") -diff --git a/mysys/my_default.cc b/mysys/my_default.cc -index 290f1666..8403425f 100644 ---- a/mysys/my_default.cc -+++ b/mysys/my_default.cc -@@ -1570,12 +1570,12 @@ static const char **init_default_directories(MEM_ROOT *alloc) { +diff -Naur mysql-8.4.6/mysys/my_default.cc mysql-8.4.6_patched/mysys/my_default.cc +--- mysql-8.4.6/mysys/my_default.cc 2025-07-10 16:20:26.000000000 +0200 ++++ mysql-8.4.6_patched/mysys/my_default.cc 2025-07-23 09:52:21.494414633 +0200 +@@ -1693,12 +1693,12 @@ #else @@ -44,11 +33,10 @@ index 290f1666..8403425f 100644 #endif /* DEFAULT_SYSCONFDIR */ #endif -diff --git a/scripts/CMakeLists.txt b/scripts/CMakeLists.txt -index 4149a764..b091d5e2 100644 ---- a/scripts/CMakeLists.txt -+++ b/scripts/CMakeLists.txt -@@ -288,9 +288,9 @@ IF(UNIX) +diff -Naur mysql-8.4.6/scripts/CMakeLists.txt mysql-8.4.6_patched/scripts/CMakeLists.txt +--- mysql-8.4.6/scripts/CMakeLists.txt 2025-07-10 16:20:26.000000000 +0200 ++++ mysql-8.4.6_patched/scripts/CMakeLists.txt 2025-07-23 09:53:30.114124746 +0200 +@@ -331,9 +331,9 @@ ENDIF(UNIX) SET(prefix "${CMAKE_INSTALL_PREFIX}") @@ -60,11 +48,10 @@ index 4149a764..b091d5e2 100644 SET(datadir ${prefix}/${INSTALL_MYSQLSHAREDIR}) SET(libsubdir ${INSTALL_LIBDIR}) SET(pkgincludedir ${prefix}/${INSTALL_INCLUDEDIR}) -diff --git a/scripts/mysqld_multi.pl.in b/scripts/mysqld_multi.pl.in -index 84dd4d7c..50397ddd 100644 ---- a/scripts/mysqld_multi.pl.in -+++ b/scripts/mysqld_multi.pl.in -@@ -586,9 +586,7 @@ sub list_defaults_files +diff -Naur mysql-8.4.6/scripts/mysqld_multi.pl.in mysql-8.4.6_patched/scripts/mysqld_multi.pl.in +--- mysql-8.4.6/scripts/mysqld_multi.pl.in 2025-07-10 16:20:26.000000000 +0200 ++++ mysql-8.4.6_patched/scripts/mysqld_multi.pl.in 2025-07-23 09:54:16.090991270 +0200 +@@ -587,9 +587,7 @@ my %seen; # Don't list the same file more than once return grep { defined $_ and not $seen{$_}++ and -f $_ and -r $_ } diff --git a/mysql8.4.spec b/mysql8.4.spec index 147e942..e49cfad 100644 --- a/mysql8.4.spec +++ b/mysql8.4.spec @@ -2,7 +2,7 @@ ExcludeArch: %{ix86} # Name of the package without any prefixes %global majorname mysql -%global package_version 8.4.5 +%global package_version 8.4.6 %global majorversion %(echo %{package_version} | cut -d'.' -f1-2 ) %global pkgnamepatch mysql @@ -21,7 +21,7 @@ ExcludeArch: %{ix86} # The last version on which the full testsuite has been run # In case of further rebuilds of that version, don't require full testsuite to be run # run only "main" suite -%global last_tested_version 8.4.5 +%global last_tested_version 8.4.6 # Set to 1 to force run the testsuite even if it was already tested in current version %global force_run_testsuite 0 @@ -1137,6 +1137,9 @@ fi %endif %changelog +* Thu Jul 24 2025 Pavol Sloboda - 8.4.6-1 +- Rebase to 8.4.6 + * Mon Apr 28 2025 Pavol Sloboda - 8.4.5-1 - Rebase to 8.4.5 diff --git a/sources b/sources index 1e98dee..458e60b 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (mysql-8.4.5.tar.gz) = d5353bbc618fb6ec3658773d834942f5bfd11f6f5d3fb4778aa684b970a6143d5e96919ba2311bfb00faf3882da307c62b9370aca8f41136ec129d5fa06bcf5c +SHA512 (mysql-8.4.6.tar.gz) = 2d498dc71eeede4368bd70fb1d1c012abd774732e341312f469afa3823c3b37489032b3290fa7531fb78c2b36251dbd1b8e1554c9330e18e56407f96fb8d4a1e From b74fea14e5ad12978296b2deaeac62bbaa63e862 Mon Sep 17 00:00:00 2001 From: Michal Schorm Date: Fri, 1 Aug 2025 09:35:57 +0200 Subject: [PATCH 09/11] [bugfix] Fix the 'Conflicts:' with MariaDB packages The package conflicts between MariaDB and MySQL packages are only set against the un-versioned names. (the un-versioned names are only provided by the distribution default version) The conflicts has to be extended to cover the '-any' virtually provided names, which are provided by all versions of the versioned packages. Related: RHEL-104250 --- mysql8.4.spec | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/mysql8.4.spec b/mysql8.4.spec index e49cfad..4f64f36 100644 --- a/mysql8.4.spec +++ b/mysql8.4.spec @@ -251,9 +251,9 @@ Provides: bundled(rapidjson) # https://github.com/martinus/unordered_dense Provides: bundled(unordered_dense) -%{?with_conflicts_mariadb:Conflicts: mariadb} +%{?with_conflicts_mariadb:Conflicts: mariadb-any} # Explicitly disallow installation of mysql + mariadb-server -%{?with_conflicts_mariadb:Conflicts: mariadb-server} +%{?with_conflicts_mariadb:Conflicts: mariadb-server-any} %{?with_provides_community_mysql:Provides: community-mysql = %community_mysql_version} %{?with_provides_community_mysql:Provides: community-mysql%{?_isa} = %community_mysql_version} %{?with_obsoletes_community_mysql:Obsoletes: community-mysql <= %obsolete_community_mysql_version} @@ -412,11 +412,11 @@ Requires: (mysql-selinux if selinux-policy-targeted) Suggests: logrotate -%{?with_conflicts_mariadb:Conflicts: mariadb-server} -%{?with_conflicts_mariadb:Conflicts: mariadb-server-utils} -%{?with_conflicts_mariadb:Conflicts: mariadb-server-galera} +%{?with_conflicts_mariadb:Conflicts: mariadb-server-any} +%{?with_conflicts_mariadb:Conflicts: mariadb-server-utils-any} +%{?with_conflicts_mariadb:Conflicts: mariadb-server-galera-any} # Explicitly disallow installation of mysql + mariadb-server -%{?with_conflicts_mariadb:Conflicts: mariadb} +%{?with_conflicts_mariadb:Conflicts: mariadb-any} %{?with_provides_community_mysql:Provides: community-mysql-server = %community_mysql_version} %{?with_provides_community_mysql:Provides: community-mysql-server%{?_isa} = %community_mysql_version} %{?with_obsoletes_community_mysql:Obsoletes: community-mysql-server <= %obsolete_community_mysql_version} @@ -437,7 +437,7 @@ Summary: Files for development of MySQL applications Requires: openssl-devel Requires: zlib-devel Requires: libzstd-devel -%{?with_conflicts_mariadb:Conflicts: mariadb-devel} +%{?with_conflicts_mariadb:Conflicts: mariadb-devel-any} %{?with_conflicts_mariadb:Conflicts: mariadb-connector-c-devel} %{?with_provides_community_mysql:Provides: community-mysql-devel = %community_mysql_version} %{?with_provides_community_mysql:Provides: community-mysql-devel%{?_isa} = %community_mysql_version} @@ -480,7 +480,7 @@ Requires: perl(Test::More) Requires: perl(Time::HiRes) Requires: perl(File::Compare) -%{?with_conflicts_mariadb:Conflicts: mariadb-test} +%{?with_conflicts_mariadb:Conflicts: mariadb-test-any} %{?with_provides_community_mysql:Provides: community-mysql-test = %community_mysql_version} %{?with_provides_community_mysql:Provides: community-mysql-test%{?_isa} = %community_mysql_version} %{?with_obsoletes_community_mysql:Obsoletes: community-mysql-test <= %obsolete_community_mysql_version} From a094014ba0d01f04f1fe415e13614c58b4d40766 Mon Sep 17 00:00:00 2001 From: Michal Schorm Date: Wed, 6 Aug 2025 10:28:35 +0200 Subject: [PATCH 10/11] [Licenses] Review of the package licenses MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The project contains tens of thousands mentions in various formats of various licenses in various formats. I did what I could, but there certainly is a space for improvement. I hope the following description of my steps may serve as a solid justification of my findings. =========== =========== =========== =========== =========== =========== GPL & LGPL There is a difference between "GPL-2.0-only" and "GPL-2.0-or-later" https://spdx.org/licenses/GPL-2.0-only.html https://spdx.org/licenses/GPL-2.0-or-later.html I understood that the license text is identical (I've ran 'diff' on top of them to verify) and the difference is decided by the license header present in the files containing the code itself. This "*-only" and "*-or-later" differenciation simmilar in other versions of GPL and LGLP I like GREP. SO here we go: \# This command is supposed to: \# - find all occurrences of the string "Public License" \# - prefixed by "GNU", "Lesser", "Library", "General", each word is optional (to match both GPL and LGPL and all variants of how people write them) \# - while every word can have any number of any white characters - including newlines - between them (to match text wrapped between lines) \# - all of that followed by string "version" (to only match text mentioning the specific version) \# - with any characters between the first part and the "version" string \# - followed by a digit (to exclude any result not talking about a concrete version specifically, e.g. text around string "from time to time" in the GPL licenses) \# - match 3 more characters (so we catch the whole version number) \# - but the "version" string and number must occur no later than any dot "." or double newline (to only match text inside the license texts or license headers, but not code) \# Once found, \# - and match everything until dot or double newline (for further parsing of the strings "or later" etc) \# - replace any newline with space (" "), so the whole above match (as well s everything else) is put on a single line \# - replace string in the variable DIR_NAME with the same string prepended by newline, so each result is on a separate line ❯ export DIR_NAME="mysql-8.4.6" ❯ export TMPFILE=$(mktemp) ❯ grep -Pzoi '(?s)((GNU\s*)?(Lesser\s*)?(Library\s*)?(General\s*)?Public\s*License)(?:(?!\.\n|\n\n).)*?version\s*\d[\s\S]{0,3}(?:(?!\.\n|\n\n).)*' -r "${DIR_NAME}" | sed ':a;N;$!ba;s/\n/ /g' | sed "s|${DIR_NAME}/|\n${DIR_NAME}/|g" > ${TMPFILE} The resulting file contains 17894 results. =========== =========== =========== ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 3" | tee >(wc -l) retuns 10 results, from which: ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 3" | grep -i --binary-files=text -e " lesser" -e " library" | tee >(wc -l) 0 is LGPL and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 3" | grep -v -i --binary-files=text -e " lesser" -e " library" | tee >(wc -l) 10 is GPL and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 3" | grep -i --binary-files=text -e "later" -e " or" | tee >(wc -l) 10 results "GPL-3.0-or-later" and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 3" | grep -i --binary-files=text -e "later" -e " or" | tee >(wc -l) 0 results "GPL-3.0-only" =========== =========== =========== ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | tee >(wc -l) retuns 17879 results, from which: ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -i --binary-files=text -e " lesser" -e " library" | tee >(wc -l) 15 is LGPL and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -v -i --binary-files=text -e " lesser" -e " library" | tee >(wc -l) 17864 is GPL and =========== =========== =========== ❯ cat ${TMPFILE} | grep -i --binary-files=text -e "version 2" | grep -i --binary-files=text -e " lesser" -e " library" | grep -i --binary-files=text -e "version 2[ ,;\<]" -e "version 2.0" | tee >(wc -l) 12 is LGPL 2.0 and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -i --binary-files=text -e " lesser" -e " library" | grep -i --binary-files=text -e "version 2[ ,;\<]" -e "version 2.0" | grep -i --binary-files=text -e "later" -e " or " | tee >(wc -l) 0 is "LGPL-2.0-or-later" and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -i --binary-files=text -e " lesser" -e " library" | grep -i --binary-files=text -e "version 2[ ,;\<]" -e "version 2.0" | grep -v -i --binary-files=text -e "later" -e " or " | tee >(wc -l) 12 is "LGPL-2.0-only" and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -i --binary-files=text -e " lesser" -e " library" | grep -i --binary-files=text -e "version 2\.[^0]" | tee >(wc -l) 3 is LGPL 2.1 and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -i --binary-files=text -e " lesser" -e " library" | grep -i --binary-files=text -e "version 2\.[^0]" | grep -i --binary-files=text -e "later" -e " or " | tee >(wc -l) 2 is "LGPL-2.1-or-later" both findings are in the 'LICENSE' file. However that doesn't necessiraly interests me, as the 'LICENSE' file is a list of just potential licenses. and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -i --binary-files=text -e " lesser" -e " library" | grep -i --binary-files=text -e "version 2\.[^0]" | grep -v -i --binary-files=text -e "later" -e " or " | tee >(wc -l) 1 is "LGPL-2.1-only" the finding is in the 'LICENSE' file. =========== =========== =========== ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -v -i --binary-files=text -e " lesser" -e " library" | grep -i --binary-files=text -e "version 2[ ,;\<]" -e "version 2.[0\s]" -e "version 2.\s" | tee >(wc -l) 17862 is GPL 2.0 and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -v -i --binary-files=text -e " lesser" -e " library" | grep -i --binary-files=text -e "version 2[ ,;\<]" -e "version 2.[0\s]" -e "version 2.\s" | grep -i --binary-files=text -e "later" -e " or " | tee >(wc -l) 33 is "GPL-2.0-or-later" found in: extra/gperftools/ extra/libbacktrace/ router/ and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -v -i --binary-files=text -e " lesser" -e " library" | grep -i --binary-files=text -e "version 2[ ,;\<]" -e "version 2.[0\s]" -e "version 2.\s" | grep -v -i --binary-files=text -e "later" -e " or " | tee >(wc -l) 17829 is "GPL-2.0-only" ~190 unique files with the FOSS 1.0 exception ~9500 unique files without it and ❯ cat ${TMPFILE} | grep -i --binary-files=text "version 2" | grep -v -i --binary-files=text -e " lesser" -e " library" | grep -i --binary-files=text -e "version 2\.[123456789]" | tee >(wc -l) 2 GPL 2.1 weird ... GPL 2.1 doesn't exists, only LGPL 2.1 does and by examining the files, both are false positives, as the text matched was: "The OpenLDAP Public License Version 2.8, 17 August 2003" =========== =========== =========== These were the GPL-family licenses. =========== =========== =========== =========== =========== =========== Now I tired a search that omits any GPL-family license to see what remained. ❯ grep -i licens -r "${DIR_NAME}/" | \ grep -v \ -e "// This source code is licensed under both the GPLv2 (found in the" \ -e "// COPYING file in the root directory) and Apache 2.0 License" \ -e "// (found in the LICENSE.Apache file in the root directory)." \ -e "// Use of this source code is governed by a BSD-style license that can be" \ -e "// found in the LICENSE file. See the AUTHORS file for names of contributors." \ -e "it under the terms of the GNU General Public License as published by" \ -e "the Free Software Foundation; version 2 of the License." \ -e "GNU General Public License for more details." \ -e "You should have received a copy of the GNU General Public License" \ -e "it under the terms of the GNU General Public License, version 2.0," \ -e "but not limited to OpenSSL) that is licensed under separate terms," \ -e "as designated in a particular file or component or in included license" \ -e "separately licensed software that they have included with MySQL." \ -e "GNU General Public License, version 2.0, for more details." \ -e "License as published by the Free Software Foundation; either" \ -e "version 2.1 of the License, or (at your option) any later version." \ -e "Lesser General Public License for more details." \ -e "License along with this library; if not, write to the Free Software" \ -e "License version 2.1 as published by the Free Software Foundation." \ -e "the terms of the GNU General Public License as published by the Free Software" \ -e "License along with this library; if not, write to the Free" \ -e "version 2 of the License, or (at your option) any later version." \ -e "Library General Public License for more details." \ -e "License along with this library; if not see " \ -e "GNU General Public License, version 2.0" \ | grep -i "licens" > ${TMPFILE} Which yelds 33132 results to go through. This is tremendously attention demanding, and likely place for oversights. I've managed to discover the following: =========== =========== =========== ❯ cat ${TMPFILE} | grep -i -e "separately licensed software that they have either included with" | wc -l 9347 This is the Universal-FOSS-exception-1.0. I had to check which licenses are these exceptions connected to. I found it connected to "GPL-2.0-only". Around 190 "GPL-2.0-only" licensed files have the exception, while around 9500 "LGPL-2.0-only" licensed files does not have it. I found that all "LGPL-2.0-only" license files also have the exception. =========== =========== =========== ❯ cat ${TMPFILE} | grep -i -e "www.boost.org/LICENSE_" -e "See accompanying file LICENSE_1_0.txt" -e "Version 1.0. (See accompanying file" -e "accompanying file LICENSE_1_0.txt" -e "Boost Software License" -e "http://www.boost.org/users/license.html" | wc -l 21337 The "BSL-1.0" license =========== =========== =========== ❯ cat ${TMPFILE} | grep -i -e "apache license" mysql-8.4.6/storage/ndb/test/crund/src/META-INF/persistence.xml: to you under the Apache License, Version 2.0 (the mysql-8.4.6/storage/ndb/test/crund/src/META-INF/persistence.xml: http://www.apache.org/licenses/LICENSE-2.0 The "Apache-2.0" licnese =========== =========== =========== ❯ cat ${TMPFILE} | grep -v -i -e "www.boost.org/LICENSE_" -e "See accompanying file LICENSE_1_0.txt" -e "Version 1.0. (See accompanying file" -e "accompanying file LICENSE_1_0.txt" -e "Boost Software License" -e "http://www.boost.org/users/license.html" | grep -v -i -e "apache" | grep -e "MIT" The "MIT" license =========== =========== =========== ❯ cat ${TMPFILE} | grep -v -i -e "www.boost.org/LICENSE_" -e "See accompanying file LICENSE_1_0.txt" -e "Version 1.0. (See accompanying file" -e "accompanying file LICENSE_1_0.txt" -e "Boost Software License" -e "http://www.boost.org/users/license.html" | grep -v -i -e "apache" | grep -v -e "MIT" | grep -e "BSD" The "BSD-2-Clause" License =========== =========== =========== ❯ cat ${TMPFILE} | grep -v -i -e "www.boost.org/LICENSE_" -e "See accompanying file LICENSE_1_0.txt" -e "Version 1.0. (See accompanying file" -e "accompanying file LICENSE_1_0.txt" -e "Boost Software License" -e "http://www.boost.org/users/license.html" | grep -v -i -e "apache" | grep -v -e "MIT" | grep -i -e "dual license" mysql-8.4.6/storage/innobase/ut/crc32.cc: Dual licensed under BSD license and GPLv2. The "( GPL-2.0-only OR BSD-2-Clause )" license =========== =========== =========== I hope I caught all of the licenses. If that's not the case, please contribute a fix or at least report a bug against this package so we can correct it. Related: RHEL-104250 --- mysql8.4.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mysql8.4.spec b/mysql8.4.spec index 4f64f36..8010536 100644 --- a/mysql8.4.spec +++ b/mysql8.4.spec @@ -108,9 +108,9 @@ Release: 2%{?with_debug:.debug}%{?dist} Summary: MySQL client programs and shared libraries URL: http://www.mysql.com -# Exceptions allow client libraries to be linked with most open source SW, -# not only GPL code. See README.mysql-license -License: GPL-2.0-or-later AND LGPL-2.1-only AND BSL-1.0 AND BSD-2-Clause +# The the `Universal-FOSS-exception-1.0` exception allow client libraries to be linked with most open source SW, not only GPL code. +# Usage of the `Universal-FOSS-exception-1.0` in the SPDX license expression does not signify that we regard "Interfaces" as protected by copyright. +License: GPL-2.0-only AND ( GPL-2.0-only WITH Universal-FOSS-exception-1.0 ) AND GPL-2.0-or-later AND ( LGPL-2.0-only WITH Universal-FOSS-exception-1.0 ) AND ( GPL-3.0-or-later WITH Bison-exception-2.2 ) AND ( GPL-2.0-only OR BSD-2-Clause ) AND BSD-2-Clause AND BSL-1.0 AND Apache-2.0 AND MIT Source0: https://cdn.mysql.com/Downloads/MySQL-8.4/mysql-%{version}.tar.gz Source2: mysql_config_multilib.sh From 670b865cb275dadafbdbc492277f8f9b75d8f75e Mon Sep 17 00:00:00 2001 From: Pavol Sloboda Date: Wed, 6 Aug 2025 08:51:52 +0000 Subject: [PATCH 11/11] [bugfix] Fix packaging of the default MySQL server log We've received a bug report, that the 'rpm -qc' incorrectly returns the MySQL server default log file '/var/log/mysql/mysqld.log' as a configuration file. https://issues.redhat.com/browse/RHEL-57601 This was caused by us packing it in the SPECfile '%files' section with the '%config %ghost' directives. The reason was historical. We tried to mark the file as owned by the package, but at the same time to not pack it, and also prevent its deleteion on package removal. The correct way is to not list the file at all. The parent directory is properly packed and owned instead (already), so it should be clear that the files inside are associated with that package. This is how we already do it with the DB datadir '/var/lib/mysql'. Resolves: RHEL-112386 While investigating this issue, we also reviewed the log file creation. The log file is created automatically by the MySQL server when needed. This can even happen in the middle of the server runtime, when the file is (re)moved, and the DB server is tasked to flush the logs. I checked the MySQL server documentation, and tested it, and I found, that the logfile is indeed created by the server. The only possible reason why the file might be needed to be created beforehand, is when the file lies on a location to which the MySQL server won't have permissions to write to. This is likely the case of MySQL upstream RPMs, which place it by default to the '/var/log': https://github.com/mysql/mysql-server/blob/96d58aa2b9a65aa1622f57aa943a336711fdb600/packaging/rpm-fedora/mysql.spec.in#L703 However Fedora and RHEL uses a designated directory '/var/log/mysql', which is owened by 'mysql:mysql', so the issue does not exists here. --- mysql8.4.spec | 4 ---- 1 file changed, 4 deletions(-) diff --git a/mysql8.4.spec b/mysql8.4.spec index 8010536..771aa7d 100644 --- a/mysql8.4.spec +++ b/mysql8.4.spec @@ -818,9 +818,6 @@ popd %post -n %{pkgname}-server %systemd_post %{daemon_name}.service -if [ ! -e "%{logfile}" -a ! -h "%{logfile}" ] ; then - install /dev/null -m0640 -omysql -gmysql "%{logfile}" -fi %preun -n %{pkgname}-server %systemd_preun %{daemon_name}.service @@ -1001,7 +998,6 @@ fi %attr(0700,mysql,mysql) %dir %{_localstatedir}/lib/mysql-keyring %attr(0755,mysql,mysql) %dir %{pidfiledir} %attr(0750,mysql,mysql) %dir %{logfiledir} -%attr(0640,mysql,mysql) %config %ghost %verify(not md5 size mtime) %{logfile} %config(noreplace) %{logrotateddir}/%{daemon_name} %if %{with devel}