xmlrpc_config.h.in 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. /* xmlrpc_config.h is generated from xmlrpc_config.h.in by 'configure'.
  2. This file just uses plain AC_SUBST substitution, the same as
  3. Makefile.config. Wherever you see @XXX@, that gets replaced by the
  4. value of 'configure' variable XXX.
  5. Logical macros are 0 or 1 instead of the more traditional defined and
  6. undefined. That's so we can distinguish when compiling code between
  7. "false" and some problem with the code.
  8. */
  9. /* We hope to replace xmlrpc_amconfig.h some day with something that
  10. doesn't require a whole special set of software to build, to make
  11. xmlrpc-c approachable by dumber developers.
  12. */
  13. #include "xmlrpc_amconfig.h"
  14. #ifndef __xmlrpc_config_h__
  15. #define __xmlrpc_config_h__
  16. #define VA_LIST_IS_ARRAY @VA_LIST_IS_ARRAY_DEFINE@
  17. #define HAVE_LIBWWW_SSL @HAVE_LIBWWW_SSL_DEFINE@
  18. #define ATTR_UNUSED @ATTR_UNUSED@
  19. #define HAVE_UNICODE_WCHAR @HAVE_UNICODE_WCHAR_DEFINE@
  20. #define DIRECTORY_SEPARATOR "@DIRECTORY_SEPARATOR@"
  21. /* Xmlrpc-c code uses __inline__ to declare functions that should
  22. be compiled as inline code. GNU C recognizes the __inline__ keyword.
  23. Others recognize 'inline' or '__inline' or nothing at all to say
  24. a function should be inlined.
  25. We could make 'configure' simply do a trial compile to figure out
  26. which one, but for now, this approximation is easier:
  27. */
  28. #ifdef _WIN32
  29. # define __inline__ __inline
  30. #else
  31. # ifndef __GNUC__
  32. # ifndef __inline__
  33. # ifdef __sgi
  34. # define __inline__ __inline
  35. # else
  36. # define __inline__
  37. # endif
  38. # endif
  39. # endif
  40. #endif
  41. /* A timeout in milliseconds. */
  42. typedef unsigned long timeout_t;
  43. #if !defined(WIN32) && defined(_WIN32)
  44. # define WIN32
  45. #endif
  46. #if defined(WIN32)
  47. #include <stdio.h>
  48. #include <stdlib.h>
  49. #include <string.h>
  50. #if !defined (vsnprintf)
  51. #define vsnprintf _vsnprintf
  52. #endif
  53. #if !defined (snprintf)
  54. #define snprintf _snprintf
  55. #endif
  56. #include <time.h>
  57. #include <winsock2.h>
  58. #include <direct.h> /* for _chdir() */
  59. __inline BOOL setenv(const char* name, const char* value, int i)
  60. {
  61. return (SetEnvironmentVariable(name, value) != 0) ? TRUE : FALSE;
  62. }
  63. #endif
  64. #endif