From de3bd6c4ed2b2b7ed694ec908d082679eca0890e Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Thu, 23 Dec 2010 22:54:59 -0500 Subject: [PATCH] Update to MySQL 5.5.8 (major version bump). --- .gitignore | 2 +- README.mysql-license | 6 + filter-requires-mysql.sh | 4 +- libmysql.version | 129 ++++++++++++++++++ mysql-cve-2008-7247.patch | 58 -------- mysql-disable-test.patch | 25 +++- mysql-dubious-exports.patch | 49 +++++++ mysql-errno.patch | 12 +- mysql-lowercase-bug.patch | 51 ------- mysql-missing-string-code.patch | 14 -- mysql-no-docs.patch | 39 ------ mysql-setschedparam.patch | 22 --- mysql-ssl-multilib.patch | 20 --- mysql-stack-guard.patch | 28 ++-- mysql-strmov.patch | 16 ++- mysql-testing.patch | 23 ---- mysql-versioning.patch | 18 +++ mysql.spec | 231 ++++++++++++++++++-------------- sources | 2 +- 19 files changed, 379 insertions(+), 370 deletions(-) create mode 100644 README.mysql-license create mode 100644 libmysql.version delete mode 100644 mysql-cve-2008-7247.patch create mode 100644 mysql-dubious-exports.patch delete mode 100644 mysql-lowercase-bug.patch delete mode 100644 mysql-missing-string-code.patch delete mode 100644 mysql-no-docs.patch delete mode 100644 mysql-setschedparam.patch delete mode 100644 mysql-ssl-multilib.patch delete mode 100644 mysql-testing.patch create mode 100644 mysql-versioning.patch diff --git a/.gitignore b/.gitignore index 3278ded..bb555d9 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -/mysql-5.1.52-nodocs.tar.gz +/mysql-5.5.8-nodocs.tar.gz diff --git a/README.mysql-license b/README.mysql-license new file mode 100644 index 0000000..1282653 --- /dev/null +++ b/README.mysql-license @@ -0,0 +1,6 @@ +MySQL is distributed under GPL v2, but there are some licensing exceptions +that allow the client libraries to be linked with a non-GPL application, +so long as the application is under a license approved by Oracle. +For details see + +http://www.mysql.com/about/legal/licensing/foss-exception/ diff --git a/filter-requires-mysql.sh b/filter-requires-mysql.sh index d435062..bce04c6 100755 --- a/filter-requires-mysql.sh +++ b/filter-requires-mysql.sh @@ -1,3 +1,5 @@ #!/bin/sh -/usr/lib/rpm/perl.req $* | grep -v -e "perl(th" -e "perl(lib::mtr" -e "perl(mtr" +/usr/lib/rpm/perl.req $* | \ + grep -v -e "perl(th" \ + -e "perl(lib::mtr" -e "perl(lib::v1/mtr" -e "perl(mtr" diff --git a/libmysql.version b/libmysql.version new file mode 100644 index 0000000..d53adbc --- /dev/null +++ b/libmysql.version @@ -0,0 +1,129 @@ +# symbols exported from mysql 5.1 +libmysqlclient_16 { + global: + _fini; + _init; + my_init; + myodbc_remove_escape; + mysql_affected_rows; + mysql_autocommit; + mysql_change_user; + mysql_character_set_name; + mysql_close; + mysql_commit; + mysql_data_seek; + mysql_debug; + mysql_dump_debug_info; + mysql_embedded; + mysql_eof; + mysql_errno; + mysql_error; + mysql_escape_string; + mysql_fetch_field; + mysql_fetch_field_direct; + mysql_fetch_fields; + mysql_fetch_lengths; + mysql_fetch_row; + mysql_field_count; + mysql_field_seek; + mysql_field_tell; + mysql_free_result; + mysql_get_character_set_info; + mysql_get_client_info; + mysql_get_client_version; + mysql_get_host_info; + mysql_get_parameters; + mysql_get_proto_info; + mysql_get_server_info; + mysql_get_server_version; + mysql_get_ssl_cipher; + mysql_hex_string; + mysql_info; + mysql_init; + mysql_insert_id; + mysql_kill; + mysql_list_dbs; + mysql_list_fields; + mysql_list_processes; + mysql_list_tables; + mysql_more_results; + mysql_next_result; + mysql_num_fields; + mysql_num_rows; + mysql_options; + mysql_ping; + mysql_query; + mysql_read_query_result; + mysql_real_connect; + mysql_real_escape_string; + mysql_real_query; + mysql_refresh; + mysql_rollback; + mysql_row_seek; + mysql_row_tell; + mysql_select_db; + mysql_send_query; + mysql_server_end; + mysql_server_init; + mysql_set_character_set; + mysql_set_local_infile_default; + mysql_set_local_infile_handler; + mysql_set_server_option; + mysql_shutdown; + mysql_sqlstate; + mysql_ssl_set; + mysql_stat; + mysql_stmt_affected_rows; + mysql_stmt_attr_get; + mysql_stmt_attr_set; + mysql_stmt_bind_param; + mysql_stmt_bind_result; + mysql_stmt_close; + mysql_stmt_data_seek; + mysql_stmt_errno; + mysql_stmt_error; + mysql_stmt_execute; + mysql_stmt_fetch; + mysql_stmt_fetch_column; + mysql_stmt_field_count; + mysql_stmt_free_result; + mysql_stmt_init; + mysql_stmt_insert_id; + mysql_stmt_num_rows; + mysql_stmt_param_count; + mysql_stmt_param_metadata; + mysql_stmt_prepare; + mysql_stmt_reset; + mysql_stmt_result_metadata; + mysql_stmt_row_seek; + mysql_stmt_row_tell; + mysql_stmt_send_long_data; + mysql_stmt_sqlstate; + mysql_stmt_store_result; + mysql_store_result; + mysql_thread_end; + mysql_thread_id; + mysql_thread_init; + mysql_thread_safe; + mysql_use_result; + mysql_warning_count; + local: + *; +}; +# symbols added in mysql 5.5 +libmysqlclient_16.1 { + global: + mysql_client_find_plugin; + mysql_client_register_plugin; + mysql_load_plugin; + mysql_load_plugin_v; + mysql_plugin_options; + mysql_stmt_next_result; +# Ideally these wouldn't be exported, but mysql-connector-odbc requires them. +# We limit the damage by prefixing mysql_ (see mysql-dubious-exports.patch), +# which means the symbols are not present in libmysqlclient_16. + mysql_default_charset_info; + mysql_get_charset; + mysql_get_charset_by_csname; + mysql_net_realloc; +}; diff --git a/mysql-cve-2008-7247.patch b/mysql-cve-2008-7247.patch deleted file mode 100644 index acd460f..0000000 --- a/mysql-cve-2008-7247.patch +++ /dev/null @@ -1,58 +0,0 @@ -Back-ported patch for upstream bug #39277. - - -diff -Naur mysql-5.1.42.orig/sql/sql_table.cc mysql-5.1.42/sql/sql_table.cc ---- mysql-5.1.42.orig/sql/sql_table.cc 2009-12-16 12:57:30.000000000 -0500 -+++ mysql-5.1.42/sql/sql_table.cc 2010-01-28 14:33:52.000000000 -0500 -@@ -3892,15 +3892,43 @@ - create_info->table_existed= 0; // Mark that table is created - - #ifdef HAVE_READLINK -- if (test_if_data_home_dir(create_info->data_file_name)) - { -- my_error(ER_WRONG_ARGUMENTS, MYF(0), "DATA DIRECTORY"); -- goto unlock_and_end; -- } -- if (test_if_data_home_dir(create_info->index_file_name)) -- { -- my_error(ER_WRONG_ARGUMENTS, MYF(0), "INDEX DIRECTORY"); -- goto unlock_and_end; -+ size_t dirlen; -+ char dirpath[FN_REFLEN]; -+ -+ /* -+ data_file_name and index_file_name include the table name without -+ extension. Mostly this does not refer to an existing file. When -+ comparing data_file_name or index_file_name against the data -+ directory, we try to resolve all symbolic links. On some systems, -+ we use realpath(3) for the resolution. This returns ENOENT if the -+ resolved path does not refer to an existing file. my_realpath() -+ does then copy the requested path verbatim, without symlink -+ resolution. Thereafter the comparison can fail even if the -+ requested path is within the data directory. E.g. if symlinks to -+ another file system are used. To make realpath(3) return the -+ resolved path, we strip the table name and compare the directory -+ path only. If the directory doesn't exist either, table creation -+ will fail anyway. -+ */ -+ if (create_info->data_file_name) -+ { -+ dirname_part(dirpath, create_info->data_file_name, &dirlen); -+ if (test_if_data_home_dir(dirpath)) -+ { -+ my_error(ER_WRONG_ARGUMENTS, MYF(0), "DATA DIRECTORY"); -+ goto unlock_and_end; -+ } -+ } -+ if (create_info->index_file_name) -+ { -+ dirname_part(dirpath, create_info->index_file_name, &dirlen); -+ if (test_if_data_home_dir(dirpath)) -+ { -+ my_error(ER_WRONG_ARGUMENTS, MYF(0), "INDEX DIRECTORY"); -+ goto unlock_and_end; -+ } -+ } - } - - #ifdef WITH_PARTITION_STORAGE_ENGINE diff --git a/mysql-disable-test.patch b/mysql-disable-test.patch index becbcf2..c48bc38 100644 --- a/mysql-disable-test.patch +++ b/mysql-disable-test.patch @@ -4,13 +4,24 @@ wrong ones. This is upstream at http://bugs.mysql.com/bug.php?id=46895 (note that upstream has also disabled it, but only for Solaris, so we still need this patch). +Also disable sys_vars.plugin_dir_basic, which is broken because +mysql-test-run doesn't set the right value of MYSQL_LIBDIR. Upstream at +http://bugs.mysql.com/bug.php?id=52223 -diff -Naur mysql-5.1.51.orig/mysql-test/t/disabled.def mysql-5.1.51/mysql-test/t/disabled.def ---- mysql-5.1.51.orig/mysql-test/t/disabled.def 2010-09-13 10:10:50.000000000 -0400 -+++ mysql-5.1.51/mysql-test/t/disabled.def 2010-10-07 11:15:46.167693893 -0400 -@@ -14,3 +14,5 @@ - partition_innodb_plugin : Bug#53307 2010-04-30 VasilDimov valgrind warnings - main.mysqlhotcopy_myisam : bug#54129 2010-06-04 Horst - main.mysqlhotcopy_archive: bug#54129 2010-06-04 Horst +Also disable perfschema.binlog_mix and perfschema.binlog_row, which +perhaps just have wrong expected-output files? Upstream at +http://bugs.mysql.com/bug.php?id=59091 + + +diff -Naur mysql-5.5.8.orig/mysql-test/t/disabled.def mysql-5.5.8/mysql-test/t/disabled.def +--- mysql-5.5.8.orig/mysql-test/t/disabled.def 2010-12-03 12:58:24.000000000 -0500 ++++ mysql-5.5.8/mysql-test/t/disabled.def 2010-12-21 11:03:07.288224692 -0500 +@@ -19,3 +19,8 @@ + sum_distinct-big : Bug#56927 2010-11-15 mattiasj was not tested + alter_table-big : Bug#37248 2010-11-15 mattiasj was not tested + create-big : Bug#37248 2010-11-15 mattiasj was not tested +# +outfile_loaddata : bug#46895 code wrong, expected results wrong too ++sys_vars.plugin_dir_basic : bug#52223 fails for lib64 library directory ++perfschema.binlog_mix : bug#59091 possibly just forgot to update result file ++perfschema.binlog_row : bug#59091 possibly just forgot to update result file diff --git a/mysql-dubious-exports.patch b/mysql-dubious-exports.patch new file mode 100644 index 0000000..30eeedb --- /dev/null +++ b/mysql-dubious-exports.patch @@ -0,0 +1,49 @@ +Prefix mysql_ to the real names of several symbols that have to be exported +from libmysqlclient because mysql-connector-odbc depends on them. This +limits the intrusion on application namespace. + + +diff -Naur mysql-5.5.8.orig/include/my_sys.h mysql-5.5.8/include/my_sys.h +--- mysql-5.5.8.orig/include/my_sys.h 2010-12-03 12:58:24.000000000 -0500 ++++ mysql-5.5.8/include/my_sys.h 2010-12-23 15:19:43.997552393 -0500 +@@ -227,6 +227,7 @@ + + /* charsets */ + #define MY_ALL_CHARSETS_SIZE 2048 ++#define default_charset_info mysql_default_charset_info /* namespace sanity */ + extern MYSQL_PLUGIN_IMPORT CHARSET_INFO *default_charset_info; + extern MYSQL_PLUGIN_IMPORT CHARSET_INFO *all_charsets[MY_ALL_CHARSETS_SIZE]; + extern CHARSET_INFO compiled_charsets[]; +@@ -914,6 +915,9 @@ + extern uint get_collation_number(const char *name); + extern const char *get_charset_name(uint cs_number); + ++#define get_charset mysql_get_charset /* namespace sanity */ ++#define get_charset_by_csname mysql_get_charset_by_csname ++ + extern CHARSET_INFO *get_charset(uint cs_number, myf flags); + extern CHARSET_INFO *get_charset_by_name(const char *cs_name, myf flags); + extern CHARSET_INFO *get_charset_by_csname(const char *cs_name, +diff -Naur mysql-5.5.8.orig/include/mysql.h.pp mysql-5.5.8/include/mysql.h.pp +--- mysql-5.5.8.orig/include/mysql.h.pp 2010-12-03 12:58:24.000000000 -0500 ++++ mysql-5.5.8/include/mysql.h.pp 2010-12-23 15:26:59.856608079 -0500 +@@ -86,7 +86,7 @@ + void my_net_local_init(NET *net); + void net_end(NET *net); + void net_clear(NET *net, my_bool clear_buffer); +-my_bool net_realloc(NET *net, size_t length); ++my_bool mysql_net_realloc(NET *net, size_t length); + my_bool net_flush(NET *net); + my_bool my_net_write(NET *net,const unsigned char *packet, size_t len); + my_bool net_write_command(NET *net,unsigned char command, +diff -Naur mysql-5.5.8.orig/include/mysql_com.h mysql-5.5.8/include/mysql_com.h +--- mysql-5.5.8.orig/include/mysql_com.h 2010-12-03 12:58:24.000000000 -0500 ++++ mysql-5.5.8/include/mysql_com.h 2010-12-23 15:18:08.955552431 -0500 +@@ -448,6 +448,7 @@ + void my_net_local_init(NET *net); + void net_end(NET *net); + void net_clear(NET *net, my_bool clear_buffer); ++#define net_realloc mysql_net_realloc /* namespace sanity */ + my_bool net_realloc(NET *net, size_t length); + my_bool net_flush(NET *net); + my_bool my_net_write(NET *net,const unsigned char *packet, size_t len); diff --git a/mysql-errno.patch b/mysql-errno.patch index 30cb09b..93e61de 100644 --- a/mysql-errno.patch +++ b/mysql-errno.patch @@ -1,11 +1,11 @@ "extern int errno" is just a really bad idea. -diff -Naur mysql-5.1.32.orig/include/my_sys.h mysql-5.1.32/include/my_sys.h ---- mysql-5.1.32.orig/include/my_sys.h 2009-02-13 19:52:19.000000000 -0500 -+++ mysql-5.1.32/include/my_sys.h 2009-03-04 18:08:40.000000000 -0500 -@@ -199,13 +199,8 @@ - #define my_afree(PTR) my_free(PTR,MYF(MY_WME)) +diff -Naur mysql-5.5.8.orig/include/my_sys.h mysql-5.5.8/include/my_sys.h +--- mysql-5.5.8.orig/include/my_sys.h 2010-12-03 12:58:24.000000000 -0500 ++++ mysql-5.5.8/include/my_sys.h 2010-12-20 21:20:12.622190325 -0500 +@@ -201,13 +201,8 @@ + #define my_afree(PTR) my_free(PTR) #endif /* HAVE_ALLOCA */ -#ifndef errno /* did we already get it? */ @@ -18,4 +18,4 @@ diff -Naur mysql-5.1.32.orig/include/my_sys.h mysql-5.1.32/include/my_sys.h + extern char *home_dir; /* Home directory for user */ extern const char *my_progname; /* program-name (printed in errors) */ - extern char NEAR curr_dir[]; /* Current directory for user */ + extern char curr_dir[]; /* Current directory for user */ diff --git a/mysql-lowercase-bug.patch b/mysql-lowercase-bug.patch deleted file mode 100644 index 4387838..0000000 --- a/mysql-lowercase-bug.patch +++ /dev/null @@ -1,51 +0,0 @@ -Fix multiple coding errors related to upstream bug #52019. - - -diff -Naur mysql-5.1.45.orig/client/mysqltest.cc mysql-5.1.45/client/mysqltest.cc ---- mysql-5.1.45.orig/client/mysqltest.cc 2010-03-01 14:30:46.000000000 -0500 -+++ mysql-5.1.45/client/mysqltest.cc 2010-03-25 19:46:36.000000000 -0400 -@@ -5586,7 +5586,7 @@ - /* Could be a multibyte character */ - /* This code is based on the code in "sql_load.cc" */ - #ifdef USE_MB -- int charlen = my_mbcharlen(charset_info, c); -+ int charlen = my_mbcharlen(charset_info, (unsigned char) c); - /* We give up if multibyte character is started but not */ - /* completed before we pass buf_end */ - if ((charlen > 1) && (p + charlen) <= buf_end) -@@ -5598,16 +5598,16 @@ - - for (i= 1; i < charlen; i++) - { -+ c= my_getc(cur_file->file); - if (feof(cur_file->file)) - goto found_eof; -- c= my_getc(cur_file->file); - *p++ = c; - } - if (! my_ismbchar(charset_info, mb_start, p)) - { - /* It was not a multiline char, push back the characters */ - /* We leave first 'c', i.e. pretend it was a normal char */ -- while (p > mb_start) -+ while (p > mb_start+1) - my_ungetc(*--p); - } - } -@@ -9642,6 +9642,8 @@ - void replace_dynstr_append_mem(DYNAMIC_STRING *ds, - const char *val, int len) - { -+ char lower[512]; -+ - #ifdef __WIN__ - fix_win_paths(val, len); - #endif -@@ -9649,7 +9651,6 @@ - if (display_result_lower) - { - /* Convert to lower case, and do this first */ -- char lower[512]; - char *c= lower; - for (const char *v= val; *v; v++) - *c++= my_tolower(charset_info, *v); diff --git a/mysql-missing-string-code.patch b/mysql-missing-string-code.patch deleted file mode 100644 index 4627760..0000000 --- a/mysql-missing-string-code.patch +++ /dev/null @@ -1,14 +0,0 @@ -Crude workaround for bug #587170. There are probably better ways ... - - -diff -Naur mysql-5.1.50.orig/storage/federated/Makefile.am mysql-5.1.50/storage/federated/Makefile.am ---- mysql-5.1.50.orig/storage/federated/Makefile.am 2010-08-03 13:24:29.000000000 -0400 -+++ mysql-5.1.50/storage/federated/Makefile.am 2010-08-27 23:49:22.280394828 -0400 -@@ -38,6 +38,7 @@ - ha_federated_la_CXXFLAGS= $(AM_CXXFLAGS) -DMYSQL_DYNAMIC_PLUGIN - ha_federated_la_CFLAGS = $(AM_CFLAGS) -DMYSQL_DYNAMIC_PLUGIN - ha_federated_la_SOURCES = ha_federated.cc -+ha_federated_la_LIBADD = ../../mysys/string.o - - - EXTRA_LIBRARIES = libfederated.a diff --git a/mysql-no-docs.patch b/mysql-no-docs.patch deleted file mode 100644 index 84ad86e..0000000 --- a/mysql-no-docs.patch +++ /dev/null @@ -1,39 +0,0 @@ -Remove makefile logic dealing with mysql.info. We cannot ship that -documentation since it is not freely redistributable. - - -diff -Naur mysql-5.1.44.orig/Docs/Makefile.am mysql-5.1.44/Docs/Makefile.am ---- mysql-5.1.44.orig/Docs/Makefile.am 2010-02-04 06:36:50.000000000 -0500 -+++ mysql-5.1.44/Docs/Makefile.am 2010-02-20 17:23:04.000000000 -0500 -@@ -13,28 +13,21 @@ - # along with this program; if not, write to the Free Software - # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - --EXTRA_DIST = mysql.info INSTALL-BINARY @extra_docs@ -+EXTRA_DIST = INSTALL-BINARY @extra_docs@ - --# make sure that "make install" installs the info page, too --# automake only seems to take care of this automatically, --# if we're building the info page from texi directly. --install-data-hook: $(srcdir)/mysql.info -+install-data-hook: - if test `basename $(prefix)` = "mysql" ; then \ - $(mkinstalldirs) $(DESTDIR)$(prefix)/docs ; \ -- $(INSTALL_DATA) $(srcdir)/mysql.info $(DESTDIR)$(prefix)/docs ; \ - test ! -f $(top_srcdir)/ChangeLog || $(INSTALL_DATA) $(top_srcdir)/ChangeLog $(DESTDIR)$(prefix)/docs ; \ - else \ -- $(mkinstalldirs) $(DESTDIR)$(infodir) $(DESTDIR)$(pkgdatadir) ; \ -- $(INSTALL_DATA) $(srcdir)/mysql.info $(DESTDIR)$(infodir) ; \ -+ $(mkinstalldirs) $(DESTDIR)$(pkgdatadir) ; \ - test ! -f $(top_srcdir)/ChangeLog || $(INSTALL_DATA) $(top_srcdir)/ChangeLog $(DESTDIR)$(pkgdatadir) ; \ - fi - - uninstall-local: - if test `basename $(prefix)` = "mysql" ; then \ -- @RM@ -f $(DESTDIR)$(prefix)/docs/mysql.info ; \ - @RM@ -f $(DESTDIR)$(prefix)/docs/ChangeLog ; \ - else \ -- @RM@ -f $(DESTDIR)$(infodir)/mysql.info ; \ - @RM@ -f $(DESTDIR)$(pkgdatadir)/ChangeLog ; \ - fi - diff --git a/mysql-setschedparam.patch b/mysql-setschedparam.patch deleted file mode 100644 index 3b0e518..0000000 --- a/mysql-setschedparam.patch +++ /dev/null @@ -1,22 +0,0 @@ -mysql tries to use pthread_setschedparam() with policy = SCHED_OTHER, -which is not standardized and is not presently supported on Red Hat -platforms; in fact it generates lots of SELinux warnings (bug #477624). -Easiest fix is to disable the configure test for it. - - -diff -Naur mysql-5.1.33.orig/configure.in mysql-5.1.33/configure.in ---- mysql-5.1.33.orig/configure.in 2009-03-13 17:48:52.000000000 -0400 -+++ mysql-5.1.33/configure.in 2009-04-07 19:27:25.000000000 -0400 -@@ -2046,10 +2046,10 @@ - localtime_r gethrtime gmtime_r \ - locking longjmp lrand48 madvise mallinfo memcpy memmove \ - mkstemp mlockall perror poll pread pthread_attr_create mmap mmap64 getpagesize \ -- pthread_attr_getstacksize pthread_attr_setprio pthread_attr_setschedparam \ -+ pthread_attr_getstacksize pthread_attr_setprio \ - pthread_attr_setstacksize pthread_condattr_create pthread_getsequence_np \ - pthread_key_delete pthread_rwlock_rdlock pthread_setprio \ -- pthread_setprio_np pthread_setschedparam pthread_sigmask readlink \ -+ pthread_setprio_np pthread_sigmask readlink \ - realpath rename rint rwlock_init setupterm \ - shmget shmat shmdt shmctl sigaction sigemptyset sigaddset \ - sighold sigset sigthreadmask port_create sleep \ diff --git a/mysql-ssl-multilib.patch b/mysql-ssl-multilib.patch deleted file mode 100644 index 845984b..0000000 --- a/mysql-ssl-multilib.patch +++ /dev/null @@ -1,20 +0,0 @@ -We can do without -L/usr/lib/, especially in 64-bit builds ... - - -diff -Naur mysql-5.1.30.orig/config/ac-macros/ssl.m4 mysql-5.1.30/config/ac-macros/ssl.m4 ---- mysql-5.1.30.orig/config/ac-macros/ssl.m4 2008-11-14 11:34:23.000000000 -0500 -+++ mysql-5.1.30/config/ac-macros/ssl.m4 2009-01-13 19:17:09.000000000 -0500 -@@ -102,7 +102,12 @@ - # - # Try to link with openSSL libs in - # -- openssl_libs="-L$location/lib/ -lssl -lcrypto" -+ if test "$location" != "/usr" -+ then -+ openssl_libs="-L$location/lib/ -lssl -lcrypto" -+ else -+ openssl_libs="-lssl -lcrypto" -+ fi - MYSQL_CHECK_SSL_DIR([$openssl_includes], [$openssl_libs]) - - if test "$mysql_ssl_found" == "no" diff --git a/mysql-stack-guard.patch b/mysql-stack-guard.patch index d1e3a3f..0634560 100644 --- a/mysql-stack-guard.patch +++ b/mysql-stack-guard.patch @@ -8,9 +8,9 @@ mysqld.cc; is it important to fix any of the others? Filed upstream at http://bugs.mysql.com/bug.php?id=35019 -diff -Naur mysql-5.1.30.orig/sql/mysqld.cc mysql-5.1.30/sql/mysqld.cc ---- mysql-5.1.30.orig/sql/mysqld.cc 2008-11-14 11:37:13.000000000 -0500 -+++ mysql-5.1.30/sql/mysqld.cc 2009-01-13 12:08:35.000000000 -0500 +diff -Naur mysql-5.5.8.orig/sql/mysqld.cc mysql-5.5.8/sql/mysqld.cc +--- mysql-5.5.8.orig/sql/mysqld.cc 2010-12-03 12:58:26.000000000 -0500 ++++ mysql-5.5.8/sql/mysqld.cc 2010-12-20 22:01:08.939186906 -0500 @@ -2602,6 +2602,70 @@ } @@ -82,10 +82,10 @@ diff -Naur mysql-5.1.30.orig/sql/mysqld.cc mysql-5.1.30/sql/mysqld.cc static void start_signal_handler(void) { int error; -@@ -2614,15 +2678,7 @@ +@@ -2612,15 +2676,7 @@ + #if !defined(HAVE_DEC_3_2_THREADS) + pthread_attr_setscope(&thr_attr,PTHREAD_SCOPE_SYSTEM); (void) pthread_attr_setdetachstate(&thr_attr,PTHREAD_CREATE_DETACHED); - if (!(opt_specialflag & SPECIAL_NO_PRIOR)) - my_pthread_attr_setprio(&thr_attr,INTERRUPT_PRIOR); -#if defined(__ia64__) || defined(__ia64) - /* - Peculiar things with ia64 platforms - it seems we only have half the @@ -98,11 +98,11 @@ diff -Naur mysql-5.1.30.orig/sql/mysqld.cc mysql-5.1.30/sql/mysqld.cc + (void) my_setstacksize(&thr_attr,my_thread_stack_size); #endif - (void) pthread_mutex_lock(&LOCK_thread_count); -@@ -4176,40 +4232,12 @@ + mysql_mutex_lock(&LOCK_thread_count); +@@ -4361,36 +4417,8 @@ + unireg_abort(1); // Will do exit + init_signals(); - if (!(opt_specialflag & SPECIAL_NO_PRIOR)) - my_pthread_setprio(pthread_self(),CONNECT_PRIOR); -#if defined(__ia64__) || defined(__ia64) - /* - Peculiar things with ia64 platforms - it seems we only have half the @@ -112,7 +112,7 @@ diff -Naur mysql-5.1.30.orig/sql/mysqld.cc mysql-5.1.30/sql/mysqld.cc -#else - pthread_attr_setstacksize(&connection_attrib,my_thread_stack_size); -#endif --#ifdef HAVE_PTHREAD_ATTR_GETSTACKSIZE + #ifdef HAVE_PTHREAD_ATTR_GETSTACKSIZE - { - /* Retrieve used stack size; Needed for checking stack overflows */ - size_t stack_size= 0; @@ -133,12 +133,6 @@ diff -Naur mysql-5.1.30.orig/sql/mysqld.cc mysql-5.1.30/sql/mysqld.cc -#endif - } - } --#endif -+ - #ifdef __NETWARE__ - /* Increasing stacksize of threads on NetWare */ - pthread_attr_setstacksize(&connection_attrib, NW_THD_STACKSIZE); -+#else + my_thread_stack_size = my_setstacksize(&connection_attrib,my_thread_stack_size); #endif diff --git a/mysql-strmov.patch b/mysql-strmov.patch index a144d09..3d8ccec 100644 --- a/mysql-strmov.patch +++ b/mysql-strmov.patch @@ -13,14 +13,16 @@ of any real performance gain from optimizing these calls. So I'm keeping this patch. -diff -Naur mysql-5.1.37.orig/include/m_string.h mysql-5.1.37/include/m_string.h ---- mysql-5.1.37.orig/include/m_string.h 2009-07-13 19:08:50.000000000 -0400 -+++ mysql-5.1.37/include/m_string.h 2009-08-31 21:49:49.000000000 -0400 -@@ -81,13 +81,6 @@ +diff -Naur mysql-5.5.8.orig/include/m_string.h mysql-5.5.8/include/m_string.h +--- mysql-5.5.8.orig/include/m_string.h 2010-12-03 12:58:24.000000000 -0500 ++++ mysql-5.5.8/include/m_string.h 2010-12-20 21:39:13.905186372 -0500 +@@ -74,15 +74,6 @@ extern void *(*my_str_malloc)(size_t); extern void (*my_str_free)(void *); --#if defined(HAVE_STPCPY) +-#if defined(HAVE_STPCPY) && MY_GNUC_PREREQ(3, 4) && !defined(__INTEL_COMPILER) +-#define strmov(A,B) __builtin_stpcpy((A),(B)) +-#elif defined(HAVE_STPCPY) -#define strmov(A,B) stpcpy((A),(B)) -#ifndef stpcpy -extern char *stpcpy(char *, const char *); /* For AIX with gcc 2.95.3 */ @@ -28,5 +30,5 @@ diff -Naur mysql-5.1.37.orig/include/m_string.h mysql-5.1.37/include/m_string.h -#endif - /* Declared in int2str() */ - extern char NEAR _dig_vec_upper[]; - extern char NEAR _dig_vec_lower[]; + extern char _dig_vec_upper[]; + extern char _dig_vec_lower[]; diff --git a/mysql-testing.patch b/mysql-testing.patch deleted file mode 100644 index 7438713..0000000 --- a/mysql-testing.patch +++ /dev/null @@ -1,23 +0,0 @@ -Hack the top-level Makefile to enable the openssl regression tests. -(Why doesn't this happen automatically given the configure option??) - -Also, increase the overall timeout for the regression tests to 12 hours, -because on a slow or heavily-loaded build machine sometimes the default of -5 hours isn't enough. (This has been demonstrated to fail in mass-rebuild -scenarios, which aren't that uncommon for Fedora.) Similarly increase the -per-testcase timeout to 30 minutes, since the default of 15 hasn't got a -great deal of headroom either. - - -diff -Naur mysql-5.1.32.orig/Makefile.am mysql-5.1.32/Makefile.am ---- mysql-5.1.32.orig/Makefile.am 2009-02-13 19:51:56.000000000 -0500 -+++ mysql-5.1.32/Makefile.am 2009-03-04 18:12:36.000000000 -0500 -@@ -98,7 +98,7 @@ - - test-ns: - cd mysql-test ; \ -- @PERL@ ./mysql-test-run.pl $(force) $(mem) --mysqld=--binlog-format=mixed -+ @PERL@ ./mysql-test-run.pl $(force) $(mem) --ssl --mysqld=--binlog-format=mixed --suite-timeout=720 --testcase-timeout=30 - - test-binlog-statement: - cd mysql-test ; \ diff --git a/mysql-versioning.patch b/mysql-versioning.patch new file mode 100644 index 0000000..aaaa828 --- /dev/null +++ b/mysql-versioning.patch @@ -0,0 +1,18 @@ +The symbol versioning solution for libmysqlclient in mysql 5.1 was pretty +awful (export everything) and as of 5.5.8 the cmake build scripts have +forgotten the issue entirely. So we now maintain our own list of exported +symbols and jam it into the build with this hack. + + +diff -Naur mysql-5.5.8.orig/libmysql/CMakeLists.txt mysql-5.5.8/libmysql/CMakeLists.txt +--- mysql-5.5.8.orig/libmysql/CMakeLists.txt 2010-12-03 12:58:26.000000000 -0500 ++++ mysql-5.5.8/libmysql/CMakeLists.txt 2010-12-21 21:00:07.135311386 -0500 +@@ -197,7 +197,7 @@ + SET(libmysql_link_flags) + ENDIF() + SET_TARGET_PROPERTIES(libmysql PROPERTIES LINK_FLAGS +- "${libmysql_link_flags} ${LINK_FLAG_NO_UNDEFINED}") ++ "${libmysql_link_flags} -Wl,--version-script=libmysql.version ${LINK_FLAG_NO_UNDEFINED}") + ENDIF() + # clean direct output needs to be set several targets have the same name + #(mysqlclient in this case) diff --git a/mysql.spec b/mysql.spec index fab4b93..0a73020 100644 --- a/mysql.spec +++ b/mysql.spec @@ -1,11 +1,11 @@ Name: mysql -Version: 5.1.52 +Version: 5.5.8 Release: 1%{?dist} Summary: MySQL client programs and shared libraries Group: Applications/Databases URL: http://www.mysql.com # exceptions allow client libraries to be linked with most open source SW, -# not only GPL code. +# not only GPL code. See README.mysql-license License: GPLv2 with exceptions # Regression tests take a long time, you can skip 'em with this @@ -25,30 +25,26 @@ Source3: my.cnf Source4: scriptstub.c Source5: my_config.h Source6: README.mysql-docs +Source7: README.mysql-license +Source8: libmysql.version Source9: mysql-embedded-check.c # Working around perl dependency checking bug in rpm FTTB. Remove later. Source999: filter-requires-mysql.sh -Patch1: mysql-ssl-multilib.patch -Patch2: mysql-errno.patch -# Patch3: mysql-stack.patch -Patch4: mysql-testing.patch -Patch5: mysql-install-test.patch -Patch6: mysql-stack-guard.patch -Patch7: mysql-disable-test.patch -Patch8: mysql-setschedparam.patch -Patch9: mysql-no-docs.patch -Patch10: mysql-strmov.patch -Patch12: mysql-cve-2008-7247.patch -Patch13: mysql-expired-certs.patch -Patch14: mysql-missing-string-code.patch -Patch15: mysql-lowercase-bug.patch -Patch16: mysql-chain-certs.patch +Patch1: mysql-errno.patch +Patch2: mysql-strmov.patch +Patch3: mysql-install-test.patch +Patch4: mysql-expired-certs.patch +Patch5: mysql-stack-guard.patch +Patch6: mysql-chain-certs.patch +Patch7: mysql-versioning.patch +Patch8: mysql-dubious-exports.patch +Patch9: mysql-disable-test.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root BuildRequires: gperf, perl, readline-devel, openssl-devel -BuildRequires: gcc-c++, ncurses-devel, zlib-devel -BuildRequires: libtool automake autoconf gawk +BuildRequires: gcc-c++, cmake, ncurses-devel, zlib-devel, libaio-devel +BuildRequires: systemtap-sdt-devel # make test requires time and ps BuildRequires: time procps # Socket is needed to run regression tests @@ -89,6 +85,7 @@ MySQL server. Summary: The MySQL server and related files Group: Applications/Databases Requires: %{name} = %{version}-%{release} +Requires: %{name}-libs = %{version}-%{release} Requires: sh-utils Requires(pre): /usr/sbin/useradd Requires(post): chkconfig @@ -111,6 +108,7 @@ the MySQL server and some accompanying files and directories. Summary: Files for development of MySQL applications Group: Applications/Databases Requires: %{name} = %{version}-%{release} +Requires: %{name}-libs = %{version}-%{release} Requires: openssl-devel Conflicts: MySQL-devel @@ -158,6 +156,7 @@ MySQL. Summary: The test suite distributed with MySQL Group: Applications/Databases Requires: %{name} = %{version}-%{release} +Requires: %{name}-libs = %{version}-%{release} Requires: %{name}-server = %{version}-%{release} Conflicts: MySQL-test @@ -171,28 +170,19 @@ the MySQL sources. %patch1 -p1 %patch2 -p1 -# %patch3 -p1 +%patch3 -p1 %patch4 -p1 %patch5 -p1 %patch6 -p1 %patch7 -p1 %patch8 -p1 %patch9 -p1 -%patch10 -p1 -%patch12 -p1 -%patch13 -p1 -%patch14 -p1 -%patch15 -p1 -%patch16 -p1 # workaround for upstream bug #56342 rm -f mysql-test/t/ssl_8k_key-master.opt -libtoolize --force -aclocal -automake --add-missing -Wno-portability -autoconf -autoheader +# upstream has fallen down badly on symbol versioning, do it ourselves +cp %{SOURCE8} libmysql/libmysql.version %build @@ -221,43 +211,46 @@ CFLAGS=`echo $CFLAGS| sed -e "s|-O2|-O1|g" ` CXXFLAGS="$CFLAGS -felide-constructors -fno-rtti -fno-exceptions" export CFLAGS CXXFLAGS -# mysql 5.1.30 fails regression tests on x86 unless we use --with-big-tables, -# suggesting that upstream doesn't bother to test the other case ... -# note: the with-plugin and without-plugin options do actually work; ignore -# warnings from configure suggesting they are ignored ... -%configure \ - --with-readline \ - --with-ssl=/usr \ - --without-debug \ - --enable-shared \ - --with-embedded-server \ - --localstatedir=/var/lib/mysql \ - --with-unix-socket-path=/var/lib/mysql/mysql.sock \ - --with-mysqld-user="mysql" \ - --with-extra-charsets=all \ - --with-big-tables \ - --with-pic \ - --with-plugin-innobase \ - --without-plugin-innodb_plugin \ - --with-plugin-partition \ - --enable-local-infile \ - --enable-largefile \ - --enable-thread-safe-client \ - --disable-dependency-tracking +# The INSTALL_xxx macros have to be specified relative to CMAKE_INSTALL_PREFIX +# so we can't use %%{_datadir} and so forth here. + +cmake . -DBUILD_CONFIG=mysql_release \ + -DFEATURE_SET="community" \ + -DINSTALL_LAYOUT=RPM \ + -DCMAKE_INSTALL_PREFIX="%{_prefix}" \ + -DINSTALL_INCLUDEDIR=include/mysql \ + -DINSTALL_INFODIR=share/info \ + -DINSTALL_LIBDIR="%{_lib}/mysql" \ + -DINSTALL_MANDIR=share/man \ + -DINSTALL_MYSQLSHAREDIR=share/mysql \ + -DINSTALL_MYSQLTESTDIR=share/mysql-test \ + -DINSTALL_PLUGINDIR="%{_lib}/mysql/plugin" \ + -DINSTALL_SBINDIR=libexec \ + -DINSTALL_SCRIPTDIR=bin \ + -DINSTALL_SQLBENCHDIR=share \ + -DINSTALL_SUPPORTFILESDIR=share/mysql \ + -DMYSQL_DATADIR="/var/lib/mysql" \ + -DMYSQL_UNIX_ADDR="/var/lib/mysql/mysql.sock" \ + -DENABLED_LOCAL_INFILE=ON \ + -DENABLE_DTRACE=ON \ + -DWITH_EMBEDDED_SERVER=ON \ + -DWITH_READLINE=ON \ + -DWITH_SSL=system \ + -DWITH_ZLIB=system gcc $CFLAGS $LDFLAGS -o scriptstub "-DLIBDIR=\"%{_libdir}/mysql\"" %{SOURCE4} -# Not enabling assembler - -make %{?_smp_mflags} +make %{?_smp_mflags} VERBOSE=1 # regular build will make libmysqld.a but not libmysqld.so :-( mkdir libmysqld/work cd libmysqld/work ar -x ../libmysqld.a +# these result in missing dependencies: (filed upstream as bug 59104) +rm -f sql_binlog.cc.o rpl_utility.cc.o 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 + *.o ../../probes_mysql.o \ + -lpthread -laio -lcrypt -lssl -lcrypto -lz -lrt -lstdc++ -ldl -lm -lc # this is to check that we built a complete library cp %{SOURCE9} . ln -s libmysqld.so.0.0.1 libmysqld.so.0 @@ -265,8 +258,6 @@ gcc -I../../include $CFLAGS mysql-embedded-check.c libmysqld.so.0 LD_LIBRARY_PATH=. ldd ./a.out cd ../.. -make check - %if %runselftest # hack to let 32- and 64-bit tests run concurrently on same build machine case `uname -m` in @@ -279,16 +270,31 @@ make check esac export MTR_BUILD_THREAD - # note: "make test" invokes two largely-duplicate sets of tests, - # which makes the runtime really unacceptably long ... - # if you want to change this, look at mysql-testing.patch too. - make test-ns + make test + + # The cmake build scripts don't provide any simple way to control the + # options for mysql-test-run, so ignore the make target and just call it + # manually. Nonstandard options chosen are: + # --force to continue tests after a failure + # no retries please + # test SSL with --ssl + # avoid redundant test runs with --binlog-format=mixed + # increase timeouts to prevent unwanted failures during mass rebuilds + ( + cd mysql-test + perl ./mysql-test-run.pl --force --retry=0 --ssl --mysqld=--binlog-format=mixed --suite-timeout=720 --testcase-timeout=30 + # cmake build scripts will install the var cruft if left alone :-( + rm -rf var + ) %endif %install rm -rf $RPM_BUILD_ROOT -%makeinstall +make DESTDIR=$RPM_BUILD_ROOT install + +# List the installed tree for RPM package maintenance purposes. +find $RPM_BUILD_ROOT -print | sed "s|^$RPM_BUILD_ROOT||" | sort > ROOTFILES # multilib header hacks # we only apply this to known Red Hat multilib arches, per bug #181335 @@ -301,56 +307,70 @@ case `uname -i` in ;; esac +# cmake generates some completely wacko references to -lprobes_mysql when +# building with dtrace support. Haven't found where to shut that off, +# so resort to this blunt instrument. While at it, let's not reference +# libmysqlclient_r anymore either. +sed -e 's/-lprobes_mysql//' -e 's/-lmysqlclient_r/-lmysqlclient/' \ + ${RPM_BUILD_ROOT}%{_bindir}/mysql_config >mysql_config.tmp +cp -f mysql_config.tmp ${RPM_BUILD_ROOT}%{_bindir}/mysql_config +chmod 755 ${RPM_BUILD_ROOT}%{_bindir}/mysql_config + mkdir -p $RPM_BUILD_ROOT/var/log touch $RPM_BUILD_ROOT/var/log/mysqld.log -# List the installed tree for RPM package maintenance purposes. -find $RPM_BUILD_ROOT -print | sed "s|^$RPM_BUILD_ROOT||" | sort > ROOTFILES - mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d mkdir -p $RPM_BUILD_ROOT/var/run/mysqld install -m 0755 -d $RPM_BUILD_ROOT/var/lib/mysql install -m 0755 %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/mysqld install -m 0644 %{SOURCE3} $RPM_BUILD_ROOT/etc/my.cnf -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 -# 5.1.32 forgets to install the mysql-test README file -install -m 0644 mysql-test/README $RPM_BUILD_ROOT%{_datadir}/mysql-test/README +# Fix funny permissions that cmake build scripts apply to config files +chmod 644 ${RPM_BUILD_ROOT}%{_datadir}/mysql/config.*.ini + +# Fix scripts for multilib safety mv ${RPM_BUILD_ROOT}%{_bindir}/mysqlbug ${RPM_BUILD_ROOT}%{_libdir}/mysql/mysqlbug install -m 0755 scriptstub ${RPM_BUILD_ROOT}%{_bindir}/mysqlbug mv ${RPM_BUILD_ROOT}%{_bindir}/mysql_config ${RPM_BUILD_ROOT}%{_libdir}/mysql/mysql_config install -m 0755 scriptstub ${RPM_BUILD_ROOT}%{_bindir}/mysql_config +# Remove libmysqld.a, install libmysqld.so rm -f ${RPM_BUILD_ROOT}%{_libdir}/mysql/libmysqld.a install -m 0755 libmysqld/work/libmysqld.so.0.0.1 ${RPM_BUILD_ROOT}%{_libdir}/mysql/libmysqld.so.0.0.1 ln -s libmysqld.so.0.0.1 ${RPM_BUILD_ROOT}%{_libdir}/mysql/libmysqld.so.0 ln -s libmysqld.so.0 ${RPM_BUILD_ROOT}%{_libdir}/mysql/libmysqld.so -rm -f ${RPM_BUILD_ROOT}%{_bindir}/comp_err -rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/comp_err.1* -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}%{_mandir}/man1/make_win_bin_dist.1* -rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/make_win_src_distribution.1* -rm -f ${RPM_BUILD_ROOT}%{_libdir}/mysql/libmysqlclient*.la +# libmysqlclient_r is no more. Upstream tries to replace it with symlinks +# but that really doesn't work (wrong soname in particular). We'll keep +# just the devel libmysqlclient_r.so link, so that rebuilding without any +# source change is enough to get rid of dependency on libmysqlclient_r. +rm -f ${RPM_BUILD_ROOT}%{_libdir}/mysql/libmysqlclient_r.so* +ln -s libmysqlclient.so ${RPM_BUILD_ROOT}%{_libdir}/mysql/libmysqlclient_r.so + +# mysql-test includes one executable that doesn't belong under /usr/share, +# so move it and provide a symlink +mv ${RPM_BUILD_ROOT}%{_datadir}/mysql-test/lib/My/SafeProcess/my_safe_process ${RPM_BUILD_ROOT}%{_bindir} +ln -s ../../../../../bin/my_safe_process ${RPM_BUILD_ROOT}%{_datadir}/mysql-test/lib/My/SafeProcess/my_safe_process + +# Remove files that %%doc will install in preferred location +rm -f ${RPM_BUILD_ROOT}/usr/COPYING +rm -f ${RPM_BUILD_ROOT}/usr/README + +# Remove files we don't want installed at all +rm -f ${RPM_BUILD_ROOT}/usr/INSTALL-BINARY +rm -f ${RPM_BUILD_ROOT}/usr/docs/ChangeLog +rm -f ${RPM_BUILD_ROOT}/usr/data/mysql/.empty +rm -f ${RPM_BUILD_ROOT}/usr/data/test/.empty +# should move this to /etc/ ? +rm -f ${RPM_BUILD_ROOT}%{_bindir}/mysqlaccess.conf rm -f ${RPM_BUILD_ROOT}%{_libdir}/mysql/*.a -rm -f ${RPM_BUILD_ROOT}%{_libdir}/mysql/plugin/*.la -rm -f ${RPM_BUILD_ROOT}%{_libdir}/mysql/plugin/*.a rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/binary-configure -rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/make_binary_distribution -rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/make_sharedlib_distribution -rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/mi_test_all* +rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/magic rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/ndb-config-2-node.ini rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/mysql.server rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/mysqld_multi.server -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/preinstall -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 -rm -f ${RPM_BUILD_ROOT}%{_datadir}/mysql/ChangeLog +rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/comp_err.1* rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/mysql-stress-test.pl.1* rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/mysql-test-run.pl.1* @@ -359,6 +379,7 @@ echo "%{_libdir}/mysql" > $RPM_BUILD_ROOT/etc/ld.so.conf.d/%{name}-%{_arch}.conf # copy additional docs into build tree so %%doc will find them cp %{SOURCE6} README.mysql-docs +cp %{SOURCE7} README.mysql-license %clean rm -rf $RPM_BUILD_ROOT @@ -397,7 +418,7 @@ fi %files %defattr(-,root,root) -%doc README COPYING EXCEPTIONS-CLIENT +%doc README COPYING README.mysql-license %doc README.mysql-docs %{_bindir}/msql2mysql @@ -426,17 +447,16 @@ fi %{_mandir}/man1/mysqlslap.1* %{_mandir}/man1/my_print_defaults.1* -%{_libdir}/mysql/mysqlbug %{_libdir}/mysql/mysql_config %files libs %defattr(-,root,root) -%doc COPYING EXCEPTIONS-CLIENT +%doc README COPYING README.mysql-license # although the default my.cnf contains only server settings, we put it in the # libs package because it can be used for client settings too. %config(noreplace) /etc/my.cnf %dir %{_libdir}/mysql -%{_libdir}/mysql/libmysqlclient*.so.* +%{_libdir}/mysql/libmysqlclient.so.* /etc/ld.so.conf.d/* %dir %{_datadir}/mysql @@ -475,7 +495,6 @@ fi %{_bindir}/myisampack %{_bindir}/mysql_convert_table_format %{_bindir}/mysql_fix_extensions -%{_bindir}/mysql_fix_privilege_tables %{_bindir}/mysql_install_db %{_bindir}/mysql_secure_installation %{_bindir}/mysql_setpermission @@ -495,7 +514,8 @@ fi %{_bindir}/resolveip /usr/libexec/mysqld -/usr/libexec/mysqlmanager + +%{_libdir}/mysql/mysqlbug %{_libdir}/mysql/plugin @@ -507,7 +527,6 @@ fi %{_mandir}/man1/myisam_ftdump.1* %{_mandir}/man1/mysql.server.1* %{_mandir}/man1/mysql_fix_extensions.1* -%{_mandir}/man1/mysql_fix_privilege_tables.1* %{_mandir}/man1/mysql_install_db.1* %{_mandir}/man1/mysql_secure_installation.1* %{_mandir}/man1/mysql_upgrade.1* @@ -530,11 +549,9 @@ fi %{_mandir}/man1/resolveip.1* %{_mandir}/man1/mysql_tzinfo_to_sql.1* %{_mandir}/man8/mysqld.8* -%{_mandir}/man8/mysqlmanager.8* -%{_datadir}/mysql/errmsg.txt +%{_datadir}/mysql/errmsg-utf8.txt %{_datadir}/mysql/fill_help_tables.sql -%{_datadir}/mysql/mysql_fix_privilege_tables.sql %{_datadir}/mysql/mysql_system_tables.sql %{_datadir}/mysql/mysql_system_tables_data.sql %{_datadir}/mysql/mysql_test_data_timezone.sql @@ -550,11 +567,12 @@ fi %defattr(-,root,root) /usr/include/mysql /usr/share/aclocal/mysql.m4 -%{_libdir}/mysql/libmysqlclient*.so +%{_libdir}/mysql/libmysqlclient.so +%{_libdir}/mysql/libmysqlclient_r.so %files embedded %defattr(-,root,root) -%doc COPYING EXCEPTIONS-CLIENT +%doc README COPYING README.mysql-license %{_libdir}/mysql/libmysqld.so.* %files embedded-devel @@ -572,11 +590,18 @@ fi %files test %defattr(-,root,root) %{_bindir}/mysql_client_test +%{_bindir}/my_safe_process %attr(-,mysql,mysql) %{_datadir}/mysql-test %{_mandir}/man1/mysql_client_test.1* %changelog +* Thu Dec 23 2010 Tom Lane 5.5.8-1 +- Update to MySQL 5.5.8 (major version bump). Note this includes removal + of libmysqlclient_r.so. +- Add a linker version script to hide libmysqlclient functions that aren't + part of the documented API. + * Mon Nov 1 2010 Tom Lane 5.1.52-1 - Update to MySQL 5.1.52, for various fixes described at http://dev.mysql.com/doc/refman/5.1/en/news-5-1-52.html diff --git a/sources b/sources index c7065a3..00d9f3f 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -998cc66664f6289596bde8fac85dd831 mysql-5.1.52-nodocs.tar.gz +a2214f5a79516c1e6b36b82f1dd361a0 mysql-5.5.8-nodocs.tar.gz