1255581Sdes/* config.h.  Generated from config.h.in by configure.  */
2255581Sdes/* config.h.in.  Generated from configure.ac by autoheader.  */
3255581Sdes
4255581Sdes/* Directory to chroot to */
5255581Sdes#define CHROOT_DIR "/var/unbound"
6255581Sdes
7255581Sdes/* Pathname to the Unbound configuration file */
8255840Sdes#define CONFIGFILE "/var/unbound/unbound.conf"
9255581Sdes
10255581Sdes/* Define this if on macOSX10.4-darwin8 and setreuid and setregid do not work
11255581Sdes   */
12255581Sdes/* #undef DARWIN_BROKEN_SETREUID */
13255581Sdes
14255581Sdes/* Whether daemon is deprecated */
15255581Sdes/* #undef DEPRECATED_DAEMON */
16255581Sdes
17255581Sdes/* Define if you want to use debug lock checking (slow). */
18255581Sdes/* #undef ENABLE_LOCK_CHECKS */
19255581Sdes
20255581Sdes/* Define this if you enabled-allsymbols from libunbound to link binaries to
21255581Sdes   it for smaller install size, but the libunbound export table is polluted by
22255581Sdes   internal symbols */
23255581Sdes/* #undef EXPORT_ALL_SYMBOLS */
24255581Sdes
25255581Sdes/* Define to 1 if you have the <arpa/inet.h> header file. */
26255581Sdes#define HAVE_ARPA_INET_H 1
27255581Sdes
28255581Sdes/* Whether the C compiler accepts the "format" attribute */
29255581Sdes#define HAVE_ATTR_FORMAT 1
30255581Sdes
31255581Sdes/* Whether the C compiler accepts the "unused" attribute */
32255581Sdes#define HAVE_ATTR_UNUSED 1
33255581Sdes
34255581Sdes/* Define to 1 if your system has a working `chown' function. */
35255581Sdes#define HAVE_CHOWN 1
36255581Sdes
37255581Sdes/* Define to 1 if you have the `chroot' function. */
38255581Sdes#define HAVE_CHROOT 1
39255581Sdes
40255581Sdes/* Define to 1 if you have the `ctime_r' function. */
41255581Sdes#define HAVE_CTIME_R 1
42255581Sdes
43255581Sdes/* Define to 1 if you have the `daemon' function. */
44255581Sdes#define HAVE_DAEMON 1
45255581Sdes
46255581Sdes/* Define to 1 if you have the declaration of `NID_secp384r1', and to 0 if you
47255581Sdes   don't. */
48255581Sdes#define HAVE_DECL_NID_SECP384R1 1
49255581Sdes
50255581Sdes/* Define to 1 if you have the declaration of `NID_X9_62_prime256v1', and to 0
51255581Sdes   if you don't. */
52255581Sdes#define HAVE_DECL_NID_X9_62_PRIME256V1 1
53255581Sdes
54255581Sdes/* Define to 1 if you have the declaration of `sk_SSL_COMP_pop_free', and to 0
55255581Sdes   if you don't. */
56255581Sdes#define HAVE_DECL_SK_SSL_COMP_POP_FREE 1
57255581Sdes
58255581Sdes/* Define to 1 if you have the declaration of
59255581Sdes   `SSL_COMP_get_compression_methods', and to 0 if you don't. */
60255581Sdes#define HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS 1
61255581Sdes
62255581Sdes/* Define to 1 if you have the <dlfcn.h> header file. */
63255581Sdes#define HAVE_DLFCN_H 1
64255581Sdes
65269257Sdes/* Define to 1 if you have the `endprotoent' function. */
66269257Sdes#define HAVE_ENDPROTOENT 1
67269257Sdes
68269257Sdes/* Define to 1 if you have the `endservent' function. */
69269257Sdes#define HAVE_ENDSERVENT 1
70269257Sdes
71255581Sdes/* Define to 1 if you have the `event_base_free' function. */
72255581Sdes/* #undef HAVE_EVENT_BASE_FREE */
73255581Sdes
74255581Sdes/* Define to 1 if you have the `event_base_get_method' function. */
75255581Sdes/* #undef HAVE_EVENT_BASE_GET_METHOD */
76255581Sdes
77255581Sdes/* Define to 1 if you have the `event_base_new' function. */
78255581Sdes/* #undef HAVE_EVENT_BASE_NEW */
79255581Sdes
80255581Sdes/* Define to 1 if you have the `event_base_once' function. */
81255581Sdes/* #undef HAVE_EVENT_BASE_ONCE */
82255581Sdes
83255581Sdes/* Define to 1 if you have the <event.h> header file. */
84255581Sdes/* #undef HAVE_EVENT_H */
85255581Sdes
86255581Sdes/* Define to 1 if you have the `EVP_sha1' function. */
87255581Sdes#define HAVE_EVP_SHA1 1
88255581Sdes
89255581Sdes/* Define to 1 if you have the `EVP_sha256' function. */
90255581Sdes#define HAVE_EVP_SHA256 1
91255581Sdes
92255581Sdes/* Define to 1 if you have the `EVP_sha512' function. */
93255581Sdes#define HAVE_EVP_SHA512 1
94255581Sdes
95255581Sdes/* Define to 1 if you have the `ev_default_loop' function. */
96255581Sdes/* #undef HAVE_EV_DEFAULT_LOOP */
97255581Sdes
98255581Sdes/* Define to 1 if you have the `ev_loop' function. */
99255581Sdes/* #undef HAVE_EV_LOOP */
100255581Sdes
101255581Sdes/* Define to 1 if you have the <expat.h> header file. */
102255581Sdes#define HAVE_EXPAT_H 1
103255581Sdes
104255581Sdes/* Define to 1 if you have the `fcntl' function. */
105255581Sdes#define HAVE_FCNTL 1
106255581Sdes
107255581Sdes/* Define to 1 if you have the `FIPS_mode' function. */
108255581Sdes#define HAVE_FIPS_MODE 1
109255581Sdes
110255581Sdes/* Define to 1 if you have the `fork' function. */
111255581Sdes#define HAVE_FORK 1
112255581Sdes
113255581Sdes/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */
114255581Sdes#define HAVE_FSEEKO 1
115255581Sdes
116255581Sdes/* Whether getaddrinfo is available */
117255581Sdes#define HAVE_GETADDRINFO 1
118255581Sdes
119255581Sdes/* Define to 1 if you have the <getopt.h> header file. */
120255581Sdes#define HAVE_GETOPT_H 1
121255581Sdes
122255581Sdes/* Define to 1 if you have the `getpwnam' function. */
123255581Sdes#define HAVE_GETPWNAM 1
124255581Sdes
125255581Sdes/* Define to 1 if you have the `getrlimit' function. */
126255581Sdes#define HAVE_GETRLIMIT 1
127255581Sdes
128255581Sdes/* Define to 1 if you have the `glob' function. */
129255581Sdes#define HAVE_GLOB 1
130255581Sdes
131255581Sdes/* Define to 1 if you have the <glob.h> header file. */
132255581Sdes#define HAVE_GLOB_H 1
133255581Sdes
134255581Sdes/* Define to 1 if you have the `gmtime_r' function. */
135255581Sdes#define HAVE_GMTIME_R 1
136255581Sdes
137255581Sdes/* Define to 1 if you have the <grp.h> header file. */
138255581Sdes#define HAVE_GRP_H 1
139255581Sdes
140255581Sdes/* If you have HMAC_CTX_init */
141255581Sdes#define HAVE_HMAC_CTX_INIT 1
142255581Sdes
143255581Sdes/* Define to 1 if you have the `inet_aton' function. */
144255581Sdes#define HAVE_INET_ATON 1
145255581Sdes
146255581Sdes/* Define to 1 if you have the `inet_ntop' function. */
147255581Sdes#define HAVE_INET_NTOP 1
148255581Sdes
149255581Sdes/* Define to 1 if you have the `inet_pton' function. */
150255581Sdes#define HAVE_INET_PTON 1
151255581Sdes
152255581Sdes/* Define to 1 if you have the `initgroups' function. */
153255581Sdes#define HAVE_INITGROUPS 1
154255581Sdes
155255581Sdes/* Define to 1 if you have the <inttypes.h> header file. */
156255581Sdes#define HAVE_INTTYPES_H 1
157255581Sdes
158255581Sdes/* if the function 'ioctlsocket' is available */
159255581Sdes/* #undef HAVE_IOCTLSOCKET */
160255581Sdes
161255581Sdes/* Define to 1 if you have the <iphlpapi.h> header file. */
162255581Sdes/* #undef HAVE_IPHLPAPI_H */
163255581Sdes
164255581Sdes/* Define to 1 if you have the `kill' function. */
165255581Sdes#define HAVE_KILL 1
166255581Sdes
167255581Sdes/* Define to 1 if you have the `localtime_r' function. */
168255581Sdes#define HAVE_LOCALTIME_R 1
169255581Sdes
170255581Sdes/* Define to 1 if you have the <login_cap.h> header file. */
171255581Sdes#define HAVE_LOGIN_CAP_H 1
172255581Sdes
173255581Sdes/* If have GNU libc compatible malloc */
174255581Sdes#define HAVE_MALLOC 1
175255581Sdes
176255581Sdes/* Define to 1 if you have the `memmove' function. */
177255581Sdes#define HAVE_MEMMOVE 1
178255581Sdes
179255581Sdes/* Define to 1 if you have the <memory.h> header file. */
180255581Sdes#define HAVE_MEMORY_H 1
181255581Sdes
182255581Sdes/* Define to 1 if you have the <netdb.h> header file. */
183255581Sdes#define HAVE_NETDB_H 1
184255581Sdes
185255581Sdes/* Define to 1 if you have the <netinet/in.h> header file. */
186255581Sdes#define HAVE_NETINET_IN_H 1
187255581Sdes
188255581Sdes/* Use libnss for crypto */
189255581Sdes/* #undef HAVE_NSS */
190255581Sdes
191255581Sdes/* Define to 1 if you have the `OPENSSL_config' function. */
192255581Sdes#define HAVE_OPENSSL_CONFIG 1
193255581Sdes
194255581Sdes/* Define to 1 if you have the <openssl/conf.h> header file. */
195255581Sdes#define HAVE_OPENSSL_CONF_H 1
196255581Sdes
197255581Sdes/* Define to 1 if you have the <openssl/engine.h> header file. */
198255581Sdes#define HAVE_OPENSSL_ENGINE_H 1
199255581Sdes
200255581Sdes/* Define to 1 if you have the <openssl/err.h> header file. */
201255581Sdes#define HAVE_OPENSSL_ERR_H 1
202255581Sdes
203255581Sdes/* Define to 1 if you have the <openssl/rand.h> header file. */
204255581Sdes#define HAVE_OPENSSL_RAND_H 1
205255581Sdes
206255581Sdes/* Define to 1 if you have the <openssl/ssl.h> header file. */
207255581Sdes#define HAVE_OPENSSL_SSL_H 1
208255581Sdes
209255581Sdes/* Define if you have POSIX threads libraries and header files. */
210255581Sdes#define HAVE_PTHREAD 1
211255581Sdes
212269257Sdes/* Have PTHREAD_PRIO_INHERIT. */
213269257Sdes#define HAVE_PTHREAD_PRIO_INHERIT 1
214269257Sdes
215255581Sdes/* Define to 1 if the system has the type `pthread_rwlock_t'. */
216255581Sdes#define HAVE_PTHREAD_RWLOCK_T 1
217255581Sdes
218255581Sdes/* Define to 1 if the system has the type `pthread_spinlock_t'. */
219255581Sdes#define HAVE_PTHREAD_SPINLOCK_T 1
220255581Sdes
221255581Sdes/* Define to 1 if you have the <pwd.h> header file. */
222255581Sdes#define HAVE_PWD_H 1
223255581Sdes
224255581Sdes/* Define if you have Python libraries and header files. */
225255581Sdes/* #undef HAVE_PYTHON */
226255581Sdes
227255581Sdes/* Define to 1 if you have the `random' function. */
228255581Sdes#define HAVE_RANDOM 1
229255581Sdes
230255581Sdes/* Define to 1 if you have the `recvmsg' function. */
231255581Sdes#define HAVE_RECVMSG 1
232255581Sdes
233255581Sdes/* Define to 1 if you have the `sbrk' function. */
234269257Sdes/* #undef HAVE_SBRK */
235255581Sdes
236255581Sdes/* Define to 1 if you have the `sendmsg' function. */
237255581Sdes#define HAVE_SENDMSG 1
238255581Sdes
239255581Sdes/* Define to 1 if you have the `setregid' function. */
240255581Sdes/* #undef HAVE_SETREGID */
241255581Sdes
242255581Sdes/* Define to 1 if you have the `setresgid' function. */
243255581Sdes#define HAVE_SETRESGID 1
244255581Sdes
245255581Sdes/* Define to 1 if you have the `setresuid' function. */
246255581Sdes#define HAVE_SETRESUID 1
247255581Sdes
248255581Sdes/* Define to 1 if you have the `setreuid' function. */
249255581Sdes/* #undef HAVE_SETREUID */
250255581Sdes
251255581Sdes/* Define to 1 if you have the `setrlimit' function. */
252255581Sdes#define HAVE_SETRLIMIT 1
253255581Sdes
254255581Sdes/* Define to 1 if you have the `setsid' function. */
255255581Sdes#define HAVE_SETSID 1
256255581Sdes
257255581Sdes/* Define to 1 if you have the `setusercontext' function. */
258255581Sdes#define HAVE_SETUSERCONTEXT 1
259255581Sdes
260255581Sdes/* Define to 1 if you have the `sigprocmask' function. */
261255581Sdes#define HAVE_SIGPROCMASK 1
262255581Sdes
263255581Sdes/* Define to 1 if you have the `sleep' function. */
264255581Sdes#define HAVE_SLEEP 1
265255581Sdes
266255581Sdes/* Define to 1 if you have the `snprintf' function. */
267255581Sdes#define HAVE_SNPRINTF 1
268255581Sdes
269255581Sdes/* Define to 1 if you have the `socketpair' function. */
270255581Sdes#define HAVE_SOCKETPAIR 1
271255581Sdes
272255581Sdes/* Using Solaris threads */
273255581Sdes/* #undef HAVE_SOLARIS_THREADS */
274255581Sdes
275255581Sdes/* Define to 1 if you have the `srandom' function. */
276255581Sdes#define HAVE_SRANDOM 1
277255581Sdes
278255581Sdes/* Define if you have the SSL libraries installed. */
279255581Sdes#define HAVE_SSL /**/
280255581Sdes
281255581Sdes/* Define to 1 if you have the <stdarg.h> header file. */
282255581Sdes#define HAVE_STDARG_H 1
283255581Sdes
284255581Sdes/* Define to 1 if you have the <stdbool.h> header file. */
285255581Sdes#define HAVE_STDBOOL_H 1
286255581Sdes
287255581Sdes/* Define to 1 if you have the <stdint.h> header file. */
288255581Sdes#define HAVE_STDINT_H 1
289255581Sdes
290255581Sdes/* Define to 1 if you have the <stdlib.h> header file. */
291255581Sdes#define HAVE_STDLIB_H 1
292255581Sdes
293255581Sdes/* Define to 1 if you have the `strftime' function. */
294255581Sdes#define HAVE_STRFTIME 1
295255581Sdes
296255581Sdes/* Define to 1 if you have the <strings.h> header file. */
297255581Sdes#define HAVE_STRINGS_H 1
298255581Sdes
299255581Sdes/* Define to 1 if you have the <string.h> header file. */
300255581Sdes#define HAVE_STRING_H 1
301255581Sdes
302269257Sdes/* Define to 1 if you have the `strlcat' function. */
303269257Sdes#define HAVE_STRLCAT 1
304269257Sdes
305255581Sdes/* Define to 1 if you have the `strlcpy' function. */
306255581Sdes#define HAVE_STRLCPY 1
307255581Sdes
308255581Sdes/* Define to 1 if you have the `strptime' function. */
309255581Sdes#define HAVE_STRPTIME 1
310255581Sdes
311255581Sdes/* Define to 1 if `ipi_spec_dst' is a member of `struct in_pktinfo'. */
312255581Sdes/* #undef HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST */
313255581Sdes
314255581Sdes/* Define if you have Swig libraries and header files. */
315255581Sdes/* #undef HAVE_SWIG */
316255581Sdes
317255581Sdes/* Define to 1 if you have the <syslog.h> header file. */
318255581Sdes#define HAVE_SYSLOG_H 1
319255581Sdes
320255581Sdes/* Define to 1 if you have the <sys/param.h> header file. */
321255581Sdes#define HAVE_SYS_PARAM_H 1
322255581Sdes
323255581Sdes/* Define to 1 if you have the <sys/resource.h> header file. */
324255581Sdes#define HAVE_SYS_RESOURCE_H 1
325255581Sdes
326255581Sdes/* Define to 1 if you have the <sys/socket.h> header file. */
327255581Sdes#define HAVE_SYS_SOCKET_H 1
328255581Sdes
329255581Sdes/* Define to 1 if you have the <sys/stat.h> header file. */
330255581Sdes#define HAVE_SYS_STAT_H 1
331255581Sdes
332255581Sdes/* Define to 1 if you have the <sys/types.h> header file. */
333255581Sdes#define HAVE_SYS_TYPES_H 1
334255581Sdes
335255581Sdes/* Define to 1 if you have the <sys/uio.h> header file. */
336255581Sdes#define HAVE_SYS_UIO_H 1
337255581Sdes
338255581Sdes/* Define to 1 if you have the <sys/wait.h> header file. */
339255581Sdes#define HAVE_SYS_WAIT_H 1
340255581Sdes
341255581Sdes/* Define to 1 if you have the <time.h> header file. */
342255581Sdes#define HAVE_TIME_H 1
343255581Sdes
344255581Sdes/* Define to 1 if you have the `tzset' function. */
345255581Sdes#define HAVE_TZSET 1
346255581Sdes
347255581Sdes/* Define to 1 if you have the <unistd.h> header file. */
348255581Sdes#define HAVE_UNISTD_H 1
349255581Sdes
350255581Sdes/* Define to 1 if you have the `usleep' function. */
351255581Sdes#define HAVE_USLEEP 1
352255581Sdes
353255581Sdes/* Define to 1 if you have the `vfork' function. */
354255581Sdes#define HAVE_VFORK 1
355255581Sdes
356255581Sdes/* Define to 1 if you have the <vfork.h> header file. */
357255581Sdes/* #undef HAVE_VFORK_H */
358255581Sdes
359255581Sdes/* Define to 1 if you have the <windows.h> header file. */
360255581Sdes/* #undef HAVE_WINDOWS_H */
361255581Sdes
362255581Sdes/* Using Windows threads */
363255581Sdes/* #undef HAVE_WINDOWS_THREADS */
364255581Sdes
365255581Sdes/* Define to 1 if you have the <winsock2.h> header file. */
366255581Sdes/* #undef HAVE_WINSOCK2_H */
367255581Sdes
368255581Sdes/* Define to 1 if `fork' works. */
369255581Sdes#define HAVE_WORKING_FORK 1
370255581Sdes
371255581Sdes/* Define to 1 if `vfork' works. */
372255581Sdes#define HAVE_WORKING_VFORK 1
373255581Sdes
374255581Sdes/* Define to 1 if you have the `writev' function. */
375255581Sdes#define HAVE_WRITEV 1
376255581Sdes
377255581Sdes/* Define to 1 if you have the <ws2tcpip.h> header file. */
378255581Sdes/* #undef HAVE_WS2TCPIP_H */
379255581Sdes
380255581Sdes/* Define to 1 if you have the `_beginthreadex' function. */
381255581Sdes/* #undef HAVE__BEGINTHREADEX */
382255581Sdes
383255581Sdes/* if lex has yylex_destroy */
384255581Sdes#define LEX_HAS_YYLEX_DESTROY 1
385255581Sdes
386255581Sdes/* Define to the sub-directory in which libtool stores uninstalled libraries.
387255581Sdes   */
388255581Sdes#define LT_OBJDIR ".libs/"
389255581Sdes
390255581Sdes/* Define to the maximum message length to pass to syslog. */
391255581Sdes#define MAXSYSLOGMSGLEN 10240
392255581Sdes
393255581Sdes/* Define if memcmp() does not compare unsigned bytes */
394255581Sdes/* #undef MEMCMP_IS_BROKEN */
395255581Sdes
396255581Sdes/* Define if mkdir has one argument. */
397255581Sdes/* #undef MKDIR_HAS_ONE_ARG */
398255581Sdes
399255581Sdes/* Define if the network stack does not fully support nonblocking io (causes
400255581Sdes   lower performance). */
401255581Sdes/* #undef NONBLOCKING_IS_BROKEN */
402255581Sdes
403255581Sdes/* Put -D_ALL_SOURCE define in config.h */
404255581Sdes/* #undef OMITTED__D_ALL_SOURCE */
405255581Sdes
406255581Sdes/* Put -D_BSD_SOURCE define in config.h */
407255581Sdes/* #undef OMITTED__D_BSD_SOURCE */
408255581Sdes
409255581Sdes/* Put -D_GNU_SOURCE define in config.h */
410255581Sdes/* #undef OMITTED__D_GNU_SOURCE */
411255581Sdes
412255581Sdes/* Put -D_LARGEFILE_SOURCE=1 define in config.h */
413255581Sdes/* #undef OMITTED__D_LARGEFILE_SOURCE_1 */
414255581Sdes
415255581Sdes/* Put -D_POSIX_C_SOURCE=200112 define in config.h */
416255581Sdes/* #undef OMITTED__D_POSIX_C_SOURCE_200112 */
417255581Sdes
418255581Sdes/* Put -D_XOPEN_SOURCE=600 define in config.h */
419255581Sdes/* #undef OMITTED__D_XOPEN_SOURCE_600 */
420255581Sdes
421255581Sdes/* Put -D_XOPEN_SOURCE_EXTENDED=1 define in config.h */
422255581Sdes/* #undef OMITTED__D_XOPEN_SOURCE_EXTENDED_1 */
423255581Sdes
424255581Sdes/* Put -D__EXTENSIONS__ define in config.h */
425255581Sdes/* #undef OMITTED__D__EXTENSIONS__ */
426255581Sdes
427255581Sdes/* Define to the address where bug reports for this package should be sent. */
428255581Sdes#define PACKAGE_BUGREPORT "unbound-bugs@nlnetlabs.nl"
429255581Sdes
430255581Sdes/* Define to the full name of this package. */
431255581Sdes#define PACKAGE_NAME "unbound"
432255581Sdes
433255581Sdes/* Define to the full name and version of this package. */
434269257Sdes#define PACKAGE_STRING "unbound 1.4.22"
435255581Sdes
436255581Sdes/* Define to the one symbol short name of this package. */
437255581Sdes#define PACKAGE_TARNAME "unbound"
438255581Sdes
439255581Sdes/* Define to the home page for this package. */
440255581Sdes#define PACKAGE_URL ""
441255581Sdes
442255581Sdes/* Define to the version of this package. */
443269257Sdes#define PACKAGE_VERSION "1.4.22"
444255581Sdes
445255581Sdes/* default pidfile location */
446255581Sdes#define PIDFILE "/var/unbound/unbound.pid"
447255581Sdes
448255581Sdes/* Define to necessary symbol if this constant uses a non-standard name on
449255581Sdes   your system. */
450255581Sdes/* #undef PTHREAD_CREATE_JOINABLE */
451255581Sdes
452255581Sdes/* Define as the return type of signal handlers (`int' or `void'). */
453255581Sdes#define RETSIGTYPE void
454255581Sdes
455255581Sdes/* default rootkey location */
456255581Sdes#define ROOT_ANCHOR_FILE "/var/unbound/root.key"
457255581Sdes
458255581Sdes/* default rootcert location */
459255581Sdes#define ROOT_CERT_FILE "/var/unbound/icannbundle.pem"
460255581Sdes
461255581Sdes/* version number for resource files */
462269257Sdes#define RSRC_PACKAGE_VERSION 1,4,22,0
463255581Sdes
464255581Sdes/* Directory to chdir to */
465255581Sdes#define RUN_DIR "/var/unbound"
466255581Sdes
467255581Sdes/* Shared data */
468255581Sdes#define SHARE_DIR "/var/unbound"
469255581Sdes
470269257Sdes/* The size of `time_t', as computed by sizeof. */
471269257Sdes#define SIZEOF_TIME_T 8
472269257Sdes
473255581Sdes/* Define to 1 if you have the ANSI C header files. */
474255581Sdes#define STDC_HEADERS 1
475255581Sdes
476255581Sdes/* use default strptime. */
477255581Sdes#define STRPTIME_WORKS 1
478255581Sdes
479255581Sdes/* Use win32 resources and API */
480255581Sdes/* #undef UB_ON_WINDOWS */
481255581Sdes
482255581Sdes/* default username */
483255581Sdes#define UB_USERNAME "unbound"
484255581Sdes
485255581Sdes/* use to enable lightweight alloc assertions, for debug use */
486255581Sdes/* #undef UNBOUND_ALLOC_LITE */
487255581Sdes
488255581Sdes/* use malloc not regions, for debug use */
489255581Sdes/* #undef UNBOUND_ALLOC_NONREGIONAL */
490255581Sdes
491255581Sdes/* use statistics for allocs and frees, for debug use */
492255581Sdes/* #undef UNBOUND_ALLOC_STATS */
493255581Sdes
494255581Sdes/* define this to enable debug checks. */
495255581Sdes/* #undef UNBOUND_DEBUG */
496255581Sdes
497255581Sdes/* Define this to enable ECDSA support. */
498255581Sdes#define USE_ECDSA 1
499255581Sdes
500255581Sdes/* Define this to enable an EVP workaround for older openssl */
501255581Sdes/* #undef USE_ECDSA_EVP_WORKAROUND */
502255581Sdes
503255581Sdes/* Define this to enable GOST support. */
504255581Sdes/* #undef USE_GOST */
505255581Sdes
506255581Sdes/* Define if you want to use internal select based events */
507255581Sdes#define USE_MINI_EVENT 1
508255581Sdes
509255581Sdes/* Define this to enable SHA256 and SHA512 support. */
510255581Sdes#define USE_SHA2 1
511255581Sdes
512255581Sdes/* Enable extensions on AIX 3, Interix.  */
513255581Sdes#ifndef _ALL_SOURCE
514255581Sdes# define _ALL_SOURCE 1
515255581Sdes#endif
516255581Sdes/* Enable GNU extensions on systems that have them.  */
517255581Sdes#ifndef _GNU_SOURCE
518255581Sdes# define _GNU_SOURCE 1
519255581Sdes#endif
520255581Sdes/* Enable threading extensions on Solaris.  */
521255581Sdes#ifndef _POSIX_PTHREAD_SEMANTICS
522255581Sdes# define _POSIX_PTHREAD_SEMANTICS 1
523255581Sdes#endif
524255581Sdes/* Enable extensions on HP NonStop.  */
525255581Sdes#ifndef _TANDEM_SOURCE
526255581Sdes# define _TANDEM_SOURCE 1
527255581Sdes#endif
528255581Sdes/* Enable general extensions on Solaris.  */
529255581Sdes#ifndef __EXTENSIONS__
530255581Sdes# define __EXTENSIONS__ 1
531255581Sdes#endif
532255581Sdes
533255581Sdes
534255581Sdes/* Whether the windows socket API is used */
535255581Sdes/* #undef USE_WINSOCK */
536255581Sdes
537255581Sdes/* the version of the windows API enabled */
538255581Sdes#define WINVER 0x0502
539255581Sdes
540255581Sdes/* Define if you want Python module. */
541255581Sdes/* #undef WITH_PYTHONMODULE */
542255581Sdes
543255581Sdes/* Define if you want PyUnbound. */
544255581Sdes/* #undef WITH_PYUNBOUND */
545255581Sdes
546255581Sdes/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a
547255581Sdes   `char[]'. */
548255581Sdes#define YYTEXT_POINTER 1
549255581Sdes
550255581Sdes/* Enable large inode numbers on Mac OS X 10.5.  */
551255581Sdes#ifndef _DARWIN_USE_64_BIT_INODE
552255581Sdes# define _DARWIN_USE_64_BIT_INODE 1
553255581Sdes#endif
554255581Sdes
555255581Sdes/* Number of bits in a file offset, on hosts where this is settable. */
556255581Sdes/* #undef _FILE_OFFSET_BITS */
557255581Sdes
558255581Sdes/* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */
559255581Sdes/* #undef _LARGEFILE_SOURCE */
560255581Sdes
561255581Sdes/* Define for large files, on AIX-style hosts. */
562255581Sdes/* #undef _LARGE_FILES */
563255581Sdes
564255581Sdes/* Define to 1 if on MINIX. */
565255581Sdes/* #undef _MINIX */
566255581Sdes
567269257Sdes/* Enable for compile on Minix */
568269257Sdes/* #undef _NETBSD_SOURCE */
569269257Sdes
570255581Sdes/* Define to 2 if the system does not provide POSIX.1 features except with
571255581Sdes   this defined. */
572255581Sdes/* #undef _POSIX_1_SOURCE */
573255581Sdes
574255581Sdes/* Define to 1 if you need to in order for `stat' and other things to work. */
575255581Sdes/* #undef _POSIX_SOURCE */
576255581Sdes
577255581Sdes/* Define to empty if `const' does not conform to ANSI C. */
578255581Sdes/* #undef const */
579255581Sdes
580255581Sdes/* Define to `int' if <sys/types.h> doesn't define. */
581255581Sdes/* #undef gid_t */
582255581Sdes
583255581Sdes/* in_addr_t */
584255581Sdes/* #undef in_addr_t */
585255581Sdes
586255581Sdes/* in_port_t */
587255581Sdes/* #undef in_port_t */
588255581Sdes
589255581Sdes/* Define to `__inline__' or `__inline' if that's what the C compiler
590255581Sdes   calls it, or to nothing if 'inline' is not supported under any name.  */
591255581Sdes#ifndef __cplusplus
592255581Sdes/* #undef inline */
593255581Sdes#endif
594255581Sdes
595255581Sdes/* Define to `short' if <sys/types.h> does not define. */
596255581Sdes/* #undef int16_t */
597255581Sdes
598255581Sdes/* Define to `int' if <sys/types.h> does not define. */
599255581Sdes/* #undef int32_t */
600255581Sdes
601255581Sdes/* Define to `long long' if <sys/types.h> does not define. */
602255581Sdes/* #undef int64_t */
603255581Sdes
604255581Sdes/* Define to `signed char' if <sys/types.h> does not define. */
605255581Sdes/* #undef int8_t */
606255581Sdes
607255581Sdes/* Define if replacement function should be used. */
608255581Sdes/* #undef malloc */
609255581Sdes
610255581Sdes/* Define to `long int' if <sys/types.h> does not define. */
611255581Sdes/* #undef off_t */
612255581Sdes
613255581Sdes/* Define to `int' if <sys/types.h> does not define. */
614255581Sdes/* #undef pid_t */
615255581Sdes
616255581Sdes/* Define to 'int' if not defined */
617255581Sdes/* #undef rlim_t */
618255581Sdes
619255581Sdes/* Define to `unsigned int' if <sys/types.h> does not define. */
620255581Sdes/* #undef size_t */
621255581Sdes
622255581Sdes/* Define to 'int' if not defined */
623255581Sdes/* #undef socklen_t */
624255581Sdes
625255581Sdes/* Define to `int' if <sys/types.h> does not define. */
626255581Sdes/* #undef ssize_t */
627255581Sdes
628255581Sdes/* Define to 'unsigned char if not defined */
629255581Sdes/* #undef u_char */
630255581Sdes
631255581Sdes/* Define to `int' if <sys/types.h> doesn't define. */
632255581Sdes/* #undef uid_t */
633255581Sdes
634255581Sdes/* Define to `unsigned short' if <sys/types.h> does not define. */
635255581Sdes/* #undef uint16_t */
636255581Sdes
637255581Sdes/* Define to `unsigned int' if <sys/types.h> does not define. */
638255581Sdes/* #undef uint32_t */
639255581Sdes
640255581Sdes/* Define to `unsigned long long' if <sys/types.h> does not define. */
641255581Sdes/* #undef uint64_t */
642255581Sdes
643255581Sdes/* Define to `unsigned char' if <sys/types.h> does not define. */
644255581Sdes/* #undef uint8_t */
645255581Sdes
646255581Sdes/* Define as `fork' if `vfork' does not work. */
647255581Sdes/* #undef vfork */
648255581Sdes
649255581Sdes#if defined(OMITTED__D_GNU_SOURCE) && !defined(_GNU_SOURCE)
650255581Sdes#define _GNU_SOURCE 1
651255581Sdes#endif
652255581Sdes
653255581Sdes#if defined(OMITTED__D_BSD_SOURCE) && !defined(_BSD_SOURCE)
654255581Sdes#define _BSD_SOURCE 1
655255581Sdes#endif
656255581Sdes
657255581Sdes#if defined(OMITTED__D__EXTENSIONS__) && !defined(__EXTENSIONS__)
658255581Sdes#define __EXTENSIONS__ 1
659255581Sdes#endif
660255581Sdes
661255581Sdes#if defined(OMITTED__D_POSIX_C_SOURCE_200112) && !defined(_POSIX_C_SOURCE)
662255581Sdes#define _POSIX_C_SOURCE 200112
663255581Sdes#endif
664255581Sdes
665255581Sdes#if defined(OMITTED__D_XOPEN_SOURCE_600) && !defined(_XOPEN_SOURCE)
666255581Sdes#define _XOPEN_SOURCE 600
667255581Sdes#endif
668255581Sdes
669255581Sdes#if defined(OMITTED__D_XOPEN_SOURCE_EXTENDED_1) && !defined(_XOPEN_SOURCE_EXTENDED)
670255581Sdes#define _XOPEN_SOURCE_EXTENDED 1
671255581Sdes#endif
672255581Sdes
673255581Sdes#if defined(OMITTED__D_ALL_SOURCE) && !defined(_ALL_SOURCE)
674255581Sdes#define _ALL_SOURCE 1
675255581Sdes#endif
676255581Sdes
677255581Sdes#if defined(OMITTED__D_LARGEFILE_SOURCE_1) && !defined(_LARGEFILE_SOURCE)
678255581Sdes#define _LARGEFILE_SOURCE 1
679255581Sdes#endif
680255581Sdes
681255581Sdes
682255581Sdes
683255581Sdes
684255581Sdes#ifndef UNBOUND_DEBUG
685255581Sdes#  define NDEBUG
686255581Sdes#endif
687255581Sdes
688269257Sdes/** Use small-ldns codebase */
689269257Sdes#define USE_SLDNS 1
690269257Sdes#ifdef HAVE_SSL
691269257Sdes#  define LDNS_BUILD_CONFIG_HAVE_SSL 1
692269257Sdes#endif
693269257Sdes
694255581Sdes#include <stdio.h>
695255581Sdes#include <string.h>
696255581Sdes#include <unistd.h>
697255581Sdes#include <assert.h>
698255581Sdes
699255581Sdes#if STDC_HEADERS
700255581Sdes#include <stdlib.h>
701255581Sdes#include <stddef.h>
702255581Sdes#endif
703255581Sdes
704269257Sdes#ifdef HAVE_STDARG_H
705269257Sdes#include <stdarg.h>
706269257Sdes#endif
707269257Sdes
708255581Sdes#ifdef HAVE_STDINT_H
709255581Sdes#include <stdint.h>
710255581Sdes#endif
711255581Sdes
712255581Sdes#include <errno.h>
713255581Sdes
714255581Sdes#if HAVE_SYS_PARAM_H
715255581Sdes#include <sys/param.h>
716255581Sdes#endif
717255581Sdes
718255581Sdes#ifdef HAVE_SYS_SOCKET_H
719255581Sdes#include <sys/socket.h>
720255581Sdes#endif
721255581Sdes
722255581Sdes#ifdef HAVE_SYS_UIO_H
723255581Sdes#include <sys/uio.h>
724255581Sdes#endif
725255581Sdes
726255581Sdes#ifdef HAVE_NETINET_IN_H
727255581Sdes#include <netinet/in.h>
728255581Sdes#endif
729255581Sdes
730255581Sdes#ifdef HAVE_ARPA_INET_H
731255581Sdes#include <arpa/inet.h>
732255581Sdes#endif
733255581Sdes
734255581Sdes#ifdef HAVE_WINSOCK2_H
735255581Sdes#include <winsock2.h>
736255581Sdes#endif
737255581Sdes
738255581Sdes#ifdef HAVE_WS2TCPIP_H
739255581Sdes#include <ws2tcpip.h>
740255581Sdes#endif
741255581Sdes
742269257Sdes#ifndef USE_WINSOCK
743269257Sdes#define ARG_LL "%ll"
744269257Sdes#else
745269257Sdes#define ARG_LL "%I64"
746269257Sdes#endif
747255581Sdes
748269257Sdes
749255581Sdes
750255581Sdes#ifdef HAVE_ATTR_FORMAT
751255581Sdes#  define ATTR_FORMAT(archetype, string_index, first_to_check) \
752255581Sdes    __attribute__ ((format (archetype, string_index, first_to_check)))
753255581Sdes#else /* !HAVE_ATTR_FORMAT */
754255581Sdes#  define ATTR_FORMAT(archetype, string_index, first_to_check) /* empty */
755255581Sdes#endif /* !HAVE_ATTR_FORMAT */
756255581Sdes
757255581Sdes
758255581Sdes#if defined(DOXYGEN)
759255581Sdes#  define ATTR_UNUSED(x)  x
760255581Sdes#elif defined(__cplusplus)
761255581Sdes#  define ATTR_UNUSED(x)
762255581Sdes#elif defined(HAVE_ATTR_UNUSED)
763255581Sdes#  define ATTR_UNUSED(x)  x __attribute__((unused))
764255581Sdes#else /* !HAVE_ATTR_UNUSED */
765255581Sdes#  define ATTR_UNUSED(x)  x
766255581Sdes#endif /* !HAVE_ATTR_UNUSED */
767255581Sdes
768255581Sdes
769255581Sdes#ifndef HAVE_FSEEKO
770255581Sdes#define fseeko fseek
771255581Sdes#define ftello ftell
772255581Sdes#endif /* HAVE_FSEEKO */
773255581Sdes
774255581Sdes
775255581Sdes#ifndef MAXHOSTNAMELEN
776255581Sdes#define MAXHOSTNAMELEN 256
777255581Sdes#endif
778255581Sdes
779255581Sdes
780255581Sdes#ifndef HAVE_SNPRINTF
781255581Sdes#define snprintf snprintf_unbound
782255581Sdes#define vsnprintf vsnprintf_unbound
783255581Sdes#include <stdarg.h>
784255581Sdesint snprintf (char *str, size_t count, const char *fmt, ...);
785255581Sdesint vsnprintf (char *str, size_t count, const char *fmt, va_list arg);
786255581Sdes#endif /* HAVE_SNPRINTF */
787255581Sdes
788255581Sdes
789255581Sdes#ifndef HAVE_INET_PTON
790255581Sdes#define inet_pton inet_pton_unbound
791255581Sdesint inet_pton(int af, const char* src, void* dst);
792255581Sdes#endif /* HAVE_INET_PTON */
793255581Sdes
794255581Sdes
795255581Sdes#ifndef HAVE_INET_NTOP
796255581Sdes#define inet_ntop inet_ntop_unbound
797255581Sdesconst char *inet_ntop(int af, const void *src, char *dst, size_t size);
798255581Sdes#endif
799255581Sdes
800255581Sdes
801255581Sdes#ifndef HAVE_INET_ATON
802255581Sdes#define inet_aton inet_aton_unbound
803255581Sdesint inet_aton(const char *cp, struct in_addr *addr);
804255581Sdes#endif
805255581Sdes
806255581Sdes
807255581Sdes#ifndef HAVE_MEMMOVE
808255581Sdes#define memmove memmove_unbound
809255581Sdesvoid *memmove(void *dest, const void *src, size_t n);
810255581Sdes#endif
811255581Sdes
812255581Sdes
813269257Sdes#ifndef HAVE_STRLCAT
814269257Sdes#define strlcat strlcat_unbound
815269257Sdessize_t strlcat(char *dst, const char *src, size_t siz);
816269257Sdes#endif
817269257Sdes
818269257Sdes
819255581Sdes#ifndef HAVE_STRLCPY
820255581Sdes#define strlcpy strlcpy_unbound
821255581Sdessize_t strlcpy(char *dst, const char *src, size_t siz);
822255581Sdes#endif
823255581Sdes
824255581Sdes
825255581Sdes#ifndef HAVE_GMTIME_R
826255581Sdes#define gmtime_r gmtime_r_unbound
827255581Sdesstruct tm *gmtime_r(const time_t *timep, struct tm *result);
828255581Sdes#endif
829255581Sdes
830255581Sdes
831269257Sdes#if !defined(HAVE_SLEEP) || defined(HAVE_WINDOWS_H)
832255581Sdes#define sleep(x) Sleep((x)*1000) /* on win32 */
833255581Sdes#endif /* HAVE_SLEEP */
834255581Sdes
835255581Sdes
836255581Sdes#ifndef HAVE_USLEEP
837255581Sdes#define usleep(x) Sleep((x)/1000 + 1) /* on win32 */
838255581Sdes#endif /* HAVE_USLEEP */
839255581Sdes
840255581Sdes
841255581Sdes#ifndef HAVE_RANDOM
842255581Sdes#define random rand /* on win32, for tests only (bad random) */
843255581Sdes#endif /* HAVE_RANDOM */
844255581Sdes
845255581Sdes
846255581Sdes#ifndef HAVE_SRANDOM
847255581Sdes#define srandom(x) srand(x) /* on win32, for tests only (bad random) */
848255581Sdes#endif /* HAVE_SRANDOM */
849255581Sdes
850255581Sdes
851255581Sdes/* detect if we need to cast to unsigned int for FD_SET to avoid warnings */
852255581Sdes#ifdef HAVE_WINSOCK2_H
853255581Sdes#define FD_SET_T (u_int)
854255581Sdes#else
855255581Sdes#define FD_SET_T
856255581Sdes#endif
857255581Sdes
858255581Sdes
859255581Sdes#ifndef IPV6_MIN_MTU
860255581Sdes#define IPV6_MIN_MTU 1280
861255581Sdes#endif /* IPV6_MIN_MTU */
862255581Sdes
863255581Sdes
864255581Sdes#ifdef MEMCMP_IS_BROKEN
865255581Sdes#include "compat/memcmp.h"
866255581Sdes#define memcmp memcmp_unbound
867255581Sdesint memcmp(const void *x, const void *y, size_t n);
868255581Sdes#endif
869255581Sdes
870255581Sdes
871255581Sdes
872255581Sdes#ifndef HAVE_CTIME_R
873255581Sdes#define ctime_r unbound_ctime_r
874255581Sdeschar *ctime_r(const time_t *timep, char *buf);
875255581Sdes#endif
876255581Sdes
877255581Sdes#if !defined(HAVE_STRPTIME) || !defined(STRPTIME_WORKS)
878255581Sdes#define strptime unbound_strptime
879255581Sdesstruct tm;
880255581Sdeschar *strptime(const char *s, const char *format, struct tm *tm);
881255581Sdes#endif
882255581Sdes
883255581Sdes#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))
884255581Sdes   /* using version of libevent that is not threadsafe. */
885255581Sdes#  define LIBEVENT_SIGNAL_PROBLEM 1
886255581Sdes#endif
887255581Sdes
888255581Sdes#ifndef CHECKED_INET6
889255581Sdes#  define CHECKED_INET6
890255581Sdes#  ifdef AF_INET6
891255581Sdes#    define INET6
892255581Sdes#  else
893255581Sdes#    define AF_INET6        28
894255581Sdes#  endif
895255581Sdes#endif /* CHECKED_INET6 */
896255581Sdes
897255581Sdes#ifndef HAVE_GETADDRINFO
898255581Sdesstruct sockaddr_storage;
899255581Sdes#include "compat/fake-rfc2553.h"
900255581Sdes#endif
901255581Sdes
902255581Sdes#ifdef UNBOUND_ALLOC_STATS
903255581Sdes#  define malloc(s) unbound_stat_malloc_log(s, __FILE__, __LINE__, __func__)
904255581Sdes#  define calloc(n,s) unbound_stat_calloc_log(n, s, __FILE__, __LINE__, __func__)
905255581Sdes#  define free(p) unbound_stat_free_log(p, __FILE__, __LINE__, __func__)
906255581Sdes#  define realloc(p,s) unbound_stat_realloc_log(p, s, __FILE__, __LINE__, __func__)
907255581Sdesvoid *unbound_stat_malloc(size_t size);
908255581Sdesvoid *unbound_stat_calloc(size_t nmemb, size_t size);
909255581Sdesvoid unbound_stat_free(void *ptr);
910255581Sdesvoid *unbound_stat_realloc(void *ptr, size_t size);
911255581Sdesvoid *unbound_stat_malloc_log(size_t size, const char* file, int line,
912255581Sdes	const char* func);
913255581Sdesvoid *unbound_stat_calloc_log(size_t nmemb, size_t size, const char* file,
914255581Sdes	int line, const char* func);
915255581Sdesvoid unbound_stat_free_log(void *ptr, const char* file, int line,
916255581Sdes	const char* func);
917255581Sdesvoid *unbound_stat_realloc_log(void *ptr, size_t size, const char* file,
918255581Sdes	int line, const char* func);
919255581Sdes#elif defined(UNBOUND_ALLOC_LITE)
920255581Sdes#  include "util/alloc.h"
921255581Sdes#endif /* UNBOUND_ALLOC_LITE and UNBOUND_ALLOC_STATS */
922255581Sdes
923255581Sdes/** default port for DNS traffic. */
924255581Sdes#define UNBOUND_DNS_PORT 53
925255581Sdes/** default port for unbound control traffic, registered port with IANA,
926255581Sdes    ub-dns-control  8953/tcp    unbound dns nameserver control */
927255581Sdes#define UNBOUND_CONTROL_PORT 8953
928255581Sdes/** the version of unbound-control that this software implements */
929255581Sdes#define UNBOUND_CONTROL_VERSION 1
930255581Sdes
931255581Sdes
932