4 * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC")
5 * Copyright (C) 1999-2003 Internet Software Consortium.
7 * Permission to use, copy, modify, and/or distribute this software for any
8 * purpose with or without fee is hereby granted, provided that the above
9 * copyright notice and this permission notice appear in all copies.
11 * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
12 * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
13 * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
14 * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
15 * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
16 * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
17 * PERFORMANCE OF THIS SOFTWARE.
20 /* $Id: platform.h.in,v 1.34.18.11 2008/06/24 23:45:55 tbox Exp $ */
22 #ifndef ISC_PLATFORM_H
23 #define ISC_PLATFORM_H 1
28 ***** Platform-dependent defines.
32 * Define if the platform has <strings.h>.
34 #define ISC_PLATFORM_HAVESTRINGSH 1
41 * Define if this system needs the <netinet/in6.h> header file included
42 * for full IPv6 support (pretty much only UnixWare).
44 #undef ISC_PLATFORM_NEEDNETINETIN6H
47 * Define if this system needs the <netinet6/in6.h> header file included
48 * to support in6_pkinfo (pretty much only BSD/OS).
50 #undef ISC_PLATFORM_NEEDNETINET6IN6H
53 * If sockaddrs on this system have an sa_len field, ISC_PLATFORM_HAVESALEN
56 #define ISC_PLATFORM_HAVESALEN 1
59 * If this system has the IPv6 structure definitions, ISC_PLATFORM_HAVEIPV6
62 #define ISC_PLATFORM_HAVEIPV6 1
65 * If this system is missing in6addr_any, ISC_PLATFORM_NEEDIN6ADDRANY will
68 #undef ISC_PLATFORM_NEEDIN6ADDRANY
71 * If this system is missing in6addr_loopback, ISC_PLATFORM_NEEDIN6ADDRLOOPBACK
74 #undef ISC_PLATFORM_NEEDIN6ADDRLOOPBACK
77 * If this system has in6_pktinfo, ISC_PLATFORM_HAVEIN6PKTINFO will be
80 #define ISC_PLATFORM_HAVEIN6PKTINFO 1
83 * If this system has in_addr6, rather than in6_addr, ISC_PLATFORM_HAVEINADDR6
86 #undef ISC_PLATFORM_HAVEINADDR6
89 * If this system has sin6_scope_id, ISC_PLATFORM_HAVESCOPEID will be defined.
91 #define ISC_PLATFORM_HAVESCOPEID 1
94 * If this system needs inet_ntop(), ISC_PLATFORM_NEEDNTOP will be defined.
96 #undef ISC_PLATFORM_NEEDNTOP
99 * If this system needs inet_pton(), ISC_PLATFORM_NEEDPTON will be defined.
101 #undef ISC_PLATFORM_NEEDPTON
104 * If this system needs inet_aton(), ISC_PLATFORM_NEEDATON will be defined.
106 #undef ISC_PLATFORM_NEEDATON
109 * If this system needs in_port_t, ISC_PLATFORM_NEEDPORTT will be defined.
111 #undef ISC_PLATFORM_NEEDPORTT
114 * If the system needs strsep(), ISC_PLATFORM_NEEDSTRSEP will be defined.
116 #undef ISC_PLATFORM_NEEDSTRSEP
119 * If the system needs strlcpy(), ISC_PLATFORM_NEEDSTRLCPY will be defined.
121 #undef ISC_PLATFORM_NEEDSTRLCPY
124 * If the system needs strlcat(), ISC_PLATFORM_NEEDSTRLCAT will be defined.
126 #undef ISC_PLATFORM_NEEDSTRLCAT
129 * Define either ISC_PLATFORM_BSD44MSGHDR or ISC_PLATFORM_BSD43MSGHDR.
131 #define ISC_NET_BSD44MSGHDR 1
134 * Define if PTHREAD_ONCE_INIT should be surrounded by braces to
135 * prevent compiler warnings (such as with gcc on Solaris 2.8).
137 #undef ISC_PLATFORM_BRACEPTHREADONCEINIT
140 * Define on some UnixWare systems to fix erroneous definitions of various
141 * IN6_IS_ADDR_* macros.
143 #undef ISC_PLATFORM_FIXIN6ISADDR
146 * Define if the system supports kqueue multiplexing
148 #define ISC_PLATFORM_HAVEKQUEUE 1
151 * Define if the system supports epoll multiplexing
153 #undef ISC_PLATFORM_HAVEEPOLL
156 * Define if the system supports /dev/poll multiplexing
158 #undef ISC_PLATFORM_HAVEDEVPOLL
165 * If this system needs vsnprintf() and snprintf(), ISC_PLATFORM_NEEDVSNPRINTF
168 #undef ISC_PLATFORM_NEEDVSNPRINTF
171 * If this system need a modern sprintf() that returns (int) not (char*).
173 #undef ISC_PLATFORM_NEEDSPRINTF
176 * The printf format string modifier to use with isc_uint64_t values.
178 #define ISC_PLATFORM_QUADFORMAT "ll"
181 * Defined if we are using threads.
183 #define ISC_PLATFORM_USETHREADS 1
186 * Defined if unistd.h does not cause fd_set to be delared.
188 #undef ISC_PLATFORM_NEEDSYSSELECTH
191 * Type used for resource limits.
193 #define ISC_PLATFORM_RLIMITTYPE rlim_t
196 * Define if your compiler supports "long long int".
198 #define ISC_PLATFORM_HAVELONGLONG 1
201 * Define if the system has struct lifconf which is a extended struct ifconf
204 #undef ISC_PLATFORM_HAVELIFCONF
207 * Define if the system has struct if_laddrconf which is a extended struct
210 #undef ISC_PLATFORM_HAVEIF_LADDRCONF
213 * Define if the system has struct if_laddrreq.
215 #undef ISC_PLATFORM_HAVEIF_LADDRREQ
218 * Used to control how extern data is linked; needed for Win32 platforms.
220 #undef ISC_PLATFORM_USEDECLSPEC
223 * Define if the system supports if_nametoindex.
225 #define ISC_PLATFORM_HAVEIFNAMETOINDEX 1
228 * Define if this system needs strtoul.
230 #undef ISC_PLATFORM_NEEDSTRTOUL
233 * Define if this system needs memmove.
235 #undef ISC_PLATFORM_NEEDMEMMOVE
238 * Define if the platform has <sys/un.h>.
240 #define ISC_PLATFORM_HAVESYSUNH 1
243 * If the "xadd" operation is available on this architecture,
244 * ISC_PLATFORM_HAVEXADD will be defined.
246 #define ISC_PLATFORM_HAVEXADD 1
249 * If the "atomic swap" operation is available on this architecture,
250 * ISC_PLATFORM_HAVEATOMICSTORE" will be defined.
252 #define ISC_PLATFORM_HAVEATOMICSTORE 1
255 * If the "compare-and-exchange" operation is available on this architecture,
256 * ISC_PLATFORM_HAVECMPXCHG will be defined.
258 #define ISC_PLATFORM_HAVECMPXCHG 1
261 * Define if gcc ASM extension is available
263 #define ISC_PLATFORM_USEGCCASM 1
266 * Define if Tru64 style ASM syntax must be used.
268 #undef ISC_PLATFORM_USEOSFASM
271 * Define if the standard __asm function must be used.
276 * Define if MacOS style of PPC assembly must be used.
277 * e.g. "r6", not "6", for register six.
281 #ifndef ISC_PLATFORM_USEDECLSPEC
282 #define LIBISC_EXTERNAL_DATA
283 #define LIBDNS_EXTERNAL_DATA
284 #define LIBISCCC_EXTERNAL_DATA
285 #define LIBISCCFG_EXTERNAL_DATA
286 #define LIBBIND9_EXTERNAL_DATA
287 #else /*! \brief ISC_PLATFORM_USEDECLSPEC */
288 #ifdef LIBISC_EXPORTS
289 #define LIBISC_EXTERNAL_DATA __declspec(dllexport)
291 #define LIBISC_EXTERNAL_DATA __declspec(dllimport)
293 #ifdef LIBDNS_EXPORTS
294 #define LIBDNS_EXTERNAL_DATA __declspec(dllexport)
296 #define LIBDNS_EXTERNAL_DATA __declspec(dllimport)
298 #ifdef LIBISCCC_EXPORTS
299 #define LIBISCCC_EXTERNAL_DATA __declspec(dllexport)
301 #define LIBISCCC_EXTERNAL_DATA __declspec(dllimport)
303 #ifdef LIBISCCFG_EXPORTS
304 #define LIBISCCFG_EXTERNAL_DATA __declspec(dllexport)
306 #define LIBISCCFG_EXTERNAL_DATA __declspec(dllimport)
308 #ifdef LIBBIND9_EXPORTS
309 #define LIBBIND9_EXTERNAL_DATA __declspec(dllexport)
311 #define LIBBIND9_EXTERNAL_DATA __declspec(dllimport)
313 #endif /*! \brief ISC_PLATFORM_USEDECLSPEC */
316 * Tell emacs to use C mode for this file.
323 #endif /* ISC_PLATFORM_H */