Commit e9cf23d1 authored by unknown's avatar unknown
Browse files

Merge neptunus.(none):/home/msvensson/mysql/bug2596

into neptunus.(none):/home/msvensson/mysql/mysql-4.1

parents f65f2799 21d5136d
Loading
Loading
Loading
Loading
+34 −5
Original line number Diff line number Diff line
@@ -97,10 +97,10 @@ undefine([AC_CV_NAME])dnl
AC_DEFUN([MYSQL_TYPE_ACCEPT],
[ac_save_CXXFLAGS="$CXXFLAGS"
AC_CACHE_CHECK([base type of last arg to accept], mysql_cv_btype_last_arg_accept,
AC_LANG_SAVE
AC_LANG_CPLUSPLUS
AC_LANG_PUSH(C++)
if test "$ac_cv_prog_gxx" = "yes"
then
  # Add -Werror, remove -fbranch-probabilities (Bug #268)
  CXXFLAGS=`echo $CXXFLAGS -Werror | sed 's/-fbranch-probabilities//'`
fi
mysql_cv_btype_last_arg_accept=none
@@ -127,7 +127,7 @@ fi
if test "$mysql_cv_btype_last_arg_accept" = "none"; then
mysql_cv_btype_last_arg_accept=int
fi)
AC_LANG_RESTORE
AC_LANG_POP(C++)
AC_DEFINE_UNQUOTED([SOCKET_SIZE_TYPE], [$mysql_cv_btype_last_arg_accept],
                   [The base type of the last arg to accept])
CXXFLAGS="$ac_save_CXXFLAGS"
@@ -153,6 +153,35 @@ then
fi
])

#---START: Figure out whether to use 'struct rlimit' or 'struct rlimit64'
AC_DEFUN([MYSQL_TYPE_STRUCT_RLIMIT],
[ac_save_CXXFLAGS="$CXXFLAGS"
AC_CACHE_CHECK([struct type to use with setrlimit], mysql_cv_btype_struct_rlimit,
AC_LANG_PUSH(C++)
if test "$ac_cv_prog_gxx" = "yes"
then
  # Add -Werror, remove -fbranch-probabilities (Bug #268)
  CXXFLAGS=`echo $CXXFLAGS -Werror | sed 's/-fbranch-probabilities//'`
fi
mysql_cv_btype_struct_rlimit=none
[AC_TRY_COMPILE([#if defined(inline)
#undef inline
#endif
#include <stdlib.h>
#include <sys/resource.h>
],
[struct rlimit64 rl; setrlimit(RLIMIT_CORE, &rl);],
mysql_cv_btype_struct_rlimit="struct rlimit64")]
if test "$mysql_cv_btype_struct_rlimit" = "none"; then
mysql_cv_btype_struct_rlimit="struct rlimit"
fi)
AC_LANG_POP(C++)
AC_DEFINE_UNQUOTED([STRUCT_RLIMIT], [$mysql_cv_btype_struct_rlimit],
                   [The struct rlimit type to use with setrlimit])
CXXFLAGS="$ac_save_CXXFLAGS"
])
#---END:

AC_DEFUN([MYSQL_TIMESPEC_TS],
[AC_CACHE_CHECK([if struct timespec has a ts_sec member], mysql_cv_timespec_ts,
[AC_TRY_COMPILE([#include <pthread.h>
@@ -1940,8 +1969,8 @@ m4_define([_AC_PROG_CXX_EXIT_DECLARATION],
   'void exit (int);' \
   '#include <stdlib.h>'
do
  _AC_COMPILE_IFELSE([AC_LANG_PROGRAM([@%:@include <stdlib.h>
$ac_declaration],
  _AC_COMPILE_IFELSE([AC_LANG_PROGRAM([$ac_declaration
@%:@include <stdlib.h>],
                                      [exit (42);])],
                     [],
                     [continue])
+2 −0
Original line number Diff line number Diff line
@@ -1795,6 +1795,8 @@ AC_C_BIGENDIAN
MYSQL_TYPE_ACCEPT

#---END:
# Figure out what type of struct rlimit to use with setrlimit
MYSQL_TYPE_STRUCT_RLIMIT
# Find where the stack goes
MYSQL_STACK_DIRECTION
# We want to skip alloca on irix unconditionally. It may work on some version..
+11 −1
Original line number Diff line number Diff line
@@ -197,6 +197,16 @@ FILE* dict_foreign_err_file = NULL;
mutex_t	dict_foreign_err_mutex; 	/* mutex protecting the foreign
					and unique error buffers */
	
/**********************************************************************
Makes all characters in a NUL-terminated UTF-8 string lower case. */

void
dict_casedn_str(
/*============*/
	char*	a)	/* in/out: string to put in lower case */
{
	innobase_casedn_str(a);
}

/************************************************************************
Checks if the database name in two table names is the same. */
+9 −0
Original line number Diff line number Diff line
@@ -25,6 +25,7 @@ Created 10/25/1995 Heikki Tuuri
#include "srv0start.h"
#include "mtr0mtr.h"
#include "mtr0log.h"
#include "dict0dict.h"

	 
/*
@@ -2732,7 +2733,15 @@ fil_load_single_table_tablespace(
	sprintf(filepath, "%s/%s/%s", fil_path_to_mysql_datadir, dbname,
								filename);
	srv_normalize_path_for_win(filepath);
#ifdef __WIN__
	/* If lower_case_table_names is 0 or 2, then MySQL allows database
	directory names with upper case letters. On Windows, all table and
	database names in InnoDB are internally always in lower case. Put the
	file path to lower case, so that we are consistent with InnoDB's
	internal data dictionary. */

	dict_casedn_str(filepath);
#endif
	file = os_file_create_simple_no_error_handling(filepath, OS_FILE_OPEN,
						OS_FILE_READ_ONLY, &success);
	if (!success) {
+7 −0
Original line number Diff line number Diff line
@@ -26,6 +26,13 @@ Created 1/8/1996 Heikki Tuuri
#include "ut0byte.h"
#include "trx0types.h"

/**********************************************************************
Makes all characters in a NUL-terminated UTF-8 string lower case. */

void
dict_casedn_str(
/*============*/
	char*	a);	/* in/out: string to put in lower case */
/************************************************************************
Get the database name length in a table name. */

Loading