X-Git-Url: https://git.tld-linux.org/?a=blobdiff_plain;f=mysql.spec;h=cf3d5731f5f9fe878ac8e5dec7f7aa5945818dcf;hb=1494d43ceb9a20c6a671939a402b109b677ea8d5;hp=825f3e054fb95ee354b8fa54326aa799ef95ab1c;hpb=e370ad03be04a1befd4bc207f6b090bbf59b97f5;p=packages%2Fmysql.git diff --git a/mysql.spec b/mysql.spec index 825f3e0..cf3d573 100644 --- a/mysql.spec +++ b/mysql.spec @@ -30,12 +30,13 @@ %bcond_with systemtap # systemtap/dtrace probes %bcond_without tcpd # libwrap (tcp_wrappers) support %bcond_with sphinx # Sphinx storage engine support -%bcond_without tokudb # TokuDB +%bcond_with tokudb # TokuDB %bcond_without rocksdb # RocksDB # mysql needs boost 1.59.0 and doesn't support newer/older boost versions %bcond_with system_boost # Use system boost package %bcond_with tests # FIXME: don't run correctly %bcond_with ndb # NDB is now a separate product, this here is broken, so disable it +%bcond_without coredumper # coredumper support # tokudb is only supported on x86_64 %ifnarch %{x8664} @@ -44,8 +45,7 @@ %endif %define rel 1 -%define percona_rel 22 -%include /usr/lib/rpm/macros.perl +%define percona_rel 39 Summary: MySQL: a very fast and reliable SQL database engine Summary(de.UTF-8): MySQL: ist eine SQL-Datenbank Summary(fr.UTF-8): MySQL: un serveur SQL rapide et fiable @@ -55,12 +55,12 @@ Summary(ru.UTF-8): MySQL - быстрый SQL-сервер Summary(uk.UTF-8): MySQL - швидкий SQL-сервер Summary(zh_CN.UTF-8): MySQL数据库服务器 Name: mysql -Version: 5.7.22 +Version: 5.7.36 Release: %{percona_rel}.%{rel} License: GPL + MySQL FLOSS Exception Group: Applications/Databases Source0: https://www.percona.com/downloads/Percona-Server-5.7/LATEST/source/tarball/percona-server-%{version}-%{percona_rel}.tar.gz -# Source0-md5: a0b0488015d3d38a77c093b476452722 +# Source0-md5: 54c63c74ee2f6aa9ec149010ccacc2dc Source100: http://www.sphinxsearch.com/files/sphinx-2.2.11-release.tar.gz # Source100-md5: 5cac34f3d78a9d612ca4301abfcbd666 %if %{without system_boost} @@ -82,16 +82,12 @@ Source13: %{name}-client.conf Source14: my.cnf Patch0: mysql-opt.patch Patch1: mysql-versioning.patch - -Patch7: lz4.patch - -Patch11: mysql-upgrade.patch -Patch12: mysql-config.patch -Patch18: mysql-sphinx.patch +Patch2: mysql-protobuf.patch +Patch3: build.patch +Patch17: mysql-sphinx.patch +Patch18: mysql-5.7-sphinx.patch Patch19: mysql-chain-certs.patch -# from fedora Patch20: mysql-dubious-exports.patch - Patch24: mysql-cmake.patch URL: https://www.percona.com/software/mysql-database/percona-server BuildRequires: bison >= 1.875 @@ -103,6 +99,7 @@ BuildRequires: automake %{?with_system_boost:BuildRequires: boost-devel = 1.59.0} BuildRequires: libhsclient-devel %{?with_tcpd:BuildRequires: libwrap-devel} +BuildRequires: lz4-devel >= 1:1.9.3 BuildRequires: mecab-devel BuildRequires: ncurses-devel >= 4.2 %{?with_ssl:BuildRequires: openssl-devel >= 0.9.7d} @@ -111,6 +108,7 @@ BuildRequires: pam-devel BuildRequires: perl-devel >= 1:5.6.1 BuildRequires: protobuf-devel BuildRequires: python-modules +BuildRequires: rpcsvc-proto BuildRequires: rpm-perlprov >= 4.1-13 BuildRequires: rpmbuild(macros) >= 1.597 BuildRequires: sed >= 4.0 @@ -498,19 +496,17 @@ find . -name CMakeLists.txt -exec sed -i -e 's#perconaserverclient#mysqlclient#g sed -i -e 's#perconaserverclient#mysqlclient#g' libmysql/libmysql.{ver.in,map} scripts/mysql_config.* %patch0 -p1 - +%patch1 -p1 +%patch2 -p1 +%patch3 -p1 %if %{with sphinx} # http://www.sphinxsearch.com/docs/manual-0.9.9.html#sphinxse-mysql51 -mv sphinx-*/mysqlse storage/sphinx +%{__mv} sphinx-*/mysqlse storage/sphinx +%patch17 -p1 %patch18 -p1 %endif -%patch1 -p1 - -%patch7 -p1 - %patch19 -p1 %patch20 -p1 - %patch24 -p1 # to get these files rebuild @@ -527,13 +523,19 @@ cd build # (it defaults to first cluster but user may change it to whatever # cluster it wants) +%if "%{cc_version}" >= "7.0" +FALLTHROUGH_OPT="-Wimplicit-fallthrough=0" +%else +FALLTHROUGH_OPT= +%endif + CPPFLAGS="%{rpmcppflags}" \ %cmake .. \ -DCMAKE_BUILD_TYPE=%{!?debug:RelWithDebInfo}%{?debug:Debug} \ - -DCMAKE_C_FLAGS_DEBUG="-fno-omit-frame-pointer -fno-strict-aliasing -Wimplicit-fallthrough=0" \ - -DCMAKE_CXX_FLAGS_DEBUG="-fno-omit-frame-pointer -fno-strict-aliasing -Wimplicit-fallthrough=0" \ - -DCMAKE_C_FLAGS_RELWITHDEBINFO="%{rpmcflags} -DNDEBUG -fno-omit-frame-pointer -fno-strict-aliasing -Wimplicit-fallthrough=0" \ - -DCMAKE_CXX_FLAGS_RELWITHDEBINFO="%{rpmcxxflags} -DNDEBUG -fno-omit-frame-pointer -fno-strict-aliasing -Wimplicit-fallthrough=0" \ + -DCMAKE_C_FLAGS_DEBUG="-fno-omit-frame-pointer -fno-strict-aliasing $FALLTHROUGH_OPT" \ + -DCMAKE_CXX_FLAGS_DEBUG="-fno-omit-frame-pointer -fno-strict-aliasing $FALLTHROUGH_OPT" \ + -DCMAKE_C_FLAGS_RELWITHDEBINFO="%{rpmcflags} -DNDEBUG -fno-omit-frame-pointer -fno-strict-aliasing $FALLTHROUGH_OPT -Wno-shadow" \ + -DCMAKE_CXX_FLAGS_RELWITHDEBINFO="%{rpmcxxflags} -DNDEBUG -fno-omit-frame-pointer -fno-strict-aliasing $FALLTHROUGH_OPT -Wno-shadow" \ -DCOMPILATION_COMMENT="TLD Linux MySQL RPM" \ -DCURSES_INCLUDE_PATH=/usr/include/ncurses \ %{?with_systemtap:-DENABLE_DTRACE=ON} \ @@ -557,22 +559,41 @@ CPPFLAGS="%{rpmcppflags}" \ -DWITH_SCALABILITY_METRICS=ON \ -DWITH_SSL=%{?with_ssl:system}%{!?with_ssl:no} \ -DWITH_UNIT_TESTS=%{?with_tests:ON}%{!?with_tests:OFF} \ + -DWITH_COREDUMPER=%{?with_coredumper:ON}%{!?with_coredumper:OFF} \ %{!?with_tokudb:-DWITHOUT_TOKUDB=ON} \ %{!?with_rocksdb:-DWITHOUT_ROCKSDB=ON} \ %if %{without system_boost} %{!?with_system_boost:-DWITH_BOOST="$(pwd)/$(ls -1d ../boost_*)"} \ %endif - -DWITH_ZLIB=system \ - -DWITH_READLINE=system \ - -DWITH_LZ4=system \ -DWITH_LIBEVENT=system \ - -DWITH_PROTOBUF=system \ + -DWITH_LZ4=system \ -DWITH_MECAB=system \ + -DWITH_PROTOBUF=system \ + -DWITH_READLINE=system \ + -DWITH_ZLIB=system \ -DTMPDIR=/var/tmp %{__make} -%{?with_tests:%{__make} test} +%if %{with tests} +%{__make} test + +cd mysql-test + +MTR_BINDIR=$(pwd)/../build/ \ +%{__perl} ./mysql-test-run.pl \ + --force \ + --retry=0 \ + --ssl \ + --suite-timeout=720 \ + --testcase-timeout=30 \ + --mysqld=--binlog-format=mixed \ + --force-restart \ + --shutdown-timeout=60 \ + --max-test-fail=0 \ + --big-test \ + --skip-test-list=unstable-tests +%endif %install rm -rf $RPM_BUILD_ROOT @@ -670,6 +691,7 @@ mv $RPM_BUILD_ROOT{%{_bindir},%{_sbindir}}/mysqlcheck # not needed %{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/plugin/libdaemon_example.* %{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/plugin/daemon_example.ini +%{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/plugin/udf_example.so # not an .info file %{__rm} $RPM_BUILD_ROOT%{_infodir}/mysql.info @@ -762,6 +784,8 @@ fi %attr(755,root,root) %{_libdir}/%{name}/plugin/auth_test_plugin.so %attr(755,root,root) %{_libdir}/%{name}/plugin/authentication_ldap_sasl_client.so %attr(755,root,root) %{_libdir}/%{name}/plugin/connection_control.so +%attr(755,root,root) %{_libdir}/%{name}/plugin/data_masking.ini +%attr(755,root,root) %{_libdir}/%{name}/plugin/data_masking.so %attr(755,root,root) %{_libdir}/%{name}/plugin/dialog.so %attr(755,root,root) %{_libdir}/%{name}/plugin/group_replication.so %attr(755,root,root) %{_libdir}/%{name}/plugin/keyring_file.so