23 #if !defined(GLOBUS_COMMON_INCLUDE_H)
24 #define GLOBUS_COMMON_INCLUDE_H 1
28 #if defined(_WIN32) && !defined(__CYGWIN__)
34 #define GlobusFuncName(func) static const char * _globus_func_name \
35 __attribute__((__unused__)) = #func
37 #define GlobusFuncName(func) static const char * _globus_func_name = #func
40 extern const char * _globus_func_name;
42 #define _GCSL(s) globus_common_i18n_get_string(GLOBUS_COMMON_MODULE,\
53 #include <sys/types.h>
58 #include <sys/param.h>
63 # include <winsock2.h>
66 # include <sys/timeb.h>
72 # include <netinet/in.h>
73 # include <sys/socket.h>
103 void globus_dump_stack();
104 #define GLOBUS_DUMP_STACK() globus_dump_stack()
106 #define GLOBUS_DUMP_STACK()
109 #if defined(BUILD_DEBUG)
110 # define globus_assert(assertion) \
114 fprintf(stderr, "Assertion " #assertion \
115 " failed in file %s at line %d\n", \
116 __FILE__, __LINE__); \
117 GLOBUS_DUMP_STACK(); \
122 # define globus_assert_string(assertion, string) \
126 fprintf(stderr, "Assertion " #assertion \
127 " failed in file %s at line %d: %s", \
128 __FILE__, __LINE__, string); \
129 GLOBUS_DUMP_STACK(); \
134 # define globus_assert(assertion)
135 # define globus_assert_string(assertion, string)
138 #define GLOBUS_MAX(V1,V2) (((V1) > (V2)) ? (V1) : (V2))
139 #define GLOBUS_MIN(V1,V2) (((V1) < (V2)) ? (V1) : (V2))
141 #ifndef EXTERN_C_BEGIN
143 #define EXTERN_C_BEGIN extern "C" {
144 #define EXTERN_C_END }
146 #define EXTERN_C_BEGIN
154 #define EWOULDBLOCK EAGAIN
157 #define ETIMEDOUT WSAETIMEDOUT
160 #define EINPROGRESS WSAEINPROGRESS
164 #include <inttypes.h>
167 #if defined(_WIN32) && !defined(__USE_MINGW_ANSI_STDIO)
168 # define vsnprintf _vsnprintf
171 #ifndef MAXHOSTNAMELEN
172 #define MAXHOSTNAMELEN 64
Globus Platform Configuration.