Eneboo - Documentación para desarrolladores
src/libmysql_std/include/config-netware.h
Ir a la documentación de este archivo.
00001 /* Copyright (C) 2000 MySQL AB
00002 
00003    This program is free software; you can redistribute it and/or modify
00004    it under the terms of the GNU General Public License as published by
00005    the Free Software Foundation; version 2 of the License.
00006 
00007    This program is distributed in the hope that it will be useful,
00008    but WITHOUT ANY WARRANTY; without even the implied warranty of
00009    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00010    GNU General Public License for more details.
00011 
00012    You should have received a copy of the GNU General Public License
00013    along with this program; if not, write to the Free Software
00014    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA */
00015 
00016 /* Header for NetWare compatible with MySQL */
00017 
00018 #ifndef _config_netware_h
00019 #define _config_netware_h
00020 
00021 /* required headers */
00022 #include <unistd.h>
00023 #include <stdio.h>
00024 #include <errno.h>
00025 #include <screen.h>
00026 #include <limits.h>
00027 #include <signal.h>
00028 #include <errno.h>
00029 #include <stdbool.h>
00030 #include <stdlib.h>
00031 #include <sys/types.h>
00032 #include <time.h>
00033 #include <sys/time.h>
00034 #include <pthread.h>
00035 #include <termios.h>
00036 
00037 #ifdef __cplusplus
00038 extern "C" {
00039 #endif
00040 
00041 /* required adjustments */
00042 #undef HAVE_READDIR_R
00043 #undef HAVE_RWLOCK_INIT
00044 #undef HAVE_SCHED_H
00045 #undef HAVE_SYS_MMAN_H
00046 #undef HAVE_SYNCH_H
00047 #undef HAVE_MMAP
00048 #undef HAVE_RINT
00049 
00050 #define HAVE_PTHREAD_ATTR_SETSTACKSIZE 1
00051 #define HAVE_PTHREAD_SIGMASK 1
00052 #define HAVE_PTHREAD_YIELD_ZERO_ARG 1
00053 #define HAVE_BROKEN_REALPATH 1
00054 
00055 /* changes made to make use of LibC-June-2004 for building purpose */
00056 #undef HAVE_POSIX_SIGNALS
00057 #undef HAVE_PTHREAD_ATTR_SETSCOPE
00058 #undef HAVE_ALLOC_A
00059 #undef HAVE_FINITE
00060 #undef HAVE_GETPWNAM
00061 #undef HAVE_GETPWUID
00062 #undef HAVE_PTHREAD_SETSCHEDPARAM
00063 #undef HAVE_READLINK
00064 #undef HAVE_STPCPY
00065 /* changes  end  */
00066 
00067 /* no libc crypt() function */
00068 #ifdef HAVE_OPENSSL
00069   #define HAVE_CRYPT 1
00070 #else
00071   #undef HAVE_CRYPT
00072 #endif /* HAVE_OPENSSL */
00073 
00074 /* Netware has an ancient zlib */
00075 #undef HAVE_COMPRESS
00076 #define HAVE_COMPRESS
00077 #undef HAVE_ARCHIVE_DB
00078 
00079 /* include the old function apis */
00080 #define USE_OLD_FUNCTIONS 1
00081 
00082 /* no case sensitivity */
00083 #define FN_NO_CASE_SENCE 1
00084 
00085 /* the thread alarm is not used */
00086 #define DONT_USE_THR_ALARM 1
00087 
00088 /* signals do not interrupt sockets */
00089 #define SIGNALS_DONT_BREAK_READ 1
00090 
00091 /* signal by closing the sockets */
00092 #define SIGNAL_WITH_VIO_CLOSE 1
00093 
00094 /* On NetWare, stack grows towards lower address*/
00095 #define STACK_DIRECTION -1
00096 
00097 /* On NetWare, we need to set stack size for threads, otherwise default 16K is used */
00098 #define NW_THD_STACKSIZE 65536
00099 
00100 /* On NetWare, to fix the problem with the deletion of open files */
00101 #define CANT_DELETE_OPEN_FILES 1
00102 
00103 #define FN_LIBCHAR '\\'
00104 #define FN_ROOTDIR "\\"
00105 #define FN_DEVCHAR ':'
00106 
00107 /* default directory information */
00108 #define DEFAULT_MYSQL_HOME    "sys:/mysql"
00109 #define PACKAGE               "mysql"
00110 #define DEFAULT_BASEDIR       "sys:/"
00111 #define SHAREDIR              "share/"
00112 #define DEFAULT_CHARSET_HOME  "sys:/mysql/"
00113 #define DATADIR               "data/"
00114 
00115 /* 64-bit file system calls */
00116 #define SIZEOF_OFF_T          8
00117 #define off_t                 off64_t
00118 #define chsize                chsize64
00119 #define ftruncate             ftruncate64
00120 #define lseek                 lseek64
00121 #define pread                 pread64
00122 #define pwrite                pwrite64
00123 #define tell                  tell64
00124 
00125 /* do not use the extended time in LibC sys\stat.h */
00126 #define _POSIX_SOURCE
00127 
00128 /* Some macros for portability */
00129 
00130 #define set_timespec(ABSTIME,SEC) { (ABSTIME).tv_sec=time(NULL)+(SEC); (ABSTIME).tv_nsec=0; }
00131 
00132 /* extra protection against CPU Hogs on NetWare */
00133 #define NETWARE_YIELD pthread_yield()
00134 /* Screen mode for help texts */
00135 #define NETWARE_SET_SCREEN_MODE(A) setscreenmode(A)
00136 
00137 #ifdef __cplusplus
00138 }
00139 #endif
00140 
00141 #endif /* _config_netware_h */
 Todo Clases Namespaces Archivos Funciones Variables 'typedefs' Enumeraciones Valores de enumeraciones Propiedades Amigas 'defines'