SPECS (DEVEL): mysql.spec - up to 5.0.13
arekm
arekm at pld-linux.org
Thu Sep 29 20:46:04 CEST 2005
Author: arekm Date: Thu Sep 29 18:46:04 2005 GMT
Module: SPECS Tag: DEVEL
---- Log message:
- up to 5.0.13
---- Files affected:
SPECS:
mysql.spec (1.259.2.2 -> 1.259.2.3)
---- Diffs:
================================================================
Index: SPECS/mysql.spec
diff -u SPECS/mysql.spec:1.259.2.2 SPECS/mysql.spec:1.259.2.3
--- SPECS/mysql.spec:1.259.2.2 Tue Apr 26 13:36:16 2005
+++ SPECS/mysql.spec Thu Sep 29 20:45:59 2005
@@ -8,9 +8,12 @@
# Conditional build:
%bcond_with bdb # Berkeley DB support
%bcond_without innodb # Without InnoDB support
+%bcond_without isam # Without ISAM table format (used in mysql 3.22)
%bcond_without raid # Without raid
%bcond_without ssl # Without OpenSSL
%bcond_without tcpd # Without libwrap (tcp_wrappers) support
+%bcond_with big_tables # enable '--with-big-tables', some performance loss on 32bit arch,
+ # but can do >= 4GB database tables.
#
%include /usr/lib/rpm/macros.perl
Summary: MySQL: a very fast and reliable SQL database engine
@@ -23,11 +26,11 @@
Summary(zh_CN): MySQLĘýžÝżâˇţÎńĆ÷
Name: mysql
Group: Applications/Databases
-Version: 5.0.3
+Version: 5.0.13
Release: 0.1
License: GPL + MySQL FLOSS Exception
-Source0: http://mysql.mirror.anlx.net/Downloads/MySQL-5.0/%{name}-%{version}-beta.tar.gz
-# Source0-md5: 15913b736389992bd031fd1dbe6f4dfe
+Source0: http://sunsite.icm.edu.pl/mysql/Downloads/MySQL-5.0/%{name}-%{version}-rc.tar.gz
+# Source0-md5: d9500d81b4253142a2a3c68b53942aab
Source1: %{name}.init
Source2: %{name}.sysconfig
Source3: %{name}.logrotate
@@ -40,6 +43,7 @@
Source10: %{name}-ndb-mgm.sysconfig
Source11: %{name}-ndb-cpc.init
Source12: %{name}-ndb-cpc.sysconfig
+Source13: %{name}-client.conf
Patch0: %{name}-libs.patch
Patch1: %{name}-libwrap.patch
Patch2: %{name}-c++.patch
@@ -47,12 +51,11 @@
Patch4: %{name}-sql-cxx-pic.patch
Patch5: %{name}-noproc.patch
Patch6: %{name}-fix_privilege_tables.patch
-Patch7: %{name}-nptl.patch
-Patch8: %{name}-align.patch
+Patch7: %{name}-align.patch
+Patch8: %{name}-client-config.patch
+Patch9: %{name}-build.patch
Icon: mysql.gif
URL: http://www.mysql.com/
-#BuildRequires: ORBit-devel
-BuildRequires: /bin/ps
BuildRequires: autoconf
BuildRequires: automake
%{?with_bdb:BuildRequires: db3-devel}
@@ -65,7 +68,7 @@
BuildRequires: perl-devel >= 1:5.6.1
BuildRequires: readline-devel >= 4.2
BuildRequires: rpm-perlprov >= 4.1-13
-BuildRequires: rpmbuild(macros) >= 1.159
+BuildRequires: rpmbuild(macros) >= 1.228
BuildRequires: texinfo
BuildRequires: zlib-devel
PreReq: rc-scripts >= 0.2.0
@@ -76,6 +79,7 @@
Requires(postun): /usr/sbin/userdel
Requires(postun): /usr/sbin/groupdel
Requires(post,preun): /sbin/chkconfig
+Requires(triggerpostun): sed >= 4.0
Requires: %{name}-libs = %{version}-%{release}
Requires: /usr/bin/setsid
Provides: MySQL-server
@@ -253,6 +257,7 @@
Summary(pl): Biblioteki dzielone MySQL
Group: Applications/Databases
Obsoletes: libmysql10
+Obsoletes: mysql-doc < 4.1.12
%description libs
Shared libraries for MySQL.
@@ -410,7 +415,7 @@
Ten pakiet zawiera standardowego demona MySQL NDB CPC.
%prep
-%setup -q -n %{name}-%{version}-beta
+%setup -q -n %{name}-%{version}-rc
%patch0 -p1
%{?with_tcpd:%patch1 -p1}
%patch2 -p1
@@ -425,6 +430,7 @@
%patch6 -p1
%patch7 -p1
%patch8 -p1
+%patch9 -p1
%{__perl} -pi -e 's@(ndb_bin_am_ldflags)="-static"@$1=""@' configure.in
@@ -433,9 +439,15 @@
%{__aclocal}
%{__automake}
%{__autoconf}
+
# The compiler flags are as per their "official" spec ;)
CXXFLAGS="%{rpmcflags} -felide-constructors -fno-rtti -fno-exceptions %{!?debug:-fomit-frame-pointer}"
CFLAGS="%{rpmcflags} %{!?debug:-fomit-frame-pointer}"
+
+# NOTE: the PS, FIND_PROC, KILL, CHECK_PID are not used by PLD Linux
+# and therefore do not add BR on these. These are here just to satisfy
+# configure.
+
%configure \
PS='/bin/ps' \
FIND_PROC='/bin/ps p $$PID' \
@@ -447,9 +459,11 @@
--enable-thread-safe-client \
--with%{!?with_bdb:out}-berkeley-db \
--with%{!?with_innodb:out}-innodb \
+ --with%{!?with_isam:out}-isam \
--with%{!?with_raid:out}-raid \
--with%{!?with_ssl:out}-openssl \
--with%{!?with_tcpd:out}-libwrap \
+ %{?with_big_tables:--with-big-tables} \
--with-comment="PLD Linux Distribution MySQL RPM" \
--with%{!?debug:out}-debug \
--with-embedded-server \
@@ -457,13 +471,15 @@
--with-low-memory \
--with-mysqld-user=mysql \
--with-named-curses-libs="-lncurses" \
- --with-pthread \
+ --with-named-thread-libs="-lpthread" \
--with-unix-socket-path=/var/lib/mysql/mysql.sock \
--with-vio \
--with-ndbcluster \
--without-readline \
+ --without-libedit \
--without-docs
# --with-mysqlfs
+# --with-ndb-test --with-ndb-docs
# NOTE that /var/lib/mysql/mysql.sock is symlink to real sock file
# (it defaults to first cluster but user may change it to whatever
@@ -504,7 +520,7 @@
install %{SOURCE4} mysqld.conf
install %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/mysql/clusters.conf
install %{SOURCE6} $RPM_BUILD_ROOT%{_sysconfdir}/monit
-touch $RPM_BUILD_ROOT/var/log/mysql/{err,log,update}
+touch $RPM_BUILD_ROOT/var/log/mysql/{err,log,update,isamlog.log}
# remove innodb directives from mysqld.conf if mysqld is configured without
%if %{without innodb}
@@ -519,6 +535,7 @@
%endif
install mysqld.conf $RPM_BUILD_ROOT%{_datadir}/mysql/mysqld.conf
+install %{SOURCE13} $RPM_BUILD_ROOT%{_sysconfdir}/mysql/mysql-client.conf
# NDB
install %{SOURCE7} $RPM_BUILD_ROOT/etc/rc.d/init.d/mysql-ndb
@@ -528,50 +545,58 @@
install %{SOURCE11} $RPM_BUILD_ROOT/etc/rc.d/init.d/mysql-ndb-cpc
install %{SOURCE12} $RPM_BUILD_ROOT/etc/sysconfig/mysql-ndb-cpc
-# remove mysqld's *.po files
-find . $RPM_BUILD_ROOT%{_datadir}/%{name} -name \*.txt | xargs -n 100 rm -f
+# remove .txt variants for .sys messages
+rm -f $RPM_BUILD_ROOT%{_datadir}/%{name}/*/*.txt
+
mv -f $RPM_BUILD_ROOT%{_libdir}/mysql/lib* $RPM_BUILD_ROOT%{_libdir}
%{__perl} -pi -e 's,%{_libdir}/mysql,%{_libdir},;' $RPM_BUILD_ROOT%{_libdir}/libmysqlclient.la
+# remove known unpackaged files
rm -rf $RPM_BUILD_ROOT%{_prefix}/mysql-test
+# rename not to be so generic name
+mv $RPM_BUILD_ROOT%{_bindir}/{,mysql_}comp_err
+mv $RPM_BUILD_ROOT%{_bindir}/{,mysql_}resolve_stack_dump
+
+# functionality in initscript / rpm
+rm $RPM_BUILD_ROOT%{_bindir}/mysql_create_system_tables
+rm $RPM_BUILD_ROOT%{_bindir}/mysql_install_db
+rm $RPM_BUILD_ROOT%{_bindir}/mysqld_safe
+rm $RPM_BUILD_ROOT%{_bindir}/mysqld_multi
+rm $RPM_BUILD_ROOT%{_mandir}/man1/mysqld_{multi,safe}*
+rm $RPM_BUILD_ROOT%{_datadir}/%{name}/fill_help_tables.sql
+rm $RPM_BUILD_ROOT%{_datadir}/%{name}/mysql-log-rotate
+rm $RPM_BUILD_ROOT%{_datadir}/%{name}/mysql.server
+rm $RPM_BUILD_ROOT%{_datadir}/%{name}/binary-configure
+rm $RPM_BUILD_ROOT%{_bindir}/mysql_waitpid
+
+# in %doc
+rm $RPM_BUILD_ROOT%{_datadir}/%{name}/*.{ini,cnf}
+
%clean
rm -rf $RPM_BUILD_ROOT
%pre
-if [ -n "`/usr/bin/getgid mysql`" ]; then
- if [ "`/usr/bin/getgid mysql`" != "89" ]; then
- echo "Error: group mysql doesn't have gid=89. Correct this before installing mysql." 1>&2
- exit 1
- fi
-else
- /usr/sbin/groupadd -g 89 mysql
-fi
-if [ -n "`/bin/id -u mysql 2>/dev/null`" ]; then
- if [ "`/bin/id -u mysql`" != "89" ]; then
- echo "Error: user mysql doesn't have uid=89. Correct this before installing mysql." 1>&2
- exit 1
- fi
-else
- /usr/sbin/useradd -u 89 \
- -d %{_mysqlhome} -s /bin/sh -g mysql \
- -c "MySQL Server" mysql 1>&2
-fi
+%groupadd -g 89 mysql
+%useradd -u 89 -d %{_mysqlhome} -s /bin/sh -g mysql -c "MySQL Server" mysql
%post
[ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
/sbin/chkconfig --add mysql
-if [ -f /var/lock/subsys/mysql ]; then
- /etc/rc.d/init.d/mysql restart >&2
-else
- echo "Run \"/etc/rc.d/init.d/mysql start\" to start mysql." >&2
+
+if [ "$1" = 1 ]; then
+ %banner -e %{name}-4.1.x <<-EOF
+ If you want to use new help tables in mysql 4.1.x then you'll need to import the help data:
+ zcat %{_docdir}/%{name}-%{version}/fill_help_tables.sql.gz | mysql mysql
+EOF
+#'
fi
+%service mysql restart || :
+
%preun
if [ "$1" = "0" ]; then
- if [ -f /var/lock/subsys/mysql ]; then
- /etc/rc.d/init.d/mysql stop
- fi
+ %service -q mysql stop
/sbin/chkconfig --del mysql
fi
@@ -648,19 +673,65 @@
fi
fi
+%triggerpostun -- mysql <= 4.1.1
+# For better compatibility with prevoius versions:
+for config in $(awk -F= '!/^#/ && /=/{print $1}' /etc/mysql/clusters.conf); do
+ if echo "$config" | grep -q '^/'; then
+ config_file="$config"
+ elif [ -f "/etc/mysql/$config" ]; then
+ config_file=/etc/mysql/$config
+ else
+ clusterdir=$(awk -F= "/^$config/{print \$2}" /etc/mysql/clusters.conf)
+ if [ -z "$clusterdir" ]; then
+ echo >&2 "Can't find cluster dir for $config!"
+ echo >&2 "Please remove extra (leading) spaces from /etc/mysql/clusters.conf"
+ exit 1
+ fi
+ config_file="$clusterdir/mysqld.conf"
+ fi
+
+ if [ ! -f "$config_file" ]; then
+ echo >&2 "Lost myself! Please report this (with above errors, if any) to http://bugs.pld-linux.org/"
+ exit 1
+ fi
+ echo "Adding option old-passwords to config: $config_file"
+ echo "If you want to use new, better passwords - remove it"
+
+ # sed magic to add 'old-passwords' to [mysqld] section
+ sed -i -e '/./{H;$!d;};x;/\[mysqld\]/{
+ a
+ a; Compatibility options:
+ aold-passwords
+ }
+ ' $config_file
+done
+
+%banner -e %{name}-4.1.x <<-EOF
+ If you want to use new help tables in mysql 4.1.x then you'll need to import the help data:
+ zcat %{_docdir}/%{name}-%{version}/fill_help_tables.sql.gz | mysql mysql
+EOF
+#'
+
%files
%defattr(644,root,root,755)
+%doc support-files/*.cnf support-files/*.ini scripts/fill_help_tables.sql
%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/mysql
%attr(754,root,root) /etc/rc.d/init.d/mysql
%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/mysql
-%attr(751,root,root) %dir %{_sysconfdir}/mysql
%attr(640,root,mysql) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mysql/clusters.conf
%attr(750,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/monit/*.monitrc
+%attr(755,root,root) %{_bindir}/innochecksum
+#%attr(755,root,root) %{_bindir}/isamchk
+#%attr(755,root,root) %{_bindir}/isamlog
%attr(755,root,root) %{_bindir}/myisamchk
%attr(755,root,root) %{_bindir}/myisamlog
%attr(755,root,root) %{_bindir}/myisampack
%attr(755,root,root) %{_bindir}/mysql_fix_privilege_tables
+#%attr(755,root,root) %{_bindir}/pack_isam
+%attr(755,root,root) %{_bindir}/my_print_defaults
%attr(755,root,root) %{_sbindir}/mysqld
+#%{_mandir}/man1/isamchk.1*
+#%{_mandir}/man1/isamlog.1*
%{_mandir}/man1/mysql_fix_privilege_tables.1*
%{_mandir}/man1/mysqld.1*
@@ -669,7 +740,7 @@
%attr(751,root,root) /var/lib/mysql
%attr(750,mysql,mysql) %dir /var/log/mysql
%attr(750,mysql,mysql) %dir /var/log/archiv/mysql
-%attr(640,mysql,mysql) %config(noreplace) %verify(not md5 mtime size) /var/log/mysql/*
+%attr(640,mysql,mysql) %ghost /var/log/mysql/*
%{_infodir}/mysql.info*
%dir %{_datadir}/mysql
@@ -705,9 +776,12 @@
%defattr(644,root,root,755)
%attr(755,root,root) %{_bindir}/msql2mysql
%attr(755,root,root) %{_bindir}/perror
-%attr(755,root,root) %{_bindir}/my_print_defaults
%attr(755,root,root) %{_bindir}/replace
%attr(755,root,root) %{_bindir}/resolveip
+%attr(755,root,root) %{_bindir}/myisam_ftdump
+%attr(755,root,root) %{_bindir}/mysql_secure_installation
+%attr(755,root,root) %{_bindir}/mysql_tzinfo_to_sql
+%attr(755,root,root) %{_bindir}/mysqlcheck
%{_mandir}/man1/perror.1*
%{_mandir}/man1/replace.1*
@@ -720,6 +794,9 @@
%attr(755,root,root) %{_bindir}/mysql_zap
%attr(755,root,root) %{_bindir}/mysql_find_rows
%attr(755,root,root) %{_bindir}/mysqlaccess
+%attr(755,root,root) %{_bindir}/mysql_fix_extensions
+%attr(755,root,root) %{_bindir}/mysql_explain_log
+%attr(755,root,root) %{_bindir}/mysql_tableinfo
%{_mandir}/man1/mysql_zap.1*
%{_mandir}/man1/mysqlaccess.1*
@@ -729,12 +806,10 @@
%attr(755,root,root) %{_bindir}/mysqlbug
%attr(755,root,root) %{_bindir}/mysqldump
%attr(755,root,root) %{_bindir}/mysqlimport
-%attr(755,root,root) %{_bindir}/mysqlmanager*
+%attr(755,root,root) %{_sbindir}/mysqlmanager*
%attr(755,root,root) %{_bindir}/mysqlshow
%attr(755,root,root) %{_bindir}/mysqlbinlog
%attr(755,root,root) %{_bindir}/mysqladmin
-%attr(755,root,root) %{_bindir}/mysqltest
-%attr(755,root,root) %{_sbindir}/mysqlmanager*
%{_mandir}/man1/mysql.1*
%{_mandir}/man1/mysqladmin.1*
%{_mandir}/man1/mysqldump.1*
@@ -744,11 +819,15 @@
%defattr(644,root,root,755)
%doc EXCEPTIONS-CLIENT
%attr(755,root,root) %{_libdir}/lib*.so.*.*
+%attr(751,root,root) %dir %{_sysconfdir}/mysql
+%attr(644,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mysql/mysql-client.conf
%files devel
%defattr(644,root,root,755)
%attr(755,root,root) %{_bindir}/mysql_config
%attr(755,root,root) %{_libdir}/lib*.so
+%attr(755,root,root) %{_bindir}/*comp_err
+%attr(755,root,root) %{_bindir}/*resolve_stack_dump
%{_libdir}/lib*.la
%{_libdir}/lib*[!tr].a
%{_includedir}/mysql
@@ -759,13 +838,18 @@
%files bench
%defattr(644,root,root,755)
+%attr(755,root,root) %{_bindir}/mysqltest
+%attr(755,root,root) %{_bindir}/mysql_client_test
%dir %{_datadir}/sql-bench
%{_datadir}/sql-bench/[CDRl]*
-%attr(755,root,root) %{_datadir}/sql-bench/[bcgrst]*
-
-%files doc
-%defattr(644,root,root,755)
-%doc Docs/manual.html Docs/manual_toc.html
+%attr(755,root,root) %{_datadir}/sql-bench/[bcgirst]*
+# wrong dir?
+%{_datadir}/mysql/mi_test_all.res
+%attr(755,root,root) %{_datadir}/mysql/mi_test_all
+
+#%files doc
+#%defattr(644,root,root,755)
+#%doc Docs/manual.html Docs/manual_toc.html
%files ndb
%defattr(644,root,root,755)
@@ -795,6 +879,9 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.259.2.3 2005/09/29 18:45:59 arekm
+- up to 5.0.13
+
Revision 1.259.2.2 2005/04/26 11:36:16 mmazur
- updated md5sum
================================================================
---- CVS-web:
http://cvs.pld-linux.org/SPECS/mysql.spec?r1=1.259.2.2&r2=1.259.2.3&f=u
More information about the pld-cvs-commit
mailing list