00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef INCL_AUTOTOOLS_ADAPTER
00021 #define INCL_AUTOTOOLS_ADAPTER
00022
00025
00026
00027
00028
00029 #include <config.h>
00030 #include <string.h>
00031 #include <stdlib.h>
00032 #include <ctype.h>
00033 #include <stdio.h>
00034 #include <time.h>
00035 #include <stdarg.h>
00036 #include <unistd.h>
00037
00038
00039 #include <netinet/in.h>
00040
00041
00042
00043 #include <base/test.h>
00044
00045
00046 #ifndef __CYGWIN__
00047 # define __declspec(x)
00048 # define __cdecl
00049 #endif
00050
00051 #define EXTRA_SECTION_00
00052 #define EXTRA_SECTION_01
00053 #define EXTRA_SECTION_02
00054 #define EXTRA_SECTION_03
00055 #define EXTRA_SECTION_04
00056 #define EXTRA_SECTION_05
00057 #define EXTRA_SECTION_06
00058
00059 #define BOOL int
00060 #define TRUE 1
00061 #define FALSE 0
00062
00063
00064 #define VOCL_ENCODING_FIX
00065
00066
00067 #ifdef USE_WCHAR
00068
00069 #undef WCHAR
00070 #include <wchar.h>
00071 #include <wctype.h>
00072
00073 #define WCHAR wchar_t
00074 #define WCHAR_PRINTF "s"
00075 #define TEXT(_x) L##_x
00076
00077
00078 WCHAR *wcstok(WCHAR *s, const WCHAR *delim);
00079
00080 inline int _wtoi(const WCHAR *s) { return (int)wcstol(s, NULL, 10); }
00081
00082 #define _wcsicmp wcscasecmp
00083 #define wcsicmp wcscasecmp
00084 #define snwprintf swprintf
00085
00086 #else
00087
00088
00089 # undef WCHAR
00090 # define WCHAR char
00091 # define WCHAR_PRINTF "s"
00092 # define TEXT(_x) _x
00093
00094 # define SYNC4J_LINEBREAK "\n"
00095
00096 # define wsprintf sprintf
00097 # define _wfopen fopen
00098 # define wprintf printf
00099 # define fwprintf fprintf
00100 # define wsprintf sprintf
00101 # define swprintf snprintf
00102 # define snwprintf snprintf
00103 # define wcscpy strcpy
00104 # define wcsncpy strncpy
00105 # define wcsncmp strncmp
00106 # define wcslen strlen
00107 # define wcstol strtol
00108 # define wcstoul strtoul
00109 # define wcsstr strstr
00110 # define wcscmp strcmp
00111 # define wcstok strtok
00112 inline char towlower(char x) { return tolower(x); }
00113 inline char towupper(char x) { return toupper(x); }
00114 # define wmemmove memmove
00115 # define wmemcpy memcpy
00116 # define wmemcmp memcmp
00117 # define wmemset memset
00118 # define wcschr strchr
00119 # define wcsrchr strrchr
00120 # define wcscat strcat
00121 # define wcsncat strncat
00122 # define _wtoi atoi
00123 # define wcstod strtod
00124 # define wcsicmp strcasecmp
00125 # define _wcsicmp strcasecmp
00126 # define _stricmp strcasecmp
00127
00128 #endif
00129
00130
00131
00132 #undef NULL
00133 #define NULL 0
00134
00135 #define min(x,y) ( (x) < (y) ? (x) : (y) )
00136 #define max(x,y) ( (x) > (y) ? (x) : (y) )
00137
00139 #endif
00140