%bcond_with systemd
%bcond_with source
%bcond_without onigmo

%global daemon_name mariadb

%define mysqld_user		mysql
%define mysqld_group		mysql
%define mysqldatadir /var/lib/mysql
%if %{with systemd}
%define pidfiledir %{_rundir}/mariadb
%else
%define pidfiledir /var/run/mariadb
%endif
# We define some system's well known locations here so we can use them easily
# later when building to another location (like SCL)
%global logrotateddir %{_sysconfdir}/logrotate.d
%global logfiledir %{_localstatedir}/log/%{daemon_name}
%global logfile %{logfiledir}/%{daemon_name}.log

# Working around perl dependency problem
%global __perl_requires %{SOURCE998}
%global __perllib_requires %{SOURCE998}

%define _unpackaged_files_terminate_build 1

%define mariadb_version		10.11.8
%define mariadb_base_version	10.11
%define mroonga_version		14.04
%define groonga_version		14.0.4
%define client_version		18

%define galera_api_version	26.4

Name:		mariadb
Summary:	MariaDB: a very fast and robust SQL database server
Version:	%{mariadb_version}
Release:	1%{_dist_release}%{?with_systemd:.systemd}
Group:		servers
Vendor:		Project Vine
Distribution:	Vine Linux
Packager:	tomop

License:	GPL2
URL:		https://mariadb.org/
Source:		https://archive.mariadb.org/mariadb-%{version}/source/mariadb-%{version}.tar.gz

# for systemd
Source10:	mysql.tmpfiles.d.in
Source11:	mysql.service.in
Source12:	mysql-prepare-db-dir.sh
Source14:	mysql-check-socket.sh
Source15:	mysql-scripts-common.sh
Source16:	mysql-check-upgrade.sh
Source18:	mysql@.service.in
Source20:	mysql-log-rotate.sh

# Don't depend on lib::mtr*
Source998:	perl-requires.sh
Source1000:	macros.mariadb.in
Source1001:	mysql.init
Source2000:	groonga-gcc14.patch

Patch0:		mariadb-scripts.patch
Patch1:		mariadb-ownsetup.patch

# replace mroonga to the newest version.
Patch1000:	0001-MariaDB-%{mariadb_version}-Mroonga-v%{mroonga_version}-Groonga-v%{groonga_version}.patch

BuildRoot:	%{_tmppath}/%{name}-%{version}-root
BuildRequires:	bison, cmake, gcc-c++, groff, git
BuildRequires:	libaio-devel, libboost-devel, libevent-devel, libxml2-devel
BuildRequires:	ncurses-devel, perl, openssl-devel, readline-devel
BuildRequires:	jemalloc-devel
BuildRequires:	pam-devel
BuildRequires:	unixODBC-devel
BuildRequires:	mecab-devel
BuildRequires:	pcre2-devel
BuildRequires:	pkgconfig(zlib)
BuildRequires:	libzstd-devel
BuildRequires:	lz4-devel
Requires:	fileutils sh-utils
Provides:	msqlormysql MySQL mysql
Obsoletes:	mysql MySQL5
%if %{with systemd}
BuildRequires:	systemd
BuildRequires:	systemd-devel
%{?systemd_requires}
%else
Requires(post): chkconfig
Requires(preun): chkconfig
%endif

# From the manual
%description
MariaDB: a very fast and robust SQL database server

It is GPL v2 licensed, which means you can use the it free of charge under the
conditions of the GNU General Public License Version 2 (http://www.gnu.org/licenses/).

MariaDB documentation can be found at http://kb.askmonty.org/
MariaDB bug reports should be submitted through https://mariadb.atlassian.net/


%package server
Summary:	MariaDB: a very fast and robust SQL database server
Version:	%{mariadb_version}
Release:	%{release}
Group:		servers
Requires:	fileutils sh-utils net-tools mariadb-common which
Requires(post):	mariadb-common
Provides:	mysql-server mysql MySQL MySQL-server mariadbserver-%{mariadb_base_version}
Obsoletes:	MySQL mysql mysql-server
Obsoletes:	MySQL-server < 5.6.0
Obsoletes:	mariadb-tokudb < 10.5.5

%description server
MariaDB: a very fast and robust SQL database server

It is GPL v2 licensed, which means you can use the it free of charge under the
conditions of the GNU General Public License Version 2 (http://www.gnu.org/licenses/).

MariaDB documentation can be found at http://kb.askmonty.org/
MariaDB bug reports should be submitted through https://mariadb.atlassian.net/


%package server-jemalloc
Summary:	A configuration file to run MariaDB with jemalloc
Group:		servers
BuildRequires:	jemalloc
Requires:	mariadb-server = %{version}-%{release}
Requires:	jemalloc

%description server-jemalloc
This package contains a systemd drop-in file to run MariaDB with jemalloc.


%package mroonga
##Version: %{mroonga_version}
Summary:	A fast fulltext searchable storage engine for MariaDB.
Version:	%{mariadb_version}
Group:		servers
Requires(pre):	mariadb-server = %{mariadb_version}-%{release}
Requires:	mariadb-server = %{mariadb_version}-%{release}
Obsoletes:	MySQL-mroonga < 4.02
Obsoletes:	mariadb-mroonga < 4.07
Obsoletes:	mariadb-mroonga-doc < 4.07

%description mroonga
Mroonga is a fast fulltext searchable storage plugin for MariaDB.
It is based on groonga that is a fast fulltext search engine and
column store. Groonga is good at real-time update.


%package connect
Summary:	CONNECT storage engine for MariaDB.
Version:	%{mariadb_version}
Group:		servers
Requires(pre):	mariadb-server = %{mariadb_version}-%{release}
Requires:	mariadb-server = %{mariadb_version}-%{release}

%description connect
The CONNECT storage engine enables MariaDB to access external
local or remote data (MED). This is done by defining tables
based on different data types, in particular files in various
formats, data extracted from other DBMS or products (such as Excel)
via ODBC, or data retrieved from the environment (for example
DIR, WMI, and MAC tables).

This storage engine supports table partitioning, MariaDB virtual
columns and also permits defining special columns such as ROWID,
FILEID, and SERVID.


%package galera
Summary:	The configuration files and scripts for galera replication
Version:	%{mariadb_version}
Group:		servers
Provides:	mariadb-server-galera = %{mariadb_version}-%{release}
Requires(pre):	mariadb-server = %{mariadb_version}-%{release}
Requires:	mariadb-server = %{mariadb_version}-%{release}
Requires:	galera(%{galera_api_version})

%description galera
 This package contains the files for MariaDB Galera Cluster.


%package lz4
Summary: lz4 compression plugin for MariaDB
Version: %{mariadb_version}
Group: servers
Requires: %{name}-server = %{version}-%{release}

%description lz4
This package contains the lz4 compression plugin for MariaDB.


%package client
Summary: MariaDB - Client
Version: %{mariadb_version}
Group: office
Obsoletes: mysql-client MySQL-client < 5.6.0
Provides: mysql-client MySQL-client  mariadbclient-%{mariadb_base_version}

%description client
This package contains the standard MariaDB clients and administration tools. 


%package devel
Summary: MariaDB - Development libraries and headers
Version: %{mariadb_version}
Group: programming
Requires: %{name}-static, openssl-devel, pkgconfig(zlib)
Conflicts: MySQL-devel < 5.6.0
Conflicts: libmysqlclient-devel
Conflicts: libmariadb-devel

%description devel
This package contains the development libraries and headers to develop
MariaDB server components (e.g. plugins or embedded applications).


%package static
Summary: MariaDB - static libraries
Version: %{mariadb_version}
Group: programming
Requires: %{name}-devel

%description static
This package provides static libraries of MariaDB.


%if %{with source}
%package source
Summary: MariaDB - Source
Version: %{mariadb_version}
Group: programming
Requires: mariadb-devel = %{version}-%{release}
Obsoletes: MySQL-source < 5.6.0
AutoReqProv: no

%description source
This package contains the sources files of MariaDB.
%endif


%package test
Summary: MariaDB - Test suite
Version: %{mariadb_version}
Group: admin-tools
Requires: %{name}-client = %{version}-%{release} perl-DBI perl
Obsoletes: mysql-bench MySQL5-bench MySQL-bench MySQL-test < 5.6.0
Provides: perl(mtr_misc.pl)

%description test
This package contains the MariaDB regression test suite.


%package embedded
Summary: MariaDB as an embeddable library
Version: %{mariadb_version}
Group: system
Obsoletes: mysql-embedded MySQL-embedded
Provides: mysql-embedded MySQL-embedded

%description embedded
This package contains a version of the MariaDB server that can be embedded
into a client application instead of running as a separate process.


%debug_package


%prep
%setup -q
%if %{with systemd}
%patch0 -p1
%endif
%patch1 -p1
git --git-dir= apply -p1 %{PATCH1000}

cp -f \
	%{SOURCE10} %{SOURCE11} %{SOURCE12} %{SOURCE14} \
	%{SOURCE15} %{SOURCE16} %{SOURCE18} \
	scripts/

cp -f %{SOURCE20} support-files/


%build
# Be strict about variables, bail at earliest opportunity, etc.
set -eu

# Optional package files
touch optional-files-devel

export CFLAGS=${MYSQL_BUILD_CFLAGS:-${CFLAGS:-$RPM_OPT_FLAGS}}
export CXXFLAGS=${MYSQL_BUILD_CXXFLAGS:-${CXXFLAGS:-$RPM_OPT_FLAGS}}

# for groonga >= 13.1.1
sed -i -e 's/CMAKE_CXX_STANDARD 11/CMAKE_CXX_STANDARD 17/' CMakeLists.txt

# Build full release
# workaround: force TOKUDB_OK=1
# https://jira.mariadb.org/browse/MDEV-14524?workflowName=MariaDB+v3&stepId=1

%cmake \
      -DINSTALL_LAYOUT=RPM \
      -DINSTALL_SBINDIR=libexec \
      -DINSTALL_SCRIPTDIR=bin \
      -DLOG_LOCATION="%{logfile}" \
      -DPID_FILE_DIR="%{pidfiledir}" \
      -DBUILD_CONFIG=mysql_release \
      -DCMAKE_BUILD_TYPE=Release \
      -DINSTALL_UNIX_ADDRDIR="/var/lib/mysql/mysql.sock" \
      -DCOMPILATION_COMMENT="Vine Linux MariaDB RPM" \
      -DDAEMON_NO_PREFIX="%{name}" \
      -DWITH_PIC="ON" \
      -DWITH_EMBEDDED_SERVER="ON" \
      -DWITH_ZLIB="system" \
      -DWITH_LOCALES="yes" \
      -DWITH_SSL="system" \
      -DWITH_UNIT_TESTS="no" \
      -DWITH_SEQUENCE_STORAGE_ENGINE="ON" \
      -DWITH_XTRADB_STORAGE_ENGINE="ON" \
      -DWITH_JEMALLOC="yes" \
      -DGRN_WITH_MECAB="yes" \
%if %{without onigmo}
      -DGRN_WITH_ONIGMO="no"
%endif
      -DWITH_PCRE="system" 

%make_build -C %{_vpath_builddir} rapidjson-ep
pushd %{_vpath_builddir}/storage/mroonga/groonga/rapidjson-ep-install/
patch -p1 < %{SOURCE2000}
popd

ln -sf $(pwd)/%{_vpath_builddir}/storage/mroonga/vendor/groonga/include/groonga/version.h storage/mroonga/vendor/groonga/include/groonga/version.h

echo BEGIN_NORMAL_CONFIG ; grep -E '^#define' %{_vpath_builddir}/include/config.h ; echo END_NORMAL_CONFIG
%cmake_build


%install
rm -rf %{buildroot}

install -d %{buildroot}%{mysqldatadir}/mysql
install -d %{buildroot}%{_infodir}

# Install all binaries
%cmake_install

%if %{with systemd}
install -d %{buildroot}%{_libexecdir}
pushd %{_vpath_builddir}
rm -rf %{buildroot}/usr/lib/systemd/system
# install systemd unit files and scripts for handling server startup
install -D -p -m 644 scripts/mysql.service %{buildroot}%{_unitdir}/%{daemon_name}.service
install -D -p -m 644 scripts/mysql@.service %{buildroot}%{_unitdir}/%{daemon_name}.service
# Remove the upstream version
rm -f %{buildroot}%{_tmpfilesdir}/tmpfiles.conf
# Install downstream version
install -D -p -m 0644 scripts/mysql.tmpfiles.d %{buildroot}%{_tmpfilesdir}/%{name}.conf
# helper scripts for service starting
install -p -m 755 scripts/mysql-prepare-db-dir %{buildroot}%{_libexecdir}/mysql-prepare-db-dir
install -p -m 755 scripts/mysql-check-socket %{buildroot}%{_libexecdir}/mysql-check-socket
install -p -m 755 scripts/mysql-check-upgrade %{buildroot}%{_libexecdir}/mysql-check-upgrade
install -p -m 644 scripts/mysql-scripts-common %{buildroot}%{_libexecdir}/mysql-scripts-common
popd

jemalloc_file=`ls %{_libdir}/libjemalloc.so.* | head -n 1`
if [ -z "$jemalloc_file" -o ! -x "$jemalloc_file" ]; then
	echo "jemalloc not found."
	exit 1
fi
mkdir -p %{buildroot}%{_unitdir}/mariadb.service.d
cat <<EOF > %{buildroot}%{_unitdir}/mariadb.service.d/jemalloc.conf
[Service]
Environment="LD_PRELOAD=$jemalloc_file"
EOF

rm -f %{buildroot}%{_sysconfdir}/init.d/*
rm -f %{buildroot}%{_libexecdir}/rcmysql
%else
install -m755 %{SOURCE1001} %{buildroot}%{_sysconfdir}/init.d/mysql
mkdir -p %{buildroot}%{pidfiledir}
# drop systemd files.
rm -rf %{buildroot}%{_sysconfdir}/systemd
%endif

# Logfile creation
mkdir -p %{buildroot}%{logfiledir}
chmod 0750 %{buildroot}%{logfiledir}
#touch %{buildroot}%{logfile}

# for compatibility with upstream RPMs, create mysqld symlink in sbin
mkdir -p %{buildroot}%{_sbindir}
ln -s ../libexec/mysqld %{buildroot}%{_sbindir}/mysqld
ln -s ../libexec/mariadbd %{buildroot}%{_sbindir}/mariadbd

mkdir -p %{buildroot}%{_localstatedir}/run

install -m 0644  Docs/mysql.info %{buildroot}%{_infodir}
rm -rf ./doc
mv -f %{buildroot}%{_docdir} ./
rm doc/README-wsrep

rm -rf ./groonga
mv -f %{buildroot}%{_datadir}/groonga ./

%if %{with source}
mkdir -p %{buildroot}%{_datadir}/%{name}-source
pushd %{buildroot}%{_datadir}/%{name}-source
tar zxf %{SOURCE0}
find %{buildroot}%{_datadir}/%{name}-source -type f -exec chmod ugo-x {} \;
popd
%endif

install -d %{buildroot}%{_sysconfdir}/rpm
sed -e 's/@BASEVERSION@/%{mariadb_base_version}/' -e 's/@VERSION@/%{version}/' -e 's/@RELEASE@/%{release}/' < %{SOURCE1000} > %{buildroot}%{_sysconfdir}/rpm/macros.mariadb

rm -f %{buildroot}%{_mandir}/man1/mysql_fix_privilege_tables.1*
rm -f %{buildroot}%{_mandir}/man8/mysqlmanager.8*
rm -f %{buildroot}%{_sysconfdir}/my.cnf
rm -f %{buildroot}%{_sysconfdir}/my.cnf.d/client.cnf
rm -f %{buildroot}%{_libdir}/libmysqlclient*.so*
rm -f %{buildroot}%{_libdir}/mysql/plugin/daemon_example.ini

# install files for galera cluster.
install -m755 ./scripts/galera_new_cluster.sh %{buildroot}%{_bindir}/galera_new_cluster
install -m755 ./scripts/galera_recovery.sh %{buildroot}%{_bindir}/galera_recovery
perl -pi -e 's|^wsrep_provider=.*$|wsrep_provider=%{_libdir}/galera/libgalera_smm.so|' %{buildroot}%{_datadir}/mysql/wsrep.cnf
perl -pi -e 's|^wsrep_notify_cmd=.*$|#wsrep_notify_cmd=%{_datadir}/mysql/wsrep_notify|' %{buildroot}%{_datadir}/mysql/wsrep.cnf
install -m644 %{buildroot}%{_datadir}/mysql/wsrep.cnf %{buildroot}%{_sysconfdir}/my.cnf.d/galera.cnf

# force linking statically.
perl -pi -e 's,-lmariadb,%{_libdir}/libmariadbclient.a,' %{buildroot}%{_bindir}/mysql_config

perl -pi -e 's,-lmariadb,%{_libdir}/libmariadbclient.a,' %{buildroot}%{_datadir}/pkgconfig/mariadb.pc

# install pam_user_map.so to /lib64/security for 64bit architectures
%ifarch x86_64
if [ ! -e %{buildroot}/%{_lib}/security/pam_user_map.so ]; then
	mkdir -p %{buildroot}/%{_lib}/security
	mv %{buildroot}/lib/security/pam_user_map.so %{buildroot}/%{_lib}/security/
fi
%endif

# drop client library
rm -f %{buildroot}%{_libdir}/libmariadb.so*
rm -f %{buildroot}%{_prefix}/lib/pkgconfig/libmariadb.pc
rm -f %{buildroot}%{_prefix}/lib64/pkgconfig/libmariadb.pc

##############################################################################

%pre server
# Create a MySQL user and group. Do not report any problems if it already
# exists.
datadir=/var/lib/mysql

groupadd -r mysql 2> /dev/null || true
useradd -M -r -d $datadir -s /bin/bash -c "MySQL server" -g mysql mysql 2> /dev/null || true
# The user may already exist, make sure it has the proper group nevertheless (BUG#12823)
usermod -g mysql mysql 2> /dev/null || true

# upgrade from mariadb-server <= 10.6.4-1
if [ ! -L %{_sbindir}/mysqld ]; then
  rm -f %{_sbindir}/mysqld
fi 
if [ ! -L %{_sbindir}/mariadbd ]; then
  rm -f %{_sbindir}/mariadbd
fi 

%post server
# Make MySQL start/shutdown automatically when the machine does it.

if [ $1 = 1 ] ; then
%if %{with systemd}
%systemd_post %{daemon_name}.service
%else
  if [ -x /sbin/chkconfig ] ; then
          /sbin/chkconfig --add mysql
  fi
%endif

  basedir=`/usr/bin/my_print_defaults --mysqld|sed -ne 's/^--basedir=//p'|tail -1`
  if [ -z "$basedir" ] ; then
    basedir=/usr
  fi

  datadir=`/usr/bin/my_print_defaults --mysqld|sed -ne 's/^--datadir=//p'|tail -1`
  if [ -z "$datadir" ] ; then
    datadir=/var/lib/mysql
  else
    # datadir may be relative to a basedir!
    if ! expr $datadir : / > /dev/null; then
      datadir=$basedir/$datadir
    fi
  fi

  tmpdir=`/usr/bin/my_print_defaults --mysqld|sed -ne 's/^--datadir=//p'|tail -1`
  if [ -z "$datadir" ] ; then
    datadir=/var/lib/mysql
  else
    # datadir may be relative to a basedir!
    if ! expr $datadir : / > /dev/null; then
      datadir=$basedir/$datadir
    fi
  fi

  # Change permissions so that the user that will run the MySQL daemon
  # owns all database files.
  chown -R mysql:mysql $datadir

  if [ ! -e $datadir/mysql ]; then
    # Create data directory
    mkdir -p $datadir/{mysql,test}
    chown -R mysql:mysql $datadir

    # Initiate databases
    /usr/bin/mysql_install_db --rpm --user=mysql
  fi

  # Change permissions again to fix any new files.
  chown -R mysql:mysql $datadir

  # Fix permissions for the permission database so that only the user
  # can read them.
  chmod -R og-rw $datadir/mysql
fi

%preun server
%if %{with systemd}
%systemd_preun %{daemon_name}.service
%else
%endif
if [ $1 = 0 ] ; then
	# Stop MySQL before uninstalling it
	if [ -x /etc/init.d/mysql ] ; then
		/etc/init.d/mysql stop > /dev/null
	fi
	# Don't start it automatically anymore
	if [ -x /sbin/chkconfig ] ; then
		/sbin/chkconfig --del mysql
	fi
fi

%postun server
%if %{with systemd}
%systemd_postun_with_restart %{daemon_name}.service
%else
if [ $1 -ge 1 ]; then
  if [ -x /etc/init.d/mysql ] ; then
    # only restart the server if it was alredy running
    /etc/init.d/mysql status > /dev/null 2>&1 && \
    /etc/init.d/mysql restart
  fi
fi
%endif


%pre mroonga
if [ $1 -gt 1 ]; then
/usr/bin/mysql -u root < %{_datadir}/mysql/mroonga/uninstall.sql || cat <<EOF
An error occured when to unregister plugin.
Please run a command below:

  /usr/bin/mysql -u root < %{_datadir}/mysql/mroonga/uninstall.sql

EOF

fi

%post mroonga
if [ $1 -eq 1 ] ; then
	/usr/bin/mysql -u root < %{_datadir}/mysql/mroonga/install.sql || cat <<EOF
An error occured when to register plugin.
Please run a command below:

  /usr/bin/mysql -u root < %{_datadir}/mysql/mroonga/install.sql

EOF
fi

%postun mroonga
if [ $1 -gt 0 ] ; then
	/usr/bin/mysql -u root < %{_datadir}/mysql/mroonga/install.sql || cat <<EOF
An error occured when to register plugin.
Please run a command below:

  /usr/bin/mysql -u root < %{_datadir}/mysql/mroonga/install.sql

EOF
fi

# Clean up the BuildRoot
%clean
[ "$RPM_BUILD_ROOT" != "/" ] && [ -d $RPM_BUILD_ROOT ] && rm -rf $RPM_BUILD_ROOT;

%files server
%defattr(-,root,root)
%{!?_licensedir:%global license %%doc}
%license COPYING*

%doc doc/*
%doc %{_infodir}/mysql.info*

%doc %{_mandir}/man1/aria_*.1*
%doc %{_mandir}/man1/innochecksum.1*
%doc %{_mandir}/man1/mariabackup.1*
%doc %{_mandir}/man1/mariadb-backup.1*
%doc %{_mandir}/man1/mariadb-convert-table-format.1*
%doc %{_mandir}/man1/mariadb-conv.1*
%doc %{_mandir}/man1/mariadb-dumpslow.1*
%doc %{_mandir}/man1/mariadb-fix-extensions.1*
%doc %{_mandir}/man1/mariadb-hotcopy.1*
%doc %{_mandir}/man1/mariadb-install-db.1*
%doc %{_mandir}/man1/mariadb-ldb.1*
%doc %{_mandir}/man1/mariadb-secure-installation.1*
%doc %{_mandir}/man1/mariadb-service-convert.1*
%doc %{_mandir}/man1/mariadb-setpermission.1*
%doc %{_mandir}/man1/mariadb-tzinfo-to-sql.1*
%doc %{_mandir}/man1/mariadb-upgrade.1*
%doc %{_mandir}/man1/mariadbd-multi.1*
%doc %{_mandir}/man1/mariadbd-safe-helper.1*
%doc %{_mandir}/man1/mariadbd-safe.1*
%doc %{_mandir}/man1/mbstream.1*
%doc %{_mandir}/man1/my_print_defaults.1*
%doc %{_mandir}/man1/my_safe_process.1*
%doc %{_mandir}/man1/myisam_ftdump.1*
%doc %{_mandir}/man1/myisamchk.1*
%doc %{_mandir}/man1/myisamlog.1*
%doc %{_mandir}/man1/myisampack.1*
%doc %{_mandir}/man1/myrocks_hotbackup.1*
%doc %{_mandir}/man1/mysql_convert_table_format.1*
%doc %{_mandir}/man1/mysql_fix_extensions.1*
%doc %{_mandir}/man1/mysqld_multi.1*
%doc %{_mandir}/man1/mysqld_safe.1*
%doc %{_mandir}/man1/mysqld_safe_helper.1*
%doc %{_mandir}/man1/mysqldumpslow.1*
%doc %{_mandir}/man1/mysql_install_db.1*
%doc %{_mandir}/man1/mysql_ldb.1*
%doc %{_mandir}/man1/mysql_secure_installation.1*
%doc %{_mandir}/man1/mysql_setpermission.1*
%doc %{_mandir}/man1/mysql_upgrade.1*
%doc %{_mandir}/man1/mysqlhotcopy.1*
%doc %{_mandir}/man1/mysql.server.1*
%doc %{_mandir}/man1/mysqltest.1*
%doc %{_mandir}/man1/mysql_tzinfo_to_sql.1*
%doc %{_mandir}/man1/perror.1*
%doc %{_mandir}/man1/replace.1*
%doc %{_mandir}/man1/resolve_stack_dump.1*
%doc %{_mandir}/man1/resolveip.1*
%doc %{_mandir}/man1/wsrep_sst_*.1*
%doc %{_mandir}/man8/mysqld.8*
%doc %{_mandir}/man8/mariadbd.8*
%{_bindir}/aria_*
%{_bindir}/innochecksum
%{_bindir}/mariabackup
%{_bindir}/mariadb-backup
%{_bindir}/mariadb-conv
%{_bindir}/mariadb-convert-table-format
%{_bindir}/mariadb-dumpslow
%{_bindir}/mariadb-fix-extensions
%{_bindir}/mariadb-hotcopy
%{_bindir}/mariadb-install-db
%{_bindir}/mariadb-secure-installation
%{_bindir}/mariadb-setpermission
%{_bindir}/mariadb-tzinfo-to-sql
%{_bindir}/mariadb-upgrade
%{_bindir}/mariadbd-multi
%{_bindir}/mariadbd-safe
%{_bindir}/mariadbd-safe-helper
%{_bindir}/mbstream
%{_bindir}/my_print_defaults
%{_bindir}/myisam_ftdump
%{_bindir}/myisamchk
%{_bindir}/myisamlog
%{_bindir}/myisampack
%{_bindir}/mysql_convert_table_format
%{_bindir}/mysql_fix_extensions
%{_bindir}/mysql_install_db
%{_bindir}/mysql_secure_installation
%{_bindir}/mysql_setpermission
%{_bindir}/mysql_tzinfo_to_sql
%{_bindir}/mysql_upgrade
%{_bindir}/mysqld_multi
%{_bindir}/mysqld_safe
%{_bindir}/mysqld_safe_helper
%{_bindir}/mysqldumpslow
%{_bindir}/mysqlhotcopy
%{_bindir}/mysqltest
%{_bindir}/perror
%{_bindir}/replace
%{_bindir}/resolve_stack_dump
%{_bindir}/resolveip
%{_bindir}/wsrep*
%{_sbindir}/mariadbd
%{_sbindir}/mysqld
%{_libexecdir}/*
%dir %{_libdir}/mysql
%dir %{_libdir}/mysql/plugin
%attr(0700,mysql,root) %dir %{_libdir}/mysql/plugin/auth_pam_tool_dir
%attr(4755,root,root) %{_libdir}/mysql/plugin/auth_pam_tool_dir/auth_pam_tool
%{_libdir}/mysql/plugin/*.so
/%{_lib}/security/pam_user_map.so
%exclude %{_libdir}/mysql/plugin/ha_connect.so
%exclude %{_libdir}/mysql/plugin/ha_mroonga.so
%exclude %{_libdir}/mysql/plugin/provider_lz4.so
%exclude %{_datadir}/mysql/mroonga
#exclude %{_datadir}/mysql/systemd/use_galera_new_cluster.conf
%attr(0750,mysql,mysql) %dir %{logfiledir}
%dir %{_sysconfdir}/my.cnf.d
%config(noreplace) %{_sysconfdir}/my.cnf.d/enable_encryption.preset
%config(noreplace) %{_sysconfdir}/my.cnf.d/server.cnf
%config(noreplace) %{_sysconfdir}/my.cnf.d/spider.cnf
%config(noreplace) %{_sysconfdir}/security/user_map.conf
%config(noreplace,missingok) %{_sysconfdir}/logrotate.d/mariadb
%if %{with systemd}
%{_bindir}/mariadb-service-convert
%{_unitdir}/*.service
%{_tmpfilesdir}/%{name}.conf
%dir %{_unitdir}/mariadb.service.d
%{_sysusersdir}/%{name}.conf
%else
%{_sysconfdir}/init.d/mysql
%attr(0755,mysql,mysql) %dir %{pidfiledir}
%endif
%{_datadir}/mysql
%attr(755, mysql, mysql) %dir %{mysqldatadir}
%ifarch x86_64
%{_bindir}/mariadb-ldb
%{_bindir}/myrocks_hotbackup
%{_bindir}/mysql_ldb
%{_bindir}/sst_dump
%endif

%if %{with systemd}
%files server-jemalloc
%{_unitdir}/mariadb.service.d/jemalloc.conf
%endif

%files mroonga
%defattr(-, root, root)
%{!?_licensedir:%global license %%doc}
%license groonga/COPYING
%{_libdir}/mysql/plugin/ha_mroonga.so
%{_datadir}/mysql/mroonga

%files connect
%defattr(-, root, root)
%{_libdir}/mysql/plugin/ha_connect.so

%files galera
%defattr(-, root, root)
%doc Docs/README-wsrep
%doc %{_mandir}/man1/galera_new_cluster.1*
%doc %{_mandir}/man1/galera_recovery.1*
%dir %{_sysconfdir}/my.cnf.d
%config(noreplace) %{_sysconfdir}/my.cnf.d/galera.cnf
%{_bindir}/galera_new_cluster
%{_bindir}/galera_recovery
%if %{with systemd}
%{_datadir}/mysql/systemd/use_galera_new_cluster.conf
%endif

%files lz4
%{_libdir}/mysql/plugin/provider_lz4.so
%dir %{_sysconfdir}/my.cnf.d
%{_sysconfdir}/my.cnf.d/provider_lz4.cnf

%files client
%defattr(-, root, root)
%{!?_licensedir:%global license %%doc}
%license COPYING*

%config(noreplace) %{_sysconfdir}/my.cnf.d/mysql-clients.cnf
%{_bindir}/mariadb
%{_bindir}/mariadb-access
%{_bindir}/mariadb-admin
%{_bindir}/mariadb-binlog
%{_bindir}/mariadb-check
%{_bindir}/mariadb-dump
%{_bindir}/mariadb-find-rows
%{_bindir}/mariadb-import
%{_bindir}/mariadb-plugin
%{_bindir}/mariadb-show
%{_bindir}/mariadb-slap
%{_bindir}/mariadb-waitpid
%{_bindir}/msql2mysql
%{_bindir}/mysql
%{_bindir}/mysql_find_rows
%{_bindir}/mysql_plugin
%{_bindir}/mysql_waitpid
%{_bindir}/mysqlaccess
%{_bindir}/mysqladmin
%{_bindir}/mysqlbinlog
%{_bindir}/mysqlcheck
%{_bindir}/mysqldump
%{_bindir}/mysqlimport
%{_bindir}/mysqlshow
%{_bindir}/mysqlslap
%{_bindir}/mytop
%doc %{_mandir}/man1/mariadb.1*
%doc %{_mandir}/man1/mariadb-access.1*
%doc %{_mandir}/man1/mariadb-admin.1*
%doc %{_mandir}/man1/mariadb-binlog.1*
%doc %{_mandir}/man1/mariadb-check.1*
%doc %{_mandir}/man1/mariadb-dump.1*
%doc %{_mandir}/man1/mariadb-find-rows.1*
%doc %{_mandir}/man1/mariadb-import.1*
%doc %{_mandir}/man1/mariadb-plugin.1*
%doc %{_mandir}/man1/mariadb-show.1*
%doc %{_mandir}/man1/mariadb-slap.1*
%doc %{_mandir}/man1/mariadb-waitpid.1*
%doc %{_mandir}/man1/msql2mysql.1*
%doc %{_mandir}/man1/mysql.1*
%doc %{_mandir}/man1/mysql_find_rows.1*
%doc %{_mandir}/man1/mysql_waitpid.1*
%doc %{_mandir}/man1/mysqlaccess.1*
%doc %{_mandir}/man1/mysqladmin.1*
%doc %{_mandir}/man1/mysqlbinlog.1*
%doc %{_mandir}/man1/mysqlcheck.1*
%doc %{_mandir}/man1/mysqldump.1*
%doc %{_mandir}/man1/mysqlimport.1*
%doc %{_mandir}/man1/mysql_plugin.1*
%doc %{_mandir}/man1/mysqlshow.1*
%doc %{_mandir}/man1/mysqlslap.1*
%doc %{_mandir}/man1/mytop.1*

%files devel
%defattr(-, root, root)
%doc %{_mandir}/man1/mysql_config.1*
%{_bindir}/mariadb-config
%{_bindir}/mariadb_config
%{_bindir}/mysql_config
%{_includedir}/mysql
%{_datadir}/aclocal/mysql.m4
%{_libdir}/pkgconfig/mariadb.pc
%{_libdir}/*.so
%{_sysconfdir}/rpm/*
%{_bindir}/mariadb-embedded
%{_bindir}/mysql_embedded
%doc %{_mandir}/man1/mariadb_config.1*
%doc %{_mandir}/man1/mariadb-embedded.1*
%doc %{_mandir}/man1/mysql_embedded.1*
%doc %{_mandir}/man3/*

%files static
%defattr(-,root,root)
%{_libdir}/lib*.a

%if %{with source}
%files source
%defattr(-, root, root)
%{_datadir}/mariadb-source
%endif

%files test
%defattr(-, root, root)
%attr(-, root, root) %{_datadir}/mysql-test
%{_bindir}/mariadb-client-test
%{_bindir}/mariadb-client-test-embedded
%{_bindir}/mariadb-test
%{_bindir}/mariadb-test-embedded
%{_bindir}/mysql_client_test
%{_bindir}/mysql_client_test_embedded
%{_bindir}/mysqltest_embedded
%{_bindir}/test-connect-t
%doc %{_mandir}/man1/mariadb-client-test-embedded.1*
%doc %{_mandir}/man1/mariadb-client-test.1*
%doc %{_mandir}/man1/mariadb-test-embedded.1*
%doc %{_mandir}/man1/mariadb-test.1*
%doc %{_mandir}/man1/mysql_client_test.1*
%doc %{_mandir}/man1/mysql-stress-test.pl.1*
%doc %{_mandir}/man1/mysql-test-run.pl.1*
%doc %{_mandir}/man1/mysql_client_test_embedded.1*
%doc %{_mandir}/man1/mysqltest_embedded.1*

%files embedded
%defattr(-,root,root)
%{_libdir}/libmariadbd.so.*


%changelog
* Wed Jun 19 2024 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.11.8-1
- new upstream release.
- updated patch1000.

* Tue Feb 13 2024 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.11.7-1
- new upstream release.
- updated patch1000.

* Wed Nov 15 2023 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.11.6-1
- new upstream release.
- updated patch1000.

* Tue Aug 15 2023 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.11.5-1
- new upstream release.
- updated patch1000.

* Wed Aug 02 2023 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.11.4-2
- updated patch1000.

* Wed Jun 07 2023 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.11.4-1
- new upstream release.
- updated patch1000.

* Tue Feb 07 2023 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.12-1
- new upstream release.
- updated patch1000.

* Tue Nov 08 2022 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.11-1
- new upstream release.
- updated patch1000.

* Tue Aug 16 2022 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.9-1
- new upstream release.
- updated patch1000.

* Sat May 21 2022 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.8-1
- new upstream release.
- updated patch1000.

* Sun Feb 13 2022 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.7-1
- new upstream release.
- updated patch1000.

* Tue Dec 28 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.5-6
- updated patch1000.

* Tue Nov 30 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.5-5
- updated patch1000.

* Tue Nov 09 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.5-4
- new upstream release.
- updated patch1000.
- forgot to reduce %%release.

* Wed Oct 06 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.4-4
- updated patch1000.
- rebuilt with openssl-3.0.0.

* Tue Aug 31 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.4-3
- updated patch1000.
- dropped Patch1001: merged into mroonga upstream.

* Sun Aug 29 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.4-2
- fixed systemd-unit.
- fixed locations of pidfile and logfile.

* Sat Aug 07 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.6.4-1
- new upstream release.
- updated patch1000.
- added Patch1001 to build mroonga with mariadb-10.6.

* Tue Jun 29 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.5.11-1
- new upstream release.
- updated patch1000.

* Sat May 08 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.5.10-1
- new upstream release.
- updated patch1000.
- dropped Patch1001: fixed in upstream.

* Tue Feb 23 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.5.9-1
- new upstream release.
- updated patch1000.
- dropped Patch2000: fixed in upstream.
- added Patch1001 to fix FTBFS.

* Thu Nov 12 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.5.8-1
- new upstream release.
- updated patch1000.
- added Patch2000 to fix failure on starting mariadbd.

* Wed Nov 04 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.5.7-1
- new upstream release.
- replaced patch1000 to update Groonga to v10.0.8.

* Thu Oct 08 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.5.6-1
- new upstream release.
- replaced patch1000 to update Groonga to v10.0.7.
- dropped Patch1001: fixed in upstream.

* Wed Aug 12 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.5.5-1
- new upstream release.
- replaced patch1000 to update Groonga to v10.0.5.
- added Patch1001 to fix FTBFS.
- disabled tokudb as default.

* Thu May 14 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.4.13-1
- new upstream release.
- replaced patch1000 to update Groonga to v10.0.2.
- added systemd support (disabled as default).

* Mon Feb 10 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.4.12-1
- new upstream release.
- replaced patch1000 to update Groonga to v9.1.2.

* Wed Dec 18 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.4.11-1
- new upstream release.
- replaced patch1000 to update Groonga to v9.1.0.

* Sat Nov 09 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.4.10-1
- new upstream release.

* Wed Nov 06 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.4.9-1
- new upstream release.
- replaced patch1000 to update Groonga to v9.0.9.

* Fri Aug 30 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.4.7-1
- new upstream release.
- replaced patch1000 to update Groonga to v9.0.7.

* Fri May 31 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.3.15-1
- new upstream release.
- replaced patch1000 to update Groonga to v9.0.3.
- added BR:lz4-devel.

* Sun May 05 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.3.14-1
- new upstream release.
- replaced patch1000 to update Groonga to v9.0.2.
- added a subpackage for galera cluster.
- enabled regexp with groonga.

* Thu Jan 31 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.3.12-1
- new upstream release.
- replaced patch1000 to update Groonga to v8.1.1.

* Fri Nov 30 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.3.11-1
- new upstream release.
- replaced patch1000 to update Mroonga to v8.09.

* Mon Nov 05 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.3.10-2
- drop shared client library.

* Mon Nov 05 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.3.10-1
- new upstream release.
- replaced patch1000 to update Mroonga to v8.07.

* Fri Mar 30 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.2.14-1
- new upstream release.
- replaced patch1000 to update Mroonga to v8.01.

* Sat Dec 02 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.2.11-1
- new upstream release.
- replaced patch1000 to update Mroonga to v7.09.

* Sun Jul 16 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.2.7-1
- new upstream release.
- replaced patch1000 to update Mroonga to v7.04.

* Thu May  4 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.23-1
- new upstream release.
- replaced patch1000 to update Mroonga to v7.02.

* Thu Mar 16 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.22-1
- new upstream release.
- replaced patch1000 to update Mroonga to v7.00.

* Wed Dec 21 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.20-1
- new upstream release.
- replaced patch1000 to update Mroonga to v6.11.

* Tue Jul 19 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.16-1
- new upstream release.
- replaced patch1000 to update Mroonga to v6.06.

* Wed May 11 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.14-1
- new upstream release.
- replaced patch1000 to update Mroonga to v6.02.

* Fri Apr  1 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.13-1
- new upstream release.
- replaced patch1000 to update Mroonga to v6.01.

* Tue Mar 15 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.12-1
- new upstream release.
- replaced patch1000 to update Mroonga to git HEAD.

* Sat Jan 30 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.11-1
- new upstream release.
- replaced patch1000 to update Mroonga to v5.12.

* Fri Jan  8 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.10-1
- new upstream release.
- replaced patch1000 to update Mroonga to v5.11.
- moved CONNECT and TokuDB storage engines to subpackages.

* Sun Nov 29 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.9-4
- replaced patch1000 to update Mroonga to git HEAD.

* Sat Nov 28 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.9-3
- replaced patch1000 to update Mroonga to git HEAD.

* Thu Nov 26 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.9-2
- replaced patch1000 to update Mroonga to git HEAD.

* Tue Nov 24 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.9-1
- new upstream release.
- replaced patch1000 to update Mroonga to git HEAD.

* Fri Oct 30 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.8-3
- added BR:jemalloc-devel.

* Thu Oct 29 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.8-2
- replaced patch1000 to update Mroonga to 5.09.

* Wed Oct 21 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.1.8-1
- new upstream release.
- replaced patch1000 for MariaDB 10.1.8.

* Fri Oct  9 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.21-3
- replaced patch1000 to update Mroonga to 5.08.

* Mon Aug 31 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.21-2
- replaced patch1000 to update Mroonga to 5.06.

* Mon Aug 10 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.21-1
- new upstream release.
- added patch1000 to update Mroonga from 5.02 to 5.05.

* Tue Jun 30 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.20-2
- fixed dependencies.

* Fri Jun 19 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.20-1
- new upstream release.

* Sun May 10 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.19-1
- new upstream release.

* Fri May  8 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.18-1
- new upstream release.

* Tue Mar  3 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.17-1
- new upstream release.

* Wed Jan 28 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.16-1
- new upstream release.

* Wed Nov 26 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.15-1
- new upstream release.
- enabled bundled Mroonga.

* Mon Sep 29 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.14-1
- new upstream release.

* Sat May 31 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.11-1
- new upstream release.

* Sun Apr 13 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.10-2
- fixed Conflicts: and Obsoletes:.

* Mon Mar 31 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.10-1
- new upstream release.

* Mon Mar 24 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.9-1
- new upstream release.

* Tue Feb 11 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.8-1
- new upstream release.

* Sat Dec 07 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.6-2
- removed duplicated files.

* Wed Dec 04 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.6-1
- switched to MariaDB.

* Wed Feb 20 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.5.30-1
- new upstream release.

* Fri Nov 16 2012 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.5.28-1
- new upstream release.

* Sat Sep 15 2012 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.5.27-1
- new upstream release.
- added a sub-package "MySQL-source".
- added some macros for rpm.

* Thu Jun 21 2012 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.5.25-1
- new upstream release.

* Thu May 10 2012 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.5.24-1
- new upstream release.

* Tue May 01 2012 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.5.23-1
- new upstream release.
- added "Vendor:" and "Distribution:" tag.

* Tue Aug 23 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.5.15-1
- new upstream release.
- removed NDB cluster support.

* Mon Apr 18 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.56-3
- Added "BR: zlib-devel" to MySQL-devel.

* Sun Apr 03 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.56-2
- Added "BR: openssl-devel" to MySQL-devel.

* Fri Mar 11 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.56-1
- new upstream release.

* Mon Jan 10 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.54-1
- new upstream release.
- updated jp-patch.
- added ssl support.

* Sat Nov 06 2010 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.52-1
- new upstream release.
- replaced '%%__find_requires' to '%%__perl_requires'.
- updated jp-patch.

* Fri Oct 29 2010 Shu KONNO <owa@bg.wakwak.com> 5.1.44-3
- added mysql-5.1.44-lib64.patch (on x86_64)
- added -fPIC (on x86_64)

* Sun Oct 17 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 5.1.44-2
- made embedded package again

* Fri Mar 05 2010 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.44-1
- new upstream release.
- updated jp-patch.

* Thu Feb 04 2010 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.43-2
- VineSeed: rebuilt with new toolchain.

* Wed Feb 03 2010 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.43-1
- new upstream release.
  - fixed CVE-2009-4484.

* Fri Nov 20 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.41-1
- new upstream release.

* Thu Nov 19 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.40-2
- added net-tools to 'Requires'.
- added groff to 'BuildRequires'.
- renamed subpackage 'MySQL-shared' to 'libmysqlclient16' (VineSeed only).

* Tue Nov 10 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.40-1
- new upstream release.

* Sat Sep 26 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.39-1
- new upstream release.

* Sun Jul  5 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.36-1
- new upstream release.
- dropped %%Patch100 (fixed in upstream).

* Sat Jun  6 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.35-1
- new upstream release.
- add %%Patch100 (no longer needed for MySQL-5.1.36 or later).

* Thu May 21 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.34-1
- new upstream release.
- rename 'MySQL-bench' to 'MySQL-test'.
- update Patch0.
- change default charset to 'utf8'.

* Sat Apr 12 2008 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 5.0.51a-1
- new upstream release.
- update Patch0.
- add "--with-client-charset=ujis".
- sync %%files to official RPM.
- remove MySQL-Max.

* Thu Dec 13 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 5.0.27-0vl7
- for VineSeed

* Thu Dec 13 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 5.0.27-0vl6
- move shared library from /usr/lib/ to /usr/lib/mysql/
- add /etc/ld.so.conf.d/*.conf
- fix broken libmysqlcient*.la files (or should we remove them permanently?)

* Sat Jun 16 2007 IWAI, Masaharu <iwai@alib.jp> 5.0.27-0vl5
- rebuild <BTS:VineLinux:534>

* Mon Nov 13 2006 NAKAMURA Kenta <kenta@vinelinux.org> 5.0.27-0vl4
- added -fPIC

* Mon Oct 30 2006 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 5.0.27-0vl3
- fixed dependency. <BTS:338>

* Mon Oct 30 2006 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 5.0.27-0vl2
- add %%Patch1. <BTS:320>

* Sat Oct 28 2006 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 5.0.27-0vl1
- new upstream release.

* Fri Oct 27 2006 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 5.0.26-0vl1
- new upstream release.

* Sat Jun  3 2006 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 5.0.22-0vl1
- new upstream release.

* Sat May 13 2006 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 5.0.21-0vl1
- release++.

* Wed May 10 2006 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 5.0.21-0vl0
- new upstream release.
- for VineSeed.

* Wed Feb  8 2006 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 4.1.16-0vl0
- new upstream release.
- replace Patch0 for MySQL-4.1.16.

* Thu Oct  6 2005 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 4.1.14-0vl0
- new upstream release.
- add Patch0.

* Tue Sep 6 2005 Takeyuki FUJIOKA <fuji@ftserve.net> 4.0.25-0vl0
- new upstream version
	-- mysql-4.0.25

* Fri Jan 21 2005 Takeyuki FUJIOKA <fuji@ftserve.net> 4.0.23-0vl0
- new upstream version
	-- mysql-4.0.23

* Tue Sep 28 2004 Takeyuki FUJIOKA <fuji@ftserve.net> 4.0.22-0vl0
- new upstream version
	-- mysql-4.0.22
 
* Tue Sep 28 2004 Takeyuki FUJIOKA <fuji@ftserve.net> 4.0.21-0vl1
- new upstream version
	-- mysql-4.0.21
 
* Fri May 21 2004 Satoshi MACHINO <machino@vinelinux.org> 4.0.20-0vl1
- new upstream version
	-- mysql-4.0.20
 
* Tue May 04 2004 Tomoya TAKA <taka@vinelinux.org> 4.0.18-0vl2
- modify CFLAGS, CXXFLAGS and configure options for alpha

* Tue Mar 23 2004 Satoshi MACHINO <machino@vinelinux.org> 4.0.18-0vl1
- Upgraded to MySQL-4
- added "with-charset=ujis" and "without-readline" to configure (vineseed-plus-02150)
- merged to MySQL Official packages
	-- renamed package "MySQL" to "MySQL-server"
	-- when using gcc, _always_ use CXX=gcc 
	-- replaced Copyright with License field (Copyright is obsolete)
	-- added myisam_ftdump to the Server package
	-- marked /etc/logrotate.d/mysql as a config file (BUG 2156)
	-- fixed file permissions (BUG 1672)
	-- removed dependency on MySQL-client from the MySQL-devel subpackage
	-- as it is not really required. (BUG 1610)
	-- Fixed BUG 1162 (removed macro names from the changelog)
	-- Really fixed BUG 998 (disable the checking for installed but
	--  unpackaged files)
	-- Fixed BUG 959 (libmysqld not being compiled properly)
	-- Fixed BUG 998 (RPM build errors): added missing files to the
	-- distribution (mysql_fix_extensions, mysql_tableinfo, mysqldumpslow,
	-- mysql_fix_privilege_tables.1), removed "-n" from install section.
	-- removed the GIF Icon (file was not included in the sources anyway)
	-- removed unused variable shared_lib_version
	-- do not run automake before building the standard binary
	--  (should not be necessary)
	-- add server suffix '-standard' to standard binary (to be in line
	-- with the binary tarball distributions)
	-- allow overriding CC and CXX (required when building 
	-- with other compilers)

* Mon Apr 14 2003 KOBAYASHI R. Taizo <tkoba@vinelinux.org> 3.23.56-0vl5
- added BuildRequires:  automake16
                                                                                
* Thu Apr 03 2003 Tomoya TAKA <taka@vinelinux.org> 3.23.56-0vl3
- add '-fPIC -DPIC' to CFLAGS on alpha
- little fix of spec file
                                                                                
* Thu Mar 27 2003 Tomoya TAKA <taka@vinelinux.org> 3.23.56-0vl2
- enable MySQL-shared subpackage for alpha
- delete 'BuildPrereq: kernel24-headers' for alpha
- fix shared %files (exclude sparc)
                                                                                
* Tue Mar 18 2003 Satoshi MACHINO <machino@vinelinux.org> 3.23.56-0vl1
- new upstream version
                                                                                
* Sun Mar  9 2003 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 3.23.55-0vl2
- fixed devel %files (dropped *.la files)
                                                                                
* Tue Jan 28 2003 Satoshi MACHINO <machino@vinelinux.org> 3.23.55-0vl1
- new upstream version
- fixed document permission
                                                                                
* Sat Dec 21 2002 Satoshi MACHINO <machino@vinelinux.org> 3.23.54a-0vl1
- new upstream version
                                                                                
* Sat Oct 19 2002 Satoshi MACHINO <machino@vinelinux.org> 3.23.53-0vl2
- dropped MySQL-Max sub-pakage for sparc/sparc64/alpha
        -- don't work
                                                                                
* Wed Oct 16 2002 Satoshi MACHINO <machino@vinelinux.org> 3.23.53-0vl1
- new upstream version
- diseble-assembler in configure on sparc,sparc64,alpha
                                                                                
* Wed Aug 21 2002 Satoshi MACHINO <machino@vinelinux.org> 3.23.52-0vl1
- new upstream version
- moved some man files to main package
- added enable-local-infile in configure
- changed --with-extra-charsets=all in configure
                                                                                
* Fri Jun 14 2002 Satoshi MACHINO <machino@vinelinux.org> 3.23.51-0vl2
- fixed changelog
                                                                                
* Thu Jun 13 2002 Satoshi MACHINO <machino@vinelinux.org> 3.23.51-0vl1
- updated to mysql-3.23.51
                                                                                
* Fri Mar 15 2002 Satoshi MACHINO <machino@vinelinux.org> 3.23.49-0vl2
- rebuild on zlib-1.1.4(security fix.)
                                                                                
* Mon Feb 18 2002 Satoshi MACHINO <machino@vinelinux.org> 3.23.49-0vl1
- updated to mysql-2.23.49
                                                                                
* Tue Feb 12 2002 Tomoya TAKA <taka@vinelinux.org> 3.23.48-0vl2
- add 'BuildPrereq: kernel24-headers' on alpha
- remove shared library and max on alpha
                                                                                
* Tue Feb 12 2002 Satoshi MACHINO <machino@vinelinux.org> 3.23.48-0vl1
- updated to mysql-3.23.48
                                                                                
* Thu Jan 03 2002 Satoshi MACHINO <machino@vinelinux.org> 3.23.47-0vl1
- updated to mysql-3.23.47
                                                                                
* Wed Dec 05 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.46-0vl1
- updated to mysql-3.23.46
                                                                                
* Thu Nov 29 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.45-0vl1
- updated to mysql-3.23.45
                                                                                
* Mon Nov 12 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.44-0vl1
- updated to mysql-3.23.44
                                                                                
* Sat Oct 13 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.43-0vl1
- updated to mysql-3.23.43
- removed shared library and max on sparc
                                                                                
* Wed Sep 12 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.42-0vl1
- updated to mysql-3.23.42
- changed MYSQL_BUILD_CC: and MYSQL_BUILD_XCC: to -gcc
                                                                                
* Thu Aug 30 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.41-0vl1
- updated to mysql-3.23.41
                                                                                
* Wed Aug 22 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.40-0vl1
- updated to mysql-3.23.40
                                                                                
* Tue Jul 10 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.39-0vl1
- updated to mysql-3.23.39

* Fri Jun 15 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.38-1vl2
- added configure --with-charset=ujis
                                                                                
* Sun May 27 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.38-1vl2
- used some rpmmacro
                                                                                
* Fri May 25 2001 Satoshi MACHINO <machino@vinelinux.org> 3.23.38-1vl1
- updated to MySQL-3.23.38
                                                                                
* Thu Dec 07 2000 Satoshi MACHINO <machino@vinelinux.org> 3.23.28-1vl2
- removed Bench pakages
                                                                                
* Tue Dec 05 2000 Satoshi MACHINO <machino@vinelinux.org> 3.23.28-1vl1
- removed pt_BR locale
- build on Vine Linux
- partially used rpmmacros
- added %clean tag
                                                                                
* Fri Aug 18 2000 Tim Smith <tim@mysql.com>
- Added separate libmysql_r directory; now both a threaded
  and non-threaded library is shipped.
                                                                                
* Tue Sep 28 1999 David Axmark <davida@mysql.com>
- Added the support-files/my-example.cnf to the docs directory.
- Removed devel dependency on base since it is about client
  development.
                                                                                
* Wed Sep 8 1999 David Axmark <davida@mysql.com>
- Cleaned up some for 3.23.
                                                                                
* Thu Jul 1 1999 David Axmark <davida@mysql.com>
- Added support for shared libraries in a separate sub
  package. Original fix by David Fox (dsfox@cogsci.ucsd.edu)
- The --enable-assembler switch is now automatically disables on
  platforms there assembler code is unavailable. This should allow
  building this RPM on non i386 systems.
                                                                                
* Mon Feb 22 1999 David Axmark <david@detron.se>
- Removed unportable cc switches from the spec file. The defaults can
  now be overridden with environment variables. This feature is used
  to compile the official RPM with optimal (but compiler version
  specific) switches.
- Removed the repetitive description parts for the sub rpms. Maybe add
  again if RPM gets a multiline macro capability.
- Added support for a pt_BR translation. Translation contributed by
  Jorge Godoy <jorge@bestway.com.br>.
                                                                                
* Wed Nov 4 1998 David Axmark <david@detron.se>
- A lot of changes in all the rpm and install scripts. This may even
  be a working RPM :-)
                                                                                
* Sun Aug 16 1998 David Axmark <david@detron.se>
- A developers changelog for MySQL is available in the source RPM. And
  there is a history of major user visible changed in the Reference
  Manual.  Only RPM specific changes will be documented here.

