1933707f3Ssthen/* config.h.in. Generated from configure.ac by autoheader. */ 2933707f3Ssthen 3933707f3Ssthen/* Directory to chroot to */ 4933707f3Ssthen#undef CHROOT_DIR 5933707f3Ssthen 698f3ca02Sbrad/* Do sha512 definitions in config.h */ 798f3ca02Sbrad#undef COMPAT_SHA512 898f3ca02Sbrad 9933707f3Ssthen/* Pathname to the Unbound configuration file */ 10933707f3Ssthen#undef CONFIGFILE 11933707f3Ssthen 12933707f3Ssthen/* Define this if on macOSX10.4-darwin8 and setreuid and setregid do not work 13933707f3Ssthen */ 14933707f3Ssthen#undef DARWIN_BROKEN_SETREUID 15933707f3Ssthen 16933707f3Ssthen/* Whether daemon is deprecated */ 17933707f3Ssthen#undef DEPRECATED_DAEMON 18933707f3Ssthen 1998f3ca02Sbrad/* default dnstap socket path */ 2098f3ca02Sbrad#undef DNSTAP_SOCKET_PATH 2198f3ca02Sbrad 22933707f3Ssthen/* Define if you want to use debug lock checking (slow). */ 23933707f3Ssthen#undef ENABLE_LOCK_CHECKS 24933707f3Ssthen 25933707f3Ssthen/* Define this if you enabled-allsymbols from libunbound to link binaries to 26933707f3Ssthen it for smaller install size, but the libunbound export table is polluted by 27933707f3Ssthen internal symbols */ 28933707f3Ssthen#undef EXPORT_ALL_SYMBOLS 29933707f3Ssthen 3098f3ca02Sbrad/* Define to 1 if you have the `arc4random' function. */ 3198f3ca02Sbrad#undef HAVE_ARC4RANDOM 3298f3ca02Sbrad 3398f3ca02Sbrad/* Define to 1 if you have the `arc4random_uniform' function. */ 3498f3ca02Sbrad#undef HAVE_ARC4RANDOM_UNIFORM 3598f3ca02Sbrad 36933707f3Ssthen/* Define to 1 if you have the <arpa/inet.h> header file. */ 37933707f3Ssthen#undef HAVE_ARPA_INET_H 38933707f3Ssthen 39933707f3Ssthen/* Whether the C compiler accepts the "format" attribute */ 40933707f3Ssthen#undef HAVE_ATTR_FORMAT 41933707f3Ssthen 42933707f3Ssthen/* Whether the C compiler accepts the "unused" attribute */ 43933707f3Ssthen#undef HAVE_ATTR_UNUSED 44933707f3Ssthen 45b2cdf21fSsthen/* Define to 1 if you have the `chown' function. */ 46933707f3Ssthen#undef HAVE_CHOWN 47933707f3Ssthen 48933707f3Ssthen/* Define to 1 if you have the `chroot' function. */ 49933707f3Ssthen#undef HAVE_CHROOT 50933707f3Ssthen 51933707f3Ssthen/* Define to 1 if you have the `ctime_r' function. */ 52933707f3Ssthen#undef HAVE_CTIME_R 53933707f3Ssthen 54933707f3Ssthen/* Define to 1 if you have the `daemon' function. */ 55933707f3Ssthen#undef HAVE_DAEMON 56933707f3Ssthen 5798f3ca02Sbrad/* Define to 1 if you have the declaration of `arc4random', and to 0 if you 5898f3ca02Sbrad don't. */ 5998f3ca02Sbrad#undef HAVE_DECL_ARC4RANDOM 6098f3ca02Sbrad 6198f3ca02Sbrad/* Define to 1 if you have the declaration of `arc4random_uniform', and to 0 6298f3ca02Sbrad if you don't. */ 6398f3ca02Sbrad#undef HAVE_DECL_ARC4RANDOM_UNIFORM 6498f3ca02Sbrad 65d8d14d0cSsthen/* Define to 1 if you have the declaration of `NID_secp384r1', and to 0 if you 66d8d14d0cSsthen don't. */ 67d8d14d0cSsthen#undef HAVE_DECL_NID_SECP384R1 68d8d14d0cSsthen 69d8d14d0cSsthen/* Define to 1 if you have the declaration of `NID_X9_62_prime256v1', and to 0 70d8d14d0cSsthen if you don't. */ 71d8d14d0cSsthen#undef HAVE_DECL_NID_X9_62_PRIME256V1 72d8d14d0cSsthen 73fdfb4ba6Ssthen/* Define to 1 if you have the declaration of `reallocarray', and to 0 if you 74fdfb4ba6Ssthen don't. */ 75fdfb4ba6Ssthen#undef HAVE_DECL_REALLOCARRAY 76fdfb4ba6Ssthen 77933707f3Ssthen/* Define to 1 if you have the declaration of `sk_SSL_COMP_pop_free', and to 0 78933707f3Ssthen if you don't. */ 79933707f3Ssthen#undef HAVE_DECL_SK_SSL_COMP_POP_FREE 80933707f3Ssthen 81933707f3Ssthen/* Define to 1 if you have the declaration of 82933707f3Ssthen `SSL_COMP_get_compression_methods', and to 0 if you don't. */ 83933707f3Ssthen#undef HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS 84933707f3Ssthen 85a961b961Ssthen/* Define to 1 if you have the declaration of `SSL_CTX_set_ecdh_auto', and to 86a961b961Ssthen 0 if you don't. */ 87a961b961Ssthen#undef HAVE_DECL_SSL_CTX_SET_ECDH_AUTO 88a961b961Ssthen 8998f3ca02Sbrad/* Define to 1 if you have the declaration of `strlcat', and to 0 if you 9098f3ca02Sbrad don't. */ 9198f3ca02Sbrad#undef HAVE_DECL_STRLCAT 9298f3ca02Sbrad 9398f3ca02Sbrad/* Define to 1 if you have the declaration of `strlcpy', and to 0 if you 9498f3ca02Sbrad don't. */ 9598f3ca02Sbrad#undef HAVE_DECL_STRLCPY 9698f3ca02Sbrad 9724893edcSsthen/* Define to 1 if you have the declaration of `XML_StopParser', and to 0 if 9824893edcSsthen you don't. */ 9924893edcSsthen#undef HAVE_DECL_XML_STOPPARSER 10024893edcSsthen 101933707f3Ssthen/* Define to 1 if you have the <dlfcn.h> header file. */ 102933707f3Ssthen#undef HAVE_DLFCN_H 103933707f3Ssthen 10498f3ca02Sbrad/* Define to 1 if you have the <endian.h> header file. */ 10598f3ca02Sbrad#undef HAVE_ENDIAN_H 10698f3ca02Sbrad 1075d76a658Ssthen/* Define to 1 if you have the `endprotoent' function. */ 1085d76a658Ssthen#undef HAVE_ENDPROTOENT 1095d76a658Ssthen 1105d76a658Ssthen/* Define to 1 if you have the `endservent' function. */ 1115d76a658Ssthen#undef HAVE_ENDSERVENT 1125d76a658Ssthen 113933707f3Ssthen/* Define to 1 if you have the `event_base_free' function. */ 114933707f3Ssthen#undef HAVE_EVENT_BASE_FREE 115933707f3Ssthen 116933707f3Ssthen/* Define to 1 if you have the `event_base_get_method' function. */ 117933707f3Ssthen#undef HAVE_EVENT_BASE_GET_METHOD 118933707f3Ssthen 119933707f3Ssthen/* Define to 1 if you have the `event_base_new' function. */ 120933707f3Ssthen#undef HAVE_EVENT_BASE_NEW 121933707f3Ssthen 122933707f3Ssthen/* Define to 1 if you have the `event_base_once' function. */ 123933707f3Ssthen#undef HAVE_EVENT_BASE_ONCE 124933707f3Ssthen 125933707f3Ssthen/* Define to 1 if you have the <event.h> header file. */ 126933707f3Ssthen#undef HAVE_EVENT_H 127933707f3Ssthen 128933707f3Ssthen/* Define to 1 if you have the `EVP_sha1' function. */ 129933707f3Ssthen#undef HAVE_EVP_SHA1 130933707f3Ssthen 131933707f3Ssthen/* Define to 1 if you have the `EVP_sha256' function. */ 132933707f3Ssthen#undef HAVE_EVP_SHA256 133933707f3Ssthen 134933707f3Ssthen/* Define to 1 if you have the `EVP_sha512' function. */ 135933707f3Ssthen#undef HAVE_EVP_SHA512 136933707f3Ssthen 137933707f3Ssthen/* Define to 1 if you have the `ev_default_loop' function. */ 138933707f3Ssthen#undef HAVE_EV_DEFAULT_LOOP 139933707f3Ssthen 140933707f3Ssthen/* Define to 1 if you have the `ev_loop' function. */ 141933707f3Ssthen#undef HAVE_EV_LOOP 142933707f3Ssthen 143933707f3Ssthen/* Define to 1 if you have the <expat.h> header file. */ 144933707f3Ssthen#undef HAVE_EXPAT_H 145933707f3Ssthen 146933707f3Ssthen/* Define to 1 if you have the `fcntl' function. */ 147933707f3Ssthen#undef HAVE_FCNTL 148933707f3Ssthen 1493dcb24b8Ssthen/* Define to 1 if you have the `FIPS_mode' function. */ 1503dcb24b8Ssthen#undef HAVE_FIPS_MODE 1513dcb24b8Ssthen 152933707f3Ssthen/* Define to 1 if you have the `fork' function. */ 153933707f3Ssthen#undef HAVE_FORK 154933707f3Ssthen 155933707f3Ssthen/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */ 156933707f3Ssthen#undef HAVE_FSEEKO 157933707f3Ssthen 15824893edcSsthen/* Define to 1 if you have the `fsync' function. */ 15924893edcSsthen#undef HAVE_FSYNC 16024893edcSsthen 161933707f3Ssthen/* Whether getaddrinfo is available */ 162933707f3Ssthen#undef HAVE_GETADDRINFO 163933707f3Ssthen 164b2cdf21fSsthen/* Define to 1 if you have the `getauxval' function. */ 165b2cdf21fSsthen#undef HAVE_GETAUXVAL 166b2cdf21fSsthen 16798f3ca02Sbrad/* Define to 1 if you have the `getentropy' function. */ 16898f3ca02Sbrad#undef HAVE_GETENTROPY 16998f3ca02Sbrad 170933707f3Ssthen/* Define to 1 if you have the <getopt.h> header file. */ 171933707f3Ssthen#undef HAVE_GETOPT_H 172933707f3Ssthen 173933707f3Ssthen/* Define to 1 if you have the `getpwnam' function. */ 174933707f3Ssthen#undef HAVE_GETPWNAM 175933707f3Ssthen 176933707f3Ssthen/* Define to 1 if you have the `getrlimit' function. */ 177933707f3Ssthen#undef HAVE_GETRLIMIT 178933707f3Ssthen 179933707f3Ssthen/* Define to 1 if you have the `glob' function. */ 180933707f3Ssthen#undef HAVE_GLOB 181933707f3Ssthen 182933707f3Ssthen/* Define to 1 if you have the <glob.h> header file. */ 183933707f3Ssthen#undef HAVE_GLOB_H 184933707f3Ssthen 185933707f3Ssthen/* Define to 1 if you have the `gmtime_r' function. */ 186933707f3Ssthen#undef HAVE_GMTIME_R 187933707f3Ssthen 188933707f3Ssthen/* Define to 1 if you have the <grp.h> header file. */ 189933707f3Ssthen#undef HAVE_GRP_H 190933707f3Ssthen 191933707f3Ssthen/* If you have HMAC_CTX_init */ 192933707f3Ssthen#undef HAVE_HMAC_CTX_INIT 193933707f3Ssthen 194933707f3Ssthen/* Define to 1 if you have the `inet_aton' function. */ 195933707f3Ssthen#undef HAVE_INET_ATON 196933707f3Ssthen 197933707f3Ssthen/* Define to 1 if you have the `inet_ntop' function. */ 198933707f3Ssthen#undef HAVE_INET_NTOP 199933707f3Ssthen 200933707f3Ssthen/* Define to 1 if you have the `inet_pton' function. */ 201933707f3Ssthen#undef HAVE_INET_PTON 202933707f3Ssthen 203933707f3Ssthen/* Define to 1 if you have the `initgroups' function. */ 204933707f3Ssthen#undef HAVE_INITGROUPS 205933707f3Ssthen 206933707f3Ssthen/* Define to 1 if you have the <inttypes.h> header file. */ 207933707f3Ssthen#undef HAVE_INTTYPES_H 208933707f3Ssthen 209933707f3Ssthen/* if the function 'ioctlsocket' is available */ 210933707f3Ssthen#undef HAVE_IOCTLSOCKET 211933707f3Ssthen 212933707f3Ssthen/* Define to 1 if you have the <iphlpapi.h> header file. */ 213933707f3Ssthen#undef HAVE_IPHLPAPI_H 214933707f3Ssthen 21524893edcSsthen/* Define to 1 if you have the `isblank' function. */ 21624893edcSsthen#undef HAVE_ISBLANK 21724893edcSsthen 218933707f3Ssthen/* Define to 1 if you have the `kill' function. */ 219933707f3Ssthen#undef HAVE_KILL 220933707f3Ssthen 22198f3ca02Sbrad/* Define if we have LibreSSL */ 22298f3ca02Sbrad#undef HAVE_LIBRESSL 22398f3ca02Sbrad 224933707f3Ssthen/* Define to 1 if you have the `localtime_r' function. */ 225933707f3Ssthen#undef HAVE_LOCALTIME_R 226933707f3Ssthen 227933707f3Ssthen/* Define to 1 if you have the <login_cap.h> header file. */ 228933707f3Ssthen#undef HAVE_LOGIN_CAP_H 229933707f3Ssthen 230933707f3Ssthen/* If have GNU libc compatible malloc */ 231933707f3Ssthen#undef HAVE_MALLOC 232933707f3Ssthen 233933707f3Ssthen/* Define to 1 if you have the `memmove' function. */ 234933707f3Ssthen#undef HAVE_MEMMOVE 235933707f3Ssthen 236933707f3Ssthen/* Define to 1 if you have the <memory.h> header file. */ 237933707f3Ssthen#undef HAVE_MEMORY_H 238933707f3Ssthen 239933707f3Ssthen/* Define to 1 if you have the <netdb.h> header file. */ 240933707f3Ssthen#undef HAVE_NETDB_H 241933707f3Ssthen 242933707f3Ssthen/* Define to 1 if you have the <netinet/in.h> header file. */ 243933707f3Ssthen#undef HAVE_NETINET_IN_H 244933707f3Ssthen 245*32e31f52Ssthen/* Define to 1 if you have the <netinet/tcp.h> header file. */ 246*32e31f52Ssthen#undef HAVE_NETINET_TCP_H 247*32e31f52Ssthen 24824893edcSsthen/* Use libnettle for crypto */ 24924893edcSsthen#undef HAVE_NETTLE 25024893edcSsthen 2513dcb24b8Ssthen/* Use libnss for crypto */ 2523dcb24b8Ssthen#undef HAVE_NSS 2533dcb24b8Ssthen 254933707f3Ssthen/* Define to 1 if you have the `OPENSSL_config' function. */ 255933707f3Ssthen#undef HAVE_OPENSSL_CONFIG 256933707f3Ssthen 257933707f3Ssthen/* Define to 1 if you have the <openssl/conf.h> header file. */ 258933707f3Ssthen#undef HAVE_OPENSSL_CONF_H 259933707f3Ssthen 260933707f3Ssthen/* Define to 1 if you have the <openssl/engine.h> header file. */ 261933707f3Ssthen#undef HAVE_OPENSSL_ENGINE_H 262933707f3Ssthen 263933707f3Ssthen/* Define to 1 if you have the <openssl/err.h> header file. */ 264933707f3Ssthen#undef HAVE_OPENSSL_ERR_H 265933707f3Ssthen 266933707f3Ssthen/* Define to 1 if you have the <openssl/rand.h> header file. */ 267933707f3Ssthen#undef HAVE_OPENSSL_RAND_H 268933707f3Ssthen 269933707f3Ssthen/* Define to 1 if you have the <openssl/ssl.h> header file. */ 270933707f3Ssthen#undef HAVE_OPENSSL_SSL_H 271933707f3Ssthen 272933707f3Ssthen/* Define if you have POSIX threads libraries and header files. */ 273933707f3Ssthen#undef HAVE_PTHREAD 274933707f3Ssthen 275229e174cSsthen/* Have PTHREAD_PRIO_INHERIT. */ 276229e174cSsthen#undef HAVE_PTHREAD_PRIO_INHERIT 277229e174cSsthen 278933707f3Ssthen/* Define to 1 if the system has the type `pthread_rwlock_t'. */ 279933707f3Ssthen#undef HAVE_PTHREAD_RWLOCK_T 280933707f3Ssthen 281933707f3Ssthen/* Define to 1 if the system has the type `pthread_spinlock_t'. */ 282933707f3Ssthen#undef HAVE_PTHREAD_SPINLOCK_T 283933707f3Ssthen 284933707f3Ssthen/* Define to 1 if you have the <pwd.h> header file. */ 285933707f3Ssthen#undef HAVE_PWD_H 286933707f3Ssthen 287933707f3Ssthen/* Define if you have Python libraries and header files. */ 288933707f3Ssthen#undef HAVE_PYTHON 289933707f3Ssthen 290933707f3Ssthen/* Define to 1 if you have the `random' function. */ 291933707f3Ssthen#undef HAVE_RANDOM 292933707f3Ssthen 293fdfb4ba6Ssthen/* Define to 1 if you have the `reallocarray' function. */ 294fdfb4ba6Ssthen#undef HAVE_REALLOCARRAY 295fdfb4ba6Ssthen 296933707f3Ssthen/* Define to 1 if you have the `recvmsg' function. */ 297933707f3Ssthen#undef HAVE_RECVMSG 298933707f3Ssthen 299*32e31f52Ssthen/* define if you have the sbrk() call */ 300933707f3Ssthen#undef HAVE_SBRK 301933707f3Ssthen 302933707f3Ssthen/* Define to 1 if you have the `sendmsg' function. */ 303933707f3Ssthen#undef HAVE_SENDMSG 304933707f3Ssthen 305933707f3Ssthen/* Define to 1 if you have the `setregid' function. */ 306933707f3Ssthen#undef HAVE_SETREGID 307933707f3Ssthen 308933707f3Ssthen/* Define to 1 if you have the `setresgid' function. */ 309933707f3Ssthen#undef HAVE_SETRESGID 310933707f3Ssthen 311933707f3Ssthen/* Define to 1 if you have the `setresuid' function. */ 312933707f3Ssthen#undef HAVE_SETRESUID 313933707f3Ssthen 314933707f3Ssthen/* Define to 1 if you have the `setreuid' function. */ 315933707f3Ssthen#undef HAVE_SETREUID 316933707f3Ssthen 317933707f3Ssthen/* Define to 1 if you have the `setrlimit' function. */ 318933707f3Ssthen#undef HAVE_SETRLIMIT 319933707f3Ssthen 320933707f3Ssthen/* Define to 1 if you have the `setsid' function. */ 321933707f3Ssthen#undef HAVE_SETSID 322933707f3Ssthen 323933707f3Ssthen/* Define to 1 if you have the `setusercontext' function. */ 324933707f3Ssthen#undef HAVE_SETUSERCONTEXT 325933707f3Ssthen 32698f3ca02Sbrad/* Define to 1 if you have the `SHA512_Update' function. */ 32798f3ca02Sbrad#undef HAVE_SHA512_UPDATE 32898f3ca02Sbrad 329933707f3Ssthen/* Define to 1 if you have the `sigprocmask' function. */ 330933707f3Ssthen#undef HAVE_SIGPROCMASK 331933707f3Ssthen 332933707f3Ssthen/* Define to 1 if you have the `sleep' function. */ 333933707f3Ssthen#undef HAVE_SLEEP 334933707f3Ssthen 335933707f3Ssthen/* Define to 1 if you have the `snprintf' function. */ 336933707f3Ssthen#undef HAVE_SNPRINTF 337933707f3Ssthen 338933707f3Ssthen/* Define to 1 if you have the `socketpair' function. */ 339933707f3Ssthen#undef HAVE_SOCKETPAIR 340933707f3Ssthen 341933707f3Ssthen/* Using Solaris threads */ 342933707f3Ssthen#undef HAVE_SOLARIS_THREADS 343933707f3Ssthen 344933707f3Ssthen/* Define to 1 if you have the `srandom' function. */ 345933707f3Ssthen#undef HAVE_SRANDOM 346933707f3Ssthen 347933707f3Ssthen/* Define if you have the SSL libraries installed. */ 348933707f3Ssthen#undef HAVE_SSL 349933707f3Ssthen 350933707f3Ssthen/* Define to 1 if you have the <stdarg.h> header file. */ 351933707f3Ssthen#undef HAVE_STDARG_H 352933707f3Ssthen 353933707f3Ssthen/* Define to 1 if you have the <stdbool.h> header file. */ 354933707f3Ssthen#undef HAVE_STDBOOL_H 355933707f3Ssthen 356933707f3Ssthen/* Define to 1 if you have the <stdint.h> header file. */ 357933707f3Ssthen#undef HAVE_STDINT_H 358933707f3Ssthen 359933707f3Ssthen/* Define to 1 if you have the <stdlib.h> header file. */ 360933707f3Ssthen#undef HAVE_STDLIB_H 361933707f3Ssthen 362933707f3Ssthen/* Define to 1 if you have the `strftime' function. */ 363933707f3Ssthen#undef HAVE_STRFTIME 364933707f3Ssthen 365933707f3Ssthen/* Define to 1 if you have the <strings.h> header file. */ 366933707f3Ssthen#undef HAVE_STRINGS_H 367933707f3Ssthen 368933707f3Ssthen/* Define to 1 if you have the <string.h> header file. */ 369933707f3Ssthen#undef HAVE_STRING_H 370933707f3Ssthen 3715d76a658Ssthen/* Define to 1 if you have the `strlcat' function. */ 3725d76a658Ssthen#undef HAVE_STRLCAT 3735d76a658Ssthen 374933707f3Ssthen/* Define to 1 if you have the `strlcpy' function. */ 375933707f3Ssthen#undef HAVE_STRLCPY 376933707f3Ssthen 377933707f3Ssthen/* Define to 1 if you have the `strptime' function. */ 378933707f3Ssthen#undef HAVE_STRPTIME 379933707f3Ssthen 380d8d14d0cSsthen/* Define to 1 if `ipi_spec_dst' is a member of `struct in_pktinfo'. */ 381d8d14d0cSsthen#undef HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST 382d8d14d0cSsthen 383b2cdf21fSsthen/* Define to 1 if `sun_len' is a member of `struct sockaddr_un'. */ 384b2cdf21fSsthen#undef HAVE_STRUCT_SOCKADDR_UN_SUN_LEN 385b2cdf21fSsthen 386933707f3Ssthen/* Define if you have Swig libraries and header files. */ 387933707f3Ssthen#undef HAVE_SWIG 388933707f3Ssthen 389933707f3Ssthen/* Define to 1 if you have the <syslog.h> header file. */ 390933707f3Ssthen#undef HAVE_SYSLOG_H 391933707f3Ssthen 392933707f3Ssthen/* Define to 1 if you have the <sys/param.h> header file. */ 393933707f3Ssthen#undef HAVE_SYS_PARAM_H 394933707f3Ssthen 395933707f3Ssthen/* Define to 1 if you have the <sys/resource.h> header file. */ 396933707f3Ssthen#undef HAVE_SYS_RESOURCE_H 397933707f3Ssthen 39898f3ca02Sbrad/* Define to 1 if you have the <sys/sha2.h> header file. */ 39998f3ca02Sbrad#undef HAVE_SYS_SHA2_H 40098f3ca02Sbrad 401933707f3Ssthen/* Define to 1 if you have the <sys/socket.h> header file. */ 402933707f3Ssthen#undef HAVE_SYS_SOCKET_H 403933707f3Ssthen 404933707f3Ssthen/* Define to 1 if you have the <sys/stat.h> header file. */ 405933707f3Ssthen#undef HAVE_SYS_STAT_H 406933707f3Ssthen 40798f3ca02Sbrad/* Define to 1 if you have the <sys/sysctl.h> header file. */ 40898f3ca02Sbrad#undef HAVE_SYS_SYSCTL_H 40998f3ca02Sbrad 410933707f3Ssthen/* Define to 1 if you have the <sys/types.h> header file. */ 411933707f3Ssthen#undef HAVE_SYS_TYPES_H 412933707f3Ssthen 413933707f3Ssthen/* Define to 1 if you have the <sys/uio.h> header file. */ 414933707f3Ssthen#undef HAVE_SYS_UIO_H 415933707f3Ssthen 416b2cdf21fSsthen/* Define to 1 if you have the <sys/un.h> header file. */ 417b2cdf21fSsthen#undef HAVE_SYS_UN_H 418b2cdf21fSsthen 419933707f3Ssthen/* Define to 1 if you have the <sys/wait.h> header file. */ 420933707f3Ssthen#undef HAVE_SYS_WAIT_H 421933707f3Ssthen 422933707f3Ssthen/* Define to 1 if you have the <time.h> header file. */ 423933707f3Ssthen#undef HAVE_TIME_H 424933707f3Ssthen 425933707f3Ssthen/* Define to 1 if you have the `tzset' function. */ 426933707f3Ssthen#undef HAVE_TZSET 427933707f3Ssthen 428933707f3Ssthen/* Define to 1 if you have the <unistd.h> header file. */ 429933707f3Ssthen#undef HAVE_UNISTD_H 430933707f3Ssthen 431933707f3Ssthen/* Define to 1 if you have the `usleep' function. */ 432933707f3Ssthen#undef HAVE_USLEEP 433933707f3Ssthen 434933707f3Ssthen/* Define to 1 if you have the `vfork' function. */ 435933707f3Ssthen#undef HAVE_VFORK 436933707f3Ssthen 437933707f3Ssthen/* Define to 1 if you have the <vfork.h> header file. */ 438933707f3Ssthen#undef HAVE_VFORK_H 439933707f3Ssthen 440933707f3Ssthen/* Define to 1 if you have the <windows.h> header file. */ 441933707f3Ssthen#undef HAVE_WINDOWS_H 442933707f3Ssthen 443933707f3Ssthen/* Using Windows threads */ 444933707f3Ssthen#undef HAVE_WINDOWS_THREADS 445933707f3Ssthen 446933707f3Ssthen/* Define to 1 if you have the <winsock2.h> header file. */ 447933707f3Ssthen#undef HAVE_WINSOCK2_H 448933707f3Ssthen 449933707f3Ssthen/* Define to 1 if `fork' works. */ 450933707f3Ssthen#undef HAVE_WORKING_FORK 451933707f3Ssthen 452933707f3Ssthen/* Define to 1 if `vfork' works. */ 453933707f3Ssthen#undef HAVE_WORKING_VFORK 454933707f3Ssthen 455933707f3Ssthen/* Define to 1 if you have the `writev' function. */ 456933707f3Ssthen#undef HAVE_WRITEV 457933707f3Ssthen 458933707f3Ssthen/* Define to 1 if you have the <ws2tcpip.h> header file. */ 459933707f3Ssthen#undef HAVE_WS2TCPIP_H 460933707f3Ssthen 461933707f3Ssthen/* Define to 1 if you have the `_beginthreadex' function. */ 462933707f3Ssthen#undef HAVE__BEGINTHREADEX 463933707f3Ssthen 464933707f3Ssthen/* if lex has yylex_destroy */ 465933707f3Ssthen#undef LEX_HAS_YYLEX_DESTROY 466933707f3Ssthen 467*32e31f52Ssthen/* Define to the sub-directory where libtool stores uninstalled libraries. */ 468933707f3Ssthen#undef LT_OBJDIR 469933707f3Ssthen 470933707f3Ssthen/* Define to the maximum message length to pass to syslog. */ 471933707f3Ssthen#undef MAXSYSLOGMSGLEN 472933707f3Ssthen 473933707f3Ssthen/* Define if memcmp() does not compare unsigned bytes */ 474933707f3Ssthen#undef MEMCMP_IS_BROKEN 475933707f3Ssthen 476933707f3Ssthen/* Define if mkdir has one argument. */ 477933707f3Ssthen#undef MKDIR_HAS_ONE_ARG 478933707f3Ssthen 479933707f3Ssthen/* Define if the network stack does not fully support nonblocking io (causes 480933707f3Ssthen lower performance). */ 481933707f3Ssthen#undef NONBLOCKING_IS_BROKEN 482933707f3Ssthen 483933707f3Ssthen/* Put -D_ALL_SOURCE define in config.h */ 484933707f3Ssthen#undef OMITTED__D_ALL_SOURCE 485933707f3Ssthen 486933707f3Ssthen/* Put -D_BSD_SOURCE define in config.h */ 487933707f3Ssthen#undef OMITTED__D_BSD_SOURCE 488933707f3Ssthen 489*32e31f52Ssthen/* Put -D_DEFAULT_SOURCE define in config.h */ 490*32e31f52Ssthen#undef OMITTED__D_DEFAULT_SOURCE 491*32e31f52Ssthen 492933707f3Ssthen/* Put -D_GNU_SOURCE define in config.h */ 493933707f3Ssthen#undef OMITTED__D_GNU_SOURCE 494933707f3Ssthen 495933707f3Ssthen/* Put -D_LARGEFILE_SOURCE=1 define in config.h */ 496933707f3Ssthen#undef OMITTED__D_LARGEFILE_SOURCE_1 497933707f3Ssthen 498933707f3Ssthen/* Put -D_POSIX_C_SOURCE=200112 define in config.h */ 499933707f3Ssthen#undef OMITTED__D_POSIX_C_SOURCE_200112 500933707f3Ssthen 501933707f3Ssthen/* Put -D_XOPEN_SOURCE=600 define in config.h */ 502933707f3Ssthen#undef OMITTED__D_XOPEN_SOURCE_600 503933707f3Ssthen 504933707f3Ssthen/* Put -D_XOPEN_SOURCE_EXTENDED=1 define in config.h */ 505933707f3Ssthen#undef OMITTED__D_XOPEN_SOURCE_EXTENDED_1 506933707f3Ssthen 507933707f3Ssthen/* Put -D__EXTENSIONS__ define in config.h */ 508933707f3Ssthen#undef OMITTED__D__EXTENSIONS__ 509933707f3Ssthen 510933707f3Ssthen/* Define to the address where bug reports for this package should be sent. */ 511933707f3Ssthen#undef PACKAGE_BUGREPORT 512933707f3Ssthen 513933707f3Ssthen/* Define to the full name of this package. */ 514933707f3Ssthen#undef PACKAGE_NAME 515933707f3Ssthen 516933707f3Ssthen/* Define to the full name and version of this package. */ 517933707f3Ssthen#undef PACKAGE_STRING 518933707f3Ssthen 519933707f3Ssthen/* Define to the one symbol short name of this package. */ 520933707f3Ssthen#undef PACKAGE_TARNAME 521933707f3Ssthen 522933707f3Ssthen/* Define to the home page for this package. */ 523933707f3Ssthen#undef PACKAGE_URL 524933707f3Ssthen 525933707f3Ssthen/* Define to the version of this package. */ 526933707f3Ssthen#undef PACKAGE_VERSION 527933707f3Ssthen 528933707f3Ssthen/* default pidfile location */ 529933707f3Ssthen#undef PIDFILE 530933707f3Ssthen 531933707f3Ssthen/* Define to necessary symbol if this constant uses a non-standard name on 532933707f3Ssthen your system. */ 533933707f3Ssthen#undef PTHREAD_CREATE_JOINABLE 534933707f3Ssthen 535933707f3Ssthen/* Define as the return type of signal handlers (`int' or `void'). */ 536933707f3Ssthen#undef RETSIGTYPE 537933707f3Ssthen 538933707f3Ssthen/* default rootkey location */ 539933707f3Ssthen#undef ROOT_ANCHOR_FILE 540933707f3Ssthen 541933707f3Ssthen/* default rootcert location */ 542933707f3Ssthen#undef ROOT_CERT_FILE 543933707f3Ssthen 544933707f3Ssthen/* version number for resource files */ 545933707f3Ssthen#undef RSRC_PACKAGE_VERSION 546933707f3Ssthen 547933707f3Ssthen/* Directory to chdir to */ 548933707f3Ssthen#undef RUN_DIR 549933707f3Ssthen 550933707f3Ssthen/* Shared data */ 551933707f3Ssthen#undef SHARE_DIR 552933707f3Ssthen 5535d76a658Ssthen/* The size of `time_t', as computed by sizeof. */ 5545d76a658Ssthen#undef SIZEOF_TIME_T 5555d76a658Ssthen 55624893edcSsthen/* define if (v)snprintf does not return length needed, (but length used) */ 55724893edcSsthen#undef SNPRINTF_RET_BROKEN 55824893edcSsthen 559933707f3Ssthen/* Define to 1 if you have the ANSI C header files. */ 560933707f3Ssthen#undef STDC_HEADERS 561933707f3Ssthen 562933707f3Ssthen/* use default strptime. */ 563933707f3Ssthen#undef STRPTIME_WORKS 564933707f3Ssthen 565933707f3Ssthen/* Use win32 resources and API */ 566933707f3Ssthen#undef UB_ON_WINDOWS 567933707f3Ssthen 568933707f3Ssthen/* default username */ 569933707f3Ssthen#undef UB_USERNAME 570933707f3Ssthen 571933707f3Ssthen/* use to enable lightweight alloc assertions, for debug use */ 572933707f3Ssthen#undef UNBOUND_ALLOC_LITE 573933707f3Ssthen 574933707f3Ssthen/* use malloc not regions, for debug use */ 575933707f3Ssthen#undef UNBOUND_ALLOC_NONREGIONAL 576933707f3Ssthen 577933707f3Ssthen/* use statistics for allocs and frees, for debug use */ 578933707f3Ssthen#undef UNBOUND_ALLOC_STATS 579933707f3Ssthen 580933707f3Ssthen/* define this to enable debug checks. */ 581933707f3Ssthen#undef UNBOUND_DEBUG 582933707f3Ssthen 58398f3ca02Sbrad/* Define to 1 to enable dnstap support */ 58498f3ca02Sbrad#undef USE_DNSTAP 58598f3ca02Sbrad 586d8d14d0cSsthen/* Define this to enable ECDSA support. */ 587d8d14d0cSsthen#undef USE_ECDSA 588d8d14d0cSsthen 589d8d14d0cSsthen/* Define this to enable an EVP workaround for older openssl */ 590d8d14d0cSsthen#undef USE_ECDSA_EVP_WORKAROUND 591d8d14d0cSsthen 592933707f3Ssthen/* Define this to enable GOST support. */ 593933707f3Ssthen#undef USE_GOST 594933707f3Ssthen 595933707f3Ssthen/* Define if you want to use internal select based events */ 596933707f3Ssthen#undef USE_MINI_EVENT 597933707f3Ssthen 598933707f3Ssthen/* Define this to enable SHA256 and SHA512 support. */ 599933707f3Ssthen#undef USE_SHA2 600933707f3Ssthen 601933707f3Ssthen/* Enable extensions on AIX 3, Interix. */ 602933707f3Ssthen#ifndef _ALL_SOURCE 603933707f3Ssthen# undef _ALL_SOURCE 604933707f3Ssthen#endif 605933707f3Ssthen/* Enable GNU extensions on systems that have them. */ 606933707f3Ssthen#ifndef _GNU_SOURCE 607933707f3Ssthen# undef _GNU_SOURCE 608933707f3Ssthen#endif 609933707f3Ssthen/* Enable threading extensions on Solaris. */ 610933707f3Ssthen#ifndef _POSIX_PTHREAD_SEMANTICS 611933707f3Ssthen# undef _POSIX_PTHREAD_SEMANTICS 612933707f3Ssthen#endif 613933707f3Ssthen/* Enable extensions on HP NonStop. */ 614933707f3Ssthen#ifndef _TANDEM_SOURCE 615933707f3Ssthen# undef _TANDEM_SOURCE 616933707f3Ssthen#endif 617933707f3Ssthen/* Enable general extensions on Solaris. */ 618933707f3Ssthen#ifndef __EXTENSIONS__ 619933707f3Ssthen# undef __EXTENSIONS__ 620933707f3Ssthen#endif 621933707f3Ssthen 622933707f3Ssthen 623933707f3Ssthen/* Whether the windows socket API is used */ 624933707f3Ssthen#undef USE_WINSOCK 625933707f3Ssthen 626933707f3Ssthen/* the version of the windows API enabled */ 627933707f3Ssthen#undef WINVER 628933707f3Ssthen 629933707f3Ssthen/* Define if you want Python module. */ 630933707f3Ssthen#undef WITH_PYTHONMODULE 631933707f3Ssthen 632933707f3Ssthen/* Define if you want PyUnbound. */ 633933707f3Ssthen#undef WITH_PYUNBOUND 634933707f3Ssthen 635933707f3Ssthen/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a 636933707f3Ssthen `char[]'. */ 637933707f3Ssthen#undef YYTEXT_POINTER 638933707f3Ssthen 639229e174cSsthen/* Enable large inode numbers on Mac OS X 10.5. */ 640229e174cSsthen#ifndef _DARWIN_USE_64_BIT_INODE 641229e174cSsthen# define _DARWIN_USE_64_BIT_INODE 1 642229e174cSsthen#endif 643229e174cSsthen 644933707f3Ssthen/* Number of bits in a file offset, on hosts where this is settable. */ 645933707f3Ssthen#undef _FILE_OFFSET_BITS 646933707f3Ssthen 647933707f3Ssthen/* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */ 648933707f3Ssthen#undef _LARGEFILE_SOURCE 649933707f3Ssthen 650933707f3Ssthen/* Define for large files, on AIX-style hosts. */ 651933707f3Ssthen#undef _LARGE_FILES 652933707f3Ssthen 653933707f3Ssthen/* Define to 1 if on MINIX. */ 654933707f3Ssthen#undef _MINIX 655933707f3Ssthen 6565d76a658Ssthen/* Enable for compile on Minix */ 6575d76a658Ssthen#undef _NETBSD_SOURCE 6585d76a658Ssthen 659933707f3Ssthen/* Define to 2 if the system does not provide POSIX.1 features except with 660933707f3Ssthen this defined. */ 661933707f3Ssthen#undef _POSIX_1_SOURCE 662933707f3Ssthen 663933707f3Ssthen/* Define to 1 if you need to in order for `stat' and other things to work. */ 664933707f3Ssthen#undef _POSIX_SOURCE 665933707f3Ssthen 666933707f3Ssthen/* Define to empty if `const' does not conform to ANSI C. */ 667933707f3Ssthen#undef const 668933707f3Ssthen 669933707f3Ssthen/* Define to `int' if <sys/types.h> doesn't define. */ 670933707f3Ssthen#undef gid_t 671933707f3Ssthen 672933707f3Ssthen/* in_addr_t */ 673933707f3Ssthen#undef in_addr_t 674933707f3Ssthen 675933707f3Ssthen/* in_port_t */ 676933707f3Ssthen#undef in_port_t 677933707f3Ssthen 678933707f3Ssthen/* Define to `__inline__' or `__inline' if that's what the C compiler 679933707f3Ssthen calls it, or to nothing if 'inline' is not supported under any name. */ 680933707f3Ssthen#ifndef __cplusplus 681933707f3Ssthen#undef inline 682933707f3Ssthen#endif 683933707f3Ssthen 684933707f3Ssthen/* Define to `short' if <sys/types.h> does not define. */ 685933707f3Ssthen#undef int16_t 686933707f3Ssthen 687933707f3Ssthen/* Define to `int' if <sys/types.h> does not define. */ 688933707f3Ssthen#undef int32_t 689933707f3Ssthen 690933707f3Ssthen/* Define to `long long' if <sys/types.h> does not define. */ 691933707f3Ssthen#undef int64_t 692933707f3Ssthen 693933707f3Ssthen/* Define to `signed char' if <sys/types.h> does not define. */ 694933707f3Ssthen#undef int8_t 695933707f3Ssthen 696933707f3Ssthen/* Define if replacement function should be used. */ 697933707f3Ssthen#undef malloc 698933707f3Ssthen 699933707f3Ssthen/* Define to `long int' if <sys/types.h> does not define. */ 700933707f3Ssthen#undef off_t 701933707f3Ssthen 702933707f3Ssthen/* Define to `int' if <sys/types.h> does not define. */ 703933707f3Ssthen#undef pid_t 704933707f3Ssthen 705933707f3Ssthen/* Define to 'int' if not defined */ 706933707f3Ssthen#undef rlim_t 707933707f3Ssthen 708933707f3Ssthen/* Define to `unsigned int' if <sys/types.h> does not define. */ 709933707f3Ssthen#undef size_t 710933707f3Ssthen 711933707f3Ssthen/* Define to 'int' if not defined */ 712933707f3Ssthen#undef socklen_t 713933707f3Ssthen 714933707f3Ssthen/* Define to `int' if <sys/types.h> does not define. */ 715933707f3Ssthen#undef ssize_t 716933707f3Ssthen 717933707f3Ssthen/* Define to 'unsigned char if not defined */ 718933707f3Ssthen#undef u_char 719933707f3Ssthen 720933707f3Ssthen/* Define to `int' if <sys/types.h> doesn't define. */ 721933707f3Ssthen#undef uid_t 722933707f3Ssthen 723933707f3Ssthen/* Define to `unsigned short' if <sys/types.h> does not define. */ 724933707f3Ssthen#undef uint16_t 725933707f3Ssthen 726933707f3Ssthen/* Define to `unsigned int' if <sys/types.h> does not define. */ 727933707f3Ssthen#undef uint32_t 728933707f3Ssthen 729933707f3Ssthen/* Define to `unsigned long long' if <sys/types.h> does not define. */ 730933707f3Ssthen#undef uint64_t 731933707f3Ssthen 732933707f3Ssthen/* Define to `unsigned char' if <sys/types.h> does not define. */ 733933707f3Ssthen#undef uint8_t 734933707f3Ssthen 735933707f3Ssthen/* Define as `fork' if `vfork' does not work. */ 736933707f3Ssthen#undef vfork 737933707f3Ssthen 738933707f3Ssthen#if defined(OMITTED__D_GNU_SOURCE) && !defined(_GNU_SOURCE) 739933707f3Ssthen#define _GNU_SOURCE 1 740933707f3Ssthen#endif 741933707f3Ssthen 742933707f3Ssthen#if defined(OMITTED__D_BSD_SOURCE) && !defined(_BSD_SOURCE) 743933707f3Ssthen#define _BSD_SOURCE 1 744933707f3Ssthen#endif 745933707f3Ssthen 746*32e31f52Ssthen#if defined(OMITTED__D_DEFAULT_SOURCE) && !defined(_DEFAULT_SOURCE) 747*32e31f52Ssthen#define _DEFAULT_SOURCE 1 748*32e31f52Ssthen#endif 749*32e31f52Ssthen 750933707f3Ssthen#if defined(OMITTED__D__EXTENSIONS__) && !defined(__EXTENSIONS__) 751933707f3Ssthen#define __EXTENSIONS__ 1 752933707f3Ssthen#endif 753933707f3Ssthen 754933707f3Ssthen#if defined(OMITTED__D_POSIX_C_SOURCE_200112) && !defined(_POSIX_C_SOURCE) 755933707f3Ssthen#define _POSIX_C_SOURCE 200112 756933707f3Ssthen#endif 757933707f3Ssthen 758933707f3Ssthen#if defined(OMITTED__D_XOPEN_SOURCE_600) && !defined(_XOPEN_SOURCE) 759933707f3Ssthen#define _XOPEN_SOURCE 600 760933707f3Ssthen#endif 761933707f3Ssthen 762933707f3Ssthen#if defined(OMITTED__D_XOPEN_SOURCE_EXTENDED_1) && !defined(_XOPEN_SOURCE_EXTENDED) 763933707f3Ssthen#define _XOPEN_SOURCE_EXTENDED 1 764933707f3Ssthen#endif 765933707f3Ssthen 766933707f3Ssthen#if defined(OMITTED__D_ALL_SOURCE) && !defined(_ALL_SOURCE) 767933707f3Ssthen#define _ALL_SOURCE 1 768933707f3Ssthen#endif 769933707f3Ssthen 770933707f3Ssthen#if defined(OMITTED__D_LARGEFILE_SOURCE_1) && !defined(_LARGEFILE_SOURCE) 771933707f3Ssthen#define _LARGEFILE_SOURCE 1 772933707f3Ssthen#endif 773933707f3Ssthen 774933707f3Ssthen 775933707f3Ssthen 776933707f3Ssthen 777933707f3Ssthen#ifndef UNBOUND_DEBUG 778933707f3Ssthen# define NDEBUG 779933707f3Ssthen#endif 780933707f3Ssthen 7815d76a658Ssthen/** Use small-ldns codebase */ 7825d76a658Ssthen#define USE_SLDNS 1 7835d76a658Ssthen#ifdef HAVE_SSL 7845d76a658Ssthen# define LDNS_BUILD_CONFIG_HAVE_SSL 1 7855d76a658Ssthen#endif 7865d76a658Ssthen 787933707f3Ssthen#include <stdio.h> 788933707f3Ssthen#include <string.h> 789933707f3Ssthen#include <unistd.h> 790933707f3Ssthen#include <assert.h> 791933707f3Ssthen 792933707f3Ssthen#if STDC_HEADERS 793933707f3Ssthen#include <stdlib.h> 794933707f3Ssthen#include <stddef.h> 795933707f3Ssthen#endif 796933707f3Ssthen 7975d76a658Ssthen#ifdef HAVE_STDARG_H 7985d76a658Ssthen#include <stdarg.h> 7995d76a658Ssthen#endif 8005d76a658Ssthen 801933707f3Ssthen#ifdef HAVE_STDINT_H 802933707f3Ssthen#include <stdint.h> 803933707f3Ssthen#endif 804933707f3Ssthen 805933707f3Ssthen#include <errno.h> 806933707f3Ssthen 807933707f3Ssthen#if HAVE_SYS_PARAM_H 808933707f3Ssthen#include <sys/param.h> 809933707f3Ssthen#endif 810933707f3Ssthen 811933707f3Ssthen#ifdef HAVE_SYS_SOCKET_H 812933707f3Ssthen#include <sys/socket.h> 813933707f3Ssthen#endif 814933707f3Ssthen 815933707f3Ssthen#ifdef HAVE_SYS_UIO_H 816933707f3Ssthen#include <sys/uio.h> 817933707f3Ssthen#endif 818933707f3Ssthen 819933707f3Ssthen#ifdef HAVE_NETINET_IN_H 820933707f3Ssthen#include <netinet/in.h> 821933707f3Ssthen#endif 822933707f3Ssthen 823*32e31f52Ssthen#ifdef HAVE_NETINET_TCP_H 824*32e31f52Ssthen#include <netinet/tcp.h> 825*32e31f52Ssthen#endif 826*32e31f52Ssthen 827933707f3Ssthen#ifdef HAVE_ARPA_INET_H 828933707f3Ssthen#include <arpa/inet.h> 829933707f3Ssthen#endif 830933707f3Ssthen 831933707f3Ssthen#ifdef HAVE_WINSOCK2_H 832933707f3Ssthen#include <winsock2.h> 833933707f3Ssthen#endif 834933707f3Ssthen 835933707f3Ssthen#ifdef HAVE_WS2TCPIP_H 836933707f3Ssthen#include <ws2tcpip.h> 837933707f3Ssthen#endif 838933707f3Ssthen 8395d76a658Ssthen#ifndef USE_WINSOCK 8405d76a658Ssthen#define ARG_LL "%ll" 8415d76a658Ssthen#else 8425d76a658Ssthen#define ARG_LL "%I64" 8435d76a658Ssthen#endif 8445d76a658Ssthen 845b2cdf21fSsthen#ifndef AF_LOCAL 846b2cdf21fSsthen#define AF_LOCAL AF_UNIX 847b2cdf21fSsthen#endif 848b2cdf21fSsthen 849933707f3Ssthen 850933707f3Ssthen 851933707f3Ssthen#ifdef HAVE_ATTR_FORMAT 852933707f3Ssthen# define ATTR_FORMAT(archetype, string_index, first_to_check) \ 853933707f3Ssthen __attribute__ ((format (archetype, string_index, first_to_check))) 854933707f3Ssthen#else /* !HAVE_ATTR_FORMAT */ 855933707f3Ssthen# define ATTR_FORMAT(archetype, string_index, first_to_check) /* empty */ 856933707f3Ssthen#endif /* !HAVE_ATTR_FORMAT */ 857933707f3Ssthen 858933707f3Ssthen 859933707f3Ssthen#if defined(DOXYGEN) 860933707f3Ssthen# define ATTR_UNUSED(x) x 861933707f3Ssthen#elif defined(__cplusplus) 862933707f3Ssthen# define ATTR_UNUSED(x) 863933707f3Ssthen#elif defined(HAVE_ATTR_UNUSED) 864933707f3Ssthen# define ATTR_UNUSED(x) x __attribute__((unused)) 865933707f3Ssthen#else /* !HAVE_ATTR_UNUSED */ 866933707f3Ssthen# define ATTR_UNUSED(x) x 867933707f3Ssthen#endif /* !HAVE_ATTR_UNUSED */ 868933707f3Ssthen 869933707f3Ssthen 870933707f3Ssthen#ifndef HAVE_FSEEKO 871933707f3Ssthen#define fseeko fseek 872933707f3Ssthen#define ftello ftell 873933707f3Ssthen#endif /* HAVE_FSEEKO */ 874933707f3Ssthen 875933707f3Ssthen 876933707f3Ssthen#ifndef MAXHOSTNAMELEN 877933707f3Ssthen#define MAXHOSTNAMELEN 256 878933707f3Ssthen#endif 879933707f3Ssthen 88024893edcSsthen#if !defined(HAVE_SNPRINTF) || defined(SNPRINTF_RET_BROKEN) 881933707f3Ssthen#define snprintf snprintf_unbound 882933707f3Ssthen#define vsnprintf vsnprintf_unbound 883933707f3Ssthen#include <stdarg.h> 884933707f3Ssthenint snprintf (char *str, size_t count, const char *fmt, ...); 885933707f3Ssthenint vsnprintf (char *str, size_t count, const char *fmt, va_list arg); 88624893edcSsthen#endif /* HAVE_SNPRINTF or SNPRINTF_RET_BROKEN */ 887933707f3Ssthen 888933707f3Ssthen#ifndef HAVE_INET_PTON 889933707f3Ssthen#define inet_pton inet_pton_unbound 890933707f3Ssthenint inet_pton(int af, const char* src, void* dst); 891933707f3Ssthen#endif /* HAVE_INET_PTON */ 892933707f3Ssthen 893933707f3Ssthen 894933707f3Ssthen#ifndef HAVE_INET_NTOP 895933707f3Ssthen#define inet_ntop inet_ntop_unbound 896933707f3Ssthenconst char *inet_ntop(int af, const void *src, char *dst, size_t size); 897933707f3Ssthen#endif 898933707f3Ssthen 899933707f3Ssthen 900933707f3Ssthen#ifndef HAVE_INET_ATON 901933707f3Ssthen#define inet_aton inet_aton_unbound 902933707f3Ssthenint inet_aton(const char *cp, struct in_addr *addr); 903933707f3Ssthen#endif 904933707f3Ssthen 905933707f3Ssthen 906933707f3Ssthen#ifndef HAVE_MEMMOVE 907933707f3Ssthen#define memmove memmove_unbound 908933707f3Ssthenvoid *memmove(void *dest, const void *src, size_t n); 909933707f3Ssthen#endif 910933707f3Ssthen 911933707f3Ssthen 9125d76a658Ssthen#ifndef HAVE_STRLCAT 9135d76a658Ssthen#define strlcat strlcat_unbound 9145d76a658Ssthensize_t strlcat(char *dst, const char *src, size_t siz); 9155d76a658Ssthen#endif 9165d76a658Ssthen 9175d76a658Ssthen 918933707f3Ssthen#ifndef HAVE_STRLCPY 919933707f3Ssthen#define strlcpy strlcpy_unbound 920933707f3Ssthensize_t strlcpy(char *dst, const char *src, size_t siz); 921933707f3Ssthen#endif 922933707f3Ssthen 923933707f3Ssthen 924933707f3Ssthen#ifndef HAVE_GMTIME_R 925933707f3Ssthen#define gmtime_r gmtime_r_unbound 926933707f3Ssthenstruct tm *gmtime_r(const time_t *timep, struct tm *result); 927933707f3Ssthen#endif 928933707f3Ssthen 929933707f3Ssthen 930fdfb4ba6Ssthen#ifndef HAVE_REALLOCARRAY 931fdfb4ba6Ssthen#define reallocarray reallocarrayunbound 932fdfb4ba6Ssthenvoid* reallocarray(void *ptr, size_t nmemb, size_t size); 933fdfb4ba6Ssthen#endif 934fdfb4ba6Ssthen 935fdfb4ba6Ssthen 936229e174cSsthen#if !defined(HAVE_SLEEP) || defined(HAVE_WINDOWS_H) 937933707f3Ssthen#define sleep(x) Sleep((x)*1000) /* on win32 */ 938933707f3Ssthen#endif /* HAVE_SLEEP */ 939933707f3Ssthen 940933707f3Ssthen 941933707f3Ssthen#ifndef HAVE_USLEEP 942933707f3Ssthen#define usleep(x) Sleep((x)/1000 + 1) /* on win32 */ 943933707f3Ssthen#endif /* HAVE_USLEEP */ 944933707f3Ssthen 945933707f3Ssthen 946933707f3Ssthen#ifndef HAVE_RANDOM 947933707f3Ssthen#define random rand /* on win32, for tests only (bad random) */ 948933707f3Ssthen#endif /* HAVE_RANDOM */ 949933707f3Ssthen 950933707f3Ssthen 951933707f3Ssthen#ifndef HAVE_SRANDOM 952933707f3Ssthen#define srandom(x) srand(x) /* on win32, for tests only (bad random) */ 953933707f3Ssthen#endif /* HAVE_SRANDOM */ 954933707f3Ssthen 955933707f3Ssthen 956933707f3Ssthen/* detect if we need to cast to unsigned int for FD_SET to avoid warnings */ 957933707f3Ssthen#ifdef HAVE_WINSOCK2_H 958933707f3Ssthen#define FD_SET_T (u_int) 959933707f3Ssthen#else 960933707f3Ssthen#define FD_SET_T 961933707f3Ssthen#endif 962933707f3Ssthen 963933707f3Ssthen 964933707f3Ssthen#ifndef IPV6_MIN_MTU 965933707f3Ssthen#define IPV6_MIN_MTU 1280 966933707f3Ssthen#endif /* IPV6_MIN_MTU */ 967933707f3Ssthen 968933707f3Ssthen 969933707f3Ssthen#ifdef MEMCMP_IS_BROKEN 970d8d14d0cSsthen#include "compat/memcmp.h" 971933707f3Ssthen#define memcmp memcmp_unbound 972933707f3Ssthenint memcmp(const void *x, const void *y, size_t n); 973933707f3Ssthen#endif 974933707f3Ssthen 975933707f3Ssthen 976933707f3Ssthen 977933707f3Ssthen#ifndef HAVE_CTIME_R 978933707f3Ssthen#define ctime_r unbound_ctime_r 979933707f3Ssthenchar *ctime_r(const time_t *timep, char *buf); 980933707f3Ssthen#endif 981933707f3Ssthen 98224893edcSsthen#ifndef HAVE_ISBLANK 98324893edcSsthen#define isblank unbound_isblank 98424893edcSsthenint isblank(int c); 98524893edcSsthen#endif 98624893edcSsthen 987933707f3Ssthen#if !defined(HAVE_STRPTIME) || !defined(STRPTIME_WORKS) 988933707f3Ssthen#define strptime unbound_strptime 989933707f3Ssthenstruct tm; 990933707f3Ssthenchar *strptime(const char *s, const char *format, struct tm *tm); 991933707f3Ssthen#endif 992933707f3Ssthen 99398f3ca02Sbrad#ifdef HAVE_LIBRESSL 99498f3ca02Sbrad# if !HAVE_DECL_STRLCPY 99598f3ca02Sbradsize_t strlcpy(char *dst, const char *src, size_t siz); 99698f3ca02Sbrad# endif 99798f3ca02Sbrad# if !HAVE_DECL_STRLCAT 99898f3ca02Sbradsize_t strlcat(char *dst, const char *src, size_t siz); 99998f3ca02Sbrad# endif 100098f3ca02Sbrad# if !HAVE_DECL_ARC4RANDOM && defined(HAVE_ARC4RANDOM) 100198f3ca02Sbraduint32_t arc4random(void); 100298f3ca02Sbrad# endif 100398f3ca02Sbrad# if !HAVE_DECL_ARC4RANDOM_UNIFORM && defined(HAVE_ARC4RANDOM_UNIFORM) 100498f3ca02Sbraduint32_t arc4random_uniform(uint32_t upper_bound); 100598f3ca02Sbrad# endif 1006fdfb4ba6Ssthen# if !HAVE_DECL_REALLOCARRAY 1007fdfb4ba6Ssthenvoid *reallocarray(void *ptr, size_t nmemb, size_t size); 1008fdfb4ba6Ssthen# endif 100998f3ca02Sbrad#endif /* HAVE_LIBRESSL */ 101098f3ca02Sbrad#ifndef HAVE_ARC4RANDOM 101198f3ca02Sbradvoid explicit_bzero(void* buf, size_t len); 101298f3ca02Sbradint getentropy(void* buf, size_t len); 101398f3ca02Sbraduint32_t arc4random(void); 101498f3ca02Sbradvoid arc4random_buf(void* buf, size_t n); 101598f3ca02Sbradvoid _ARC4_LOCK(void); 101698f3ca02Sbradvoid _ARC4_UNLOCK(void); 101798f3ca02Sbrad#endif 101898f3ca02Sbrad#ifndef HAVE_ARC4RANDOM_UNIFORM 101998f3ca02Sbraduint32_t arc4random_uniform(uint32_t upper_bound); 102098f3ca02Sbrad#endif 102198f3ca02Sbrad#ifdef COMPAT_SHA512 102298f3ca02Sbrad#ifndef SHA512_DIGEST_LENGTH 102398f3ca02Sbrad#define SHA512_BLOCK_LENGTH 128 102498f3ca02Sbrad#define SHA512_DIGEST_LENGTH 64 102598f3ca02Sbrad#define SHA512_DIGEST_STRING_LENGTH (SHA512_DIGEST_LENGTH * 2 + 1) 102698f3ca02Sbradtypedef struct _SHA512_CTX { 102798f3ca02Sbrad uint64_t state[8]; 102898f3ca02Sbrad uint64_t bitcount[2]; 102998f3ca02Sbrad uint8_t buffer[SHA512_BLOCK_LENGTH]; 103098f3ca02Sbrad} SHA512_CTX; 103198f3ca02Sbrad#endif /* SHA512_DIGEST_LENGTH */ 103298f3ca02Sbradvoid SHA512_Init(SHA512_CTX*); 103398f3ca02Sbradvoid SHA512_Update(SHA512_CTX*, void*, size_t); 103498f3ca02Sbradvoid SHA512_Final(uint8_t[SHA512_DIGEST_LENGTH], SHA512_CTX*); 103598f3ca02Sbradunsigned char *SHA512(void* data, unsigned int data_len, unsigned char *digest); 103698f3ca02Sbrad#endif /* COMPAT_SHA512 */ 103798f3ca02Sbrad 103898f3ca02Sbrad 103998f3ca02Sbrad 1040933707f3Ssthen#if defined(HAVE_EVENT_H) && !defined(HAVE_EVENT_BASE_ONCE) && !(defined(HAVE_EV_LOOP) || defined(HAVE_EV_DEFAULT_LOOP)) && (defined(HAVE_PTHREAD) || defined(HAVE_SOLARIS_THREADS)) 1041933707f3Ssthen /* using version of libevent that is not threadsafe. */ 1042933707f3Ssthen# define LIBEVENT_SIGNAL_PROBLEM 1 1043933707f3Ssthen#endif 1044933707f3Ssthen 1045933707f3Ssthen#ifndef CHECKED_INET6 1046933707f3Ssthen# define CHECKED_INET6 1047933707f3Ssthen# ifdef AF_INET6 1048933707f3Ssthen# define INET6 1049933707f3Ssthen# else 1050933707f3Ssthen# define AF_INET6 28 1051933707f3Ssthen# endif 1052933707f3Ssthen#endif /* CHECKED_INET6 */ 1053933707f3Ssthen 1054933707f3Ssthen#ifndef HAVE_GETADDRINFO 1055933707f3Ssthenstruct sockaddr_storage; 1056933707f3Ssthen#include "compat/fake-rfc2553.h" 1057933707f3Ssthen#endif 1058933707f3Ssthen 1059933707f3Ssthen#ifdef UNBOUND_ALLOC_STATS 1060933707f3Ssthen# define malloc(s) unbound_stat_malloc_log(s, __FILE__, __LINE__, __func__) 1061933707f3Ssthen# define calloc(n,s) unbound_stat_calloc_log(n, s, __FILE__, __LINE__, __func__) 1062933707f3Ssthen# define free(p) unbound_stat_free_log(p, __FILE__, __LINE__, __func__) 1063933707f3Ssthen# define realloc(p,s) unbound_stat_realloc_log(p, s, __FILE__, __LINE__, __func__) 1064933707f3Ssthenvoid *unbound_stat_malloc(size_t size); 1065933707f3Ssthenvoid *unbound_stat_calloc(size_t nmemb, size_t size); 1066933707f3Ssthenvoid unbound_stat_free(void *ptr); 1067933707f3Ssthenvoid *unbound_stat_realloc(void *ptr, size_t size); 1068933707f3Ssthenvoid *unbound_stat_malloc_log(size_t size, const char* file, int line, 1069933707f3Ssthen const char* func); 1070933707f3Ssthenvoid *unbound_stat_calloc_log(size_t nmemb, size_t size, const char* file, 1071933707f3Ssthen int line, const char* func); 1072933707f3Ssthenvoid unbound_stat_free_log(void *ptr, const char* file, int line, 1073933707f3Ssthen const char* func); 1074933707f3Ssthenvoid *unbound_stat_realloc_log(void *ptr, size_t size, const char* file, 1075933707f3Ssthen int line, const char* func); 1076933707f3Ssthen#elif defined(UNBOUND_ALLOC_LITE) 1077933707f3Ssthen# include "util/alloc.h" 1078933707f3Ssthen#endif /* UNBOUND_ALLOC_LITE and UNBOUND_ALLOC_STATS */ 1079933707f3Ssthen 1080933707f3Ssthen/** default port for DNS traffic. */ 1081933707f3Ssthen#define UNBOUND_DNS_PORT 53 1082933707f3Ssthen/** default port for unbound control traffic, registered port with IANA, 1083933707f3Ssthen ub-dns-control 8953/tcp unbound dns nameserver control */ 1084933707f3Ssthen#define UNBOUND_CONTROL_PORT 8953 1085933707f3Ssthen/** the version of unbound-control that this software implements */ 1086933707f3Ssthen#define UNBOUND_CONTROL_VERSION 1 1087933707f3Ssthen 1088933707f3Ssthen 1089