diff options
author | unknown <monty@mysql.com> | 2004-05-25 22:54:00 +0300 |
---|---|---|
committer | unknown <monty@mysql.com> | 2004-05-25 22:54:00 +0300 |
commit | a9b481d3cd7fbf832b17523c521185db6366492c (patch) | |
tree | b258dbd41e0b45f70adf8c42ee94cce74cd0232f /include | |
parent | de5edbf8db66e1f896b76d408152cd0094dcf684 (diff) | |
parent | a3d0ce6bc611673e2d5342bc9cd735a9febfe6b4 (diff) | |
download | mariadb-git-a9b481d3cd7fbf832b17523c521185db6366492c.tar.gz |
merge with 4.0 to get Netware patches and fixes for libmysqld.dll
configure.in:
Auto merged
Build-tools/Do-compile:
Auto merged
client/mysql.cc:
Auto merged
client/mysqladmin.c:
Auto merged
client/mysqlcheck.c:
Auto merged
client/mysqldump.c:
Auto merged
client/mysqlimport.c:
Auto merged
client/mysqlshow.c:
Auto merged
client/mysqltest.c:
Auto merged
include/my_global.h:
Auto merged
include/thr_alarm.h:
Auto merged
innobase/include/trx0roll.h:
Auto merged
innobase/include/trx0trx.h:
Auto merged
innobase/que/que0que.c:
Auto merged
innobase/srv/srv0srv.c:
Auto merged
innobase/trx/trx0purge.c:
Auto merged
innobase/trx/trx0roll.c:
Auto merged
innobase/trx/trx0trx.c:
Auto merged
innobase/usr/usr0sess.c:
Auto merged
isam/isamchk.c:
Auto merged
myisam/myisam_ftdump.c:
Auto merged
myisam/myisamchk.c:
Auto merged
myisam/myisampack.c:
Auto merged
mysys/default.c:
Auto merged
mysys/my_getopt.c:
Auto merged
mysys/my_init.c:
Auto merged
mysys/my_pthread.c:
Auto merged
netware/Makefile.am:
Auto merged
netware/init_db.sql:
Auto merged
scripts/make_binary_distribution.sh:
Auto merged
tools/mysqlmanager.c:
Auto merged
VC++Files/dbug/dbug.dsp:
Auto merged
VC++Files/heap/heap.dsp:
Auto merged
VC++Files/isam/isam.dsp:
Auto merged
VC++Files/libmysql/libmysql.dsp:
Auto merged
VC++Files/myisam/myisam.dsp:
Auto merged
VC++Files/myisammrg/myisammrg.dsp:
Auto merged
VC++Files/mysys/mysys.dsp:
Auto merged
VC++Files/libmysqld/libmysqld.dsp:
merge
client/mysqlbinlog.cc:
merge
extra/perror.c:
merge
include/mysql_com.h:
merge
libmysqld/Makefile.am:
merge
netware/BUILD/mwenv:
merge
sql/mysqld.cc:
merge
Diffstat (limited to 'include')
-rw-r--r-- | include/config-netware.h | 36 | ||||
-rw-r--r-- | include/help_end.h | 6 | ||||
-rw-r--r-- | include/help_start.h | 7 | ||||
-rw-r--r-- | include/my_global.h | 6 | ||||
-rw-r--r-- | include/mysql_com.h | 10 | ||||
-rw-r--r-- | include/thr_alarm.h | 2 |
6 files changed, 61 insertions, 6 deletions
diff --git a/include/config-netware.h b/include/config-netware.h index dab365a7127..c4e63056353 100644 --- a/include/config-netware.h +++ b/include/config-netware.h @@ -14,7 +14,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -/* Defines for netware compatible with MySQL */ +/* Header for NetWare compatible with MySQL */ + +#ifndef _config_netware_h +#define _config_netware_h /* required headers */ #include <unistd.h> @@ -32,18 +35,28 @@ #include <pthread.h> #include <termios.h> +#ifdef __cplusplus +extern "C" { +#endif + /* required adjustments */ #undef HAVE_READDIR_R #undef HAVE_RWLOCK_INIT #undef HAVE_SCHED_H #undef HAVE_SYS_MMAN_H #undef HAVE_SYNCH_H -#undef HAVE_CRYPT #define HAVE_PTHREAD_ATTR_SETSTACKSIZE 1 #define HAVE_PTHREAD_SIGMASK 1 #define HAVE_PTHREAD_YIELD_ZERO_ARG 1 #define HAVE_BROKEN_REALPATH 1 +/* no libc crypt() function */ +#ifdef HAVE_OPENSSL + #define HAVE_CRYPT 1 +#else + #undef HAVE_CRYPT +#endif /* HAVE_OPENSSL */ + /* include the old function apis */ #define USE_OLD_FUNCTIONS 1 @@ -59,6 +72,9 @@ /* signal by closing the sockets */ #define SIGNAL_WITH_VIO_CLOSE 1 +/* On NetWare, stack grows towards lower address*/ +#define STACK_DIRECTION -1 + /* default directory information */ #define DEFAULT_MYSQL_HOME "sys:/mysql" #define PACKAGE "mysql" @@ -80,6 +96,20 @@ /* do not use the extended time in LibC sys\stat.h */ #define _POSIX_SOURCE +/* Kernel call on NetWare that will only yield if our time slice is up */ +void kYieldIfTimeSliceUp(void); + /* Some macros for portability */ -#define set_timespec(ABSTIME,SEC) { (ABSTIME).tv_sec=(SEC); (ABSTIME).tv_nsec=0; } +#define set_timespec(ABSTIME,SEC) { (ABSTIME).tv_sec=time(NULL)+(SEC); (ABSTIME).tv_nsec=0; } + +/* extra protection against CPU Hogs on NetWare */ +#define NETWARE_YIELD kYieldIfTimeSliceUp() +/* Screen mode for help texts */ +#define NETWARE_SET_SCREEN_MODE(A) setscreenmode(A) + +#ifdef __cplusplus +} +#endif + +#endif /* _config_netware_h */ diff --git a/include/help_end.h b/include/help_end.h new file mode 100644 index 00000000000..a63d9e7ca9f --- /dev/null +++ b/include/help_end.h @@ -0,0 +1,6 @@ +#ifdef __NETWARE__ +#undef printf +#undef puts +#undef fputs +#undef putchar +#endif diff --git a/include/help_start.h b/include/help_start.h new file mode 100644 index 00000000000..38bb91f7655 --- /dev/null +++ b/include/help_start.h @@ -0,0 +1,7 @@ +/* Divert all help information on NetWare to logger screen. */ + +#ifdef __NETWARE__ +#define printf consoleprintf +#define puts(s) consoleprintf("%s\n",s) +#define fputs(s,f) puts(s) +#endif diff --git a/include/my_global.h b/include/my_global.h index fafe0425c55..88756742552 100644 --- a/include/my_global.h +++ b/include/my_global.h @@ -73,6 +73,12 @@ #endif #endif /* _WIN32... */ +/* Some defines to avoid ifdefs in the code */ +#ifndef NETWARE_YIELD +#define NETWARE_YIELD +#define NETWARE_SET_SCREEN_MODE(A) +#endif + /* The macros below are borrowed from include/linux/compiler.h in the Linux kernel. Use them to indicate the likelyhood of the truthfulness diff --git a/include/mysql_com.h b/include/mysql_com.h index a1da896af38..801937a9e7b 100644 --- a/include/mysql_com.h +++ b/include/mysql_com.h @@ -36,6 +36,12 @@ #define MYSQL_SERVICENAME "MySQL" #endif /* __WIN__ */ +#if defined(__WIN__) && !defined(MYSQL_SERVER) && !defined(MYSQL_CLIENT) && !defined(EMBEDDED_LIBRARY) +#define dll_import_spec __declspec( dllimport ) +#else +#define dll_import_spec +#endif + enum enum_server_command { COM_SLEEP, COM_QUIT, COM_INIT_DB, COM_QUERY, COM_FIELD_LIST, @@ -306,8 +312,8 @@ typedef struct st_udf_init extern "C" { #endif -extern unsigned long max_allowed_packet; -extern unsigned long net_buffer_length; +dll_import_spec extern unsigned long max_allowed_packet; +dll_import_spec extern unsigned long net_buffer_length; /* These functions are used for authentication by client and server and diff --git a/include/thr_alarm.h b/include/thr_alarm.h index 0dbb700b4fc..7a10d6886ce 100644 --- a/include/thr_alarm.h +++ b/include/thr_alarm.h @@ -64,7 +64,7 @@ typedef my_bool ALARM; #define init_thr_alarm(A) #define thr_alarm_kill(A) #define resize_thr_alarm(N) -#define end_thr_alarm() +#define end_thr_alarm(A) #else #if defined(__WIN__) |