Commit cc57e4e0 authored by knielsen@mysql.com's avatar knielsen@mysql.com

Manual merge.

parents 8cb3cf23 45905063
...@@ -20,7 +20,7 @@ AUTOMAKE_OPTIONS = foreign ...@@ -20,7 +20,7 @@ AUTOMAKE_OPTIONS = foreign
# These are built from source in the Docs directory # These are built from source in the Docs directory
EXTRA_DIST = INSTALL-SOURCE INSTALL-WIN-SOURCE \ EXTRA_DIST = INSTALL-SOURCE INSTALL-WIN-SOURCE \
README COPYING EXCEPTIONS-CLIENT README COPYING EXCEPTIONS-CLIENT cmakelists.txt
SUBDIRS = . include @docs_dirs@ @zlib_dir@ @yassl_dir@ \ SUBDIRS = . include @docs_dirs@ @zlib_dir@ @yassl_dir@ \
@readline_topdir@ sql-common \ @readline_topdir@ sql-common \
@thread_dirs@ pstack \ @thread_dirs@ pstack \
...@@ -29,7 +29,7 @@ SUBDIRS = . include @docs_dirs@ @zlib_dir@ @yassl_dir@ \ ...@@ -29,7 +29,7 @@ SUBDIRS = . include @docs_dirs@ @zlib_dir@ @yassl_dir@ \
@mysql_se_plugins@ \ @mysql_se_plugins@ \
netware @libmysqld_dirs@ \ netware @libmysqld_dirs@ \
@bench_dirs@ support-files @tools_dirs@ \ @bench_dirs@ support-files @tools_dirs@ \
plugin plugin win
DIST_SUBDIRS = . include @docs_dirs@ zlib \ DIST_SUBDIRS = . include @docs_dirs@ zlib \
@readline_topdir@ sql-common \ @readline_topdir@ sql-common \
...@@ -39,7 +39,7 @@ DIST_SUBDIRS = . include @docs_dirs@ zlib \ ...@@ -39,7 +39,7 @@ DIST_SUBDIRS = . include @docs_dirs@ zlib \
@man_dirs@ tests SSL\ @man_dirs@ tests SSL\
BUILD netware os2 @libmysqld_dirs@\ BUILD netware os2 @libmysqld_dirs@\
@bench_dirs@ support-files server-tools tools \ @bench_dirs@ support-files server-tools tools \
plugin plugin win
# Run these targets before any others, also make part of clean target, # Run these targets before any others, also make part of clean target,
# to make sure we create new links after a clean. # to make sure we create new links after a clean.
......
...@@ -77,6 +77,7 @@ strings_src=decimal.c ...@@ -77,6 +77,7 @@ strings_src=decimal.c
# Fix for mit-threads # Fix for mit-threads
DEFS = -DUNDEF_THREADS_HACK DEFS = -DUNDEF_THREADS_HACK
EXTRA_DIST = get_password.c cmakelists.txt
link_sources: link_sources:
for f in $(sql_src) ; do \ for f in $(sql_src) ; do \
......
...@@ -33,5 +33,5 @@ ENDIF(CMAKE_GENERATOR MATCHES "Visual Studio 7" OR CMAKE_GENERATOR MATCHES "Visu ...@@ -33,5 +33,5 @@ ENDIF(CMAKE_GENERATOR MATCHES "Visual Studio 7" OR CMAKE_GENERATOR MATCHES "Visu
ADD_DEFINITIONS("-D_WINDOWS -D__WIN__ -D _CRT_SECURE_NO_DEPRECATE") ADD_DEFINITIONS("-D_WINDOWS -D__WIN__ -D _CRT_SECURE_NO_DEPRECATE")
SUBDIRS(vio dbug strings regex mysys extra/yassl extra/yassl/taocrypt extra SUBDIRS(vio dbug strings regex mysys extra/yassl extra/yassl/taocrypt extra
zlib storage/innobase storage/heap storage/myisam storage/myisammrg zlib storage/heap storage/myisam storage/myisammrg client
client sql server-tools/instance-manager libmysql tests) ${se_subdirs} sql server-tools/instance-manager libmysql tests)
...@@ -2620,7 +2620,8 @@ AC_CONFIG_FILES(Makefile extra/Makefile mysys/Makefile dnl ...@@ -2620,7 +2620,8 @@ AC_CONFIG_FILES(Makefile extra/Makefile mysys/Makefile dnl
zlib/Makefile dnl zlib/Makefile dnl
cmd-line-utils/readline/Makefile dnl cmd-line-utils/readline/Makefile dnl
plugin/Makefile dnl plugin/Makefile dnl
plugin/fulltext/Makefile) plugin/fulltext/Makefile dnl
win/Makefile)
AC_CONFIG_COMMANDS([default], , test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h) AC_CONFIG_COMMANDS([default], , test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h)
AC_OUTPUT AC_OUTPUT
......
...@@ -20,7 +20,7 @@ LDADD = libdbug.a ../mysys/libmysys.a ../strings/libmystrings.a ...@@ -20,7 +20,7 @@ LDADD = libdbug.a ../mysys/libmysys.a ../strings/libmystrings.a
pkglib_LIBRARIES = libdbug.a pkglib_LIBRARIES = libdbug.a
noinst_HEADERS = dbug_long.h noinst_HEADERS = dbug_long.h
libdbug_a_SOURCES = dbug.c sanity.c libdbug_a_SOURCES = dbug.c sanity.c
EXTRA_DIST = example1.c example2.c example3.c \ EXTRA_DIST = cmakelists.txt example1.c example2.c example3.c \
user.r monty.doc dbug_add_tags.pl \ user.r monty.doc dbug_add_tags.pl \
my_main.c main.c factorial.c dbug_analyze.c my_main.c main.c factorial.c dbug_analyze.c
NROFF_INC = example1.r example2.r example3.r main.r \ NROFF_INC = example1.r example2.r example3.r main.r \
......
...@@ -43,6 +43,7 @@ $(top_builddir)/include/sql_state.h: $(top_builddir)/include/mysqld_error.h ...@@ -43,6 +43,7 @@ $(top_builddir)/include/sql_state.h: $(top_builddir)/include/mysqld_error.h
bin_PROGRAMS = replace comp_err perror resolveip my_print_defaults \ bin_PROGRAMS = replace comp_err perror resolveip my_print_defaults \
resolve_stack_dump mysql_waitpid innochecksum resolve_stack_dump mysql_waitpid innochecksum
noinst_PROGRAMS = charset2html noinst_PROGRAMS = charset2html
EXTRA_DIST = cmakelists.txt
perror.o: perror.c perror.o: perror.c
$(COMPILE) @ndbcluster_includes@ $(LM_CFLAGS) -c $< $(COMPILE) @ndbcluster_includes@ $(LM_CFLAGS) -c $<
......
...@@ -188,8 +188,9 @@ int main(int argc, char *argv[]) ...@@ -188,8 +188,9 @@ int main(int argc, char *argv[])
DBUG_RETURN(1); DBUG_RETURN(1);
} }
clean_up(lang_head, error_head); clean_up(lang_head, error_head);
DBUG_LEAVE; /* Can't use dbug after my_end() */
my_end(info_flag ? MY_CHECK_ERROR | MY_GIVE_INFO : 0); my_end(info_flag ? MY_CHECK_ERROR | MY_GIVE_INFO : 0);
DBUG_RETURN(0); return 0;
} }
} }
......
SUBDIRS = taocrypt src SUBDIRS = taocrypt src
EXTRA_DIST = yassl.dsp yassl.dsw yassl.vcproj $(wildcard mySTL/*.hpp) EXTRA_DIST = yassl.dsp yassl.dsw yassl.vcproj $(wildcard mySTL/*.hpp) \
cmakelists.txt
SUBDIRS = src SUBDIRS = src
EXTRA_DIST = taocrypt.dsw taocrypt.dsp taocrypt.vcproj EXTRA_DIST = taocrypt.dsw taocrypt.dsp taocrypt.vcproj cmakelists.txt
...@@ -81,6 +81,7 @@ extern FILE *_db_fp_(void); ...@@ -81,6 +81,7 @@ extern FILE *_db_fp_(void);
#else /* No debugger */ #else /* No debugger */
#define DBUG_ENTER(a1) #define DBUG_ENTER(a1)
#define DBUG_LEAVE
#define DBUG_RETURN(a1) do { return(a1); } while(0) #define DBUG_RETURN(a1) do { return(a1); } while(0)
#define DBUG_VOID_RETURN do { return; } while(0) #define DBUG_VOID_RETURN do { return; } while(0)
#define DBUG_EXECUTE(keyword,a1) do { } while(0) #define DBUG_EXECUTE(keyword,a1) do { } while(0)
......
...@@ -116,6 +116,13 @@ void pthread_exit(void *a); /* was #define pthread_exit(A) ExitThread(A)*/ ...@@ -116,6 +116,13 @@ void pthread_exit(void *a); /* was #define pthread_exit(A) ExitThread(A)*/
#define _REENTRANT 1 #define _REENTRANT 1
#define HAVE_PTHREAD_ATTR_SETSTACKSIZE 1 #define HAVE_PTHREAD_ATTR_SETSTACKSIZE 1
/*
Windows has two ways to use thread local storage. The most efficient
is using __declspec(thread), but that does not work properly when
used in a .dll that is loaded at runtime, after program load. So for
libmysql.dll and libmysqld.dll we define USE_TLS in order to use the
TlsXxx() API instead, which works in all cases.
*/
#ifdef USE_TLS /* For LIBMYSQL.DLL */ #ifdef USE_TLS /* For LIBMYSQL.DLL */
#undef SAFE_MUTEX /* This will cause conflicts */ #undef SAFE_MUTEX /* This will cause conflicts */
#define pthread_key(T,V) DWORD V #define pthread_key(T,V) DWORD V
......
...@@ -31,7 +31,7 @@ include $(srcdir)/Makefile.shared ...@@ -31,7 +31,7 @@ include $(srcdir)/Makefile.shared
libmysqlclient_la_SOURCES = $(target_sources) libmysqlclient_la_SOURCES = $(target_sources)
libmysqlclient_la_LIBADD = $(target_libadd) $(yassl_libs_with_path) libmysqlclient_la_LIBADD = $(target_libadd) $(yassl_libs_with_path)
libmysqlclient_la_LDFLAGS = $(target_ldflags) libmysqlclient_la_LDFLAGS = $(target_ldflags)
EXTRA_DIST = Makefile.shared libmysql.def EXTRA_DIST = Makefile.shared libmysql.def dll.c mytest.c cmakelists.txt
noinst_HEADERS = client_settings.h noinst_HEADERS = client_settings.h
# This is called from the toplevel makefile # This is called from the toplevel makefile
......
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX") # Need to set USE_TLS, since __declspec(thread) approach to thread local
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX") # storage does not work properly in DLLs.
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX -DUSE_TLS")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX -DUSE_TLS")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include
${CMAKE_SOURCE_DIR}/zlib ${CMAKE_SOURCE_DIR}/zlib
...@@ -48,6 +50,5 @@ ADD_LIBRARY(libmysql MODULE dll.c libmysql.def ...@@ -48,6 +50,5 @@ ADD_LIBRARY(libmysql MODULE dll.c libmysql.def
ADD_DEPENDENCIES(libmysql dbug vio mysys strings GenError zlib yassl taocrypt) ADD_DEPENDENCIES(libmysql dbug vio mysys strings GenError zlib yassl taocrypt)
TARGET_LINK_LIBRARIES(libmysql mysys strings wsock32) TARGET_LINK_LIBRARIES(libmysql mysys strings wsock32)
# ToDo: We should move the mytest.c program out in libmysql/ ADD_EXECUTABLE(myTest mytest.c)
ADD_EXECUTABLE(myTest ../VC++Files/libmysqltest/mytest.c)
TARGET_LINK_LIBRARIES(myTest libmysql) TARGET_LINK_LIBRARIES(myTest libmysql)
/*C4*/
/****************************************************************/
/* Author: Jethro Wright, III TS : 3/ 4/1998 9:15 */
/* Date: 02/18/1998 */
/* mytest.c : do some testing of the libmySQL.DLL.... */
/* */
/* History: */
/* 02/18/1998 jw3 also sprach zarathustra.... */
/****************************************************************/
#include <windows.h>
#include <stdio.h>
#include <string.h>
#include <mysql.h>
#define DEFALT_SQL_STMT "SELECT * FROM db"
#ifndef offsetof
#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
#endif
/********************************************************
**
** main :-
**
********************************************************/
int
main( int argc, char * argv[] )
{
char szSQL[ 200 ], aszFlds[ 25 ][ 25 ], szDB[ 50 ] ;
const char *pszT;
int i, j, k, l, x ;
MYSQL * myData ;
MYSQL_RES * res ;
MYSQL_FIELD * fd ;
MYSQL_ROW row ;
//....just curious....
printf( "sizeof( MYSQL ) == %d\n", (int) sizeof( MYSQL ) ) ;
if ( argc == 2 )
{
strcpy( szDB, argv[ 1 ] ) ;
strcpy( szSQL, DEFALT_SQL_STMT ) ;
if (!strcmp(szDB,"--debug"))
{
strcpy( szDB, "mysql" ) ;
printf("Some mysql struct information (size and offset):\n");
printf("net:\t%3d %3d\n",(int) sizeof(myData->net),
(int) offsetof(MYSQL,net));
printf("host:\t%3d %3d\n",(int) sizeof(myData->host),
(int) offsetof(MYSQL,host));
printf("port:\t%3d %3d\n", (int) sizeof(myData->port),
(int) offsetof(MYSQL,port));
printf("protocol_version:\t%3d %3d\n",
(int) sizeof(myData->protocol_version),
(int) offsetof(MYSQL,protocol_version));
printf("thread_id:\t%3d %3d\n",(int) sizeof(myData->thread_id),
(int) offsetof(MYSQL,thread_id));
printf("affected_rows:\t%3d %3d\n",(int) sizeof(myData->affected_rows),
(int) offsetof(MYSQL,affected_rows));
printf("packet_length:\t%3d %3d\n",(int) sizeof(myData->packet_length),
(int) offsetof(MYSQL,packet_length));
printf("status:\t%3d %3d\n",(int) sizeof(myData->status),
(int) offsetof(MYSQL,status));
printf("fields:\t%3d %3d\n",(int) sizeof(myData->fields),
(int) offsetof(MYSQL,fields));
printf("field_alloc:\t%3d %3d\n",(int) sizeof(myData->field_alloc),
(int) offsetof(MYSQL,field_alloc));
printf("free_me:\t%3d %3d\n",(int) sizeof(myData->free_me),
(int) offsetof(MYSQL,free_me));
printf("options:\t%3d %3d\n",(int) sizeof(myData->options),
(int) offsetof(MYSQL,options));
puts("");
}
}
else if ( argc > 2 ) {
strcpy( szDB, argv[ 1 ] ) ;
strcpy( szSQL, argv[ 2 ] ) ;
}
else {
strcpy( szDB, "mysql" ) ;
strcpy( szSQL, DEFALT_SQL_STMT ) ;
}
//....
if ( (myData = mysql_init((MYSQL*) 0)) &&
mysql_real_connect( myData, NULL, NULL, NULL, NULL, MYSQL_PORT,
NULL, 0 ) )
{
myData->reconnect= 1;
if ( mysql_select_db( myData, szDB ) < 0 ) {
printf( "Can't select the %s database !\n", szDB ) ;
mysql_close( myData ) ;
return 2 ;
}
}
else {
printf( "Can't connect to the mysql server on port %d !\n",
MYSQL_PORT ) ;
mysql_close( myData ) ;
return 1 ;
}
//....
if ( ! mysql_query( myData, szSQL ) ) {
res = mysql_store_result( myData ) ;
i = (int) mysql_num_rows( res ) ; l = 1 ;
printf( "Query: %s\nNumber of records found: %ld\n", szSQL, i ) ;
//....we can get the field-specific characteristics here....
for ( x = 0 ; fd = mysql_fetch_field( res ) ; x++ )
strcpy( aszFlds[ x ], fd->name ) ;
//....
while ( row = mysql_fetch_row( res ) ) {
j = mysql_num_fields( res ) ;
printf( "Record #%ld:-\n", l++ ) ;
for ( k = 0 ; k < j ; k++ )
printf( " Fld #%d (%s): %s\n", k + 1, aszFlds[ k ],
(((row[k]==NULL)||(!strlen(row[k])))?"NULL":row[k])) ;
puts( "==============================\n" ) ;
}
mysql_free_result( res ) ;
}
else printf( "Couldn't execute %s on the server !\n", szSQL ) ;
//....
puts( "==== Diagnostic info ====" ) ;
pszT = mysql_get_client_info() ;
printf( "Client info: %s\n", pszT ) ;
//....
pszT = mysql_get_host_info( myData ) ;
printf( "Host info: %s\n", pszT ) ;
//....
pszT = mysql_get_server_info( myData ) ;
printf( "Server info: %s\n", pszT ) ;
//....
res = mysql_list_processes( myData ) ; l = 1 ;
if (res)
{
for ( x = 0 ; fd = mysql_fetch_field( res ) ; x++ )
strcpy( aszFlds[ x ], fd->name ) ;
while ( row = mysql_fetch_row( res ) ) {
j = mysql_num_fields( res ) ;
printf( "Process #%ld:-\n", l++ ) ;
for ( k = 0 ; k < j ; k++ )
printf( " Fld #%d (%s): %s\n", k + 1, aszFlds[ k ],
(((row[k]==NULL)||(!strlen(row[k])))?"NULL":row[k])) ;
puts( "==============================\n" ) ;
}
}
else
{
printf("Got error %s when retreiving processlist\n",mysql_error(myData));
}
//....
res = mysql_list_tables( myData, "%" ) ; l = 1 ;
for ( x = 0 ; fd = mysql_fetch_field( res ) ; x++ )
strcpy( aszFlds[ x ], fd->name ) ;
while ( row = mysql_fetch_row( res ) ) {
j = mysql_num_fields( res ) ;
printf( "Table #%ld:-\n", l++ ) ;
for ( k = 0 ; k < j ; k++ )
printf( " Fld #%d (%s): %s\n", k + 1, aszFlds[ k ],
(((row[k]==NULL)||(!strlen(row[k])))?"NULL":row[k])) ;
puts( "==============================\n" ) ;
}
//....
pszT = mysql_stat( myData ) ;
puts( pszT ) ;
//....
mysql_close( myData ) ;
return 0 ;
}
...@@ -22,6 +22,7 @@ MYSQLSHAREdir = $(pkgdatadir) ...@@ -22,6 +22,7 @@ MYSQLSHAREdir = $(pkgdatadir)
MYSQLBASEdir= $(prefix) MYSQLBASEdir= $(prefix)
MYSQLLIBdir= $(libdir) MYSQLLIBdir= $(libdir)
EXTRA_DIST = libmysqld.def
DEFS = -DEMBEDDED_LIBRARY -DMYSQL_SERVER \ DEFS = -DEMBEDDED_LIBRARY -DMYSQL_SERVER \
-DDEFAULT_MYSQL_HOME="\"$(MYSQLBASEdir)\"" \ -DDEFAULT_MYSQL_HOME="\"$(MYSQLBASEdir)\"" \
-DDATADIR="\"$(MYSQLDATAdir)\"" \ -DDATADIR="\"$(MYSQLDATAdir)\"" \
......
...@@ -1063,6 +1063,8 @@ sub executable_setup () { ...@@ -1063,6 +1063,8 @@ sub executable_setup () {
$exe_mysqltest= mtr_exe_exists("$path_client_bindir/mysqltest"); $exe_mysqltest= mtr_exe_exists("$path_client_bindir/mysqltest");
$exe_mysql_client_test= $exe_mysql_client_test=
mtr_exe_exists("$glob_basedir/tests/mysql_client_test", mtr_exe_exists("$glob_basedir/tests/mysql_client_test",
"$glob_basedir/tests/release/mysql_client_test",
"$glob_basedir/tests/debug/mysql_client_test",
"$path_client_bindir/mysql_client_test", "$path_client_bindir/mysql_client_test",
"/usr/bin/false"); "/usr/bin/false");
} }
...@@ -1074,7 +1076,8 @@ sub executable_setup () { ...@@ -1074,7 +1076,8 @@ sub executable_setup () {
$exe_mysqladmin= mtr_exe_exists("$path_client_bindir/mysqladmin"); $exe_mysqladmin= mtr_exe_exists("$path_client_bindir/mysqladmin");
$exe_mysql= mtr_exe_exists("$path_client_bindir/mysql"); $exe_mysql= mtr_exe_exists("$path_client_bindir/mysql");
$exe_mysql_fix_system_tables= $exe_mysql_fix_system_tables=
mtr_script_exists("$glob_basedir/scripts/mysql_fix_privilege_tables"); mtr_script_exists("$glob_basedir/scripts/mysql_fix_privilege_tables",
"/usr/bin/false");
$path_ndb_tools_dir= mtr_path_exists("$glob_basedir/storage/ndb/tools"); $path_ndb_tools_dir= mtr_path_exists("$glob_basedir/storage/ndb/tools");
$exe_ndb_mgm= "$glob_basedir/storage/ndb/src/mgmclient/ndb_mgm"; $exe_ndb_mgm= "$glob_basedir/storage/ndb/src/mgmclient/ndb_mgm";
} }
...@@ -1090,7 +1093,8 @@ sub executable_setup () { ...@@ -1090,7 +1093,8 @@ sub executable_setup () {
$exe_mysql= mtr_exe_exists("$path_client_bindir/mysql"); $exe_mysql= mtr_exe_exists("$path_client_bindir/mysql");
$exe_mysql_fix_system_tables= $exe_mysql_fix_system_tables=
mtr_script_exists("$path_client_bindir/mysql_fix_privilege_tables", mtr_script_exists("$path_client_bindir/mysql_fix_privilege_tables",
"$glob_basedir/scripts/mysql_fix_privilege_tables"); "$glob_basedir/scripts/mysql_fix_privilege_tables",
"/usr/bin/false");
$exe_my_print_defaults= $exe_my_print_defaults=
mtr_exe_exists("$path_client_bindir/my_print_defaults"); mtr_exe_exists("$path_client_bindir/my_print_defaults");
...@@ -1126,6 +1130,8 @@ sub executable_setup () { ...@@ -1126,6 +1130,8 @@ sub executable_setup () {
$exe_mysqltest= mtr_exe_exists("$path_client_bindir/mysqltest"); $exe_mysqltest= mtr_exe_exists("$path_client_bindir/mysqltest");
$exe_mysql_client_test= $exe_mysql_client_test=
mtr_exe_exists("$path_client_bindir/mysql_client_test", mtr_exe_exists("$path_client_bindir/mysql_client_test",
"$glob_basedir/tests/release/mysql_client_test",
"$glob_basedir/tests/debug/mysql_client_test",
"/usr/bin/false"); # FIXME temporary "/usr/bin/false"); # FIXME temporary
} }
......
...@@ -58,7 +58,9 @@ libmysys_a_SOURCES = my_init.c my_getwd.c mf_getdate.c my_mmap.c \ ...@@ -58,7 +58,9 @@ libmysys_a_SOURCES = my_init.c my_getwd.c mf_getdate.c my_mmap.c \
my_handler.c my_netware.c my_largepage.c \ my_handler.c my_netware.c my_largepage.c \
my_windac.c my_access.c base64.c my_windac.c my_access.c base64.c
EXTRA_DIST = thr_alarm.c thr_lock.c my_pthread.c my_thr_init.c \ EXTRA_DIST = thr_alarm.c thr_lock.c my_pthread.c my_thr_init.c \
thr_mutex.c thr_rwlock.c thr_mutex.c thr_rwlock.c \
cmakelists.txt mf_soundex.c \
my_conio.c my_wincond.c my_winsem.c my_winthread.c
libmysys_a_LIBADD = @THREAD_LOBJECTS@ libmysys_a_LIBADD = @THREAD_LOBJECTS@
# test_dir_DEPENDENCIES= $(LIBRARIES) # test_dir_DEPENDENCIES= $(LIBRARIES)
# testhash_DEPENDENCIES= $(LIBRARIES) # testhash_DEPENDENCIES= $(LIBRARIES)
......
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX -DUSE_SYMDIR") SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX -DUSE_SYMDIR") SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX")
# Need to set USE_TLS, since mysys is linked into libmysql.dll and
# libmysqld.dll, and __declspec(thread) approach to thread local storage does
# not work properly in DLLs.
# Currently, USE_TLS crashes in Debug builds, so until that is fixed Debug
# .dlls cannot be loaded at runtime.
SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -DUSE_TLS")
SET(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -DUSE_TLS")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/zlib ${CMAKE_SOURCE_DIR}/include) INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/zlib ${CMAKE_SOURCE_DIR}/include)
ADD_LIBRARY(mysys array.c charset-def.c charset.c checksum.c default.c default_modify.c ADD_LIBRARY(mysys array.c charset-def.c charset.c checksum.c default.c default_modify.c
......
...@@ -134,7 +134,10 @@ void my_end(int infoflag) ...@@ -134,7 +134,10 @@ void my_end(int infoflag)
*/ */
FILE *info_file= DBUG_FILE; FILE *info_file= DBUG_FILE;
my_bool print_info= (info_file != stderr); my_bool print_info= (info_file != stderr);
DBUG_ENTER("my_end"); /* We do not use DBUG_ENTER here, as after cleanup DBUG is no longer
operational, so we cannot use DBUG_RETURN.
*/
DBUG_PRINT("info",("Shutting down"));
if (!info_file) if (!info_file)
{ {
info_file= stderr; info_file= stderr;
...@@ -214,7 +217,6 @@ Voluntary context switches %ld, Involuntary context switches %ld\n", ...@@ -214,7 +217,6 @@ Voluntary context switches %ld, Involuntary context switches %ld\n",
WSACleanup(); WSACleanup();
#endif /* __WIN__ */ #endif /* __WIN__ */
my_init_done=0; my_init_done=0;
DBUG_VOID_RETURN;
} /* my_end */ } /* my_end */
......
...@@ -25,7 +25,7 @@ re_SOURCES = split.c debug.c main.c ...@@ -25,7 +25,7 @@ re_SOURCES = split.c debug.c main.c
re_LDFLAGS= @NOINST_LDFLAGS@ re_LDFLAGS= @NOINST_LDFLAGS@
EXTRA_DIST = tests CHANGES COPYRIGHT WHATSNEW regexp.c \ EXTRA_DIST = tests CHANGES COPYRIGHT WHATSNEW regexp.c \
debug.ih engine.ih main.ih regcomp.ih regerror.ih \ debug.ih engine.ih main.ih regcomp.ih regerror.ih \
regex.3 regex.7 regex.3 regex.7 cmakelists.txt
test: re tests test: re tests
./re < tests ./re < tests
......
...@@ -87,6 +87,8 @@ mysqlmanager_LDADD= @CLIENT_EXTRA_LDFLAGS@ \ ...@@ -87,6 +87,8 @@ mysqlmanager_LDADD= @CLIENT_EXTRA_LDFLAGS@ \
$(top_builddir)/dbug/libdbug.a \ $(top_builddir)/dbug/libdbug.a \
@openssl_libs@ @yassl_libs@ @ZLIB_LIBS@ @openssl_libs@ @yassl_libs@ @ZLIB_LIBS@
EXTRA_DIST = WindowsService.cpp WindowsService.h IMService.cpp \
IMService.h cmakelists.txt
tags: tags:
ctags -R *.h *.cc ctags -R *.h *.cc
......
...@@ -124,7 +124,8 @@ DEFS = -DMYSQL_SERVER \ ...@@ -124,7 +124,8 @@ DEFS = -DMYSQL_SERVER \
@DEFS@ @DEFS@
BUILT_SOURCES = sql_yacc.cc sql_yacc.h lex_hash.h BUILT_SOURCES = sql_yacc.cc sql_yacc.h lex_hash.h
EXTRA_DIST = udf_example.cc $(BUILT_SOURCES) EXTRA_DIST = udf_example.cc $(BUILT_SOURCES) \
nt_servc.cc nt_servc.h message.mc cmakelists.txt
CLEANFILES = lex_hash.h sql_yacc.cc sql_yacc.h CLEANFILES = lex_hash.h sql_yacc.cc sql_yacc.h
AM_YFLAGS = -d AM_YFLAGS = -d
......
...@@ -5,7 +5,9 @@ INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ...@@ -5,7 +5,9 @@ INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include
${CMAKE_SOURCE_DIR}/extra/yassl/include ${CMAKE_SOURCE_DIR}/extra/yassl/include
${CMAKE_SOURCE_DIR}/sql ${CMAKE_SOURCE_DIR}/sql
${CMAKE_SOURCE_DIR}/regex ${CMAKE_SOURCE_DIR}/regex
${CMAKE_SOURCE_DIR}/zlib) ${CMAKE_SOURCE_DIR}/zlib
${CMAKE_SOURCE_DIR}/storage/bdb/build_win32
${CMAKE_SOURCE_DIR}/storage/bdb/dbinc)
SET_SOURCE_FILES_PROPERTIES(${CMAKE_SOURCE_DIR}/sql/message.rc SET_SOURCE_FILES_PROPERTIES(${CMAKE_SOURCE_DIR}/sql/message.rc
${CMAKE_SOURCE_DIR}/sql/message.h ${CMAKE_SOURCE_DIR}/sql/message.h
...@@ -61,9 +63,8 @@ CONFIGURE_FILE(${CMAKE_SOURCE_DIR}/sql/handlerton.cc.in ${CMAKE_SOURCE_DIR}/sql/ ...@@ -61,9 +63,8 @@ CONFIGURE_FILE(${CMAKE_SOURCE_DIR}/sql/handlerton.cc.in ${CMAKE_SOURCE_DIR}/sql/
ADD_DEFINITIONS(-DHAVE_ROW_BASED_REPLICATION -DMYSQL_SERVER -D_CONSOLE -DHAVE_DLOPEN) ADD_DEFINITIONS(-DHAVE_ROW_BASED_REPLICATION -DMYSQL_SERVER -D_CONSOLE -DHAVE_DLOPEN)
ADD_EXECUTABLE(mysqld ../sql-common/client.c derror.cc des_key_file.cc discover.cc ../libmysql/errmsg.c field.cc ADD_EXECUTABLE(mysqld ../sql-common/client.c derror.cc des_key_file.cc discover.cc ../libmysql/errmsg.c field.cc
field_conv.cc filesort.cc gstream.cc ha_blackhole.cc field_conv.cc filesort.cc gstream.cc ha_heap.cc ha_myisam.cc ha_myisammrg.cc
ha_federated.cc ha_heap.cc ha_innodb.cc ha_myisam.cc ha_myisammrg.cc ${handlertons} handler.cc hash_filo.cc hash_filo.h hostname.cc
ha_partition.cc handler.cc hash_filo.cc hash_filo.h hostname.cc
init.cc item.cc item_buff.cc item_cmpfunc.cc item_create.cc item_func.cc item_geofunc.cc init.cc item.cc item_buff.cc item_cmpfunc.cc item_create.cc item_func.cc item_geofunc.cc
item_row.cc item_strfunc.cc item_subselect.cc item_sum.cc item_timefunc.cc item_uniq.cc item_row.cc item_strfunc.cc item_subselect.cc item_sum.cc item_timefunc.cc item_uniq.cc
key.cc log.cc lock.cc log_event.cc message.rc message.h mf_iocache.cc key.cc log.cc lock.cc log_event.cc message.rc message.h mf_iocache.cc
...@@ -88,7 +89,7 @@ ADD_EXECUTABLE(mysqld ../sql-common/client.c derror.cc des_key_file.cc discover. ...@@ -88,7 +89,7 @@ ADD_EXECUTABLE(mysqld ../sql-common/client.c derror.cc des_key_file.cc discover.
${PROJECT_SOURCE_DIR}/include/mysql_version.h ${PROJECT_SOURCE_DIR}/include/mysql_version.h
${PROJECT_SOURCE_DIR}/sql/handlerton.cc ${PROJECT_SOURCE_DIR}/sql/handlerton.cc
${PROJECT_SOURCE_DIR}/sql/lex_hash.h) ${PROJECT_SOURCE_DIR}/sql/lex_hash.h)
TARGET_LINK_LIBRARIES(mysqld heap myisam myisammrg innobase mysys yassl zlib dbug yassl taocrypt strings vio regex wsock32) TARGET_LINK_LIBRARIES(mysqld heap myisam myisammrg ${se_deps} mysys yassl zlib dbug yassl taocrypt strings vio regex wsock32)
ADD_DEPENDENCIES(mysqld GenError) ADD_DEPENDENCIES(mysqld GenError)
# Sql Parser custom command # Sql Parser custom command
...@@ -106,10 +107,10 @@ ADD_CUSTOM_COMMAND( ...@@ -106,10 +107,10 @@ ADD_CUSTOM_COMMAND(
# Windows message file # Windows message file
ADD_CUSTOM_COMMAND( ADD_CUSTOM_COMMAND(
SOURCE ../VC++Files/sql/messae.mc SOURCE message.mc
OUTPUT message.rc message.h OUTPUT message.rc message.h
COMMAND mc ARGS ../VC++Files/sql/message.mc COMMAND mc ARGS message.mc
DEPENDS ../VC++Files/sql/message.mc) DEPENDS message.mc)
# Gen_lex_hash # Gen_lex_hash
ADD_EXECUTABLE(gen_lex_hash gen_lex_hash.cc) ADD_EXECUTABLE(gen_lex_hash gen_lex_hash.cc)
......
MessageId = 100
Severity = Error
Facility = Application
SymbolicName = MSG_DEFAULT
Language = English
%1For more information, see Help and Support Center at http://www.mysql.com.
...@@ -8173,6 +8173,7 @@ my_bool innobase_log_archive, ...@@ -8173,6 +8173,7 @@ my_bool innobase_log_archive,
innobase_file_per_table, innobase_file_per_table,
innobase_locks_unsafe_for_binlog; innobase_locks_unsafe_for_binlog;
extern "C" {
ulong srv_max_buf_pool_modified_pct; ulong srv_max_buf_pool_modified_pct;
ulong srv_max_purge_lag; ulong srv_max_purge_lag;
ulong srv_auto_extend_increment; ulong srv_auto_extend_increment;
...@@ -8181,6 +8182,7 @@ ulong srv_n_free_tickets_to_enter; ...@@ -8181,6 +8182,7 @@ ulong srv_n_free_tickets_to_enter;
ulong srv_thread_sleep_delay; ulong srv_thread_sleep_delay;
ulong srv_thread_concurrency; ulong srv_thread_concurrency;
ulong srv_commit_concurrency; ulong srv_commit_concurrency;
}
#endif #endif
#ifndef WITH_NDBCLUSTER_STORAGE_ENGINE #ifndef WITH_NDBCLUSTER_STORAGE_ENGINE
......
...@@ -1605,13 +1605,14 @@ class select_create: public select_insert { ...@@ -1605,13 +1605,14 @@ class select_create: public select_insert {
lock(0) lock(0)
{} {}
int prepare(List<Item> &list, SELECT_LEX_UNIT *u); int prepare(List<Item> &list, SELECT_LEX_UNIT *u);
friend class select_create_prepare_hooks;
void binlog_show_create_table(TABLE **tables, uint count); void binlog_show_create_table(TABLE **tables, uint count);
void store_values(List<Item> &values); void store_values(List<Item> &values);
void send_error(uint errcode,const char *err); void send_error(uint errcode,const char *err);
bool send_eof(); bool send_eof();
void abort(); void abort();
// Needed for access from local class MY_HOOKS in prepare(), since thd is proteted.
THD *get_thd(void) { return thd; }
}; };
#include <myisam.h> #include <myisam.h>
......
...@@ -2507,28 +2507,25 @@ bool select_insert::send_eof() ...@@ -2507,28 +2507,25 @@ bool select_insert::send_eof()
CREATE TABLE (SELECT) ... CREATE TABLE (SELECT) ...
***************************************************************************/ ***************************************************************************/
/* HPUX compiler bug prevents this from being a local class, since then it
does not have access to protected member select_create::thd.
*/
class select_create_prepare_hooks : public TABLEOP_HOOKS {
public:
select_create_prepare_hooks(select_create *x) : ptr(x) { }
virtual void do_prelock(TABLE **tables, uint count)
{
if (ptr->thd->current_stmt_binlog_row_based)
ptr->binlog_show_create_table(tables, count);
}
private:
select_create *ptr;
};
int int
select_create::prepare(List<Item> &values, SELECT_LEX_UNIT *u) select_create::prepare(List<Item> &values, SELECT_LEX_UNIT *u)
{ {
DBUG_ENTER("select_create::prepare"); DBUG_ENTER("select_create::prepare");
select_create_prepare_hooks hooks(this); class MY_HOOKS : public TABLEOP_HOOKS {
public:
MY_HOOKS(select_create *x) : ptr(x) { }
virtual void do_prelock(TABLE **tables, uint count)
{
if (ptr->get_thd()->current_stmt_binlog_row_based)
ptr->binlog_show_create_table(tables, count);
}
private:
select_create *ptr;
};
MY_HOOKS hooks(this);
unit= u; unit= u;
table= create_table_from_items(thd, create_info, create_table, table= create_table_from_items(thd, create_info, create_table,
......
...@@ -27,6 +27,7 @@ noinst_PROGRAMS = archive_test ...@@ -27,6 +27,7 @@ noinst_PROGRAMS = archive_test
archive_test_LDFLAGS = @NOINST_LDFLAGS@ archive_test_LDFLAGS = @NOINST_LDFLAGS@
noinst_HEADERS = azlib.h noinst_HEADERS = azlib.h
libarchive_a_SOURCES = azio.c libarchive_a_SOURCES = azio.c
EXTRA_DIST = cmakelists.txt
# Don't update the files from bitkeeper # Don't update the files from bitkeeper
%::SCCS/s.% %::SCCS/s.%
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/zlib)
ADD_LIBRARY(archive azio.c)
TARGET_LINK_LIBRARIES(archive zlib mysys dbug strings)
...@@ -23,13 +23,13 @@ top_srcdir = @top_srcdir@ ...@@ -23,13 +23,13 @@ top_srcdir = @top_srcdir@
# distdir and top_distdir are set by the calling Makefile # distdir and top_distdir are set by the calling Makefile
bdb_build = build_unix bdb_build = build_unix
files = LICENSE Makefile Makefile.in README files = LICENSE Makefile Makefile.in README cmakelists.txt
subdirs = btree build_win32 clib common cxx db dbinc \ subdirs = btree build_win32 clib common cxx db dbinc \
dbinc_auto db185 db_archive db_checkpoint db_deadlock db_dump \ dbinc_auto db185 db_archive db_checkpoint db_deadlock db_dump \
db_dump185 db_hotbackup db_load db_printlog db_recover db_stat db_upgrade \ db_dump185 db_hotbackup db_load db_printlog db_recover db_stat db_upgrade \
db_verify dbm dbreg dist env fileops hash \ db_verify dbm dbreg dist env fileops hash \
hsearch hmac include lock log mp mutex os \ hsearch hmac include lock log mp mutex os \
os_win32 qam rep txn xa sequence os_win32 qam rep txn xa sequence crypto
@SET_MAKE@ @SET_MAKE@
......
SET(CMAKE_CXX_FLAGS_DEBUG "-DSAFEMALLOC -DSAFE_MUTEX") SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_DEBUG "-DSAFEMALLOC -DSAFE_MUTEX") SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX")
#INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/extra/yassl/include) INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/storage/bdb/build_win32
ADD_LIBRARY(bdb _check.c _rectest.c hp_block.c hp_clear.c hp_close.c hp_create.c ${CMAKE_SOURCE_DIR}/storage/bdb/dbinc
hp_delete.c hp_extra.c hp_hash.c hp_info.c hp_open.c hp_panic.c ${CMAKE_SOURCE_DIR}/storage/bdb)
hp_rename.c hp_rfirst.c hp_rkey.c hp_rlast.c hp_rnext.c hp_rprev.c
hp_rrnd.c hp_rsame.c hp_scan.c hp_static.c hp_update.c hp_write.c) # BDB needs a number of source files that are auto-generated by the unix
# configure. So to build BDB, it is necessary to copy these over to the Windows
# bitkeeper tree, or to use a source .tar.gz package which already has these
# files.
ADD_LIBRARY(bdb crypto/aes_method.c btree/bt_compact.c btree/bt_compare.c
btree/bt_conv.c btree/bt_curadj.c btree/bt_cursor.c
btree/bt_delete.c btree/bt_method.c btree/bt_open.c btree/bt_put.c
btree/bt_rec.c btree/bt_reclaim.c btree/bt_recno.c
btree/bt_rsearch.c btree/bt_search.c btree/bt_split.c
btree/bt_stat.c btree/bt_upgrade.c btree/bt_verify.c
btree/btree_auto.c db/crdel_auto.c db/crdel_rec.c crypto/crypto.c
db/db.c db/db_am.c db/db_auto.c common/db_byteorder.c db/db_cam.c
common/db_clock.c db/db_conv.c db/db_dispatch.c db/db_dup.c
common/db_err.c common/db_getlong.c common/db_idspace.c
db/db_iface.c db/db_join.c common/db_log2.c db/db_meta.c
db/db_method.c db/db_open.c db/db_overflow.c db/db_ovfl_vrfy.c
db/db_pr.c db/db_rec.c db/db_reclaim.c db/db_remove.c
db/db_rename.c db/db_ret.c env/db_salloc.c db/db_setid.c
db/db_setlsn.c env/db_shash.c db/db_stati.c db/db_truncate.c
db/db_upg.c db/db_upg_opd.c db/db_vrfy.c db/db_vrfyutil.c
dbm/dbm.c dbreg/dbreg.c dbreg/dbreg_auto.c dbreg/dbreg_rec.c
dbreg/dbreg_stat.c dbreg/dbreg_util.c env/env_failchk.c
env/env_file.c env/env_method.c env/env_open.c env/env_recover.c
env/env_region.c env/env_register.c env/env_stat.c
fileops/fileops_auto.c fileops/fop_basic.c fileops/fop_rec.c
fileops/fop_util.c hash/hash.c hash/hash_auto.c hash/hash_conv.c
hash/hash_dup.c hash/hash_func.c hash/hash_meta.c
hash/hash_method.c hash/hash_open.c hash/hash_page.c
hash/hash_rec.c hash/hash_reclaim.c hash/hash_stat.c
hash/hash_upgrade.c hash/hash_verify.c hmac/hmac.c
hsearch/hsearch.c lock/lock.c lock/lock_deadlock.c
lock/lock_failchk.c lock/lock_id.c lock/lock_list.c
lock/lock_method.c lock/lock_region.c lock/lock_stat.c
lock/lock_timer.c lock/lock_util.c log/log.c log/log_archive.c
log/log_compare.c log/log_debug.c log/log_get.c log/log_method.c
log/log_put.c log/log_stat.c mp/mp_alloc.c mp/mp_bh.c mp/mp_fget.c
mp/mp_fmethod.c mp/mp_fopen.c mp/mp_fput.c mp/mp_fset.c
mp/mp_method.c mp/mp_region.c mp/mp_register.c mp/mp_stat.c
mp/mp_sync.c mp/mp_trickle.c crypto/mersenne/mt19937db.c
mutex/mut_alloc.c mutex/mut_method.c mutex/mut_region.c
mutex/mut_stat.c mutex/mut_tas.c mutex/mut_win32.c
os_win32/os_abs.c os/os_alloc.c os_win32/os_clock.c
os_win32/os_config.c os_win32/os_dir.c os_win32/os_errno.c
os_win32/os_fid.c os_win32/os_flock.c os_win32/os_fsync.c
os_win32/os_handle.c os/os_id.c os_win32/os_map.c os/os_method.c
os/os_oflags.c os_win32/os_open.c os/os_region.c
os_win32/os_rename.c os/os_root.c os/os_rpath.c os_win32/os_rw.c
os_win32/os_seek.c os_win32/os_sleep.c os_win32/os_spin.c
os_win32/os_stat.c os/os_tmpdir.c os_win32/os_truncate.c
os/os_unlink.c qam/qam.c qam/qam_auto.c qam/qam_conv.c
qam/qam_files.c qam/qam_method.c qam/qam_open.c qam/qam_rec.c
qam/qam_stat.c qam/qam_upgrade.c qam/qam_verify.c rep/rep_auto.c
rep/rep_backup.c rep/rep_elect.c rep/rep_log.c rep/rep_method.c
rep/rep_record.c rep/rep_region.c rep/rep_stat.c rep/rep_stub.c
rep/rep_util.c rep/rep_verify.c crypto/rijndael/rijndael-alg-fst.c
crypto/rijndael/rijndael-api-fst.c hmac/sha1.c clib/strcasecmp.c
txn/txn.c txn/txn_auto.c txn/txn_chkpt.c txn/txn_failchk.c
txn/txn_method.c txn/txn_rec.c txn/txn_recover.c txn/txn_region.c
txn/txn_stat.c txn/txn_util.c common/util_log.c common/util_sig.c
xa/xa.c xa/xa_db.c xa/xa_map.c)
...@@ -31,7 +31,7 @@ pkglib_LTLIBRARIES = ha_example.la ...@@ -31,7 +31,7 @@ pkglib_LTLIBRARIES = ha_example.la
ha_example_la_LDFLAGS = -module ha_example_la_LDFLAGS = -module
noinst_HEADERS = ha_example.h noinst_HEADERS = ha_example.h
ha_example_la_SOURCES = ha_example.cc ha_example_la_SOURCES = ha_example.cc
EXTRA_DIST = cmakelists.txt
LDADD = LDADD =
DEFS = -DMYSQL_SERVER @DEFS@ DEFS = -DMYSQL_SERVER @DEFS@
......
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/sql
${CMAKE_SOURCE_DIR}/extra/yassl/include)
ADD_LIBRARY(example ha_example.cc)
...@@ -30,6 +30,7 @@ libheap_a_SOURCES = hp_open.c hp_extra.c hp_close.c hp_panic.c hp_info.c \ ...@@ -30,6 +30,7 @@ libheap_a_SOURCES = hp_open.c hp_extra.c hp_close.c hp_panic.c hp_info.c \
hp_rnext.c hp_rlast.c hp_rprev.c hp_clear.c \ hp_rnext.c hp_rlast.c hp_rprev.c hp_clear.c \
hp_rkey.c hp_block.c \ hp_rkey.c hp_block.c \
hp_hash.c _check.c _rectest.c hp_static.c hp_hash.c _check.c _rectest.c hp_static.c
EXTRA_DIST = cmakelists.txt
# Don't update the files from bitkeeper # Don't update the files from bitkeeper
%::SCCS/s.% %::SCCS/s.%
...@@ -76,7 +76,8 @@ EXTRA_DIST = include/btr0btr.h include/btr0btr.ic include/btr0cur.h include/btr ...@@ -76,7 +76,8 @@ EXTRA_DIST = include/btr0btr.h include/btr0btr.ic include/btr0cur.h include/btr
include/univ.i include/usr0sess.h include/usr0sess.ic include/usr0types.h \ include/univ.i include/usr0sess.h include/usr0sess.ic include/usr0types.h \
include/ut0byte.h include/ut0byte.ic include/ut0dbg.h include/ut0lst.h \ include/ut0byte.h include/ut0byte.ic include/ut0dbg.h include/ut0lst.h \
include/ut0mem.h include/ut0mem.ic include/ut0rnd.h include/ut0rnd.ic \ include/ut0mem.h include/ut0mem.ic include/ut0rnd.h include/ut0rnd.ic \
include/ut0sort.h include/ut0ut.h include/ut0ut.ic include/ut0sort.h include/ut0ut.h include/ut0ut.ic \
cmakelists.txt
# Don't update the files from bitkeeper # Don't update the files from bitkeeper
%::SCCS/s.% %::SCCS/s.%
...@@ -40,7 +40,9 @@ if we are compiling on Windows. */ ...@@ -40,7 +40,9 @@ if we are compiling on Windows. */
#undef VERSION #undef VERSION
/* Include the header file generated by GNU autoconf */ /* Include the header file generated by GNU autoconf */
#ifndef __WIN__
#include "../ib_config.h" #include "../ib_config.h"
#endif
#ifdef HAVE_SCHED_H #ifdef HAVE_SCHED_H
#include <sched.h> #include <sched.h>
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
# along with this program; if not, write to the Free Software # along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
EXTRA_DIST = mi_test_all.sh mi_test_all.res EXTRA_DIST = mi_test_all.sh mi_test_all.res ft_stem.c cmakelists.txt
pkgdata_DATA = mi_test_all mi_test_all.res pkgdata_DATA = mi_test_all mi_test_all.res
INCLUDES = -I$(top_builddir)/include -I$(top_srcdir)/include INCLUDES = -I$(top_builddir)/include -I$(top_srcdir)/include
......
...@@ -23,6 +23,7 @@ libmyisammrg_a_SOURCES = myrg_open.c myrg_extra.c myrg_info.c myrg_locking.c \ ...@@ -23,6 +23,7 @@ libmyisammrg_a_SOURCES = myrg_open.c myrg_extra.c myrg_info.c myrg_locking.c \
myrg_rkey.c myrg_rfirst.c myrg_rlast.c myrg_rnext.c \ myrg_rkey.c myrg_rfirst.c myrg_rlast.c myrg_rnext.c \
myrg_rprev.c myrg_queue.c myrg_write.c myrg_range.c \ myrg_rprev.c myrg_queue.c myrg_write.c myrg_range.c \
myrg_rnext_same.c myrg_rnext_same.c
EXTRA_DIST = cmakelists.txt
# Don't update the files from bitkeeper # Don't update the files from bitkeeper
%::SCCS/s.% %::SCCS/s.%
...@@ -54,7 +54,7 @@ EXTRA_DIST = ctype-big5.c ctype-cp932.c ctype-czech.c ctype-eucjpms.c ctype-euc ...@@ -54,7 +54,7 @@ EXTRA_DIST = ctype-big5.c ctype-cp932.c ctype-czech.c ctype-eucjpms.c ctype-euc
bmove_upp-sparc.s strappend-sparc.s strend-sparc.s \ bmove_upp-sparc.s strappend-sparc.s strend-sparc.s \
strinstr-sparc.s strmake-sparc.s strmov-sparc.s \ strinstr-sparc.s strmake-sparc.s strmov-sparc.s \
strnmov-sparc.s strstr-sparc.s strxmov-sparc.s \ strnmov-sparc.s strstr-sparc.s strxmov-sparc.s \
t_ctype.h my_strchr.c t_ctype.h my_strchr.c cmakelists.txt
libmystrings_a_LIBADD= libmystrings_a_LIBADD=
conf_to_src_SOURCES = conf_to_src.c xml.c ctype.c bcmp.c conf_to_src_SOURCES = conf_to_src.c xml.c ctype.c bcmp.c
......
...@@ -29,7 +29,8 @@ EXTRA_DIST = auto_increment.res auto_increment.tst \ ...@@ -29,7 +29,8 @@ EXTRA_DIST = auto_increment.res auto_increment.tst \
insert_and_repair.pl \ insert_and_repair.pl \
grant.pl grant.res test_delayed_insert.pl \ grant.pl grant.res test_delayed_insert.pl \
pmail.pl mail_to_db.pl table_types.pl \ pmail.pl mail_to_db.pl table_types.pl \
udf_test udf_test.res myisam-big-rows.tst udf_test udf_test.res myisam-big-rows.tst \
cmakelists.txt
bin_PROGRAMS = mysql_client_test bin_PROGRAMS = mysql_client_test
noinst_PROGRAMS = insert_test select_test thread_test noinst_PROGRAMS = insert_test select_test thread_test
......
...@@ -38,6 +38,7 @@ test_sslclient_LDADD= @CLIENT_EXTRA_LDFLAGS@ ../dbug/libdbug.a libvio.a \ ...@@ -38,6 +38,7 @@ test_sslclient_LDADD= @CLIENT_EXTRA_LDFLAGS@ ../dbug/libdbug.a libvio.a \
../mysys/libmysys.a ../strings/libmystrings.a \ ../mysys/libmysys.a ../strings/libmystrings.a \
$(openssl_libs) $(yassl_libs) $(openssl_libs) $(yassl_libs)
libvio_a_SOURCES= vio.c viosocket.c viossl.c viosslfactories.c libvio_a_SOURCES= vio.c viosocket.c viossl.c viosslfactories.c
EXTRA_DIST= cmakelists.txt
# Don't update the files from bitkeeper # Don't update the files from bitkeeper
%::SCCS/s.% %::SCCS/s.%
# Copyright (C) 2006 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
## Process this file with automake to create Makefile.in
EXTRA_DIST = build-vs71.bat build-vs8.bat config-handlerton.js configure.js config-version.js README
# Don't update the files from bitkeeper
%::SCCS/s.%
...@@ -34,12 +34,25 @@ Clone your bk tree to any location you like. ...@@ -34,12 +34,25 @@ Clone your bk tree to any location you like.
Step 4 Step 4
------ ------
From the root of your bk clone, execute the command: win\configure <options>. From the root of your bk clone, execute the command: win\configure <options>.
The options right now are WITH_INNODB and WITH_PARTITION. So the command line The options right now are
would look like:
WITH_INNOBASE_STORAGE_ENGINE Enable particular storage engines
win\configure WITH_INNODB WITH_PARTITION WITH_PARTITION_STORAGE_ENGINE
WITH_ARCHIVE_STORAGE_ENGINE
These are the only two flags supported right now. Others will come later. WITH_BERKELEY_STORAGE_ENGINE
WITH_BLACKHOLE_STORAGE_ENGINE
WITH_EXAMPLE_STORAGE_ENGINE
WITH_FEDERATED_STORAGE_ENGINE
WITH_INNOBASE_STORAGE_ENGINE
__NT__ Enable named pipe support
MYSQL_SERVER_SUFFIX=<suffix> Server suffix, default none
COMPILATION_COMMENT=<comment> Server comment, default "Source distribution"
MYSQL_TCP_PORT=<port> Server port, default 3306
CYBOZU
So the command line could look like:
win\configure WITH_INNOBASE_STORAGE_ENGINE WITH_PARTITION_STORAGE_ENGINE MYSQL_SERVER_SUFFIX=-pro
Step 5 Step 5
------ ------
...@@ -60,11 +73,5 @@ click the build solution menu option. ...@@ -60,11 +73,5 @@ click the build solution menu option.
Current issues Current issues
-------------- --------------
1. Not all configurations are currently available. i.e. Classic, Pro, Max. 1. After changing configuration (eg. adding or removing a storage engine), it
Currently, only debug and release are available. This will change in the near may be necessary to clean the build tree to remove any stale objects.
future.
2. The definitions set for features (partitioning, blackhole, etc) are not
changed based on the options given with configure. This will soon be fixed
as well.
...@@ -17,16 +17,41 @@ try ...@@ -17,16 +17,41 @@ try
while (! datafile.AtEndOfStream) while (! datafile.AtEndOfStream)
{ {
var line = datafile.ReadLine(); var line = datafile.ReadLine();
if (line == "WITH_INNODB") if (line == "WITH_INNOBASE_STORAGE_ENGINE")
{ {
extern_line += ",innobase_hton"; extern_line += ",innobase_hton";
address_line += ",&innobase_hton"; address_line += ",&innobase_hton";
} }
else if (line == "WITH_PARTITION") else if (line == "WITH_PARTITION_STORAGE_ENGINE")
{ {
extern_line += ",partition_hton"; extern_line += ",partition_hton";
address_line += ",&partition_hton"; address_line += ",&partition_hton";
} }
else if (line == "WITH_ARCHIVE_STORAGE_ENGINE")
{
extern_line += ",archive_hton";
address_line += ",&archive_hton";
}
else if (line == "WITH_BERKELEY_STORAGE_ENGINE")
{
extern_line += ",berkeley_hton";
address_line += ",&berkeley_hton";
}
else if (line == "WITH_BLACKHOLE_STORAGE_ENGINE")
{
extern_line += ",blackhole_hton";
address_line += ",&blackhole_hton";
}
else if (line == "WITH_EXAMPLE_STORAGE_ENGINE")
{
extern_line += ",example_hton";
address_line += ",&example_hton";
}
else if (line == "WITH_FEDERATED_STORAGE_ENGINE")
{
extern_line += ",federated_hton";
address_line += ",&federated_hton";
}
} }
datafile.Close(); datafile.Close();
......
...@@ -9,11 +9,91 @@ try ...@@ -9,11 +9,91 @@ try
// first we attempt to open the main configure.in file // first we attempt to open the main configure.in file
var fso = new ActiveXObject("Scripting.FileSystemObject"); var fso = new ActiveXObject("Scripting.FileSystemObject");
var args = WScript.Arguments
// Find any configured MYSQL_SERVER_SUFFIX.
// Find any extra preprocessor definitions.
var datafile = fso.OpenTextFile(args.Item(0), ForReading);
var server_suffix = '';
var server_comment = 'Source distribution';
var server_port = '';
var defs = '';
var htons = '';
var subdirs = '';
var depends = '';
while (! datafile.AtEndOfStream)
{
var line = datafile.ReadLine();
if (line.indexOf("MYSQL_SERVER_SUFFIX=") == 0)
{
server_suffix = line.substring(20, line.length);
}
else if (line.indexOf("COMPILATION_COMMENT=") == 0)
{
server_comment = line.substring(20, line.length);
}
else if (line.indexOf("MYSQL_TCP_PORT=") == 0)
{
server_port = line.substring(15, line.length);
}
else if (line == "WITH_ARCHIVE_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_archive.cc";
subdirs += " storage/archive";
depends += " archive";
}
else if (line == "WITH_BERKELEY_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_berkeley.cc";
subdirs += " storage/bdb";
depends += " bdb";
}
else if (line == "WITH_BLACKHOLE_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_blackhole.cc";
}
else if (line == "WITH_EXAMPLE_STORAGE_ENGINE")
{
defs += " -D" + line;
subdirs += " storage/example";
depends += " example";
}
else if (line == "WITH_FEDERATED_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_federated.cc";
}
else if (line == "WITH_INNOBASE_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_innodb.cc";
subdirs += " storage/innobase";
depends += " innobase";
}
else if (line == "WITH_PARTITION_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_partition.cc";
}
else if (line == "__NT__" ||
line == "CYBOZU" ||
line.indexOf("LICENSE=") == 0) {
defs += " -D" + line;
}
}
datafile.Close();
ConfigureMySqlVersion(); ConfigureMySqlVersion();
//ConfigureBDB(); //ConfigureBDB();
fso = null; fso = null;
WScript.Echo("done!"); WScript.Echo("DEFINITIONS@" + defs + "@");
WScript.Echo("HANDLERTONS@" + htons + "@");
WScript.Echo("DEPENDS@" + depends + "@");
WScript.Echo("SUBDIRS@" + subdirs + "@");
} }
catch (e) catch (e)
{ {
...@@ -63,10 +143,11 @@ function ConfigureMySqlVersion() ...@@ -63,10 +143,11 @@ function ConfigureMySqlVersion()
mysqlin = mysqlin.replace("@PROTOCOL_VERSION@", GetValue(configureIn, "PROTOCOL_VERSION")); mysqlin = mysqlin.replace("@PROTOCOL_VERSION@", GetValue(configureIn, "PROTOCOL_VERSION"));
mysqlin = mysqlin.replace("@DOT_FRM_VERSION@", GetValue(configureIn, "DOT_FRM_VERSION")); mysqlin = mysqlin.replace("@DOT_FRM_VERSION@", GetValue(configureIn, "DOT_FRM_VERSION"));
mysqlin = mysqlin.replace("@MYSQL_TCP_PORT@", GetValue(configureIn, "MYSQL_TCP_PORT_DEFAULT")); if (server_port == '') { server_port = GetValue(configureIn, "MYSQL_TCP_PORT_DEFAULT"); }
mysqlin = mysqlin.replace("@MYSQL_TCP_PORT@", server_port);
mysqlin = mysqlin.replace("@MYSQL_UNIX_ADDR@", GetValue(configureIn, "MYSQL_UNIX_ADDR_DEFAULT")); mysqlin = mysqlin.replace("@MYSQL_UNIX_ADDR@", GetValue(configureIn, "MYSQL_UNIX_ADDR_DEFAULT"));
mysqlin = mysqlin.replace("@MYSQL_SERVER_SUFFIX@", ''); mysqlin = mysqlin.replace("@MYSQL_SERVER_SUFFIX@", server_suffix);
mysqlin = mysqlin.replace("@COMPILATION_COMMENT@", 'Source distribution'); mysqlin = mysqlin.replace("@COMPILATION_COMMENT@", server_comment);
var version = GetVersion(configureIn); var version = GetVersion(configureIn);
......
...@@ -29,5 +29,4 @@ libz_la_SOURCES= adler32.c compress.c crc32.c deflate.c gzio.c \ ...@@ -29,5 +29,4 @@ libz_la_SOURCES= adler32.c compress.c crc32.c deflate.c gzio.c \
infback.c inffast.c inflate.c inftrees.c trees.c \ infback.c inffast.c inflate.c inftrees.c trees.c \
uncompr.c zutil.c uncompr.c zutil.c
EXTRA_DIST= README FAQ INDEX ChangeLog algorithm.txt zlib.3 EXTRA_DIST= README FAQ INDEX ChangeLog algorithm.txt zlib.3 cmakelists.txt
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment