2 |
%define name smeserver-mysql |
%define name smeserver-mysql |
3 |
Name: %{name} |
Name: %{name} |
4 |
%define version 2.7.0 |
%define version 2.7.0 |
5 |
%define release 13 |
%define release 16 |
6 |
Version: %{version} |
Version: %{version} |
7 |
Release: %{release}%{?dist} |
Release: %{release}%{?dist} |
8 |
License: GPL |
License: GPL |
11 |
Patch0: smeserver-mysql-2.7.0-bz11899-sclo.patch |
Patch0: smeserver-mysql-2.7.0-bz11899-sclo.patch |
12 |
Patch1: smeserver-mysql-2.7.0-bz11922-mysqlinit.patch |
Patch1: smeserver-mysql-2.7.0-bz11922-mysqlinit.patch |
13 |
Patch2: smeserver-mysql-2.7.0-bz11936.patch |
Patch2: smeserver-mysql-2.7.0-bz11936.patch |
14 |
|
Patch3: smeserver-mysql-2.7.0-bz11953-mysql.init-logging.patch |
15 |
|
|
16 |
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot |
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot |
17 |
BuildArchitectures: noarch |
BuildArchitectures: noarch |
36 |
%patch0 -p1 |
%patch0 -p1 |
37 |
%patch1 -p1 |
%patch1 -p1 |
38 |
%patch2 -p1 |
%patch2 -p1 |
39 |
|
%patch3 -p1 |
40 |
|
|
41 |
%build |
%build |
42 |
for ver in 101 102 103 105 |
for ver in 101 102 103 105 |
136 |
-e "s_/usr/bin/mysql_/opt/rh/rh-mariadb${ver}/root/usr/bin/mysql_g" \ |
-e "s_/usr/bin/mysql_/opt/rh/rh-mariadb${ver}/root/usr/bin/mysql_g" \ |
137 |
-e "s_mariadb.service_mariadb$ver-mariadb.service_" \ |
-e "s_mariadb.service_mariadb$ver-mariadb.service_" \ |
138 |
-e "s_/var/run/mariadb/mariadb.pid_${pidfile}_g" \ |
-e "s_/var/run/mariadb/mariadb.pid_${pidfile}_g" \ |
139 |
-e "s_mysqld_rh-mariadb$ver-mariadb_g" \ |
-e "s_mysqld_mariadb$ver-mariadb_g" \ |
140 |
-e "s_| mysql |_| /opt/rh/rh-mariadb${ver}/root/usr/bin/mysql --socket=$socket |_g" \ |
-e "s_| mysql |_| /opt/rh/rh-mariadb${ver}/root/usr/bin/mysql --socket=$socket |_g" \ |
141 |
-e "s_mysql\_upgrade_mysql\_upgrade --socket=$socket _g" |
-e "s_mysql\_upgrade_mysql\_upgrade --socket=$socket _g" |
142 |
mkdir -p root$ver/etc/e-smith/templates/etc/my.cnf |
mkdir -p root$ver/etc/e-smith/templates/etc/my.cnf |
194 |
if [ $ver -ge 102 ] |
if [ $ver -ge 102 ] |
195 |
then |
then |
196 |
sed -i root$ver/usr/lib/systemd/system/mariadb${ver}-mariadb.service \ |
sed -i root$ver/usr/lib/systemd/system/mariadb${ver}-mariadb.service \ |
197 |
-e "s/_safe//"; |
-e "s/_safe//" \ |
198 |
|
-e "s/^ExecStopPost.*//"; |
199 |
fi |
fi |
200 |
if [ $ver -ge 104 ] |
if [ $ver -ge 104 ] |
201 |
then |
then |
236 |
--file "/sbin/e-smith/systemd/mysql.init" 'attr(0554,root,root)' \ |
--file "/sbin/e-smith/systemd/mysql.init" 'attr(0554,root,root)' \ |
237 |
--dir '/home/e-smith/db/mysql' 'attr(0750,root,root)' \ |
--dir '/home/e-smith/db/mysql' 'attr(0750,root,root)' \ |
238 |
--dir "/var/log/mariadb" 'attr(0750,mysql,mysql)' \ |
--dir "/var/log/mariadb" 'attr(0750,mysql,mysql)' \ |
239 |
|
--dir "/var/log/mysql.init" 'attr(0750,root,root)' \ |
240 |
> %{name}-%{version}-filelist |
> %{name}-%{version}-filelist |
241 |
echo "%doc COPYING" >> %{name}-%{version}-filelist |
echo "%doc COPYING" >> %{name}-%{version}-filelist |
242 |
|
|
347 |
|
|
348 |
|
|
349 |
%changelog |
%changelog |
350 |
|
* Mon Jul 11 2022 Jean-Philippe Pialasse <tests@pialasse.com> 2.7.0-16.sme |
351 |
|
- use dedicated log file for *mysql.init [SME: 11953] |
352 |
|
|
353 |
|
* Tue Jun 07 2022 John Crisp <jcrisp@safeandsoundit.co.uk> 2.7.0-15.sme |
354 |
|
- Fix init for MariaDB 104+ [SME:11991] |
355 |
|
|
356 |
|
* Sun Apr 10 2022 Jean-Philippe Pialasse <tests@pialasse.com> 2.7.0-14.sme |
357 |
|
- /usr/libexec/mysql-wait-stop not used after mariadb101 [SME: 11936] |
358 |
|
|
359 |
* Sat Apr 09 2022 Jean-Philippe Pialasse <tests@pialasse.com> 2.7.0-13.sme |
* Sat Apr 09 2022 Jean-Philippe Pialasse <tests@pialasse.com> 2.7.0-13.sme |
360 |
- fix few typos [SME: 11936] |
- fix few typos [SME: 11936] |
361 |
|
|