config.h 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452
  1. /* ldns/config.h.in. Generated from configure.ac by autoheader. */
  2. /* Define if building universal (internal helper macro) */
  3. #undef AC_APPLE_UNIVERSAL_BUILD
  4. /* Define to 1 if you have the <arpa/inet.h> header file. */
  5. #undef HAVE_ARPA_INET_H
  6. /* Whether the C compiler accepts the "format" attribute */
  7. #undef HAVE_ATTR_FORMAT
  8. /* Whether the C compiler accepts the "unused" attribute */
  9. #undef HAVE_ATTR_UNUSED
  10. /* Define to 1 if you have the `b32_ntop' function. */
  11. #undef HAVE_B32_NTOP
  12. /* Define to 1 if you have the `b32_pton' function. */
  13. #undef HAVE_B32_PTON
  14. /* Define to 1 if you have the `b64_ntop' function. */
  15. #undef HAVE_B64_NTOP
  16. /* Define to 1 if you have the `b64_pton' function. */
  17. #undef HAVE_B64_PTON
  18. /* Define to 1 if you have the `ctime_r' function. */
  19. #undef HAVE_CTIME_R
  20. /* Define to 1 if you have the <dlfcn.h> header file. */
  21. #undef HAVE_DLFCN_H
  22. /* Define to 1 if you have the `endprotoent' function. */
  23. #undef HAVE_ENDPROTOENT
  24. /* Define to 1 if you have the `endservent' function. */
  25. #undef HAVE_ENDSERVENT
  26. /* Define to 1 if you have the `EVP_sha256' function. */
  27. #undef HAVE_EVP_SHA256
  28. /* Whether getaddrinfo is available */
  29. #undef HAVE_GETADDRINFO
  30. /* Define to 1 if you have the <getopt.h> header file. */
  31. #undef HAVE_GETOPT_H
  32. /* Define to 1 if you have the `gmtime_r' function. */
  33. #undef HAVE_GMTIME_R
  34. /* If you have HMAC_CTX_init */
  35. #undef HAVE_HMAC_CTX_INIT
  36. /* Define to 1 if you have the `inet_aton' function. */
  37. #undef HAVE_INET_ATON
  38. /* Define to 1 if you have the `inet_ntop' function. */
  39. #undef HAVE_INET_NTOP
  40. /* Define to 1 if you have the `inet_pton' function. */
  41. #undef HAVE_INET_PTON
  42. /* define if you have inttypes.h */
  43. #undef HAVE_INTTYPES_H
  44. /* Define to 1 if you have the `isblank' function. */
  45. #undef HAVE_ISBLANK
  46. /* Define to 1 if you have the `crypto' library (-lcrypto). */
  47. #undef HAVE_LIBCRYPTO
  48. /* Define to 1 if you have the `nsl' library (-lnsl). */
  49. #undef HAVE_LIBNSL
  50. /* Define to 1 if you have the `socket' library (-lsocket). */
  51. #undef HAVE_LIBSOCKET
  52. /* Define to 1 if your system has a GNU libc compatible `malloc' function, and
  53. to 0 otherwise. */
  54. #define HAVE_MALLOC 1
  55. /* Define to 1 if you have the `memmove' function. */
  56. #define HAVE_MEMMOVE 1
  57. /* Define to 1 if you have the <memory.h> header file. */
  58. #undef HAVE_MEMORY_H
  59. /* Define to 1 if you have the <netdb.h> header file. */
  60. #undef HAVE_NETDB_H
  61. /* Define to 1 if you have the <netinet/in.h> header file. */
  62. #undef HAVE_NETINET_IN_H
  63. /* Define to 1 if you have the <openssl/err.h> header file. */
  64. #undef HAVE_OPENSSL_ERR_H
  65. /* Define to 1 if you have the <openssl/rand.h> header file. */
  66. #undef HAVE_OPENSSL_RAND_H
  67. /* Define to 1 if you have the <openssl/ssl.h> header file. */
  68. #undef HAVE_OPENSSL_SSL_H
  69. /* Define to 1 if you have the `random' function. */
  70. #define HAVE_RANDOM 1
  71. /* Define to 1 if your system has a GNU libc compatible `realloc' function,
  72. and to 0 otherwise. */
  73. #define HAVE_REALLOC 1
  74. /* Define to 1 if you have the `sleep' function. */
  75. #undef HAVE_SLEEP
  76. /* Define to 1 if you have the `snprintf' function. */
  77. #define HAVE_SNPRINTF 1
  78. /* Define if you have the SSL libraries installed. */
  79. #undef HAVE_SSL
  80. /* Define to 1 if you have the <stdarg.h> header file. */
  81. #undef HAVE_STDARG_H
  82. /* Define to 1 if you have the <stdbool.h> header file. */
  83. #undef HAVE_STDBOOL_H
  84. /* Define to 1 if you have the <stdint.h> header file. */
  85. #undef HAVE_STDINT_H
  86. /* Define to 1 if you have the <stdlib.h> header file. */
  87. #undef HAVE_STDLIB_H
  88. /* Define to 1 if you have the <strings.h> header file. */
  89. #undef HAVE_STRINGS_H
  90. /* Define to 1 if you have the <string.h> header file. */
  91. #undef HAVE_STRING_H
  92. /* Define to 1 if you have the `strlcpy' function. */
  93. #undef HAVE_STRLCPY
  94. /* Define to 1 if you have the <sys/mount.h> header file. */
  95. #undef HAVE_SYS_MOUNT_H
  96. /* Define to 1 if you have the <sys/param.h> header file. */
  97. #undef HAVE_SYS_PARAM_H
  98. /* define if you have sys/socket.h */
  99. #undef HAVE_SYS_SOCKET_H
  100. /* Define to 1 if you have the <sys/stat.h> header file. */
  101. #undef HAVE_SYS_STAT_H
  102. /* Define to 1 if you have the <sys/types.h> header file. */
  103. #undef HAVE_SYS_TYPES_H
  104. /* Define to 1 if you have the `timegm' function. */
  105. #undef HAVE_TIMEGM
  106. /* Define to 1 if you have the <time.h> header file. */
  107. #undef HAVE_TIME_H
  108. /* Define to 1 if you have the <unistd.h> header file. */
  109. #undef HAVE_UNISTD_H
  110. /* Define to 1 if you have the <winsock2.h> header file. */
  111. #define HAVE_WINSOCK2_H 1
  112. /* Define to 1 if you have the <ws2tcpip.h> header file. */
  113. #undef HAVE_WS2TCPIP_H
  114. /* Define to the sub-directory in which libtool stores uninstalled libraries.
  115. */
  116. #undef LT_OBJDIR
  117. /* Define to the address where bug reports for this package should be sent. */
  118. #undef PACKAGE_BUGREPORT
  119. /* Define to the full name of this package. */
  120. #undef PACKAGE_NAME
  121. /* Define to the full name and version of this package. */
  122. #undef PACKAGE_STRING
  123. /* Define to the one symbol short name of this package. */
  124. #undef PACKAGE_TARNAME
  125. /* Define to the version of this package. */
  126. #undef PACKAGE_VERSION
  127. /* Define to 1 if you have the ANSI C header files. */
  128. #undef STDC_HEADERS
  129. /* System configuration dir */
  130. #undef SYSCONFDIR
  131. /* Define this to enable GOST support. */
  132. #undef USE_GOST
  133. /* Define this to enable SHA256 and SHA512 support. */
  134. #undef USE_SHA2
  135. /* Enable extensions on AIX 3, Interix. */
  136. #ifndef _ALL_SOURCE
  137. # undef _ALL_SOURCE
  138. #endif
  139. /* Enable GNU extensions on systems that have them. */
  140. #ifndef _GNU_SOURCE
  141. # undef _GNU_SOURCE
  142. #endif
  143. /* Enable threading extensions on Solaris. */
  144. #ifndef _POSIX_PTHREAD_SEMANTICS
  145. # undef _POSIX_PTHREAD_SEMANTICS
  146. #endif
  147. /* Enable extensions on HP NonStop. */
  148. #ifndef _TANDEM_SOURCE
  149. # undef _TANDEM_SOURCE
  150. #endif
  151. /* Enable general extensions on Solaris. */
  152. #ifndef __EXTENSIONS__
  153. # undef __EXTENSIONS__
  154. #endif
  155. /* Whether the windows socket API is used */
  156. #define USE_WINSOCK
  157. /* the version of the windows API enabled */
  158. //#undef WINVER
  159. /* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
  160. significant byte first (like Motorola and SPARC, unlike Intel). */
  161. #if defined AC_APPLE_UNIVERSAL_BUILD
  162. # if defined __BIG_ENDIAN__
  163. # define WORDS_BIGENDIAN 1
  164. # endif
  165. #else
  166. # ifndef WORDS_BIGENDIAN
  167. # undef WORDS_BIGENDIAN
  168. # endif
  169. #endif
  170. /* Define to 1 if on MINIX. */
  171. #undef _MINIX
  172. /* Define to 2 if the system does not provide POSIX.1 features except with
  173. this defined. */
  174. #undef _POSIX_1_SOURCE
  175. /* Define to 1 if you need to in order for `stat' and other things to work. */
  176. #undef _POSIX_SOURCE
  177. /* Define to empty if `const' does not conform to ANSI C. */
  178. #undef const
  179. /* in_addr_t */
  180. #undef in_addr_t
  181. /* in_port_t */
  182. #undef in_port_t
  183. /* Define to `__inline__' or `__inline' if that's what the C compiler
  184. calls it, or to nothing if 'inline' is not supported under any name. */
  185. #ifndef __cplusplus
  186. #ifndef _WIN32
  187. #define inline /* Do not define inline for Windows to avoid warnings/errors with winsock2.h usage of inline within the latest Windows SDKs */
  188. #endif
  189. #endif
  190. #if _MSC_VER >= 1900
  191. #include <stdint.h>
  192. #else
  193. /* Define to `short' if <sys/types.h> does not define. */
  194. #undef int16_t
  195. /* Define to `int' if <sys/types.h> does not define. */
  196. #undef int32_t
  197. /* Define to `long long' if <sys/types.h> does not define. */
  198. #undef int64_t
  199. /* Define to `char' if <sys/types.h> does not define. */
  200. #undef int8_t
  201. /* Define to rpl_malloc if the replacement function should be used. */
  202. #undef malloc
  203. /* Define to rpl_realloc if the replacement function should be used. */
  204. #undef realloc
  205. /* Define to 'int' if not defined */
  206. #undef socklen_t
  207. /* Define to `unsigned short' if <sys/types.h> does not define. */
  208. #define uint16_t unsigned short
  209. #define int16_t short
  210. /* Define to `unsigned int' if <sys/types.h> does not define. */
  211. #define uint32_t unsigned int
  212. /* Define to `unsigned long long' if <sys/types.h> does not define. */
  213. #define uint64_t unsigned long long
  214. /* Define to `unsigned char' if <sys/types.h> does not define. */
  215. #define uint8_t unsigned char
  216. #define int8_t char
  217. #endif
  218. /* Define to `int' if <sys/types.h> does not define. */
  219. #define ssize_t int
  220. #include <stdio.h>
  221. #include <string.h>
  222. //#include <unistd.h>
  223. #include <assert.h>
  224. #ifndef LITTLE_ENDIAN
  225. #define LITTLE_ENDIAN 1234
  226. #endif
  227. #ifndef BIG_ENDIAN
  228. #define BIG_ENDIAN 4321
  229. #endif
  230. #ifndef BYTE_ORDER
  231. #ifdef WORDS_BIGENDIAN
  232. #define BYTE_ORDER BIG_ENDIAN
  233. #else
  234. #define BYTE_ORDER LITTLE_ENDIAN
  235. #endif /* WORDS_BIGENDIAN */
  236. #endif /* BYTE_ORDER */
  237. #if STDC_HEADERS
  238. #include <stdlib.h>
  239. #include <stddef.h>
  240. #endif
  241. #ifdef HAVE_STDINT_H
  242. #include <stdint.h>
  243. #endif
  244. #ifdef HAVE_SYS_SOCKET_H
  245. #include <sys/socket.h>
  246. #endif
  247. #ifdef HAVE_NETINET_IN_H
  248. #include <netinet/in.h>
  249. #endif
  250. #ifdef HAVE_ARPA_INET_H
  251. #include <arpa/inet.h>
  252. #endif
  253. #ifdef HAVE_WINSOCK2_H
  254. #include <winsock2.h>
  255. #endif
  256. #ifdef HAVE_WS2TCPIP_H
  257. #include <ws2tcpip.h>
  258. #endif
  259. #ifdef _MSC_VER
  260. #if _MSC_VER < 1900
  261. #define snprintf _snprintf
  262. #else
  263. #ifndef HAVE_ISBLANK
  264. #define HAVE_ISBLANK
  265. #endif
  266. #endif
  267. #define vsnprintf _vsnprintf
  268. #define strcasecmp _stricmp
  269. #define strncasecmp _strnicmp
  270. #define strdup _strdup
  271. /*
  272. #define gmtime gmtime_s
  273. #define ctime ctime_s
  274. #define strcpy strcpu_s
  275. */
  276. #define putenv _putenv
  277. #define srandom srand
  278. #define random rand
  279. #endif
  280. #ifndef B64_PTON
  281. int ldns_b64_ntop(uint8_t const *src, size_t srclength,
  282. char *target, size_t targsize);
  283. /**
  284. * calculates the size needed to store the result of b64_ntop
  285. */
  286. /*@unused@*/
  287. inline static size_t ldns_b64_ntop_calculate_size(size_t srcsize)
  288. {
  289. return ((((srcsize + 2) / 3) * 4) + 1);
  290. }
  291. #endif /* !B64_PTON */
  292. #ifndef B64_NTOP
  293. int ldns_b64_pton(char const *src, uint8_t *target, size_t targsize);
  294. /**
  295. * calculates the size needed to store the result of ldns_b64_pton
  296. */
  297. /*@unused@*/
  298. inline static size_t ldns_b64_pton_calculate_size(size_t srcsize)
  299. {
  300. return ((((srcsize / 4) * 3) - 2) + 2);
  301. }
  302. #endif /* !B64_NTOP */
  303. #ifndef HAVE_SLEEP
  304. /* use windows sleep, in millisecs, instead */
  305. #define sleep(x) Sleep((x)*1000)
  306. #endif
  307. #ifndef HAVE_RANDOM
  308. #define srandom(x) srand(x)
  309. #define random(x) rand(x)
  310. #endif
  311. #ifndef HAVE_TIMEGM
  312. #include <time.h>
  313. time_t timegm (struct tm *tm);
  314. #endif /* !TIMEGM */
  315. #ifndef HAVE_GMTIME_R
  316. struct tm *gmtime_r(const time_t *timep, struct tm *result);
  317. #endif
  318. #ifndef HAVE_ISBLANK
  319. int isblank(int c);
  320. #endif /* !HAVE_ISBLANK */
  321. #ifndef HAVE_SNPRINTF
  322. #include <stdarg.h>
  323. int snprintf (char *str, size_t count, const char *fmt, ...);
  324. int vsnprintf (char *str, size_t count, const char *fmt, va_list arg);
  325. #endif /* HAVE_SNPRINTF */
  326. #ifndef HAVE_INET_PTON
  327. int inet_pton(int af, const char* src, void* dst);
  328. #endif /* HAVE_INET_PTON */
  329. #ifndef HAVE_INET_NTOP
  330. const char *inet_ntop(int af, const void *src, char *dst, size_t size);
  331. #endif
  332. #ifndef HAVE_INET_ATON
  333. int inet_aton(const char *cp, struct in_addr *addr);
  334. #endif
  335. #ifndef HAVE_MEMMOVE
  336. void *memmove(void *dest, const void *src, size_t n);
  337. #endif
  338. #ifndef HAVE_STRLCPY
  339. size_t strlcpy(char *dst, const char *src, size_t siz);
  340. #endif
  341. #ifndef HAVE_GETADDRINFO
  342. #include "compat/fake-rfc2553.h"
  343. #endif