diff --git a/.gitignore b/.gitignore index d836308..28f1300 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -SOURCES/mysql-boost-8.0.13.tar.gz +SOURCES/mysql-boost-8.0.17.tar.gz diff --git a/.rh-mysql80-mysql.metadata b/.rh-mysql80-mysql.metadata index e43b40f..b695da0 100644 --- a/.rh-mysql80-mysql.metadata +++ b/.rh-mysql80-mysql.metadata @@ -1 +1 @@ -c4109cb99c1a70d1d1bb54a9934f44c68b51dad3 SOURCES/mysql-boost-8.0.13.tar.gz +8395df42d93e2030fcef862bb096831b24ed5c28 SOURCES/mysql-boost-8.0.17.tar.gz diff --git a/SOURCES/mysql-paths.patch b/SOURCES/mysql-paths.patch index 078782f..a27ca7a 100644 --- a/SOURCES/mysql-paths.patch +++ b/SOURCES/mysql-paths.patch @@ -3,11 +3,10 @@ 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 f5ac0bf2..cd3132de 100644 ---- a/cmake/install_layout.cmake -+++ b/cmake/install_layout.cmake -@@ -114,7 +114,7 @@ IF(UNIX) +diff -up mysql-8.0.17/cmake/install_layout.cmake.patch5 mysql-8.0.17/cmake/install_layout.cmake +--- mysql-8.0.17/cmake/install_layout.cmake.patch5 2019-06-25 12:23:30.000000000 +0200 ++++ mysql-8.0.17/cmake/install_layout.cmake 2019-07-22 19:07:56.476692609 +0200 +@@ -115,7 +115,7 @@ IF(UNIX) " Choose between ${VALID_INSTALL_LAYOUTS}" ) ENDIF() @@ -16,7 +15,7 @@ index f5ac0bf2..cd3132de 100644 CACHE PATH "config directory (for my.cnf)") MARK_AS_ADVANCED(SYSCONFDIR) ENDIF() -@@ -318,6 +318,7 @@ SET(INSTALL_SECURE_FILE_PRIVDIR_TARGZ ${secure_file_priv_path}) +@@ -319,6 +319,7 @@ SET(INSTALL_SECURE_FILE_PRIVDIR_TARGZ ${ # SET(INSTALL_BINDIR_RPM "bin") SET(INSTALL_SBINDIR_RPM "sbin") @@ -24,11 +23,10 @@ index f5ac0bf2..cd3132de 100644 # IF(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64") SET(INSTALL_LIBDIR_RPM "lib64") -diff --git a/mysys_ssl/my_default.cc b/mysys_ssl/my_default.cc -index 1317e362..cfa0feb7 100644 ---- a/mysys_ssl/my_default.cc -+++ b/mysys_ssl/my_default.cc -@@ -1570,12 +1570,12 @@ static const char **init_default_directories(MEM_ROOT *alloc) { +diff -up mysql-8.0.17/mysys/my_default.cc.patch5 mysql-8.0.17/mysys/my_default.cc +--- mysql-8.0.17/mysys/my_default.cc.patch5 2019-06-25 12:23:30.000000000 +0200 ++++ mysql-8.0.17/mysys/my_default.cc 2019-07-22 19:07:56.476692609 +0200 +@@ -1565,12 +1565,12 @@ static const char **init_default_directo #else @@ -44,21 +42,11 @@ index 1317e362..cfa0feb7 100644 #endif /* DEFAULT_SYSCONFDIR */ #endif -diff --git a/scripts/CMakeLists.txt b/scripts/CMakeLists.txt -index c1202103..06a055b1 100644 ---- a/scripts/CMakeLists.txt -+++ b/scripts/CMakeLists.txt -@@ -315,7 +315,7 @@ ENDIF(UNIX) - - SET(bindir ${prefix}/${INSTALL_BINDIR}) - SET(sbindir ${prefix}/${INSTALL_SBINDIR}) --SET(libexecdir ${prefix}/${INSTALL_SBINDIR}) -+SET(libexecdir ${prefix}/${INSTALL_LIBEXECDIR}) - SET(pkgdatadir ${prefix}/${INSTALL_MYSQLSHAREDIR}) - IF(INSTALL_LAYOUT MATCHES "STANDALONE") - SET(localstatedir ${prefix}/data) -@@ -324,9 +324,9 @@ ELSE() - ENDIF() +diff -up mysql-8.0.17/scripts/CMakeLists.txt.patch5 mysql-8.0.17/scripts/CMakeLists.txt +--- mysql-8.0.17/scripts/CMakeLists.txt.patch5 2019-07-22 19:07:56.477692619 +0200 ++++ mysql-8.0.17/scripts/CMakeLists.txt 2019-07-22 19:09:26.160640283 +0200 +@@ -324,9 +324,9 @@ IF(UNIX) + ENDIF(UNIX) SET(prefix "${CMAKE_INSTALL_PREFIX}") -SET(sysconfdir ${prefix}) @@ -67,13 +55,12 @@ index c1202103..06a055b1 100644 -SET(libexecdir ${prefix}/${INSTALL_SBINDIR}) +SET(libexecdir ${prefix}/${INSTALL_LIBEXECDIR}) SET(datadir ${prefix}/${INSTALL_MYSQLSHAREDIR}) - SET(pkgdatadir ${prefix}/${INSTALL_MYSQLSHAREDIR}) SET(libsubdir ${INSTALL_LIBDIR}) -diff --git a/scripts/mysqld_multi.sh b/scripts/mysqld_multi.sh -index 5ad36e7b..5dd032f2 100644 ---- a/scripts/mysqld_multi.sh -+++ b/scripts/mysqld_multi.sh -@@ -572,9 +572,7 @@ sub list_defaults_files + SET(pkgincludedir ${prefix}/${INSTALL_INCLUDEDIR}) +diff -up mysql-8.0.17/scripts/mysqld_multi.sh.patch5 mysql-8.0.17/scripts/mysqld_multi.sh +--- mysql-8.0.17/scripts/mysqld_multi.sh.patch5 2019-06-25 12:23:30.000000000 +0200 ++++ mysql-8.0.17/scripts/mysqld_multi.sh 2019-07-22 19:07:56.477692619 +0200 +@@ -586,9 +586,7 @@ sub list_defaults_files my %seen; # Don't list the same file more than once return grep { defined $_ and not $seen{$_}++ and -f $_ and -r $_ } diff --git a/SOURCES/mysql-router.patch b/SOURCES/mysql-router.patch deleted file mode 100644 index 6e19604..0000000 --- a/SOURCES/mysql-router.patch +++ /dev/null @@ -1,17 +0,0 @@ -Do not build MySQL Router. -It is a set of tools and libraries used for the InnoDB cluster. - -However without MySQL SHELL it can't be operated. -We don't pack the MySQL SHELL, so donĀ“t build the router at all. - ---- mysql-8.0.13/CMakeLists.txt 2018-10-07 10:44:22.000000000 +0200 -+++ mysql-8.0.13/CMakeLists.txt_patched 2018-10-23 03:10:01.490792624 +0200 -@@ -1046,7 +1046,7 @@ CONFIGURE_FILE(${CMAKE_SOURCE_DIR}/sql/s - - # depends on mysql_version.h to exist - IF(NOT WITHOUT_SERVER) -- ADD_SUBDIRECTORY(router) -+# ADD_SUBDIRECTORY(router) - ENDIF() - - GET_PROPERTY(CWD_DEFINITIONS DIRECTORY PROPERTY COMPILE_DEFINITIONS) diff --git a/SOURCES/mysql-s390-tsc.patch b/SOURCES/mysql-s390-tsc.patch index 7e5eee3..0f549c4 100644 --- a/SOURCES/mysql-s390-tsc.patch +++ b/SOURCES/mysql-s390-tsc.patch @@ -1,10 +1,9 @@ Support s390/s390x in performance schema's cycle-counting functions. Filed upstream at http://bugs.mysql.com/bug.php?id=59953 -diff --git a/include/my_rdtsc.h b/include/my_rdtsc.h -index 65f7df1..a28f470 100644 ---- a/include/my_rdtsc.h -+++ b/include/my_rdtsc.h +diff -up mysql-8.0.17/include/my_rdtsc.h.patch2 mysql-8.0.17/include/my_rdtsc.h +--- mysql-8.0.17/include/my_rdtsc.h.patch2 2019-06-25 12:23:30.000000000 +0200 ++++ mysql-8.0.17/include/my_rdtsc.h 2019-07-22 19:02:43.824388869 +0200 @@ -128,5 +128,6 @@ void my_timer_init(MY_TIMER_INFO *mti); #define MY_TIMER_ROUTINE_GETSYSTEMTIMEASFILETIME 26 #define MY_TIMER_ROUTINE_ASM_SUNPRO_X86_64 27 @@ -12,12 +11,11 @@ index 65f7df1..a28f470 100644 +#define MY_TIMER_ROUTINE_ASM_S390 29 #endif -diff --git a/mysys/my_rdtsc.cc b/mysys/my_rdtsc.cc -index ec8e855..c3408b1 100644 ---- a/mysys/my_rdtsc.cc -+++ b/mysys/my_rdtsc.cc +diff -up mysql-8.0.17/mysys/my_rdtsc.cc.patch2 mysql-8.0.17/mysys/my_rdtsc.cc +--- mysql-8.0.17/mysys/my_rdtsc.cc.patch2 2019-06-25 12:23:30.000000000 +0200 ++++ mysql-8.0.17/mysys/my_rdtsc.cc 2019-07-22 19:04:03.227227901 +0200 @@ -204,6 +204,13 @@ ulonglong my_timer_cycles(void) { - __asm __volatile__("mrs %[rt],cntvct_el0" : [rt] "=r"(result)); + __asm __volatile__("mrs %[rt],cntvct_el0" : [ rt ] "=r"(result)); return result; } +#elif defined(__GNUC__) && defined(__s390__) diff --git a/SOURCES/mysql-sharedir.patch b/SOURCES/mysql-sharedir.patch index e34aa67..e8ced9a 100644 --- a/SOURCES/mysql-sharedir.patch +++ b/SOURCES/mysql-sharedir.patch @@ -1,23 +1,20 @@ -diff --git a/mysql-test/CMakeLists.txt b/mysql-test/CMakeLists.txt -index 7c1e82b5..a92ba915 100644 ---- a/mysql-test/CMakeLists.txt -+++ b/mysql-test/CMakeLists.txt -@@ -56,6 +56,10 @@ INSTALL( +diff -up mysql-8.0.17/mysql-test/CMakeLists.txt.patch52 mysql-8.0.17/mysql-test/CMakeLists.txt +--- mysql-8.0.17/mysql-test/CMakeLists.txt.patch52 2019-07-22 19:11:41.226067493 +0200 ++++ mysql-8.0.17/mysql-test/CMakeLists.txt 2019-07-22 19:12:14.539419508 +0200 +@@ -55,6 +55,9 @@ INSTALL( + ENDIF() ENDIF() - +# Expand some paths in the perl scripts correctly +CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/lib/My/ConfigFactory.pm ${CMAKE_CURRENT_SOURCE_DIR}/lib/My/ConfigFactory.pm @ONLY) +CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/mysql-test-run.pl ${CMAKE_CURRENT_SOURCE_DIR}/mysql-test-run.pl @ONLY) -+ + IF(NOT ${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_BINARY_DIR}) # Enable running mtr from build directory - CONFIGURE_FILE( -diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl -index 8c058527..7acd8534 100755 ---- a/mysql-test/mysql-test-run.pl -+++ b/mysql-test/mysql-test-run.pl -@@ -1479,11 +1479,11 @@ sub command_line_setup { +diff -up mysql-8.0.17/mysql-test/mysql-test-run.pl.patch52 mysql-8.0.17/mysql-test/mysql-test-run.pl +--- mysql-8.0.17/mysql-test/mysql-test-run.pl.patch52 2019-06-25 12:23:30.000000000 +0200 ++++ mysql-8.0.17/mysql-test/mysql-test-run.pl 2019-07-22 19:11:41.228067514 +0200 +@@ -1651,11 +1651,11 @@ sub command_line_setup { } # Look for language files and charsetsdir, use same share diff --git a/SPECS/mysql.spec b/SPECS/mysql.spec index aef286b..0c5a9aa 100644 --- a/SPECS/mysql.spec +++ b/SPECS/mysql.spec @@ -125,7 +125,7 @@ %endif Name: %{?scl_prefix}mysql -Version: 8.0.13 +Version: 8.0.17 Release: 1%{?with_debug:.debug}%{?dist} Summary: MySQL client programs and shared libraries URL: http://www.mysql.com @@ -168,7 +168,6 @@ Patch5: %{pkgnamepatch}-paths.patch # Patches specific for this mysql package Patch51: %{pkgnamepatch}-chain-certs.patch Patch52: %{pkgnamepatch}-sharedir.patch -Patch53: %{pkgnamepatch}-router.patch Patch75: %{pkgnamepatch}-arm32-timer.patch Patch76: %{pkgnamepatch}-header-file-include.patch @@ -182,7 +181,11 @@ Patch125: boost-1.57.0-mpl-print.patch # Use same logfile path in logrotate and mysql configs Patch126: mysql-logrotate-log-path.patch -BuildRequires: cmake +# mysql 8.0.17 and newer requires cmake 3.5.1 and higher, so we can use cmake from llvm scl +%if 0%{?rhel} == 7 && 0%{?scl:1} +%global llvm llvm-toolset-7.0 +%endif +BuildRequires: %{?llvm:%llvm-}cmake BuildRequires: gcc-c++ BuildRequires: libaio-devel BuildRequires: libedit-devel @@ -247,7 +250,7 @@ Requires: bash coreutils grep Requires: %{name}-common%{?_isa} = %{sameevr} %{?scl:Requires:%scl_runtime} -Provides: bundled(boost) = 1.67 +Provides: bundled(boost) = 1.69 %if %{with bundled_protobuf} Provides: bundled(protobuf) = 2.6.1 %endif @@ -461,17 +464,17 @@ the MySQL sources. %patch5 -p1 %patch51 -p1 %patch52 -p1 -%patch53 -p1 %patch75 -p1 %patch76 -p1 %patch126 -p1 # Patch Boost -pushd boost/boost_1_67_0 +pushd boost/boost_1_69_0 %patch115 -p0 %patch125 -p1 popd + # Modify tests to pass on all archs pushd mysql-test @@ -493,7 +496,6 @@ cp %{SOURCE2} %{SOURCE3} %{SOURCE10} %{SOURCE11} %{SOURCE12} %{SOURCE13} \ cp %{SOURCE41} mysql-sysnice.te - %build make -f /usr/share/selinux/devel/Makefile mysql-sysnice.te mysql-sysnice.pp # fail quickly and obviously if user tries to build as root @@ -506,7 +508,7 @@ make -f /usr/share/selinux/devel/Makefile mysql-sysnice.te mysql-sysnice.pp fi %endif -%{?scl:scl enable %{scl} %{?dts} - << \EOF} +%{?scl:scl enable %{scl} %{?dts} %{?llvm} - << \EOF} set -ex # build out of source @@ -571,6 +573,7 @@ cmake .. \ %if %{with bundled_protobuf} -DWITH_PROTOBUF=bundled \ %endif + -DWITH_ROUTER=OFF \ -DWITH_MECAB=system \ -DWITH_BOOST=../boost \ -DREPRODUCIBLE_BUILD=OFF \ @@ -594,6 +597,9 @@ install -p -m 644 -D mysql-sysnice.pp %{buildroot}%{selinux_packages_dir}/%{name %{?scl:scl enable %{scl} %{?dts} - << \EOF} set -ex +# clean previously created file lists, otherwise --short-circuit will not work properly +rm -f %{_builddir}/%{buildsubdir}/*.lst + pushd build make DESTDIR=%{buildroot} install @@ -652,13 +658,7 @@ install -p -m 644 scripts/mysql-scripts-common %{buildroot}%{_libexecdir}/mysql- install -D -p -m 0644 scripts/server.cnf %{buildroot}%{_sysconfdir}/my.cnf.d/%{pkg_name}-server.cnf install -D -p -m 0644 %{SOURCE32} %{buildroot}%{_sysconfdir}/my.cnf.d/%{pkg_name}-default-authentication-plugin.cnf -# mysql-test includes one executable that doesn't belong under /usr/share, -# so move it and provide a symlink -mv %{buildroot}%{_datadir}/mysql-test/lib/My/SafeProcess/my_safe_process %{buildroot}%{_bindir} -ln -s ../../../../../bin/my_safe_process %{buildroot}%{_datadir}/mysql-test/lib/My/SafeProcess/my_safe_process - rm %{buildroot}%{_libdir}/mysql/*.a -rm %{buildroot}%{_datadir}/%{pkg_name}/magic rm %{buildroot}%{_datadir}/%{pkg_name}/mysql.server rm %{buildroot}%{_datadir}/%{pkg_name}/mysqld_multi.server rm %{buildroot}%{_mandir}/man1/comp_err.1* @@ -742,7 +742,7 @@ polish,portuguese,romanian,russian,serbian,slovak,spanish,swedish,ukrainian} %endif %if %{without test} -rm %{buildroot}%{_bindir}/{mysql_client_test,mysqlxtest,my_safe_process} +rm %{buildroot}%{_bindir}/{mysql_client_test,mysqlxtest,mysqltest_safe_process} rm -r %{buildroot}%{_datadir}/mysql-test rm %{buildroot}%{_mandir}/man1/mysql_client_test.1* %endif @@ -777,8 +777,7 @@ mans= ; for bin in $mysql_binaries; do mans+=" man1/$bin.1.gz" ; done # Creating syspath without prefix for mysql-server package mysql_server_binaries='ibd2sdi innochecksum my_print_defaults myisam_ftdump myisamchk myisamlog myisampack mysql_secure_installation mysql_ssl_rsa_setup -mysql_tzinfo_to_sql mysql_upgrade mysqldumpslow perror -resolve_stack_dump resolveip' +mysql_tzinfo_to_sql mysql_upgrade mysqldumpslow perror' %scl_syspaths_install_wrappers -n mysql-server -m script -p bin $mysql_server_binaries @@ -1010,8 +1009,6 @@ fi %{_bindir}/mysqldumpslow %{_bindir}/innochecksum %{_bindir}/perror -%{_bindir}/resolve_stack_dump -%{_bindir}/resolveip %config(noreplace) %{_sysconfdir}/my.cnf.d/%{pkg_name}-server.cnf %config(noreplace) %{_sysconfdir}/my.cnf.d/%{pkg_name}-default-authentication-plugin.cnf @@ -1050,8 +1047,6 @@ fi %{_mandir}/man1/mysqlman.1* %{_mandir}/man1/innochecksum.1* %{_mandir}/man1/perror.1* -%{_mandir}/man1/resolve_stack_dump.1* -%{_mandir}/man1/resolveip.1* %{_mandir}/man1/lz4_decompress.1* %{_mandir}/man1/zlib_decompress.1* %{_mandir}/man8/mysqld.8* @@ -1100,8 +1095,8 @@ fi %files test %{_bindir}/mysql_client_test %{_bindir}/mysqltest +%{_bindir}/mysqltest_safe_process %{_bindir}/mysqlxtest -%{_bindir}/my_safe_process %attr(-,mysql,mysql) %{_datadir}/mysql-test %endif @@ -1112,6 +1107,35 @@ fi %endif %changelog +* Thu Jul 25 2019 Honza Horak - 8.0.17-1 +- Rebase to 8.0.17 + CVEs fixed: + Resolves: #1670206 + CVE-2019-2420 CVE-2019-2434 CVE-2019-2436 CVE-2019-2481 CVE-2019-2482 + CVE-2019-2486 CVE-2019-2494 CVE-2019-2495 CVE-2019-2502 CVE-2019-2507 + CVE-2019-2528 CVE-2019-2529 CVE-2019-2530 CVE-2019-2531 CVE-2019-2532 + CVE-2019-2533 CVE-2019-2534 CVE-2019-2535 CVE-2019-2536 CVE-2019-2539 + Resolves: #1707124 + CVE-2019-2580 CVE-2019-2581 CVE-2019-2584 CVE-2019-2585 CVE-2019-2587 + CVE-2019-2589 CVE-2019-2592 CVE-2019-2593 CVE-2019-2596 CVE-2019-2606 + CVE-2019-2607 CVE-2019-2614 CVE-2019-2617 CVE-2019-2620 CVE-2019-2623 + CVE-2019-2624 CVE-2019-2625 CVE-2019-2626 CVE-2019-2627 CVE-2019-2628 + CVE-2019-2630 CVE-2019-2631 CVE-2019-2635 CVE-2019-2636 CVE-2019-2644 + CVE-2019-2681 CVE-2019-2683 CVE-2019-2685 CVE-2019-2686 CVE-2019-2687 + CVE-2019-2688 CVE-2019-2689 CVE-2019-2691 CVE-2019-2693 CVE-2019-2694 + CVE-2019-2695 CVE-2019-2634 + Resolves: #1733478, #1733486 + CVE-2019-2800 CVE-2019-2822 + Other CVEs fixed in 8.0.17: + CVE-2019-2737 CVE-2019-2738 CVE-2019-2739 CVE-2019-2740 CVE-2019-2741 + CVE-2019-2743 CVE-2019-2746 CVE-2019-2747 CVE-2019-2752 CVE-2019-2755 + CVE-2019-2757 CVE-2019-2758 CVE-2019-2774 CVE-2019-2778 CVE-2019-2780 + CVE-2019-2784 CVE-2019-2785 CVE-2019-2789 CVE-2019-2791 CVE-2019-2795 + CVE-2019-2796 CVE-2019-2797 CVE-2019-2798 CVE-2019-2800 CVE-2019-2801 + CVE-2019-2802 CVE-2019-2803 CVE-2019-2805 CVE-2019-2808 CVE-2019-2810 + CVE-2019-2811 CVE-2019-2812 CVE-2019-2814 CVE-2019-2815 CVE-2019-2819 + CVE-2019-2822 CVE-2019-2826 CVE-2019-2830 CVE-2019-2834 CVE-2019-2879 + * Tue Oct 23 2018 Michal Schorm - 8.0.13-1 - Rebase to 8.0.13 - CVEs fixed: #1642059