Synchronize FC6 with recent work in 4E-stacks branch.
This commit is contained in:
parent
b367ab972a
commit
587f6c6241
81
mysql-install-test.patch
Normal file
81
mysql-install-test.patch
Normal file
@ -0,0 +1,81 @@
|
|||||||
|
mysql's idea of a suitable place to install the regression tests is
|
||||||
|
/usr/mysql-test. To relocate this to a reasonably FHS-compliant place
|
||||||
|
like /usr/share/mysql-test, we have to hack up the paths in install_test_db
|
||||||
|
and mysql-test-run. This patch also improves the documentation a tad.
|
||||||
|
|
||||||
|
|
||||||
|
diff -Naur mysql-5.0.18.orig/mysql-test/README mysql-5.0.18/mysql-test/README
|
||||||
|
--- mysql-5.0.18.orig/mysql-test/README 2005-12-21 14:39:48.000000000 -0500
|
||||||
|
+++ mysql-5.0.18/mysql-test/README 2006-03-09 20:29:24.000000000 -0500
|
||||||
|
@@ -2,11 +2,20 @@
|
||||||
|
the currently existing test cases, simply execute ./mysql-test-run in
|
||||||
|
this directory. It will fire up the newly built mysqld and test it.
|
||||||
|
|
||||||
|
+For use in Red Hat distributions, you should run the script as user mysql,
|
||||||
|
+so the best bet is something like
|
||||||
|
+ cd /usr/share/mysql-test
|
||||||
|
+ sudo -u mysql ./mysql-test-run
|
||||||
|
+This will use the installed mysql executables, but will run a private copy
|
||||||
|
+of the server process (using data files within /usr/share/mysql-test),
|
||||||
|
+so you need not start the mysqld service beforehand.
|
||||||
|
+
|
||||||
|
If you want to run a test with a running MySQL server use the --extern
|
||||||
|
option to mysql-test-run. Please note that in this mode the test suite
|
||||||
|
expects user to specify test names to run. Otherwise it falls back to the
|
||||||
|
-normal "non-extern" behaviour. The reason is that some tests
|
||||||
|
-could not run with external server. Here is the sample command
|
||||||
|
+normal "non-extern" behaviour. The reason is that many tests
|
||||||
|
+will fail with external server (because they need to control the options
|
||||||
|
+with which the server is started). Here is the sample command
|
||||||
|
to test "alias" and "analyze" tests on external server:
|
||||||
|
|
||||||
|
mysql-test-run --extern alias analyze
|
||||||
|
diff -Naur mysql-5.0.18.orig/mysql-test/install_test_db.sh mysql-5.0.18/mysql-test/install_test_db.sh
|
||||||
|
--- mysql-5.0.18.orig/mysql-test/install_test_db.sh 2005-12-21 14:39:48.000000000 -0500
|
||||||
|
+++ mysql-5.0.18/mysql-test/install_test_db.sh 2006-03-09 20:20:45.000000000 -0500
|
||||||
|
@@ -9,17 +9,17 @@
|
||||||
|
shift 1
|
||||||
|
|
||||||
|
# Check if it's a binary distribution or a 'make install'
|
||||||
|
- if test -x ../libexec/mysqld
|
||||||
|
+ if test -x /usr/libexec/mysqld
|
||||||
|
then
|
||||||
|
- execdir=../libexec
|
||||||
|
+ execdir=/usr/libexec
|
||||||
|
else
|
||||||
|
- execdir=../bin
|
||||||
|
+ execdir=/usr/bin
|
||||||
|
fi
|
||||||
|
- bindir=../bin
|
||||||
|
+ bindir=/usr/bin
|
||||||
|
BINARY_DIST=1
|
||||||
|
fix_bin=mysql-test
|
||||||
|
- scriptdir=../bin
|
||||||
|
- libexecdir=../libexec
|
||||||
|
+ scriptdir=/usr/bin
|
||||||
|
+ libexecdir=/usr/libexec
|
||||||
|
else
|
||||||
|
execdir=../sql
|
||||||
|
bindir=../client
|
||||||
|
@@ -75,7 +75,8 @@
|
||||||
|
|
||||||
|
#for error messages
|
||||||
|
if [ x$BINARY_DIST = x1 ] ; then
|
||||||
|
-basedir=..
|
||||||
|
+basedir=/usr/share
|
||||||
|
+EXTRA_ARG="--language=/usr/share/mysql/english/ --character-sets-dir=/usr/share/mysql/charsets/"
|
||||||
|
else
|
||||||
|
basedir=.
|
||||||
|
EXTRA_ARG="--language=../sql/share/english/ --character-sets-dir=../sql/share/charsets/"
|
||||||
|
diff -Naur mysql-5.0.18.orig/mysql-test/mysql-test-run.sh mysql-5.0.18/mysql-test/mysql-test-run.sh
|
||||||
|
--- mysql-5.0.18.orig/mysql-test/mysql-test-run.sh 2005-12-21 14:39:59.000000000 -0500
|
||||||
|
+++ mysql-5.0.18/mysql-test/mysql-test-run.sh 2006-03-09 20:20:45.000000000 -0500
|
||||||
|
@@ -693,6 +693,8 @@
|
||||||
|
# currently all binaries are in "bin", for a MySQL AB packaging
|
||||||
|
# some are in "tests".
|
||||||
|
|
||||||
|
+ BASEDIR="/usr"
|
||||||
|
+
|
||||||
|
if test -x "$BASEDIR/libexec/mysqld"
|
||||||
|
then
|
||||||
|
MYSQLD="$VALGRIND $BASEDIR/libexec/mysqld"
|
57
mysql.spec
57
mysql.spec
@ -1,6 +1,6 @@
|
|||||||
Name: mysql
|
Name: mysql
|
||||||
Version: 5.0.18
|
Version: 5.0.18
|
||||||
Release: 2.1
|
Release: 4
|
||||||
Summary: MySQL client programs and shared libraries.
|
Summary: MySQL client programs and shared libraries.
|
||||||
License: GPL
|
License: GPL
|
||||||
Group: Applications/Databases
|
Group: Applications/Databases
|
||||||
@ -11,7 +11,6 @@ URL: http://www.mysql.com
|
|||||||
|
|
||||||
Source0: http://dev.mysql.com/get/Downloads/MySQL-5.0/mysql-%{version}.tar.gz
|
Source0: http://dev.mysql.com/get/Downloads/MySQL-5.0/mysql-%{version}.tar.gz
|
||||||
Source1: mysql.init
|
Source1: mysql.init
|
||||||
Source2: mysql.logrotate
|
|
||||||
Source3: my.cnf
|
Source3: my.cnf
|
||||||
Source4: scriptstub.c
|
Source4: scriptstub.c
|
||||||
Source5: my_config.h
|
Source5: my_config.h
|
||||||
@ -24,6 +23,7 @@ Patch4: mysql-testing.patch
|
|||||||
Patch5: mysql-no-atomic.patch
|
Patch5: mysql-no-atomic.patch
|
||||||
Patch6: mysql-rpl_ddl.patch
|
Patch6: mysql-rpl_ddl.patch
|
||||||
Patch7: mysql-rpl-test.patch
|
Patch7: mysql-rpl-test.patch
|
||||||
|
Patch8: mysql-install-test.patch
|
||||||
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
||||||
Prereq: /sbin/ldconfig, /sbin/install-info, grep, fileutils, chkconfig
|
Prereq: /sbin/ldconfig, /sbin/install-info, grep, fileutils, chkconfig
|
||||||
@ -90,6 +90,19 @@ MySQL is a multi-user, multi-threaded SQL database server. This
|
|||||||
package contains benchmark scripts and data for use when benchmarking
|
package contains benchmark scripts and data for use when benchmarking
|
||||||
MySQL.
|
MySQL.
|
||||||
|
|
||||||
|
%package test
|
||||||
|
|
||||||
|
Summary: The test suite distributed with MySQL.
|
||||||
|
License: GPL
|
||||||
|
Group: Applications/Databases
|
||||||
|
Requires: %{name} = %{version}-%{release}
|
||||||
|
Requires: %{name}-server = %{version}-%{release}
|
||||||
|
|
||||||
|
%description test
|
||||||
|
MySQL is a multi-user, multi-threaded SQL database server. This
|
||||||
|
package contains the regression test suite distributed with
|
||||||
|
the MySQL sources.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
|
|
||||||
@ -100,6 +113,7 @@ MySQL.
|
|||||||
%patch5 -p1
|
%patch5 -p1
|
||||||
%patch6 -p1
|
%patch6 -p1
|
||||||
%patch7 -p1
|
%patch7 -p1
|
||||||
|
%patch8 -p1
|
||||||
|
|
||||||
libtoolize --force
|
libtoolize --force
|
||||||
aclocal
|
aclocal
|
||||||
@ -153,33 +167,40 @@ make check
|
|||||||
rm -rf $RPM_BUILD_ROOT
|
rm -rf $RPM_BUILD_ROOT
|
||||||
|
|
||||||
%makeinstall
|
%makeinstall
|
||||||
install -m 644 include/my_config.h $RPM_BUILD_ROOT/usr/include/mysql/my_config_`uname -i`.h
|
|
||||||
install -m 644 %{SOURCE5} $RPM_BUILD_ROOT/usr/include/mysql/
|
# multilib header hack
|
||||||
|
# we only apply this to known Red Hat multilib arches, per bug #181335
|
||||||
|
case `uname -i` in
|
||||||
|
i386 | x86_64 | ppc | ppc64 | s390 | s390x)
|
||||||
|
install -m 644 include/my_config.h $RPM_BUILD_ROOT/usr/include/mysql/my_config_`uname -i`.h
|
||||||
|
install -m 644 %{SOURCE5} $RPM_BUILD_ROOT/usr/include/mysql/
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/var/log
|
mkdir -p $RPM_BUILD_ROOT/var/log
|
||||||
touch $RPM_BUILD_ROOT/var/log/mysqld.log
|
touch $RPM_BUILD_ROOT/var/log/mysqld.log
|
||||||
|
|
||||||
# List the installed tree for RPM package maintenance purposes.
|
# List the installed tree for RPM package maintenance purposes.
|
||||||
find $RPM_BUILD_ROOT -print | sed "s|^$RPM_BUILD_ROOT||" | sort > ROOTFILES
|
find $RPM_BUILD_ROOT -print | sed "s|^$RPM_BUILD_ROOT||" | sort > ROOTFILES
|
||||||
gzip ${RPM_BUILD_ROOT}%{_infodir}/*
|
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/mysql-*.spec
|
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/mysql-log-rotate
|
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/etc/{rc.d/init.d,logrotate.d}
|
gzip ${RPM_BUILD_ROOT}%{_infodir}/*
|
||||||
|
|
||||||
|
mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d
|
||||||
mkdir -p $RPM_BUILD_ROOT/var/run/mysqld
|
mkdir -p $RPM_BUILD_ROOT/var/run/mysqld
|
||||||
install -m 0755 -d $RPM_BUILD_ROOT/var/lib/mysql
|
install -m 0755 -d $RPM_BUILD_ROOT/var/lib/mysql
|
||||||
install -m 0755 %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/mysqld
|
install -m 0755 %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/mysqld
|
||||||
install -m 0644 %{SOURCE2} $RPM_BUILD_ROOT/etc/logrotate.d/mysqld
|
|
||||||
install -m 0644 %{SOURCE3} $RPM_BUILD_ROOT/etc/my.cnf
|
install -m 0644 %{SOURCE3} $RPM_BUILD_ROOT/etc/my.cnf
|
||||||
rm -f $RPM_BUILD_ROOT/%{_infodir}/dir*
|
rm -f $RPM_BUILD_ROOT/%{_infodir}/dir*
|
||||||
mv $RPM_BUILD_ROOT/usr/sql-bench $RPM_BUILD_ROOT%{_datadir}/sql-bench
|
mv $RPM_BUILD_ROOT/usr/sql-bench $RPM_BUILD_ROOT%{_datadir}/sql-bench
|
||||||
|
mv $RPM_BUILD_ROOT/usr/mysql-test $RPM_BUILD_ROOT%{_datadir}/mysql-test
|
||||||
|
|
||||||
mv ${RPM_BUILD_ROOT}%{_bindir}/mysqlbug ${RPM_BUILD_ROOT}%{_libdir}/mysql/mysqlbug
|
mv ${RPM_BUILD_ROOT}%{_bindir}/mysqlbug ${RPM_BUILD_ROOT}%{_libdir}/mysql/mysqlbug
|
||||||
install -m 0755 scriptstub ${RPM_BUILD_ROOT}%{_bindir}/mysqlbug
|
install -m 0755 scriptstub ${RPM_BUILD_ROOT}%{_bindir}/mysqlbug
|
||||||
mv ${RPM_BUILD_ROOT}%{_bindir}/mysql_config ${RPM_BUILD_ROOT}%{_libdir}/mysql/mysql_config
|
mv ${RPM_BUILD_ROOT}%{_bindir}/mysql_config ${RPM_BUILD_ROOT}%{_libdir}/mysql/mysql_config
|
||||||
install -m 0755 scriptstub ${RPM_BUILD_ROOT}%{_bindir}/mysql_config
|
install -m 0755 scriptstub ${RPM_BUILD_ROOT}%{_bindir}/mysql_config
|
||||||
|
|
||||||
rm -fr $RPM_BUILD_ROOT/usr/mysql-test
|
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_bindir}/*client_test
|
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_bindir}/comp_err
|
rm -f ${RPM_BUILD_ROOT}%{_bindir}/comp_err
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_bindir}/make_win_binary_distribution
|
rm -f ${RPM_BUILD_ROOT}%{_bindir}/make_win_binary_distribution
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_bindir}/make_win_src_distribution
|
rm -f ${RPM_BUILD_ROOT}%{_bindir}/make_win_src_distribution
|
||||||
@ -195,6 +216,8 @@ rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/MySQL-shared-compat.spec
|
|||||||
rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/*.plist
|
rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/*.plist
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/preinstall
|
rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/preinstall
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/postinstall
|
rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/postinstall
|
||||||
|
rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/mysql-*.spec
|
||||||
|
rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/mysql-log-rotate
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/etc/ld.so.conf.d
|
mkdir -p $RPM_BUILD_ROOT/etc/ld.so.conf.d
|
||||||
echo "%{_libdir}/mysql" > $RPM_BUILD_ROOT/etc/ld.so.conf.d/%{name}-%{_arch}.conf
|
echo "%{_libdir}/mysql" > $RPM_BUILD_ROOT/etc/ld.so.conf.d/%{name}-%{_arch}.conf
|
||||||
@ -364,7 +387,6 @@ fi
|
|||||||
%{_datadir}/mysql/mysql_fix_privilege_tables.sql
|
%{_datadir}/mysql/mysql_fix_privilege_tables.sql
|
||||||
/etc/rc.d/init.d/mysqld
|
/etc/rc.d/init.d/mysqld
|
||||||
%attr(0755,mysql,mysql) %dir /var/run/mysqld
|
%attr(0755,mysql,mysql) %dir /var/run/mysqld
|
||||||
%config(noreplace) /etc/logrotate.d/mysqld
|
|
||||||
%attr(0755,mysql,mysql) %dir /var/lib/mysql
|
%attr(0755,mysql,mysql) %dir /var/lib/mysql
|
||||||
%attr(0640,mysql,mysql) %config(noreplace) %verify(not md5 size mtime) /var/log/mysqld.log
|
%attr(0640,mysql,mysql) %config(noreplace) %verify(not md5 size mtime) /var/log/mysqld.log
|
||||||
|
|
||||||
@ -379,7 +401,18 @@ fi
|
|||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%{_datadir}/sql-bench
|
%{_datadir}/sql-bench
|
||||||
|
|
||||||
|
%files test
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%{_bindir}/mysql_client_test
|
||||||
|
%attr(-,mysql,mysql) %{_datadir}/mysql-test
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Mar 27 2006 Tom Lane <tgl@redhat.com> 5.0.18-4
|
||||||
|
- Modify multilib header hack to not break non-RH arches, per bug #181335
|
||||||
|
- Remove logrotate script, per bug #180639.
|
||||||
|
- Add a new mysql-test RPM to carry the regression test files;
|
||||||
|
hack up test scripts as needed to make them run in /usr/share/mysql-test.
|
||||||
|
|
||||||
* Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 5.0.18-2.1
|
* Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 5.0.18-2.1
|
||||||
- bump again for double-long bug on ppc(64)
|
- bump again for double-long bug on ppc(64)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user