db_config.h
上传用户:tsgydb
上传日期:2007-04-14
资源大小:10674k
文件大小:7k
源码类别:

MySQL数据库

开发平台:

Visual C++

  1. /*
  2.  * $Id: db_config.h,v 11.24 2000/12/12 18:39:26 bostic Exp $
  3.  */
  4. /* Define to empty if the keyword does not work.  */
  5. /* #undef const */
  6. /* Define if your struct stat has st_blksize.  */
  7. /* #undef HAVE_ST_BLKSIZE */
  8. /* Define to `int' if <sys/types.h> doesn't define.  */
  9. /* #undef mode_t */
  10. /* Define to `long' if <sys/types.h> doesn't define.  */
  11. /* #undef off_t */
  12. /* Define to `int' if <sys/types.h> doesn't define.  */
  13. /* #undef pid_t */
  14. /* Define to `unsigned' if <sys/types.h> doesn't define.  */
  15. /* #undef size_t */
  16. /* Define if the `S_IS*' macros in <sys/stat.h> do not work properly.  */
  17. /* #undef STAT_MACROS_BROKEN */
  18. /* Define if you have the ANSI C header files.  */
  19. #define STDC_HEADERS 1
  20. /* Define if you can safely include both <sys/time.h> and <time.h>.  */
  21. /* #undef TIME_WITH_SYS_TIME */
  22. /* Define if your processor stores words with the most significant
  23.    byte first (like Motorola and SPARC, unlike Intel and VAX).  */
  24. /* #undef WORDS_BIGENDIAN */
  25. /* Define if you are building a version for running the test suite. */
  26. /* #undef CONFIG_TEST */
  27. /* Define if you want a debugging version. */
  28. /* #undef DEBUG */
  29. #if defined(_DEBUG)
  30. #if !defined(DEBUG)
  31. #define DEBUG 1
  32. #endif
  33. #endif
  34. /* Define if you want a version that logs read operations. */
  35. /* #undef DEBUG_ROP */
  36. /* Define if you want a version that logs write operations. */
  37. /* #undef DEBUG_WOP */
  38. /* Define if you want a version with run-time diagnostic checking. */
  39. /* #undef DIAGNOSTIC */
  40. /* Define if you want to mask harmless unitialized memory read/writes. */
  41. /* #undef UMRW */
  42. /* Define if fcntl/F_SETFD denies child access to file descriptors. */
  43. /* #undef HAVE_FCNTL_F_SETFD */
  44. /* Define if building big-file environment (e.g., AIX, HP/UX, Solaris). */
  45. /* #undef HAVE_FILE_OFFSET_BITS */
  46. /* Mutex possibilities. */
  47. /* #undef HAVE_MUTEX_68K_GCC_ASSEMBLY */
  48. /* #undef HAVE_MUTEX_AIX_CHECK_LOCK */
  49. /* #undef HAVE_MUTEX_ALPHA_GCC_ASSEMBLY */
  50. /* #undef HAVE_MUTEX_HPPA_GCC_ASSEMBLY */
  51. /* #undef HAVE_MUTEX_HPPA_MSEM_INIT */
  52. /* #undef HAVE_MUTEX_IA64_GCC_ASSEMBLY */
  53. /* #undef HAVE_MUTEX_MACOS */
  54. /* #undef HAVE_MUTEX_MSEM_INIT */
  55. /* #undef HAVE_MUTEX_PPC_GCC_ASSEMBLY */
  56. /* #undef HAVE_MUTEX_PTHREADS */
  57. /* #undef HAVE_MUTEX_RELIANTUNIX_INITSPIN */
  58. /* #undef HAVE_MUTEX_SCO_X86_CC_ASSEMBLY */
  59. /* #undef HAVE_MUTEX_SEMA_INIT */
  60. /* #undef HAVE_MUTEX_SGI_INIT_LOCK */
  61. /* #undef HAVE_MUTEX_SOLARIS_LOCK_TRY */
  62. /* #undef HAVE_MUTEX_SOLARIS_LWP */
  63. /* #undef HAVE_MUTEX_SPARC_GCC_ASSEMBLY */
  64. #define HAVE_MUTEX_THREADS 1
  65. /* #undef HAVE_MUTEX_UI_THREADS */
  66. /* #undef HAVE_MUTEX_UTS_CC_ASSEMBLY */
  67. /* #undef HAVE_MUTEX_VMS */
  68. /* #undef HAVE_MUTEX_VXWORKS */
  69. /* #undef HAVE_MUTEX_WIN16 */
  70. #define HAVE_MUTEX_WIN32 1
  71. /* #undef HAVE_MUTEX_X86_GCC_ASSEMBLY */
  72. /* Define if building on QNX. */
  73. /* #undef HAVE_QNX */
  74. /* Define if building RPC client/server. */
  75. /* #undef HAVE_RPC */
  76. /* Define if your sprintf returns a pointer, not a length. */
  77. /* #undef SPRINTF_RET_CHARPNT */
  78. /* Define if you have the getcwd function.  */
  79. #define HAVE_GETCWD 1
  80. /* Define if you have the getopt function.  */
  81. /* #undef HAVE_GETOPT */
  82. /* Define if you have the getuid function.  */
  83. /* #undef HAVE_GETUID */
  84. /* Define if you have the memcmp function.  */
  85. #define HAVE_MEMCMP 1
  86. /* Define if you have the memcpy function.  */
  87. #define HAVE_MEMCPY 1
  88. /* Define if you have the memmove function.  */
  89. #define HAVE_MEMMOVE 1
  90. /* Define if you have the mlock function.  */
  91. /* #undef HAVE_MLOCK */
  92. /* Define if you have the mmap function.  */
  93. /* #undef HAVE_MMAP */
  94. /* Define if you have the munlock function.  */
  95. /* #undef HAVE_MUNLOCK */
  96. /* Define if you have the munmap function.  */
  97. /* #undef HAVE_MUNMAP */
  98. /* Define if you have the pread function.  */
  99. /* #undef HAVE_PREAD */
  100. /* Define if you have the pstat_getdynamic function.  */
  101. /* #undef HAVE_PSTAT_GETDYNAMIC */
  102. /* Define if you have the pwrite function.  */
  103. /* #undef HAVE_PWRITE */
  104. /* Define if you have the qsort function.  */
  105. #define HAVE_QSORT 1
  106. /* Define if you have the raise function.  */
  107. #define HAVE_RAISE 1
  108. /* Define if you have the sched_yield function.  */
  109. /* #undef HAVE_SCHED_YIELD */
  110. /* Define if you have the select function.  */
  111. /* #undef HAVE_SELECT */
  112. /* Define if you have the shmget function.  */
  113. /* #undef HAVE_SHMGET */
  114. /* Define if you have the snprintf function.  */
  115. #define HAVE_SNPRINTF 1
  116. /* Define if you have the strcasecmp function.  */
  117. /* #undef HAVE_STRCASECMP */
  118. /* Define if you have the strerror function.  */
  119. #define HAVE_STRERROR 1
  120. /* Define if you have the strtoul function.  */
  121. #define HAVE_STRTOUL 1
  122. /* Define if you have the sysconf function.  */
  123. /* #undef HAVE_SYSCONF */
  124. /* Define if you have the vsnprintf function.  */
  125. #define HAVE_VSNPRINTF 1
  126. /* Define if you have the yield function.  */
  127. /* #undef HAVE_YIELD */
  128. /* Define if you have the <dirent.h> header file.  */
  129. /* #undef HAVE_DIRENT_H */
  130. /* Define if you have the <ndir.h> header file.  */
  131. /* #undef HAVE_NDIR_H */
  132. /* Define if you have the <sys/dir.h> header file.  */
  133. /* #undef HAVE_SYS_DIR_H */
  134. /* Define if you have the <sys/ndir.h> header file.  */
  135. /* #undef HAVE_SYS_NDIR_H */
  136. /* Define if you have the <sys/select.h> header file.  */
  137. /* #undef HAVE_SYS_SELECT_H */
  138. /* Define if you have the <sys/time.h> header file.  */
  139. /* #undef HAVE_SYS_TIME_H */
  140. /* Define if you have the nsl library (-lnsl).  */
  141. /* #undef HAVE_LIBNSL */
  142. /*
  143.  * XXX
  144.  * The following is not part of the automatic configuration setup,
  145.  * but provides the information necessary to build DB on Windows.
  146.  */
  147. #include <sys/types.h>
  148. #include <sys/stat.h>
  149. #include <direct.h>
  150. #include <fcntl.h>
  151. #include <io.h>
  152. #include <limits.h>
  153. #include <memory.h>
  154. #include <process.h>
  155. #include <signal.h>
  156. #include <stdio.h>
  157. #include <stdlib.h>
  158. #include <time.h>
  159. #include <errno.h>
  160. #if defined(__cplusplus)
  161. #include <iostream.h>
  162. #endif
  163. /*
  164.  * To build Tcl interface libraries, the include path must be configured to
  165.  * use the directory containing <tcl.h>, usually the include directory in
  166.  * the Tcl distribution.
  167.  */
  168. #ifdef DB_TCL_SUPPORT
  169. #include <tcl.h>
  170. #endif
  171. #define WIN32_LEAN_AND_MEAN
  172. #include <windows.h>
  173. /*
  174.  * Win32 has fsync, getcwd, snprintf and vsnprintf, but under different names.
  175.  */
  176. #define fsync(fd) _commit(fd)
  177. #define getcwd(buf, size) _getcwd(buf, size)
  178. #define snprintf _snprintf
  179. #define vsnprintf _vsnprintf
  180. /*
  181.  * Win32 does not define getopt and friends in any header file, so we must.
  182.  */
  183. #if defined(__cplusplus)
  184. extern "C" {
  185. #endif
  186. extern int optind;
  187. extern char *optarg;
  188. extern int getopt(int, char * const *, const char *);
  189. #if defined(__cplusplus)
  190. }
  191. #endif
  192. #define NO_SYSTEM_INCLUDES
  193. /*
  194.  * We use DB_WIN32 much as one would use _WIN32, to determine that we're
  195.  * using an operating system environment that supports Win32 calls
  196.  * and semantics.  We don't use _WIN32 because cygwin/gcc also defines
  197.  * that, even though it closely emulates the Unix environment.
  198.  */
  199. #define DB_WIN32 1
  200. /*
  201.  * This is a grievous hack -- once we've included windows.h, we have no choice
  202.  * but to use ANSI-style varargs (because it pulls in stdarg.h for us).  DB's
  203.  * code decides which type of varargs to use based on the state of __STDC__.
  204.  * Sensible.  Unfortunately, Microsoft's compiler _doesn't_ define __STDC__
  205.  * unless you invoke it with arguments turning OFF all vendor extensions.  Even
  206.  * more unfortunately, if we do that, it fails to parse windows.h!!!!!  So, we
  207.  * define __STDC__ here, after windows.h comes in.  Note: the compiler knows
  208.  * we've defined it, and starts enforcing strict ANSI compilance from this point
  209.  * on.
  210.  */
  211. #define __STDC__ 1