Hello community,
here is the log from the commit of package mysql-cluster for openSUSE:Factory
checked in at Wed Dec 29 00:21:05 CET 2010.
--------
--- mysql-cluster/mysql-cluster.changes 2010-06-04 18:18:24.000000000 +0200
+++ /mounts/work_src_done/STABLE/mysql-cluster/mysql-cluster.changes 2010-12-21 18:08:18.000000000 +0100
@@ -1,0 +2,37 @@
+Tue Dec 14 15:22:16 CET 2010 - mhrusecky@suse.cz
+
+- updated to MySQL Cluster 7.1.9a (based on MySQL 5.1.51), see
+ http://dev.mysql.com/doc/refman/5.1/en/mysql-cluster-news-5-1-51-ndb-7-1-9a....
+
+-------------------------------------------------------------------
+Fri Oct 22 11:11:41 CEST 2010 - mhrusecky@suse.cz
+
+- fixed all places where variable was used in printf for format
+
+-------------------------------------------------------------------
+Thu Oct 21 11:10:21 CEST 2010 - mhrusecky@suse.cz
+
+- fixed Mandriva build
+
+-------------------------------------------------------------------
+Wed Oct 20 08:45:56 CEST 2010 - mhrusecky@suse.cz
+
+- rewritten spec file
+ - build and install parts are in separate file now
+ - patches in the archive
+ - contains more documentation
+ - contains tags
+ - adding/removing patches just at in one configuration file
+
+-------------------------------------------------------------------
+Wed Sep 29 13:38:34 CEST 2010 - mhrusecky@suse.cz
+
+- fixed init script to work on SELinux machines (bnc#635645)
+
+-------------------------------------------------------------------
+Tue Aug 24 15:02:39 CEST 2010 - mhrusecky@suse.cz
+
+- updated to MySQL Cluster 7.0.16 (based on MySQL 5.1.47), see
+ http://dev.mysql.com/doc/refman/5.1/en/mysql-cluster-news-5-1-47-ndb-7-0-16....
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
abi_test.patch
libmysql-no-pkglibdir.patch
mysql-5.1.23-vpath.patch
mysql-5.1.30-federated-workaround.patch
mysql-5.1.31-shebang.patch
mysql-5.1.33-safe-process-in-bin.patch
mysql-5.1.33-ssl-lib64-macro.patch
mysql-5.1.35-test-utf8.patch
mysql-5.1.35-test-variables-big.patch
mysql-5.1.36-bmove512.patch
mysql-5.1.36-hotcopy.patch
mysql-cluster-7.0.13-undefined-operation.patch
mysql-cluster-7.0.9-libmysqld.patch
mysql-cluster-7.0.9-myslq-test.patch
mysql-cluster-gpl-7.0.13.tar.bz2
mysql-cnf.patch
mysql-enable-plugins.patch
mysql-group.patch
mysql-install_db-quiet.patch
mysql-logrotate.patch
mysql-multi-configuration.patch
mysql-plugins-avoid-version.patch
mysql_config.patch
mysql_upgrade-exit-status.patch
mysqld_multi.patch
New:
----
build.inc
install.inc
mysql-cluster-gpl-7.1.9a.tar.bz2
mysql-patches.tar.bz2
series
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ mysql-cluster.spec ++++++
--- /var/tmp/diff_new_pack.e5FsNJ/_old 2010-12-29 00:20:12.000000000 +0100
+++ /var/tmp/diff_new_pack.e5FsNJ/_new 2010-12-29 00:20:12.000000000 +0100
@@ -1,5 +1,5 @@
#
-# spec file for package mysql-cluster (Version 7.0.13)
+# spec file for package mysql-cluster (Version 7.1.9a)
#
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -20,7 +20,7 @@
# Few definitions which will alter build
%define prefered 0
%define cluster 1
-%define srv_vers 5.1.41
+%define builtin_plugins partition,csv,heap,myisam,ndbcluster,innobase
%if %{?rel:0}%{!?rel:1}
%define rel 1
@@ -31,8 +31,9 @@
Name: mysql-cluster
Summary: A True Multiuser, Multithreaded SQL Database Server
-Version: 7.0.13
-Release: 2
+Version: 7.1.9a
+Release: 1
+%define srv_vers 5.1.51
License: GPLv2 ; with additional permissions: EXCEPTIONS-CLIENT
Group: Productivity/Databases/Servers
Url: http://www.mysql.com
@@ -43,54 +44,10 @@
Source5: mysql.SuSEfirewall2
Source7: rc.mysql-multi
Source8: README.SuSE
-# Polishing default config file
-Patch2: mysql-cnf.patch
-Patch3: mysql-multi-configuration.patch
-# Adds option to set group to something else similarly to the user settings
-Patch4: mysql-group.patch
-# Warning about initscript in mysql_install_db disabled, since the SUSE RPM comes with an init script installed
-Patch5: mysql-install_db-quiet.patch
-# Checks flush-logs exit status in support-files/mysql-log-rotate.sh
-Patch7: mysql-logrotate.patch
-# Adds reload funcionality to mysqld_multi.sh perl script and adds --datadir support
-Patch8: mysqld_multi.patch
-# Disables failure on one test during update and improves error message during update a little bit
-Patch13: mysql_upgrade-exit-status.patch
-# Check in configure script for readline uses variable instead of relative path now
-# (maybe safer, shouldn't affect functionality, maybe it can be dropped)
-Patch15: mysql-5.1.23-vpath.patch
-# Changes pkglib_LIBRARIES into lib_LIBRARIES in libmysql
-Patch18: libmysql-no-pkglibdir.patch
-# Adds option -avoid-version to LDFLAGS for plugins blackhole, archive and example
-Patch19: mysql-plugins-avoid-version.patch
-# This patch loads plugins by default if there is no settings regarding plugins.
-Patch23: mysql-enable-plugins.patch
-# Really ugly patch which fixes federated to work as a plugin. We should get rid of this asap.
-Patch24: mysql-5.1.30-federated-workaround.patch
-# PATCH-FIX-UPSTREAM mysql-5.1.31-shebang.patch [] mhrusecky@suse.cz -- adds mising shebangs
-Patch25: mysql-5.1.31-shebang.patch
-# PATCH-FIX-UPSTREAM mysql-5.1.35-test-variables-big.patch [upstream bug #38811] -- different way to test whether server crashed
-# http://bugs.mysql.com/bug.php?id=38811
-Patch27: mysql-5.1.35-test-variables-big.patch
-# PATCH-FIX-SUSE mysql-5.1.32-myslq-test.patch mhrusecky@suse.cz -- installs tests into datadir not into prefix
-Patch28: mysql-cluster-7.0.9-myslq-test.patch
-# PATCH-FIX-SUSE mysql-5.1.33-safe-process-in-bin.patch [] mhrusecky@suse.cz -- this will let us move one binary to /usr/bin instead of /usr/share/mysql-test/...
-Patch30: mysql-5.1.33-safe-process-in-bin.patch
-# PATCH-FIX-SUSE mysql-5.1.33-ssl-lib64-macro.patch [] mhrusecky@suse.cz -- search for ssl libraries also in lib64
-Patch31: mysql-5.1.33-ssl-lib64-macro.patch
-# PATCH-FIX-SUSE mysql-5.1.35-test-utf8.patch [] mhrusecky@suse.cz -- we use utf-8 by default which produces different output with few tests
-Patch35: mysql-5.1.35-test-utf8.patch
-# PATCH-FIX-UPSTREAM mysql-5.1.36-bmove512.patch [ upstream#19975 ] mhrusecky@suse.cz -- using standard memcpy instead of bmove512 as it should be beeter
-# http://bugs.mysql.com/bug.php?id=19975
-Patch37: mysql-5.1.36-bmove512.patch
-# PATCH-FIX-UPSTREAM mysql-5.1.36-hotcopy.patch [ upstream#43594, bnc#525325 ] mhrusecky@suse.cz -- hotcopy ignores log tables
-# http://bugs.mysql.com/bug.php?id=43594
-Patch38: mysql-5.1.36-hotcopy.patch
-# PATCH-FIX-UPSTREAM mysql_config.patch [ upstream#39175, bnc#420313 ] mhrusecky@suse.cz -- Fix linking options.
-Patch39: mysql_config.patch
-Patch45: abi_test.patch
-Patch46: mysql-cluster-7.0.9-libmysqld.patch
-Patch47: mysql-cluster-7.0.13-undefined-operation.patch
+Source9: mysql-patches.tar.bz2
+Source10: build.inc
+Source11: install.inc
+Source12: series
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version}
PreReq: pwdutils
@@ -101,7 +58,7 @@
%if 0%{?suse_version}
PreReq: %install_info_prereq %insserv_prereq
%endif
-BuildRequires: gcc-c++ ncurses-devel openssl-devel procps readline-devel zlib-devel
+BuildRequires: bison gcc-c++ ncurses-devel openssl-devel procps readline-devel zlib-devel
%if 0%{?suse_version}
BuildRequires: pwdutils tcpd-devel
%endif
@@ -306,7 +263,14 @@
David Axmark
#-------------------------------------------------------------------------------
+%if %{defined mdkversion}
+
+%package debuging
+License: GPLv2 ; with additional permissions: EXCEPTIONS-CLIENT
+%else
+
%package debug
+%endif
#-------------------------------------------------------------------------------
License: GPLv2 ; with additional permissions: EXCEPTIONS-CLIENT
Summary: MySQL Cluster server with debug options turned on
@@ -315,7 +279,15 @@
Provides: mysql-debug = %{srv_vers}
Conflicts: otherproviders(mysql-debug)
+%if %{defined mdkversion}
+
+%description debuging
+
+%else
+
%description debug
+
+%endif
A version of the mysql server that has some debug code turned on.
It should be only used to track down problems with the standard
servers. Note that merely installing this package won't replace the
@@ -327,8 +299,8 @@
Michael Widenius
David Axmark
-
#-------------------------------------------------------------------------------
+
%package test
#-------------------------------------------------------------------------------
License: GPLv2 ; with additional permissions: EXCEPTIONS-CLIENT
@@ -440,33 +412,13 @@
%prep
#-------------------------------------------------------------------------------
-%setup -q -n mysql-cluster-gpl-%{version}
+%setup -q -n mysql-cluster-gpl-%{version} -D -a 9
cp %_sourcedir/README.SuSE .
cp %_sourcedir/suse-test-run .
-%patch2
-%patch3
-%patch4
-%patch5
-%patch7
-%patch8
-%patch13
-%patch15
-%patch18
-%patch19
-%patch23
-%patch24
-%patch25 -p1
-%patch27
-%patch28
-%patch30
-%patch31
-%patch35
-%patch37
-%patch38
-%patch39
-%patch45
-%patch46
-%patch47 -p1
+# apply patches from series
+ln -s mysql-patches/patches .
+cp %_sourcedir/series patches
+mysql-patches/apply-series.sh patches/series
# remove unneeded manpages ('make install' basically installs everything under
# man/*)
rm -f man/mysqlman.1 # dummy fallback manpage
@@ -488,207 +440,13 @@
%build
#-------------------------------------------------------------------------------
-%if 0%{?suse_version} < 1120 && 0%{?suse_version} > 0
-%define socketpath /var/lib/mysql
-%else
-%define socketpath /var/run/mysql
-%endif
-autoreconf -f -i
-export CFLAGS="$RPM_OPT_FLAGS -DPIC -fPIC -DUNDEF_HAVE_INITGROUPS -DFORCE_INIT_OF_VARS -fno-strict-aliasing"
-export CXXFLAGS="$CFLAGS -fno-exceptions -fno-rtti"
-# Make the compile a function, since we do multiple builds
-BuildMySQL() {
- # The --enable-assembler simply does nothing on systems that do not
- # support assembler speedups.
- suffix="$1"; shift
- mkdir _build$suffix
- pushd _build$suffix
- ../configure \
- --enable-assembler \
- --without-readline \
- --infodir=%{_infodir} \
- --libdir=%{_libdir} \
- --libexecdir=/usr/sbin \
- --localstatedir=/var/lib/mysql \
- --mandir=%{_mandir} \
- --prefix=%{_prefix} \
- --sysconfdir=/etc \
- --with-mysqld-user=mysql \
- --with-mysqld-group=mysql \
- --without-debug \
- --datadir=/usr/share \
- --includedir=/usr/include \
- --with-charset=utf8 \
- --with-collation=utf8_unicode_ci \
- --with-extra-charsets=complex \
- --with-unix-socket-path=%{socketpath}/mysql.sock \
- --enable-thread-safe-client \
- --with-comment="SUSE MySQL Cluster RPM" \
- --with-libwrap \
- --with-server-suffix=$suffix \
-%ifarch s390 s390x
- --with-atomic-ops=rwlocks \
-%else
- --with-atomic-ops=smp \
-%endif
- --with-ssl=/usr \
- --with-plugins=partition,csv,heap,myisam,ndbcluster,innobase \
- HOSTNAME="/bin/hostname -f" \
- "$@"
- # Add this for MyISAM RAID support:
- # --with-raid
- # benchdir does not fit in above model. Fix when we make a separate package
- make %{?jobs:-j%jobs}
- nm --numeric-sort sql/mysqld > sql/mysqld.sym
- # needed for make check, which is not VPATH aware
- # copy the files unconditionally so that manual 'make check' after
- # the build works, too
- cp -a ../mysql-test/* mysql-test/
- cp -a ../sql/share/{english,charsets} sql/share/
- cp -a ../scripts/*.sql scripts/
-%if %{?_with_testsuite:1}0
- pushd mysql-test; perl ./mysql-test-run.pl --force; popd
-%endif
- popd
-}
-# Build the client, extra tools, libraries
-BuildMySQL "" --with-embedded-server
-# build mysqld-debug
-BuildMySQL "-debug" --with-debug --without-embedded-server
-
-%if 0%{?prefered} > 0
-mkdir -p _buildlibmysqld/tmp
-cd _buildlibmysqld/tmp
-ar -x ../../_build/libmysqld/libmysqld.a
-gcc $CFLAGS $LDFLAGS -shared -Wl,-soname,libmysqld.so.0 -o ../libmysqld.so.0.0.1 \
-*.o \
--lpthread -lcrypt -lnsl -lssl -lcrypto -lz -lrt -lstdc++ -lm -lc
-cd ..
-rm -rf tmp
-cd ..
-%endif
+%{expand:%(cat %_sourcedir/build.inc)}
#-------------------------------------------------------------------------------
%install
#-------------------------------------------------------------------------------
-# install the debug server first, so that we don't overwrite the standard
-# /usr/sbin/mysqld
-mkdir -p %buildroot%_libdir/mysql
-make -C _build-debug/sql install DESTDIR=%buildroot
-mv %buildroot/usr/sbin/mysqld %buildroot/usr/sbin/mysqld-debug
-install -m 644 _build-debug/sql/mysqld.sym %buildroot%_libdir/mysql/mysqld-debug.sym
-# install the client, extra tools, libraries and the standard server
-make -C _build install DESTDIR=%buildroot benchdir_root=/usr/share/
-install -m 644 _build/sql/mysqld.sym %buildroot%_libdir/mysql/mysqld.sym
-# remove most static libs (FIXME: don't build them at all...)
-rm -f %buildroot%_libdir/libmysqlclient*a
-rm -f %buildroot%_libdir/mysql/*.a %buildroot%_libdir/mysql/*.la
-rm -f %buildroot%_libdir/mysql/plugin/*a
-# XXX: package these? The ndb tools are linked statically atm
-rm -f %buildroot%_libdir/mysql/libndbclient.*
-rm -f %{buildroot}/usr/share/mysql-test/mysql-test-run
-rm -f %{buildroot}/usr/share/mysql-test/mtr
-ln -sf mysql-test-run.pl %{buildroot}/usr/share/mysql-test/mtr
-ln -sf mysql-test-run.pl %{buildroot}/usr/share/mysql-test/mysql-test-run
-mv %{buildroot}/usr/share/mysql-test/lib/My/SafeProcess/my_safe_process %{buildroot}%{_bindir}
-# generate filelist for binaries and their manpages (easier than enumerating
-# all the binaries and manapages manually, esp. when there are new manpages in
-# each release)
-filelist()
-{
- echo '%%defattr(-, root, root)'
- pushd %buildroot >/dev/null
- for i; do
- if test -e usr/sbin/"$i"; then
- echo /usr/sbin/"$i"
- fi
- if test -e usr/bin/"$i"; then
- echo /usr/bin/"$i"
- fi
- if ls usr/share/man/*/"$i".[1-9]* >/dev/null 2>&1; then
- echo "%%doc %_mandir/*/$i.[1-9]*"
- fi
- done
- popd >/dev/null
-}
-filelist innochecksum my_print_defaults myisam_ftdump myisamchk myisamlog myisampack mysql_fix_extensions mysql_fix_privilege_tables mysql_install_db mysql_secure_installation mysql_upgrade mysqlbug mysqld mysqld_multi mysqld_safe mysqlbinlog mysqldumpslow mysqlmanager resolve_stack_dump resolveip >mysql.files
-filelist mysql mysqladmin mysqlcheck mysqldump mysqlimport mysqlshow >mysql-client.files
-filelist mysql_config >libmysqlclient-devel.files
-filelist mysqlslap >mysql-bench.files
-filelist mysql_client_test mysql_client_test_embedded mysql_waitpid mysqltest mysqltest_embedded >mysql-test.files
-# all binaries that don't need to be in a "default" install (mysql.rpm +
-# mysql-client.rpm)
-filelist msql2mysql mysql_convert_table_format mysql_find_rows mysql_setpermission mysql_tzinfo_to_sql mysql_zap mysqlaccess mysqlhotcopy perror replace >mysql-tools.files
-filelist ndbd ndbmtd ndbd_redo_log_reader >mysql-ndb-storage.files
-filelist ndb_mgmd >mysql-ndb-management.files
-filelist ndb_{config,desc,error_reporter,mgm,print_backup_file,print_schema_file,print_sys_file,restore,select_all,select_count,show_tables,size.pl,test_platform,waiter} >mysql-ndb-tools.files
-filelist ndb_{cpcd,delete_all,drop_index,drop_table} >mysql-ndb-extra.files
-### files not installed by make install
-# Create directory structure
-DOCS=(COPYING README EXCEPTIONS-CLIENT %_sourcedir/README.debug %_sourcedir/README.SuSE)
-DOCDIR=%buildroot%_defaultdocdir/%name
-install -d -m 755 ${DOCDIR}
-install -d -m 755 %buildroot/etc/logrotate.d
-install -d -m 755 %buildroot/etc/init.d
-install -m 644 _build/support-files/mysql-log-rotate %buildroot/etc/logrotate.d/mysql
-%if 0%{?prefered} > 0
-install -m 644 _buildlibmysqld/*.so* %buildroot%_libdir
-ln -s libmysqld.so.0.0.1 %buildroot%_libdir/libmysqld.so.0
-ln -s libmysqld.so.0.0.1 %buildroot%_libdir/libmysqld.so
-%endif
-install -m 660 _build/support-files/my-medium.cnf %buildroot/etc/my.cnf
-install -m 640 scripts/mysqlaccess.conf %buildroot/etc/mysqlaccess.conf
-install -m 644 "${DOCS[@]}" ${DOCDIR}
-install -m 755 %_sourcedir/rc.mysql-multi %buildroot/etc/init.d/mysql
-ln -sf ../../etc/init.d/mysql %buildroot/usr/sbin/rcmysql
-# this is used by the init script
-install -m 755 -d %buildroot/var/run/mysql
-# SuSEfirewall service description
-install -D -m 644 %_sourcedir/mysql.SuSEfirewall2 \
- %buildroot/etc/sysconfig/SuSEfirewall2.d/services/mysql
-# testsuite
-mkdir -p '%buildroot'/usr/share/mysql-test/
-install -m 755 suse-test-run '%buildroot'/usr/share/mysql-test/
-# XXX this should go under /var/..., but some tests get confused by a symlink
-# var -> ../../../var/...
-#ln -sf ../../../var/lib/mysql/mysql-test %buildroot/usr/share/mysql-test/var
-mkdir '%buildroot'/usr/share/mysql-test/var
-# Final fixes
-find '%buildroot'/usr/share/mysql-test -name '*.orig' -delete
-%if 0%{?suse_version} > 1030
-%fdupes -s '%buildroot'/usr/share/mysql-test
-%endif
-%if 0%{?fedora_version} > 8
-fdupes -q -n -r '%buildroot'/usr/share/mysql-test
-%endif
-dos2unixConversion() {
- %{__sed} -i 's/\r//g' "$1"
-}
-for i in `grep -Rl '\r' '%buildroot'/usr/share/sql-bench`; do
- dos2unixConversion "$i"
-done
-%if ! 0%{cluster} > 0
-cat mysql-ndb-storage.files mysql-ndb-management.files \
- mysql-ndb-tools.files mysql-ndb-extra.files | \
- sed 's|^%%doc\ ||' | while read tmp; do
- cd '%buildroot'
- rm -f .$tmp
-done
-%endif
-%if ! 0%{prefered} > 0
-cat libmysqlclient-devel.files | while read tmp; do
- cd '%buildroot'
- rm -f .$tmp
-done
-rm -rf '%buildroot'/%_libdir/libmysqld.*
-rm -rf '%buildroot'/%_libdir/libmysqlclient*
-rm -rf '%buildroot'/%_libdir/libmysqlclusterclient.{a,la,so}
-rm -rf '%buildroot'/%_libdir/libmysqlclusterclient_r*.{a,la,so}
-rm -rf '%buildroot'/%_includedir
-rm -rf '%buildroot'/%_datadir/man/*/mysql_config*
-rm -rf '%buildroot'/%_datadir/aclocal
-%endif
+%{expand:%(cat %_sourcedir/install.inc)}
#-------------------------------------------------------------------------------
@@ -725,7 +483,7 @@
%posttrans
#-------------------------------------------------------------------------------
-%install_info --info-dir=%{_infodir} %{_infodir}/mysql.info.gz
+%install_info --info-dir=%{_infodir} %{_infodir}/mysql.info.*
if [ -d /var/lib/mysql ]; then
touch /var/lib/mysql/.run-mysql_upgrade
chown -R mysql:mysql /var/lib/mysql
@@ -818,7 +576,7 @@
%postun
#-------------------------------------------------------------------------------
if [ $1 = 0 ]; then
- %install_info_delete --info-dir=%{_infodir} %{_infodir}/mysql.info.gz
+ %install_info_delete --info-dir=%{_infodir} %{_infodir}/mysql.info.*
%{insserv_cleanup}
fi
#-------------------------------------------------------------------------------
@@ -836,9 +594,11 @@
#-------------------------------------------------------------------------------
%defattr(-, root, root)
%config(noreplace) %attr(0640, root, mysql) /etc/my.cnf
+%dir %attr(0750, root, mysql) /etc/mysql
+%config(noreplace) %attr(0640, root, mysql) /etc/mysql/*
%config /etc/logrotate.d/mysql
%doc %{_defaultdocdir}/%{name}
-%doc %{_infodir}/mysql.info.gz
+%doc %{_infodir}/mysql.info.*
/etc/init.d/mysql
/usr/sbin/rcmysql
/usr/share/mysql/
@@ -866,6 +626,7 @@
%defattr(-, root, root)
%{_libdir}/libmysqlclusterclient.so.*
#-------------------------------------------------------------------------------
+
#-------------------------------------------------------------------------------
%files -n libmysqlclusterclient_r16
@@ -874,6 +635,7 @@
%{_libdir}/libmysqlclusterclient_r.so.*
#-------------------------------------------------------------------------------
%endif
+
%if 0%{prefered} > 0
#-------------------------------------------------------------------------------
@@ -929,8 +691,13 @@
#-------------------------------------------------------------------------------
#-------------------------------------------------------------------------------
+%if %{defined mdkversion}
+
+%files debuging
+%else
%files debug
+%endif
#-------------------------------------------------------------------------------
%defattr(-, root, root)
/usr/sbin/mysqld-debug
@@ -954,6 +721,10 @@
#-------------------------------------------------------------------------------
%files tools -f mysql-tools.files
+%defattr(-, root, root)
+/usr/bin/mysqlanalyze
+/usr/bin/mysqloptimize
+/usr/bin/mysqlrepair
#-------------------------------------------------------------------------------
%if 0%{cluster} > 0
++++++ build.inc ++++++
%if 0%{?suse_version} < 1120 && 0%{?suse_version} > 0
%define socketpath /var/lib/mysql
%else
%define socketpath /var/run/mysql
%endif
autoreconf -f -i
export CFLAGS="$RPM_OPT_FLAGS -DPIC -fPIC -DUNDEF_HAVE_INITGROUPS -DFORCE_INIT_OF_VARS -fno-strict-aliasing"
export CXXFLAGS="$CFLAGS -fno-exceptions -fno-rtti"
# Make the compile a function, since we do multiple builds
BuildMySQL() {
# The --enable-assembler simply does nothing on systems that do not
# support assembler speedups.
suffix="$1"; shift
mkdir _build$suffix
pushd _build$suffix
../configure \
--enable-assembler \
--without-readline \
--infodir=%{_infodir} \
--libdir=%{_libdir} \
--libexecdir=/usr/sbin \
--localstatedir=/var/lib/mysql \
--mandir=%{_mandir} \
--prefix=%{_prefix} \
--sysconfdir=/etc \
--with-mysqld-user=mysql \
--with-mysqld-group=mysql \
--without-debug \
--datadir=/usr/share \
--includedir=/usr/include \
--with-charset=utf8 \
--with-collation=utf8_unicode_ci \
--with-extra-charsets=all \
--with-unix-socket-path=%{socketpath}/mysql.sock \
--enable-thread-safe-client \
--with-comment="SUSE MySQL RPM" \
--with-libwrap \
--with-server-suffix=$suffix \
%ifarch s390 s390x
--with-atomic-ops=rwlocks \
%else
--with-atomic-ops=smp \
%endif
--with-ssl=/usr \
--with-plugins=%{builtin_plugins} \
HOSTNAME="/bin/hostname -f" \
"$@"
# Add this for MyISAM RAID support:
# --with-raid
# benchdir does not fit in above model. Fix when we make a separate package
make %{?jobs:-j%jobs}
nm --numeric-sort sql/mysqld > sql/mysqld.sym
# needed for make check, which is not VPATH aware
# copy the files unconditionally so that manual 'make check' after
# the build works, too
cp -a ../mysql-test/* mysql-test/
for i in ../sql/share/{english,charsets}; do
[ -d $i ] && cp -a $i sql/share/
done
cp -a ../scripts/*.sql scripts/
%if %{?_with_testsuite:1}0
pushd mysql-test; perl ./mysql-test-run.pl --force; popd
%endif
popd
}
# Build the client, extra tools, libraries
BuildMySQL "" --with-embedded-server
# build mysqld-debug
BuildMySQL "-debug" --with-debug --without-embedded-server
%if 0%{?prefered} > 0
mkdir -p _buildlibmysqld/tmp
cd _buildlibmysqld/tmp
ar -x ../../_build/libmysqld/libmysqld.a
gcc $CFLAGS $LDFLAGS -shared -Wl,-soname,libmysqld.so.0 -o ../libmysqld.so.0.0.1 \
*.o \
-lpthread -lcrypt -lnsl -lssl -lcrypto -lz -lrt -lstdc++ -lm -lc
cd ..
rm -rf tmp
cd ..
%endif
++++++ install.inc ++++++
# install the debug server first, so that we don't overwrite the standard
# /usr/sbin/mysqld
mkdir -p %buildroot%_libdir/mysql
make -C _build-debug/sql install DESTDIR=%buildroot
mv %buildroot/usr/sbin/mysqld %buildroot/usr/sbin/mysqld-debug
install -m 644 _build-debug/sql/mysqld.sym %buildroot%_libdir/mysql/mysqld-debug.sym
# install the client, extra tools, libraries and the standard server
make -C _build install DESTDIR=%buildroot benchdir_root=/usr/share/
install -m 644 _build/sql/mysqld.sym %buildroot%_libdir/mysql/mysqld.sym
# remove most static libs (FIXME: don't build them at all...)
rm -f %buildroot%_libdir/libmysqlclient*a
rm -f %buildroot%_libdir/mysql/*.a %buildroot%_libdir/mysql/*.la
rm -f %buildroot%_libdir/mysql/plugin/*a
# XXX: package these? The ndb tools are linked statically atm
rm -f %buildroot%_libdir/mysql/libndbclient.*
rm -f %{buildroot}/usr/share/mysql-test/mysql-test-run
rm -f %{buildroot}/usr/share/mysql-test/mtr
ln -sf mysql-test-run.pl %{buildroot}/usr/share/mysql-test/mtr
ln -sf mysql-test-run.pl %{buildroot}/usr/share/mysql-test/mysql-test-run
mv %{buildroot}/usr/share/mysql-test/lib/My/SafeProcess/my_safe_process %{buildroot}%{_bindir}
# generate filelist for binaries and their manpages (easier than enumerating
# all the binaries and manapages manually, esp. when there are new manpages in
# each release)
filelist()
{
echo '%%defattr(-, root, root)'
pushd %buildroot >/dev/null
for i; do
if test -e usr/sbin/"$i"; then
echo /usr/sbin/"$i"
fi
if test -e usr/bin/"$i"; then
echo /usr/bin/"$i"
fi
if ls usr/share/man/*/"$i".[1-9]* >/dev/null 2>&1; then
echo "%%doc %_mandir/*/$i.[1-9]*"
fi
done
popd >/dev/null
}
filelist innochecksum my_print_defaults myisam_ftdump myisamchk myisamlog myisampack mysql_fix_extensions mysql_fix_privilege_tables mysql_install_db mysql_secure_installation mysql_upgrade mysqlbug mysqld mysqld_multi mysqld_safe mysqlbinlog mysqldumpslow mysqlmanager resolve_stack_dump resolveip {m,}aria_chk {m,}aria_dump_log {m,}aria_ftdump {m,}aria_pack {m,}aria_read_log xtstat >mysql.files
filelist mysql mysqladmin mysqlcheck mysqldump mysqlimport mysqlshow >mysql-client.files
filelist mysql_config >libmysqlclient-devel.files
filelist mysqlslap >mysql-bench.files
filelist mysql_client_test mysql_client_test_embedded mysql_waitpid mysqltest mysqltest_embedded >mysql-test.files
# all binaries that don't need to be in a "default" install (mysql.rpm +
# mysql-client.rpm)
filelist msql2mysql mysql_convert_table_format mysql_find_rows mysql_setpermission mysql_tzinfo_to_sql mysql_zap mysqlaccess mysqlhotcopy perror replace >mysql-tools.files
filelist ndbd ndbmtd ndbd_redo_log_reader >mysql-ndb-storage.files
filelist ndb_mgmd >mysql-ndb-management.files
filelist ndb_{config,desc,error_reporter,mgm,print_backup_file,print_schema_file,print_sys_file,restore,select_all,select_count,show_tables,size.pl,test_platform,waiter} >mysql-ndb-tools.files
filelist ndb_{cpcd,delete_all,drop_index,drop_table} >mysql-ndb-extra.files
### files not installed by make install
# Create directory structure
DOCS=(COPYING README EXCEPTIONS-CLIENT %_sourcedir/README.debug %_sourcedir/README.SuSE)
DOCDIR=%buildroot%_defaultdocdir/%name
install -d -m 755 ${DOCDIR}
install -d -m 755 %buildroot/etc/logrotate.d
install -d -m 755 %buildroot/etc/init.d
install -m 644 _build/support-files/mysql-log-rotate %buildroot/etc/logrotate.d/mysql
%if 0%{?prefered} > 0
install -m 644 _buildlibmysqld/*.so* %buildroot%_libdir
ln -s libmysqld.so.0.0.1 %buildroot%_libdir/libmysqld.so.0
ln -s libmysqld.so.0.0.1 %buildroot%_libdir/libmysqld.so
%endif
install -m 660 _build/support-files/my-medium.cnf %buildroot/etc/my.cnf
install -m 640 scripts/mysqlaccess.conf %buildroot/etc/mysqlaccess.conf
install -m 644 "${DOCS[@]}" ${DOCDIR}
install -m 755 %_sourcedir/rc.mysql-multi %buildroot/etc/init.d/mysql
ln -sf ../../etc/init.d/mysql %buildroot/usr/sbin/rcmysql
# this is used by the init script
install -m 755 -d %buildroot/var/run/mysql
# SuSEfirewall service description
install -D -m 644 %_sourcedir/mysql.SuSEfirewall2 \
%buildroot/etc/sysconfig/SuSEfirewall2.d/services/mysql
# testsuite
mkdir -p '%buildroot'/usr/share/mysql-test/
install -m 755 suse-test-run '%buildroot'/usr/share/mysql-test/
# XXX this should go under /var/..., but some tests get confused by a symlink
# var -> ../../../var/...
#ln -sf ../../../var/lib/mysql/mysql-test %buildroot/usr/share/mysql-test/var
mkdir '%buildroot'/usr/share/mysql-test/var
# Final fixes
find '%buildroot'/usr/share/mysql-test -name '*.orig' -delete
%if 0%{?suse_version} > 1030
%fdupes -s '%buildroot'/usr/share/mysql-test
%endif
%if 0%{?fedora_version} > 8
fdupes -q -n -r '%buildroot'/usr/share/mysql-test
%endif
dos2unixConversion() {
%{__sed} -i 's/\r//g' "$1"
}
for i in `grep -Rl '\r' '%buildroot'/usr/share/sql-bench`; do
dos2unixConversion "$i"
done
%if ! 0%{cluster} > 0
cat mysql-ndb-storage.files mysql-ndb-management.files \
mysql-ndb-tools.files mysql-ndb-extra.files | \
sed 's|^%%doc\ ||' | while read tmp; do
cd '%buildroot'
rm -f .$tmp
done
%endif
%if ! 0%{prefered} > 0
cat libmysqlclient-devel.files | while read tmp; do
cd '%buildroot'
rm -f .$tmp
done
rm -rf '%buildroot'/%_libdir/libmysqld.*
rm -rf '%buildroot'/%_libdir/*.la
rm -rf '%buildroot'/%_libdir/*.so
rm -rf '%buildroot'/%_libdir/*.a
rm -rf '%buildroot'/%_includedir
rm -rf '%buildroot'/%_datadir/man/*/mysql_config*
rm -rf '%buildroot'/%_datadir/aclocal
%endif
sed -i 's|doc/packages/mysql|doc/packages/%{name}|g' '%buildroot'/etc/init.d/mysql
ln -s mysqlcheck '%buildroot'%_bindir/mysqlrepair
ln -s mysqlcheck '%buildroot'%_bindir/mysqlanalyze
ln -s mysqlcheck '%buildroot'%_bindir/mysqloptimize
mkdir -p '%buildroot'/etc/mysql
[ -z "`ls -1 %_sourcedir/*.cnf`" ] || cp %_sourcedir/*.cnf '%buildroot'/etc/mysql
++++++ series ++++++
mysql-community-server-5.1.30-federated-workaround.patch
mysql-community-server-5.1.31-shebang.patch
mysql-community-server-5.1.33-ssl-lib64-macro.patch
mysql-community-server-5.1.35-utf8-test-results.patch
mysql-community-server-5.1.36-bmove512.patch
mysql-community-server-5.1.36-hotcopy.patch
mysql-community-server-5.1.45-cnf.patch
mysql-community-server-5.1.45-group.patch
mysql-community-server-5.1.45-multi-configuration.patch
mysql-community-server-5.1.45-safe-process-in-bin.patch
mysql-community-server-5.1.46-logrotate.patch
mysql-cluster-7.1.8-myslq-test.patch
mysql-community-server-5.1.51-install_db-quiet.patch
mysql-community-server-5.1.51-libmysql-no-pkglibdir.patch
mysql-community-server-5.1.51-mysql_config.patch
mysql-community-server-5.1.51-mysqld_multi-features.patch
mysql-community-server-5.1.51-plugins-avoid-version.patch
mysql-community-server-5.1.51-upgrade-exit-status.patch
mysql-cluster-7.1.8-no-mysqld-examples.patch
mysql-cluster-7.1.9a-strncat-overflow.patch
mysql-cluster-7.1.9a-string-format-indirect.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org