Provide subackage with a client static library needed by mysql-connector-odbc package

Remove Group tag as it shouldn't be used anymore
This commit is contained in:
Michal Schorm 2018-01-02 14:52:58 +01:00
parent 51a726ceaa
commit dd46f0a7a0

View File

@ -84,9 +84,8 @@
Name: community-mysql
Version: 5.7.20
Release: 1%{?with_debug:.debug}%{?dist}
Release: 2%{?with_debug:.debug}%{?dist}
Summary: MySQL client programs and shared libraries
Group: Applications/Databases
URL: http://www.mysql.com
# Exceptions allow client libraries to be linked with most open source SW,
@ -216,7 +215,6 @@ contains the standard MySQL client programs and generic MySQL files.
%if %{with clibrary}
%package libs
Summary: The shared libraries required for MySQL clients
Group: Applications/Databases
Requires: %{name}-common%{?_isa} = %{sameevr}
%if %{with mysql_names}
Provides: mysql-libs = %{sameevr}
@ -234,7 +232,6 @@ MySQL server.
%if %{with config}
%package config
Summary: The config files required by server and client
Group: Applications/Databases
%description config
The package provides the config file my.cnf and my.cnf.d directory used by any
@ -247,7 +244,6 @@ package itself.
%if %{with common}
%package common
Summary: The shared files required for MySQL server and client
Group: Applications/Databases
Requires: %{_sysconfdir}/my.cnf
%description common
@ -260,7 +256,6 @@ MySQL package.
%if %{with errmsg}
%package errmsg
Summary: The error messages files required by server and embedded
Group: Applications/Databases
Requires: %{name}-common%{?_isa} = %{sameevr}
%description errmsg
@ -272,7 +267,6 @@ MySQL packages.
%package server
Summary: The MySQL server and related files
Group: Applications/Databases
# Require any mysql client, but prefer community-mysql client for community-mysql server
Suggests: %{name}%{?_isa} = %{sameevr}
@ -315,7 +309,6 @@ the MySQL server and some accompanying files and directories.
%if %{with devel}
%package devel
Summary: Files for development of MySQL applications
Group: Applications/Databases
%{?with_clibrary:Requires: %{name}-libs%{?_isa} = %{sameevr}}
Requires: pkgconfig(openssl)
Requires: zlib-devel
@ -331,7 +324,6 @@ developing MySQL client applications.
%if %{with embedded}
%package embedded
Summary: MySQL as an embeddable library
Group: Applications/Databases
Requires: %{name}-common%{?_isa} = %{sameevr}
Requires: %{name}-errmsg%{?_isa} = %{sameevr}
%if %{with mysql_names}
@ -347,7 +339,6 @@ into a client application instead of running as a separate process.
%package embedded-devel
Summary: Development files for MySQL as an embeddable library
Group: Applications/Databases
Requires: %{name}-embedded%{?_isa} = %{sameevr}
Requires: %{name}-devel%{?_isa} = %{sameevr}
Requires: libaio-devel
@ -365,7 +356,6 @@ the embedded version of the MySQL server.
%if %{with test}
%package test
Summary: The test suite distributed with MySQL
Group: Applications/Databases
Requires: %{name}%{?_isa} = %{sameevr}
Requires: %{name}-common%{?_isa} = %{sameevr}
Requires: %{name}-server%{?_isa} = %{sameevr}
@ -396,6 +386,17 @@ the MySQL sources.
%endif
%package static
Summary: Static mysql client library
Suggests: %{name}-devel%{?_isa} = %{sameevr}
%description static
MySQL is a multi-user, multi-threaded SQL database server.
This package contains the static client library "libmysqlclient.a", that is
required by mysql-connector-odbc package. This package should not be required
by any other package than mysql-connector-odbc.
%prep
%setup -q -n mysql-%{version}
%patch1 -p1
@ -585,9 +586,12 @@ install -D -p -m 0644 scripts/server.cnf %{buildroot}%{_sysconfdir}/my.cnf.d/%{p
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
# Do not pack those libraries
rm %{buildroot}%{_libdir}/mysql/libmysqld.a
rm %{buildroot}%{_libdir}/mysql/libmysqlservices.a
# not needed in rpm package
rm %{buildroot}%{_bindir}/mysql_embedded
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
@ -791,6 +795,9 @@ fi
%config(noreplace) %{_sysconfdir}/ld.so.conf.d/*
%endif
%files static
%{_libdir}/mysql/libmysqlclient.a
%if %{with config}
%files config
# although the default my.cnf contains only server settings, we put it in the
@ -968,6 +975,11 @@ fi
%endif
%changelog
* Tue Jan 02 2018 Michal Schorm <mschorm@redhat.com> - 5.7.20-2
- Provide subackage with a client static library
Needed by mysql-connector-odbc package
- Remove Group tag as it shouldn't be used anymore
* Wed Oct 25 2017 Michal Schorm <mschorm@redhat.com> - 5.7.20-1
- Fix owner and perms on log file in post script
Related: #1497694