Blame config-win32.h

Packit 514978
#ifndef HEADER_CARES_CONFIG_WIN32_H
Packit 514978
#define HEADER_CARES_CONFIG_WIN32_H
Packit 514978
Packit 514978
/* Copyright (C) 2004 - 2011 by Daniel Stenberg et al
Packit 514978
 *
Packit 514978
 * Permission to use, copy, modify, and distribute this software and its
Packit 514978
 * documentation for any purpose and without fee is hereby granted, provided
Packit 514978
 * that the above copyright notice appear in all copies and that both that
Packit 514978
 * copyright notice and this permission notice appear in supporting
Packit 514978
 * documentation, and that the name of M.I.T. not be used in advertising or
Packit 514978
 * publicity pertaining to distribution of the software without specific,
Packit 514978
 * written prior permission.  M.I.T. makes no representations about the
Packit 514978
 * suitability of this software for any purpose.  It is provided "as is"
Packit 514978
 * without express or implied warranty.
Packit 514978
 */
Packit 514978
Packit 514978
/* ================================================================ */
Packit 514978
/*   c-ares/config-win32.h - Hand crafted config file for Windows   */
Packit 514978
/* ================================================================ */
Packit 514978
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
/*                          HEADER FILES                            */
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
Packit 514978
/* Define if you have the <assert.h> header file. */
Packit 514978
#define HAVE_ASSERT_H 1
Packit 514978
Packit 514978
/* Define if you have the <errno.h> header file. */
Packit 514978
#define HAVE_ERRNO_H 1
Packit 514978
Packit 514978
/* Define if you have the <getopt.h> header file. */
Packit 514978
#if defined(__MINGW32__) || defined(__POCC__)
Packit 514978
#define HAVE_GETOPT_H 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* Define if you have the <limits.h> header file. */
Packit 514978
#define HAVE_LIMITS_H 1
Packit 514978
Packit 514978
/* Define if you have the <process.h> header file. */
Packit 514978
#ifndef __SALFORDC__
Packit 514978
#define HAVE_PROCESS_H 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* Define if you have the <signal.h> header file. */
Packit 514978
#define HAVE_SIGNAL_H 1
Packit 514978
Packit 514978
/* Define if you have the <sys/time.h> header file */
Packit 514978
/* #define HAVE_SYS_TIME_H 1 */
Packit 514978
Packit 514978
/* Define if you have the <time.h> header file. */
Packit 514978
#define HAVE_TIME_H 1
Packit 514978
Packit 514978
/* Define if you have the <unistd.h> header file. */
Packit 514978
#if defined(__MINGW32__) || defined(__WATCOMC__) || defined(__LCC__) || \
Packit 514978
    defined(__POCC__)
Packit 514978
#define HAVE_UNISTD_H 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* Define if you have the <windows.h> header file. */
Packit 514978
#define HAVE_WINDOWS_H 1
Packit 514978
Packit 514978
/* Define if you have the <winsock.h> header file. */
Packit 514978
#define HAVE_WINSOCK_H 1
Packit 514978
Packit 514978
/* Define if you have the <winsock2.h> header file. */
Packit 514978
#ifndef __SALFORDC__
Packit 514978
#define HAVE_WINSOCK2_H 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* Define if you have the <ws2tcpip.h> header file. */
Packit 514978
#ifndef __SALFORDC__
Packit 514978
#define HAVE_WS2TCPIP_H 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
/*                        OTHER HEADER INFO                         */
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
Packit 514978
/* Define if sig_atomic_t is an available typedef. */
Packit 514978
#define HAVE_SIG_ATOMIC_T 1
Packit 514978
Packit 514978
/* Define if you have the ANSI C header files. */
Packit 514978
#define STDC_HEADERS 1
Packit 514978
Packit 514978
/* Define if you can safely include both <sys/time.h> and <time.h>. */
Packit 514978
/* #define TIME_WITH_SYS_TIME 1 */
Packit 514978
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
/*                             FUNCTIONS                            */
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
Packit 514978
/* Define if you have the closesocket function. */
Packit 514978
#define HAVE_CLOSESOCKET 1
Packit 514978
Packit 514978
/* Define if you have the getenv function. */
Packit 514978
#define HAVE_GETENV 1
Packit 514978
Packit 514978
/* Define if you have the gethostname function. */
Packit 514978
#define HAVE_GETHOSTNAME 1
Packit 514978
Packit 514978
/* Define if you have the ioctlsocket function. */
Packit 514978
#define HAVE_IOCTLSOCKET 1
Packit 514978
Packit 514978
/* Define if you have a working ioctlsocket FIONBIO function. */
Packit 514978
#define HAVE_IOCTLSOCKET_FIONBIO 1
Packit 514978
Packit 514978
/* Define if you have the strcasecmp function. */
Packit 514978
/* #define HAVE_STRCASECMP 1 */
Packit 514978
Packit 514978
/* Define if you have the strdup function. */
Packit 514978
#define HAVE_STRDUP 1
Packit 514978
Packit 514978
/* Define if you have the stricmp function. */
Packit 514978
#define HAVE_STRICMP 1
Packit 514978
Packit 514978
/* Define if you have the strncasecmp function. */
Packit 514978
/* #define HAVE_STRNCASECMP 1 */
Packit 514978
Packit 514978
/* Define if you have the strnicmp function. */
Packit 514978
#define HAVE_STRNICMP 1
Packit 514978
Packit 514978
/* Define if you have the recv function. */
Packit 514978
#define HAVE_RECV 1
Packit 514978
Packit 514978
/* Define to the type of arg 1 for recv. */
Packit 514978
#define RECV_TYPE_ARG1 SOCKET
Packit 514978
Packit 514978
/* Define to the type of arg 2 for recv. */
Packit 514978
#define RECV_TYPE_ARG2 char *
Packit 514978
Packit 514978
/* Define to the type of arg 3 for recv. */
Packit 514978
#define RECV_TYPE_ARG3 int
Packit 514978
Packit 514978
/* Define to the type of arg 4 for recv. */
Packit 514978
#define RECV_TYPE_ARG4 int
Packit 514978
Packit 514978
/* Define to the function return type for recv. */
Packit 514978
#define RECV_TYPE_RETV int
Packit 514978
Packit 514978
/* Define if you have the recvfrom function. */
Packit 514978
#define HAVE_RECVFROM 1
Packit 514978
Packit 514978
/* Define to the type of arg 1 for recvfrom. */
Packit 514978
#define RECVFROM_TYPE_ARG1 SOCKET
Packit 514978
Packit 514978
/* Define to the type pointed by arg 2 for recvfrom. */
Packit 514978
#define RECVFROM_TYPE_ARG2 char
Packit 514978
Packit 514978
/* Define to the type of arg 3 for recvfrom. */
Packit 514978
#define RECVFROM_TYPE_ARG3 int
Packit 514978
Packit 514978
/* Define to the type of arg 4 for recvfrom. */
Packit 514978
#define RECVFROM_TYPE_ARG4 int
Packit 514978
Packit 514978
/* Define to the type pointed by arg 5 for recvfrom. */
Packit 514978
#define RECVFROM_TYPE_ARG5 struct sockaddr
Packit 514978
Packit 514978
/* Define to the type pointed by arg 6 for recvfrom. */
Packit 514978
#define RECVFROM_TYPE_ARG6 int
Packit 514978
Packit 514978
/* Define to the function return type for recvfrom. */
Packit 514978
#define RECVFROM_TYPE_RETV int
Packit 514978
Packit 514978
/* Define if you have the send function. */
Packit 514978
#define HAVE_SEND 1
Packit 514978
Packit 514978
/* Define to the type of arg 1 for send. */
Packit 514978
#define SEND_TYPE_ARG1 SOCKET
Packit 514978
Packit 514978
/* Define to the type qualifier of arg 2 for send. */
Packit 514978
#define SEND_QUAL_ARG2 const
Packit 514978
Packit 514978
/* Define to the type of arg 2 for send. */
Packit 514978
#define SEND_TYPE_ARG2 char *
Packit 514978
Packit 514978
/* Define to the type of arg 3 for send. */
Packit 514978
#define SEND_TYPE_ARG3 int
Packit 514978
Packit 514978
/* Define to the type of arg 4 for send. */
Packit 514978
#define SEND_TYPE_ARG4 int
Packit 514978
Packit 514978
/* Define to the function return type for send. */
Packit 514978
#define SEND_TYPE_RETV int
Packit 514978
Packit 514978
/* Specifics for the Watt-32 tcp/ip stack. */
Packit 514978
#ifdef WATT32
Packit 514978
  #define SOCKET              int
Packit 514978
  #define NS_INADDRSZ         4
Packit 514978
  #define HAVE_ARPA_NAMESER_H 1
Packit 514978
  #define HAVE_ARPA_INET_H    1
Packit 514978
  #define HAVE_NETDB_H        1
Packit 514978
  #define HAVE_NETINET_IN_H   1
Packit 514978
  #define HAVE_SYS_SOCKET_H   1
Packit 514978
  #define HAVE_NETINET_TCP_H  1
Packit 514978
  #define HAVE_AF_INET6       1
Packit 514978
  #define HAVE_PF_INET6       1
Packit 514978
  #define HAVE_STRUCT_IN6_ADDR     1
Packit 514978
  #define HAVE_STRUCT_SOCKADDR_IN6 1
Packit 514978
  #undef HAVE_WINSOCK_H
Packit 514978
  #undef HAVE_WINSOCK2_H
Packit 514978
  #undef HAVE_WS2TCPIP_H
Packit 514978
#endif
Packit 514978
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
/*                       TYPEDEF REPLACEMENTS                       */
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
Packit 514978
/* Define if in_addr_t is not an available 'typedefed' type. */
Packit 514978
#define in_addr_t unsigned long
Packit 514978
Packit 514978
/* Define to the return type of signal handlers (int or void). */
Packit 514978
#define RETSIGTYPE void
Packit 514978
Packit 514978
#ifdef __cplusplus
Packit 514978
/* Compiling headers in C++ mode means bool is available */
Packit 514978
#define HAVE_BOOL_T
Packit 514978
#endif
Packit 514978
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
/*                            TYPE SIZES                            */
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
/*                          STRUCT RELATED                          */
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
Packit 514978
/* Define if you have struct addrinfo. */
Packit 514978
#define HAVE_STRUCT_ADDRINFO 1
Packit 514978
Packit 514978
/* Define if you have struct sockaddr_storage. */
Packit 514978
#if !defined(__SALFORDC__) && !defined(__BORLANDC__)
Packit 514978
#define HAVE_STRUCT_SOCKADDR_STORAGE 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* Define if you have struct timeval. */
Packit 514978
#define HAVE_STRUCT_TIMEVAL 1
Packit 514978
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
/*                        COMPILER SPECIFIC                         */
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
Packit 514978
/* Define to avoid VS2005 complaining about portable C functions. */
Packit 514978
#if defined(_MSC_VER) && (_MSC_VER >= 1400)
Packit 514978
#  define _CRT_SECURE_NO_DEPRECATE 1
Packit 514978
#  define _CRT_NONSTDC_NO_DEPRECATE 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* Set the Target to Vista. However, any symbols required above Win2000 
Packit 514978
 * should be loaded via LoadLibrary() */
Packit 514978
#if defined(_MSC_VER) && (_MSC_VER >= 1500)
Packit 514978
#  define VS2008_MIN_TARGET 0x0600
Packit 514978
#endif
Packit 514978
Packit 514978
/* VS2008 default target settings and minimum build target check. */
Packit 514978
#if defined(_MSC_VER) && (_MSC_VER >= 1500)
Packit 514978
#  ifndef _WIN32_WINNT
Packit 514978
#    define _WIN32_WINNT VS2008_MIN_TARGET
Packit 514978
#  endif
Packit 514978
#  ifndef WINVER
Packit 514978
#    define WINVER VS2008_MIN_TARGET
Packit 514978
#  endif
Packit 514978
#  if (_WIN32_WINNT < VS2008_MIN_TARGET) || (WINVER < VS2008_MIN_TARGET)
Packit 514978
#    error VS2008 does not support Windows build targets prior to Windows 2000
Packit 514978
#  endif
Packit 514978
#endif
Packit 514978
Packit 514978
/* When no build target is specified Pelles C 5.00 and later default build
Packit 514978
   target is Windows Vista. */
Packit 514978
#if defined(__POCC__) && (__POCC__ >= 500)
Packit 514978
#  ifndef _WIN32_WINNT
Packit 514978
#    define _WIN32_WINNT 0x0600
Packit 514978
#  endif
Packit 514978
#  ifndef WINVER
Packit 514978
#    define WINVER 0x0600
Packit 514978
#  endif
Packit 514978
#endif
Packit 514978
Packit 514978
/* Availability of freeaddrinfo, getaddrinfo and getnameinfo functions is
Packit 514978
   quite convoluted, compiler dependent and even build target dependent. */
Packit 514978
#if defined(HAVE_WS2TCPIP_H)
Packit 514978
#  if defined(__POCC__)
Packit 514978
#    define HAVE_FREEADDRINFO 1
Packit 514978
#    define HAVE_GETADDRINFO  1
Packit 514978
#    define HAVE_GETNAMEINFO  1
Packit 514978
#  elif defined(_WIN32_WINNT) && (_WIN32_WINNT >= 0x0501)
Packit 514978
#    define HAVE_FREEADDRINFO 1
Packit 514978
#    define HAVE_GETADDRINFO  1
Packit 514978
#    define HAVE_GETNAMEINFO  1
Packit 514978
#  elif defined(_MSC_VER) && (_MSC_VER >= 1200)
Packit 514978
#    define HAVE_FREEADDRINFO 1
Packit 514978
#    define HAVE_GETADDRINFO  1
Packit 514978
#    define HAVE_GETNAMEINFO  1
Packit 514978
#  endif
Packit 514978
#endif
Packit 514978
Packit 514978
#if defined(__POCC__)
Packit 514978
#  ifndef _MSC_VER
Packit 514978
#    error Microsoft extensions /Ze compiler option is required
Packit 514978
#  endif
Packit 514978
#  ifndef __POCC__OLDNAMES
Packit 514978
#    error Compatibility names /Go compiler option is required
Packit 514978
#  endif
Packit 514978
#endif
Packit 514978
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
/*                         IPV6 COMPATIBILITY                       */
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
Packit 514978
/* Define if you have address family AF_INET6. */
Packit 514978
#ifdef HAVE_WINSOCK2_H
Packit 514978
#define HAVE_AF_INET6 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* Define if you have protocol family PF_INET6. */
Packit 514978
#ifdef HAVE_WINSOCK2_H
Packit 514978
#define HAVE_PF_INET6 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* Define if you have struct in6_addr. */
Packit 514978
#ifdef HAVE_WS2TCPIP_H
Packit 514978
#define HAVE_STRUCT_IN6_ADDR 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* Define if you have struct sockaddr_in6. */
Packit 514978
#ifdef HAVE_WS2TCPIP_H
Packit 514978
#define HAVE_STRUCT_SOCKADDR_IN6 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* Define if you have sockaddr_in6 with scopeid. */
Packit 514978
#ifdef HAVE_WS2TCPIP_H
Packit 514978
#define HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID 1
Packit 514978
#endif
Packit 514978
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
/*                              Win CE                              */
Packit 514978
/* ---------------------------------------------------------------- */
Packit 514978
Packit 514978
/* FIXME: A proper config-win32ce.h should be created to hold these */
Packit 514978
Packit 514978
/*
Packit 514978
 *  System error codes for Windows CE
Packit 514978
 */
Packit 514978
Packit 514978
#if defined(_WIN32_WCE) && !defined(HAVE_ERRNO_H)
Packit 514978
#  define ENOENT    ERROR_FILE_NOT_FOUND
Packit 514978
#  define ESRCH     ERROR_PATH_NOT_FOUND
Packit 514978
#  define ENOMEM    ERROR_NOT_ENOUGH_MEMORY
Packit 514978
#  define ENOSPC    ERROR_INVALID_PARAMETER
Packit 514978
#endif
Packit 514978
Packit 514978
#endif /* HEADER_CARES_CONFIG_WIN32_H */