2010-05-05 23:42:29 +02:00
|
|
|
#
|
2011-08-17 09:42:39 +02:00
|
|
|
# spec file for package mariadb
|
2010-05-05 23:42:29 +02:00
|
|
|
#
|
2014-05-23 12:52:59 +02:00
|
|
|
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2010-05-05 23:42:29 +02:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
# Few definitions which will alter build
|
2014-05-23 10:06:28 +02:00
|
|
|
%define preferred 01
|
2014-05-23 09:29:50 +02:00
|
|
|
%define use_systemd 01
|
|
|
|
%define use_cmake 01
|
|
|
|
%define cluster 00
|
|
|
|
%define have_info 0
|
2011-12-08 10:43:01 +01:00
|
|
|
%define builtin_plugins partition,csv,heap,aria,pbxt,myisam,myisammrg,xtradb
|
2012-03-12 17:06:36 +01:00
|
|
|
%define use_extra_provides 1
|
2014-05-23 09:29:50 +02:00
|
|
|
%define extra_provides mariadb_100
|
2010-05-05 23:42:29 +02:00
|
|
|
|
2014-05-14 19:52:29 +02:00
|
|
|
%if ! %{defined _rundir}
|
|
|
|
%define _rundir %{_localstatedir}/run
|
|
|
|
%endif
|
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%if %{?rel:0}%{!?rel:1}
|
|
|
|
%define rel 1
|
|
|
|
%endif
|
|
|
|
#Distribution: %dist
|
|
|
|
#Packager: %packager
|
|
|
|
#Vendor: %vendor
|
|
|
|
|
2011-03-14 16:49:42 +01:00
|
|
|
Name: mariadb
|
2011-12-08 10:43:01 +01:00
|
|
|
Summary: Server part of MariaDB
|
2012-02-18 09:26:22 +01:00
|
|
|
License: SUSE-GPL-2.0-with-FLOSS-exception
|
2010-05-05 23:42:29 +02:00
|
|
|
Group: Productivity/Databases/Servers
|
2014-08-18 19:44:17 +02:00
|
|
|
Version: 10.0.13
|
2013-02-04 17:08:57 +01:00
|
|
|
Release: 0
|
2014-09-16 08:39:59 +02:00
|
|
|
%define srv_vers 5.6.19
|
2014-09-03 15:09:43 +02:00
|
|
|
Url: https://www.mariadb.org
|
2012-04-10 11:53:56 +02:00
|
|
|
Source: mariadb-%{version}.tar.bz2
|
2010-05-05 23:42:29 +02:00
|
|
|
Source2: baselibs.conf
|
|
|
|
Source3: README.debug
|
|
|
|
Source4: suse-test-run
|
|
|
|
Source5: mysql.SuSEfirewall2
|
2014-05-23 09:29:50 +02:00
|
|
|
Source7: README.install
|
2014-09-03 15:09:43 +02:00
|
|
|
Source8: README.SUSE
|
2011-01-11 12:12:56 +01:00
|
|
|
Source9: mysql-patches.tar.bz2
|
|
|
|
Source10: build.inc
|
|
|
|
Source11: install.inc
|
|
|
|
Source12: series
|
2011-12-08 10:43:01 +01:00
|
|
|
Source13: configuration-tweaks.tar.bz2
|
2013-06-05 07:52:53 +02:00
|
|
|
Source14: my.ini
|
2014-05-23 09:29:50 +02:00
|
|
|
Source15: rc.mysql.sysvinit
|
|
|
|
Source16: rc.mysql.systemd
|
|
|
|
Source17: mysql.service
|
2010-05-05 23:42:29 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
%if 0%{?suse_version}
|
|
|
|
PreReq: pwdutils
|
2013-08-30 11:26:18 +02:00
|
|
|
%if %have_info
|
|
|
|
PreReq: %install_info_prereq %insserv_prereq
|
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
%endif
|
2012-07-02 14:29:26 +02:00
|
|
|
BuildRequires: autoconf
|
|
|
|
BuildRequires: automake
|
2013-07-30 22:06:56 +02:00
|
|
|
BuildRequires: bison
|
2012-07-02 14:29:26 +02:00
|
|
|
BuildRequires: cmake
|
|
|
|
BuildRequires: gcc-c++
|
2013-06-06 15:23:51 +02:00
|
|
|
BuildRequires: libaio-devel
|
2013-06-05 07:52:53 +02:00
|
|
|
BuildRequires: libedit-devel
|
2014-05-23 12:52:59 +02:00
|
|
|
BuildRequires: libevent-devel
|
2012-07-02 14:29:26 +02:00
|
|
|
BuildRequires: libtool
|
|
|
|
BuildRequires: ncurses-devel
|
|
|
|
BuildRequires: openssl-devel
|
2012-02-18 09:26:22 +01:00
|
|
|
BuildRequires: pam-devel
|
2012-07-02 14:29:26 +02:00
|
|
|
BuildRequires: procps
|
2013-08-12 12:27:00 +02:00
|
|
|
BuildRequires: readline-devel
|
2012-07-02 14:29:26 +02:00
|
|
|
BuildRequires: zlib-devel
|
2010-05-05 23:42:29 +02:00
|
|
|
%if 0%{?suse_version}
|
2012-07-02 14:29:26 +02:00
|
|
|
BuildRequires: pwdutils
|
|
|
|
BuildRequires: tcpd-devel
|
2010-05-05 23:42:29 +02:00
|
|
|
%endif
|
|
|
|
%if 0%{?suse_version} > 1030 || 0%{?fedora_version} > 8
|
|
|
|
BuildRequires: fdupes
|
|
|
|
%endif
|
2011-01-11 12:12:56 +01:00
|
|
|
%if 0%{?fedora_version} > 11
|
|
|
|
BuildRequires: sqlite
|
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
%if 0%{?suse_version} > 1030
|
|
|
|
Recommends: logrotate
|
|
|
|
%else
|
|
|
|
Requires: logrotate
|
|
|
|
%endif
|
|
|
|
# required by rcmysql
|
2013-02-04 17:08:57 +01:00
|
|
|
Requires: %{name}-client
|
2012-06-25 14:08:16 +02:00
|
|
|
Requires: %{name}-errormessages = %version
|
2013-02-04 17:08:57 +01:00
|
|
|
Requires: perl-base
|
2013-03-15 09:54:20 +01:00
|
|
|
# systemd requirements for openSUSE >= 12.1
|
|
|
|
%if 0%{?suse_version} >= 1210
|
2014-06-16 12:16:35 +02:00
|
|
|
BuildRequires: pkgconfig(systemd)
|
2013-03-15 09:54:20 +01:00
|
|
|
%{?systemd_requires}
|
|
|
|
%endif
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2013-02-03 15:37:10 +01:00
|
|
|
Provides: mysql = %{srv_vers}
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2013-02-04 17:08:57 +01:00
|
|
|
Provides: mysql-Max = %{srv_vers}
|
2012-03-12 17:06:36 +01:00
|
|
|
%if 0%{?use_extra_provides} > 0
|
|
|
|
Provides: %{extra_provides} = %{version}
|
|
|
|
Obsoletes: %{extra_provides} < %{version}
|
|
|
|
%endif
|
2014-05-23 10:06:28 +02:00
|
|
|
%if 0%{?preferred} > 0
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql < %{srv_vers}
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-Max < %{srv_vers}
|
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
Conflicts: otherproviders(mysql)
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%description
|
|
|
|
MariaDB is a backward compatible, drop-in replacement branch of the MySQL
|
|
|
|
Database Server. It includes all major open source storage engines, including
|
|
|
|
the Maria storage engine.
|
|
|
|
|
|
|
|
This package only contains the server-side programs.
|
|
|
|
|
2014-05-23 10:06:28 +02:00
|
|
|
%if 0%{?preferred} > 0
|
2010-05-05 23:42:29 +02:00
|
|
|
%package -n libmysqlclient-devel
|
|
|
|
# mysql-devel was last used in openSUSE 10.2
|
|
|
|
Provides: mysql-devel = %srv_vers-%release
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-devel < %srv_vers
|
2013-02-04 17:08:57 +01:00
|
|
|
Requires: glibc-devel
|
2012-04-15 11:06:13 +02:00
|
|
|
Requires: libmysqlclient18 = %version
|
|
|
|
Requires: libmysqlclient_r18 = %version
|
2011-12-08 10:43:01 +01:00
|
|
|
Requires: openssl-devel
|
|
|
|
Requires: zlib-devel
|
|
|
|
Summary: MariaDB development header files and libraries
|
2010-05-05 23:42:29 +02:00
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
|
|
|
|
%description -n libmysqlclient-devel
|
|
|
|
This package contains the development header files and libraries
|
2011-12-08 10:43:01 +01:00
|
|
|
necessary to develop client applications for MariaDB.
|
2010-05-05 23:42:29 +02:00
|
|
|
|
2012-04-15 11:06:13 +02:00
|
|
|
%package -n libmysqld18
|
2010-05-05 23:42:29 +02:00
|
|
|
Summary: MariaDB embedded server development files
|
|
|
|
Group: Development/Libraries/C and C++
|
2013-01-28 14:19:19 +01:00
|
|
|
Requires: %{name}-errormessages = %version
|
2010-05-05 23:42:29 +02:00
|
|
|
|
2012-04-15 11:06:13 +02:00
|
|
|
%description -n libmysqld18
|
2010-05-05 23:42:29 +02:00
|
|
|
This package contains the development header files and libraries
|
2011-12-08 10:43:01 +01:00
|
|
|
for developing applications that embed the MariaDB.
|
2010-05-05 23:42:29 +02:00
|
|
|
|
|
|
|
%package -n libmysqld-devel
|
|
|
|
Summary: MariaDB embedded server development files
|
2013-02-04 17:08:57 +01:00
|
|
|
Group: Development/Libraries/C and C++
|
2010-05-05 23:42:29 +02:00
|
|
|
# the headers files are the shared
|
2011-12-08 10:43:01 +01:00
|
|
|
Requires: libmysqlclient-devel = %version
|
2013-02-03 15:37:10 +01:00
|
|
|
Requires: libmysqld18 = %version
|
2013-02-04 17:08:57 +01:00
|
|
|
Requires: tcpd-devel
|
2010-05-05 23:42:29 +02:00
|
|
|
|
|
|
|
%description -n libmysqld-devel
|
|
|
|
This package contains the development header files and libraries
|
2011-12-08 10:43:01 +01:00
|
|
|
for developing applications that embed the MariaDB.
|
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
|
2013-01-17 09:17:25 +01:00
|
|
|
%package -n libmysqlclient18
|
2011-12-08 10:43:01 +01:00
|
|
|
Summary: Shared Libraries for MariaDB
|
2010-05-05 23:42:29 +02:00
|
|
|
Group: Development/Libraries/Other
|
|
|
|
|
2013-01-17 09:17:25 +01:00
|
|
|
%description -n libmysqlclient18
|
2010-05-05 23:42:29 +02:00
|
|
|
This package contains the shared libraries (.so) which certain
|
|
|
|
languages and applications need to dynamically load and use MariaDB.
|
|
|
|
|
2013-01-17 09:17:25 +01:00
|
|
|
%package -n libmysqlclient_r18
|
2011-12-08 10:43:01 +01:00
|
|
|
Summary: Shared Libraries for MariaDB
|
2010-05-05 23:42:29 +02:00
|
|
|
Group: Development/Libraries/Other
|
2013-09-26 10:56:26 +02:00
|
|
|
Requires: libmysqlclient18
|
2010-05-05 23:42:29 +02:00
|
|
|
|
2013-01-17 09:17:25 +01:00
|
|
|
%description -n libmysqlclient_r18
|
2010-05-05 23:42:29 +02:00
|
|
|
This package contains the shared libraries (.so) which certain
|
|
|
|
languages and applications need to dynamically load and use MariaDB.
|
|
|
|
|
|
|
|
%package client
|
2011-12-08 10:43:01 +01:00
|
|
|
Summary: Client for MariaDB
|
2010-05-05 23:42:29 +02:00
|
|
|
Group: Productivity/Databases/Clients
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2010-05-05 23:42:29 +02:00
|
|
|
Provides: mysql-client = %{srv_vers}
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2013-06-06 15:23:51 +02:00
|
|
|
%if 0%{?suse_version}
|
|
|
|
PreReq: pwdutils
|
|
|
|
%endif
|
2012-03-12 17:06:36 +01:00
|
|
|
%if 0%{?use_extra_provides} > 0
|
|
|
|
Provides: %{extra_provides}-client = %{version}
|
|
|
|
Obsoletes: %{extra_provides}-client < %{version}
|
|
|
|
%endif
|
2013-08-12 12:27:00 +02:00
|
|
|
Requires: %{name}-errormessages = %version
|
2014-05-23 10:06:28 +02:00
|
|
|
%if 0%{?preferred} > 0
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-client < %{srv_vers}
|
|
|
|
%endif
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
Conflicts: otherproviders(mysql-client)
|
|
|
|
|
|
|
|
%description client
|
2011-12-08 10:43:01 +01:00
|
|
|
This package contains the standard clients for MariaDB.
|
2010-05-05 23:42:29 +02:00
|
|
|
|
2012-06-25 14:08:16 +02:00
|
|
|
%package errormessages
|
|
|
|
Summary: MySQL Community Server development header files and libraries
|
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
|
|
|
|
%description errormessages
|
|
|
|
This package provides the translated error messages for the standalone
|
|
|
|
server daemon as well as the embedded server
|
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%package bench
|
2013-02-04 17:08:57 +01:00
|
|
|
Requires: %{name}-client
|
|
|
|
Requires: perl-DBD-mysql
|
2011-12-08 10:43:01 +01:00
|
|
|
Summary: Benchmarks for MariaDB
|
2010-05-05 23:42:29 +02:00
|
|
|
Group: Productivity/Databases/Tools
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2010-05-05 23:42:29 +02:00
|
|
|
Provides: mysql-bench = %{srv_vers}
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2012-03-12 17:06:36 +01:00
|
|
|
%if 0%{?use_extra_provides} > 0
|
|
|
|
Provides: %{extra_provides}-bench = %{version}
|
|
|
|
Obsoletes: %{extra_provides}-bench < %{version}
|
|
|
|
%endif
|
2014-05-23 10:06:28 +02:00
|
|
|
%if 0%{?preferred} > 0
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-bench < %{srv_vers}
|
|
|
|
%endif
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
Conflicts: otherproviders(mysql-bench)
|
|
|
|
|
|
|
|
%description bench
|
2011-12-08 10:43:01 +01:00
|
|
|
This package contains benchmark scripts and data for MariaDB.
|
2010-05-05 23:42:29 +02:00
|
|
|
|
|
|
|
To run these database benchmarks, start the script "run-all-tests" in
|
|
|
|
the directory /usr/share/sql-bench after starting MariaDB.
|
|
|
|
|
|
|
|
|
2012-01-30 14:38:58 +01:00
|
|
|
%package debug-version
|
2011-12-08 10:43:01 +01:00
|
|
|
Summary: MariaDB with debug options turned on
|
2010-05-05 23:42:29 +02:00
|
|
|
Group: Productivity/Databases/Servers
|
2011-07-27 13:56:09 +02:00
|
|
|
Requires: %{name} = %{version}
|
2013-02-03 15:37:10 +01:00
|
|
|
Provides: %{name}-debug = %{srv_vers}
|
2013-02-04 17:08:57 +01:00
|
|
|
Provides: mysql-debug = %{srv_vers}
|
2012-03-12 17:06:36 +01:00
|
|
|
%if 0%{?use_extra_provides} > 0
|
|
|
|
Provides: %{extra_provides}-debug-verion = %{version}
|
|
|
|
Obsoletes: %{extra_provides}-debug-version < %{version}
|
|
|
|
%endif
|
2014-05-23 10:06:28 +02:00
|
|
|
%if 0%{?preferred} > 0
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-debug < %{srv_vers}
|
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
Conflicts: otherproviders(mysql-debug)
|
|
|
|
|
2012-01-30 14:38:58 +01:00
|
|
|
%description debug-version
|
2011-12-08 10:43:01 +01:00
|
|
|
A version of the MariaDB that has some debug code turned on.
|
2010-05-05 23:42:29 +02:00
|
|
|
It should be only used to track down problems with the standard
|
2011-12-08 10:43:01 +01:00
|
|
|
servers. Note that merely installing this package will bot replace the
|
2010-05-05 23:42:29 +02:00
|
|
|
standard server. Read /usr/share/doc/packages/mysql/README.debug for
|
|
|
|
information on how to use the debug server.
|
|
|
|
|
|
|
|
%package test
|
2011-12-08 10:43:01 +01:00
|
|
|
Summary: Testsuite for MariaDB
|
2010-05-05 23:42:29 +02:00
|
|
|
Group: Productivity/Databases/Servers
|
2011-07-27 13:56:09 +02:00
|
|
|
Requires: %{name} = %{version}
|
2013-02-04 17:08:57 +01:00
|
|
|
Requires: %{name}-bench = %{version}
|
2011-07-27 13:56:09 +02:00
|
|
|
Requires: %{name}-client = %{version}
|
2013-02-03 15:37:10 +01:00
|
|
|
Requires: %{name}-tools = %{version}
|
2013-02-04 17:08:57 +01:00
|
|
|
Requires: perl-DBD-mysql
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2010-05-05 23:42:29 +02:00
|
|
|
Provides: mysql-test = %{srv_vers}
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2012-03-12 17:06:36 +01:00
|
|
|
%if 0%{?use_extra_provides} > 0
|
|
|
|
Provides: %{extra_provides}-test = %{version}
|
|
|
|
Obsoletes: %{extra_provides}-test < %{version}
|
|
|
|
%endif
|
2014-05-23 10:06:28 +02:00
|
|
|
%if 0%{?preferred} > 0
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-test < %{srv_vers}
|
|
|
|
%endif
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
Conflicts: otherproviders(mysql-test)
|
|
|
|
|
|
|
|
%description test
|
2011-12-08 10:43:01 +01:00
|
|
|
This package contains the test scripts and data for MariaDB.
|
2010-05-05 23:42:29 +02:00
|
|
|
|
|
|
|
To run the testsuite, run /usr/share/mysql-test/suse-test-run.
|
|
|
|
|
|
|
|
%package tools
|
|
|
|
Summary: MariaDB tools
|
|
|
|
Group: Productivity/Databases/Servers
|
|
|
|
Requires: perl-DBD-mysql
|
|
|
|
# make sure this package is installed when updating from 10.2 and older
|
2012-07-02 14:29:26 +02:00
|
|
|
Provides: mysql-client:/usr/bin/perror
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2010-05-05 23:42:29 +02:00
|
|
|
Provides: mysql-tools = %{srv_vers}
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2012-07-02 14:29:26 +02:00
|
|
|
Provides: mysql:/usr/bin/mysqlhotcopy
|
2012-03-12 17:06:36 +01:00
|
|
|
%if 0%{?use_extra_provides} > 0
|
|
|
|
Provides: %{extra_provides}-tools = %{version}
|
|
|
|
Obsoletes: %{extra_provides}-tools < %{version}
|
|
|
|
%endif
|
2014-05-23 10:06:28 +02:00
|
|
|
%if 0%{?preferred} > 0
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-tools < %{srv_vers}
|
|
|
|
%endif
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
Conflicts: otherproviders(mysql-tools)
|
|
|
|
|
|
|
|
%description tools
|
2011-12-08 10:43:01 +01:00
|
|
|
A set of scripts for administering a MariaDB or developing
|
2010-05-05 23:42:29 +02:00
|
|
|
applications with MariaDB.
|
|
|
|
|
|
|
|
%if 0%{?cluster} > 0
|
|
|
|
|
2012-03-12 17:06:36 +01:00
|
|
|
%if 0%{?cluster} > 1
|
|
|
|
%package -n libndbclient6
|
|
|
|
Summary: Shared Libraries for cluster client
|
|
|
|
Group: Development/Libraries/Other
|
|
|
|
|
|
|
|
%description -n libndbclient6
|
|
|
|
This package contains the shared libraries (.so) which certain
|
|
|
|
languages and applications need to dynamically load and use MariaDB
|
|
|
|
cluster.
|
|
|
|
|
|
|
|
%endif
|
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%package ndb-storage
|
|
|
|
Summary: MariaDB - ndbcluster storage engine
|
|
|
|
Group: Productivity/Databases/Servers
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2010-05-05 23:42:29 +02:00
|
|
|
Provides: mysql-ndb-storage = %{srv_vers}
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-ndb-storage < %{srv_vers}
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
Conflicts: otherproviders(mysql-ndb-storage)
|
|
|
|
|
|
|
|
%description ndb-storage
|
|
|
|
This package contains the ndbcluster storage engine.
|
|
|
|
It is necessary to have this package installed on all
|
|
|
|
computers that should store ndbcluster table data.
|
|
|
|
|
|
|
|
|
|
|
|
%package ndb-management
|
|
|
|
Summary: MariaDB - ndbcluster storage engine management
|
|
|
|
Group: Productivity/Databases/Servers
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2010-05-05 23:42:29 +02:00
|
|
|
Provides: mysql-ndb-management = %{srv_vers}
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-ndb-management < %{srv_vers}
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
Conflicts: otherproviders(mysql-ndb-management)
|
|
|
|
|
|
|
|
%description ndb-management
|
|
|
|
This package contains ndbcluster storage engine management.
|
|
|
|
It is necessary to have this package installed on at least
|
|
|
|
one computer in the cluster.
|
|
|
|
|
|
|
|
%package ndb-tools
|
|
|
|
Summary: MariaDB - ndbcluster storage engine basic tools
|
|
|
|
Group: Productivity/Databases/Servers
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2010-05-05 23:42:29 +02:00
|
|
|
Provides: mysql-ndb-tools = %{srv_vers}
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-ndb-tools < %{srv_vers}
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
Conflicts: otherproviders(mysql-ndb-tools)
|
|
|
|
|
|
|
|
%description ndb-tools
|
|
|
|
This package contains ndbcluster storage engine basic tools.
|
|
|
|
|
|
|
|
%package ndb-extra
|
|
|
|
Summary: MariaDB - ndbcluster storage engine extra tools
|
|
|
|
Group: Productivity/Databases/Servers
|
2013-08-12 12:27:00 +02:00
|
|
|
%if "%{name}" != mysql
|
2010-05-05 23:42:29 +02:00
|
|
|
Provides: mysql-ndb-extra = %{srv_vers}
|
2011-12-08 10:43:01 +01:00
|
|
|
Obsoletes: mysql-ndb-extra < %{srv_vers}
|
2013-08-12 12:27:00 +02:00
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
Conflicts: otherproviders(mysql-ndb-extra)
|
|
|
|
|
|
|
|
%description ndb-extra
|
|
|
|
This package contains some extra ndbcluster storage engine tools for the
|
|
|
|
advanced user. They should be used with caution.
|
|
|
|
%endif
|
|
|
|
|
|
|
|
%prep
|
2012-04-10 11:53:56 +02:00
|
|
|
%setup -q -n mariadb-%{version} -D -a 9
|
2014-09-03 15:09:43 +02:00
|
|
|
cp %_sourcedir/README.SUSE .
|
2010-05-05 23:42:29 +02:00
|
|
|
cp %_sourcedir/suse-test-run .
|
2011-01-11 12:12:56 +01:00
|
|
|
# apply patches from series
|
2011-05-16 11:42:12 +02:00
|
|
|
mysql-patches/tools/quilt-setup.sh "%{S:12}"
|
|
|
|
mysql-patches/tools/apply-series.sh "%{S:12}"
|
2010-05-05 23:42:29 +02:00
|
|
|
# remove unneeded manpages ('make install' basically installs everything under
|
|
|
|
# man/*)
|
|
|
|
rm -f man/mysqlman.1 # dummy fallback manpage
|
2012-06-19 16:26:01 +02:00
|
|
|
[ \! -f man/CMakeLists.txt ] || sed -i 's|mysqlman.1||' man/CMakeLists.txt
|
2010-05-05 23:42:29 +02:00
|
|
|
rm -f man/mysql.server.1 # init script, not installed in our rpm
|
2012-06-19 16:26:01 +02:00
|
|
|
[ \! -f man/CMakeLists.txt ] || sed -i 's|mysql.server.1||' man/CMakeLists.txt
|
2010-05-05 23:42:29 +02:00
|
|
|
rm -f man/make_win_*.1 # windows build scripts
|
|
|
|
rm -f man/comp_err.1 # built-time utility
|
|
|
|
# 5.1 Carrier Grade Edition only / still under development as of 5.1.22
|
|
|
|
rm -f man/ndbd_redo_log_reader.1
|
|
|
|
# breaks VPATH builds when in sourcedir, is generated in the builddirs
|
|
|
|
rm -f sql/sql_builtin.cc
|
|
|
|
sed -i 's|@localstatedir@|/var/log|' support-files/mysql-log-rotate.sh
|
2014-05-23 10:06:28 +02:00
|
|
|
%if 0%{preferred} < 1
|
2010-05-05 23:42:29 +02:00
|
|
|
for i in `grep -Rl mysqlclient .`; do
|
2013-01-17 09:17:25 +01:00
|
|
|
sed -i 's|mysqlclient|mysqlclient|g' $i
|
2014-05-23 09:29:50 +02:00
|
|
|
sed -i 's|-libmysqlclient-symbols.patch|-libmysqlclient-symbols.patch|g' $i
|
2010-05-05 23:42:29 +02:00
|
|
|
done
|
|
|
|
%endif
|
2013-01-17 09:17:25 +01:00
|
|
|
# Broken test that needs sources
|
|
|
|
rm -f mysql-test/t/file_contents.test mysql-test/r/file_contents.result
|
2013-12-11 12:03:05 +01:00
|
|
|
# Specify perl path on shebangs
|
|
|
|
for i in `grep -Rl '^#!@PERL@$' .`; do
|
2014-05-23 09:29:50 +02:00
|
|
|
sed -i 's|@PERL@|/usr/bin/perl|' $i
|
2013-12-11 12:03:05 +01:00
|
|
|
done
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%build
|
2011-01-11 12:12:56 +01:00
|
|
|
%{expand:%(cat %_sourcedir/build.inc)}
|
2010-05-05 23:42:29 +02:00
|
|
|
|
|
|
|
%install
|
2011-01-11 12:12:56 +01:00
|
|
|
%{expand:%(cat %_sourcedir/install.inc)}
|
2010-05-05 23:42:29 +02:00
|
|
|
|
|
|
|
%pre
|
|
|
|
/usr/sbin/groupadd -r mysql >/dev/null 2>/dev/null || :
|
2011-10-18 14:28:51 +02:00
|
|
|
/usr/sbin/useradd -r -o -g mysql -u 60 -c "MySQL database admin" \
|
2010-05-05 23:42:29 +02:00
|
|
|
-s /bin/false -d /var/lib/mysql mysql 2> /dev/null || :
|
2013-07-30 22:06:56 +02:00
|
|
|
/usr/sbin/usermod -g mysql -s /bin/false mysql 2> /dev/null || :
|
2013-03-15 09:54:20 +01:00
|
|
|
# systemd requirment
|
|
|
|
%if 0%{?suse_version} >= 1210
|
|
|
|
%service_add_pre mysql.service
|
|
|
|
%endif
|
|
|
|
|
2013-06-06 15:23:51 +02:00
|
|
|
%pre client
|
|
|
|
/usr/sbin/groupadd -r mysql >/dev/null 2>/dev/null || :
|
|
|
|
/usr/sbin/useradd -r -o -g mysql -u 60 -c "MySQL database admin" \
|
|
|
|
-s /bin/false -d /var/lib/mysql mysql 2> /dev/null || :
|
2013-07-30 22:06:56 +02:00
|
|
|
/usr/sbin/usermod -g mysql -s /bin/false mysql 2> /dev/null || :
|
2013-06-06 15:23:51 +02:00
|
|
|
|
2013-03-15 09:54:20 +01:00
|
|
|
%post
|
|
|
|
# systemd requirment
|
|
|
|
%if 0%{?suse_version} >= 1210
|
|
|
|
%service_add_post mysql.service
|
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
|
2011-12-08 10:43:01 +01:00
|
|
|
#######################################################################
|
|
|
|
# preun and posttran takes care of restart #
|
|
|
|
#######################################################################
|
2010-05-05 23:42:29 +02:00
|
|
|
%preun
|
2014-05-23 09:29:50 +02:00
|
|
|
[ $1 = 1 ] || /usr/sbin/rcmysql stop || true
|
2011-12-08 10:43:01 +01:00
|
|
|
|
2011-11-03 13:11:27 +01:00
|
|
|
%pretrans -p <lua>
|
|
|
|
if posix.access("/usr/sbin/rcmysql", "x") then
|
|
|
|
restart = os.execute("/usr/sbin/rcmysql status > /dev/null")
|
|
|
|
if restart == 0 then
|
2014-05-23 09:29:50 +02:00
|
|
|
os.execute("/usr/sbin/rcmysql stop")
|
2014-05-14 19:52:29 +02:00
|
|
|
os.execute("/bin/mkdir -p %{_rundir}/mysql/restart")
|
2011-11-03 13:11:27 +01:00
|
|
|
end
|
|
|
|
end
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%posttrans
|
2013-08-30 11:26:18 +02:00
|
|
|
%if %have_info
|
|
|
|
[ -z "`ls %{_infodir}/mysql.info.* 2> /dev/null`" ] || \
|
|
|
|
%install_info --info-dir=%{_infodir} %{_infodir}/mysql.info.*
|
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
if [ -d /var/lib/mysql ]; then
|
|
|
|
touch /var/lib/mysql/.run-mysql_upgrade
|
|
|
|
fi
|
|
|
|
for i in /var/lib/mysql/{.protected,.tmp}; do
|
|
|
|
( [ -d "$i" ] && rmdir "$i" ) || :
|
|
|
|
done
|
|
|
|
# start mysql again if it should run
|
2014-05-14 19:52:29 +02:00
|
|
|
if [ "`ls /etc/rc.d/rc*.d/S*mysql 2> /dev/null`" ] || [ -d %{_rundir}/mysql/restart ]; then
|
2010-05-05 23:42:29 +02:00
|
|
|
[ -x /usr/sbin/rcmysql ] && /usr/sbin/rcmysql start
|
2014-09-19 19:45:25 +02:00
|
|
|
# Might not be there, so ignoring errors
|
|
|
|
rmdir %{_rundir}/mysql/restart 2> /dev/null || :
|
2010-05-05 23:42:29 +02:00
|
|
|
fi
|
2014-05-23 09:29:50 +02:00
|
|
|
# warn on first run
|
|
|
|
datadir="/var/lib/mysql"
|
|
|
|
if [ -x /usr/bin/my_print_defaults ]; then
|
|
|
|
datadir="`/usr/bin/my_print_defaults mysqld mysql_server | sed -n 's|--datadir=||p'`"
|
|
|
|
[ "$datadir" ] || datadir="/var/lib/mysql"
|
|
|
|
fi
|
|
|
|
if [ \! -d "$datadir/mysql" ]; then
|
|
|
|
cat > /var/adm/update-messages/%{name}-%{version}-%{release} << EOF
|
|
|
|
%(cat %_sourcedir/README.install)
|
|
|
|
EOF
|
|
|
|
fi
|
2010-05-05 23:42:29 +02:00
|
|
|
|
2011-12-08 10:43:01 +01:00
|
|
|
#######################################################################
|
|
|
|
# Various ldconfig post scripts #
|
|
|
|
#######################################################################
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2013-01-17 09:17:25 +01:00
|
|
|
%post -n libmysqlclient18 -p /sbin/ldconfig
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2013-01-17 09:17:25 +01:00
|
|
|
%postun -n libmysqlclient18 -p /sbin/ldconfig
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2013-01-17 09:17:25 +01:00
|
|
|
%post -n libmysqlclient_r18 -p /sbin/ldconfig
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2013-01-17 09:17:25 +01:00
|
|
|
%postun -n libmysqlclient_r18 -p /sbin/ldconfig
|
2011-01-11 12:12:56 +01:00
|
|
|
|
2012-03-12 17:06:36 +01:00
|
|
|
%if 0%{cluster} > 1
|
|
|
|
%post -n libndbclient6 -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%postun -n libndbclient6 -p /sbin/ldconfig
|
|
|
|
%endif
|
|
|
|
|
2014-05-23 10:06:28 +02:00
|
|
|
%if 0%{preferred} > 0
|
2011-12-08 10:43:01 +01:00
|
|
|
%post -n libmysqld18 -p /sbin/ldconfig
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2011-12-08 10:43:01 +01:00
|
|
|
%postun -n libmysqld18 -p /sbin/ldconfig
|
2010-05-05 23:42:29 +02:00
|
|
|
%endif
|
|
|
|
|
|
|
|
%postun
|
|
|
|
if [ $1 = 0 ]; then
|
2013-08-30 11:26:18 +02:00
|
|
|
%if %have_info
|
|
|
|
%install_info_delete --info-dir=%{_infodir} %{_infodir}/mysql.info.*
|
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
%{insserv_cleanup}
|
2013-03-26 13:57:24 +01:00
|
|
|
rm -f "/var/lib/systemd/migrated/mysql.service"
|
|
|
|
if [ -x /usr/bin/systemctl ]; then
|
|
|
|
/usr/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
|
|
|
fi
|
2010-05-05 23:42:29 +02:00
|
|
|
fi
|
|
|
|
|
2011-12-08 10:43:01 +01:00
|
|
|
#######################################################################
|
|
|
|
# Files section #
|
|
|
|
#######################################################################
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%files -f mysql.files
|
|
|
|
%defattr(-, root, root)
|
|
|
|
%config(noreplace) %attr(0640, root, mysql) /etc/my.cnf
|
2013-06-05 10:49:48 +02:00
|
|
|
%dir %attr(0750, root, mysql) /etc/my.cnf.d
|
|
|
|
%config(noreplace) %attr(0640, root, mysql) /etc/my.cnf.d/*
|
2010-05-05 23:42:29 +02:00
|
|
|
%config /etc/logrotate.d/mysql
|
|
|
|
%doc %{_defaultdocdir}/%{name}
|
2013-08-30 11:26:18 +02:00
|
|
|
%if %have_info
|
|
|
|
%doc %{_infodir}/mysql.info.*
|
|
|
|
%endif
|
2014-05-23 09:29:50 +02:00
|
|
|
%if 0%{?suse_version} >= 1210 && 0%{?use_systemd} > 0
|
|
|
|
%dir /usr/lib/mysql
|
|
|
|
/usr/lib/mysql/rcmysql
|
|
|
|
/usr/lib/systemd/system/mysql.service
|
|
|
|
%else
|
2010-05-05 23:42:29 +02:00
|
|
|
/etc/init.d/mysql
|
2014-05-23 09:29:50 +02:00
|
|
|
%endif
|
2010-05-05 23:42:29 +02:00
|
|
|
/usr/sbin/rcmysql
|
2012-06-25 14:08:16 +02:00
|
|
|
%dir /usr/share/%{name}
|
|
|
|
%dir /usr/share/mysql
|
|
|
|
/usr/share/%{name}/charsets/
|
|
|
|
/usr/share/%{name}/*.sql
|
2010-05-05 23:42:29 +02:00
|
|
|
%dir %{_libdir}/mysql
|
|
|
|
%{_libdir}/mysql/mysqld.sym
|
|
|
|
%config /etc/sysconfig/SuSEfirewall2.d/services/mysql
|
|
|
|
%dir %_libdir/mysql/plugin
|
2012-06-12 09:21:22 +02:00
|
|
|
%_libdir/mysql/plugin/[!d]*.so
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2012-06-25 14:08:16 +02:00
|
|
|
%files errormessages -f errormessages.files
|
|
|
|
%defattr(-, root, root)
|
|
|
|
/usr/share/%{name}/*/errmsg.sys
|
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%files client -f mysql-client.files
|
|
|
|
%defattr(-, root, root)
|
|
|
|
|
2014-05-23 10:06:28 +02:00
|
|
|
%if 0%{preferred} > 0
|
2010-05-05 23:42:29 +02:00
|
|
|
%files -n libmysqlclient-devel -f libmysqlclient-devel.files
|
|
|
|
%defattr(-, root, root)
|
|
|
|
/usr/include/mysql
|
2014-05-23 09:29:50 +02:00
|
|
|
%{_libdir}/libmysqlclient.so
|
|
|
|
%{_libdir}/libmysqlclient_r.so
|
2012-01-30 14:38:58 +01:00
|
|
|
%dir /usr/share/aclocal
|
2010-05-05 23:42:29 +02:00
|
|
|
/usr/share/aclocal/mysql.m4
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%files -n libmysqld-devel
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%_libdir/libmysqld.a
|
|
|
|
%_libdir/libmysqld.so
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2011-12-08 10:43:01 +01:00
|
|
|
%files -n libmysqld18
|
2010-05-05 23:42:29 +02:00
|
|
|
%defattr(-,root,root)
|
|
|
|
%_libdir/libmysqld.so.*
|
2011-12-08 10:43:01 +01:00
|
|
|
%endif
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2013-01-17 09:17:25 +01:00
|
|
|
%files -n libmysqlclient18
|
2010-05-05 23:42:29 +02:00
|
|
|
%defattr(-, root, root)
|
2014-05-23 09:29:50 +02:00
|
|
|
%{_libdir}/libmysqlclient.so.*
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2012-03-12 17:06:36 +01:00
|
|
|
%if 0%{cluster} > 1
|
|
|
|
%files -n libndbclient6
|
|
|
|
%defattr(-, root, root)
|
|
|
|
%{_libdir}/libndbclient.so.*
|
|
|
|
%endif
|
|
|
|
|
2013-01-17 09:17:25 +01:00
|
|
|
%files -n libmysqlclient_r18
|
2010-05-05 23:42:29 +02:00
|
|
|
%defattr(-, root, root)
|
2014-05-23 09:29:50 +02:00
|
|
|
%{_libdir}/libmysqlclient_r.so.*
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%files bench -f mysql-bench.files
|
|
|
|
%defattr(-, root, root)
|
|
|
|
/usr/share/sql-bench
|
|
|
|
|
2012-01-30 14:38:58 +01:00
|
|
|
%files debug-version
|
2010-05-05 23:42:29 +02:00
|
|
|
%defattr(-, root, root)
|
|
|
|
/usr/sbin/mysqld-debug
|
|
|
|
%{_libdir}/mysql/mysqld-debug.sym
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%files test -f mysql-test.files
|
|
|
|
%defattr(-, root, root)
|
|
|
|
%{_bindir}/my_safe_process
|
|
|
|
%_mandir/man1/mysql-test-run.pl.1*
|
|
|
|
%_mandir/man1/mysql-stress-test.pl.1*
|
|
|
|
/usr/share/mysql-test/valgrind.supp
|
|
|
|
%dir %attr(755, root, root)/usr/share/mysql-test
|
|
|
|
/usr/share/mysql-test/[^v]*
|
|
|
|
%dir %attr(755, mysql, mysql) /usr/share/mysql-test/var
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%files tools -f mysql-tools.files
|
|
|
|
%defattr(-, root, root)
|
|
|
|
%_bindir/mysqlrepair
|
|
|
|
%_bindir/mysqlanalyze
|
|
|
|
%_bindir/mysqloptimize
|
|
|
|
|
|
|
|
%if 0%{cluster} > 0
|
|
|
|
%files ndb-storage -f mysql-ndb-storage.files
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%files ndb-management -f mysql-ndb-management.files
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%files ndb-tools -f mysql-ndb-tools.files
|
2011-08-17 09:42:39 +02:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%files ndb-extra -f mysql-ndb-extra.files
|
2011-12-08 10:43:01 +01:00
|
|
|
|
2010-05-05 23:42:29 +02:00
|
|
|
%endif
|
|
|
|
|
|
|
|
%changelog
|