fix declaration of struct addrinfo

SVN revision: 46434
This commit is contained in:
Vincent Torri 2010-02-24 17:52:54 +00:00
parent 3c8d96125a
commit 89594ec456
3 changed files with 32 additions and 9 deletions

View File

@ -857,20 +857,26 @@ PKG_CHECK_MODULES([EVAS], [evas >= 0.9.9],
AC_HEADER_SYS_WAIT
have_addrinfo="no"
case "$host_os" in
mingw* | cegcc*)
AC_DEFINE(HAVE_DLFCN_H, 1, [Define to 1 if you have the <dlfcn.h> header file.])
AC_DEFINE(HAVE_SYS_MMAN_H, 1, [Define to 1 if you have the <sys/mman.h> header file.])
AC_DEFINE(HAVE_SYS_TIME_H, 1, [Define to 1 if you have the <sys/time.h> header file.])
have_addrinfo="yes"
;;
*)
AC_CHECK_HEADERS([dlfcn.h features.h langinfo.h locale.h netdb.h sys/time.h sys/mman.h signal.h sys/resource.h])
AC_CHECK_HEADERS([dlfcn.h features.h langinfo.h locale.h sys/time.h sys/mman.h signal.h sys/resource.h])
;;
esac
# ecore_con
AC_CHECK_HEADERS([arpa/inet.h netinet/tcp.h netinet/in.h sys/socket.h sys/un.h ws2tcpip.h])
AC_CHECK_HEADERS([arpa/inet.h arpa/nameser.h netinet/tcp.h netinet/in.h sys/socket.h sys/un.h ws2tcpip.h netdb.h])
if test "x${ac_cv_header_netdb_h}" = "xyes" ; then
have_addrinfo="yes"
fi
# Framebuffer (ecore_fb)
have_fb="no"
@ -979,7 +985,7 @@ ECORE_CHECK_MODULE([data], [${want_ecore_data}], [Data])
ECORE_CHECK_MODULE([txt], [${want_ecore_txt}], [Txt], [$have_iconv])
# ecore_con
ECORE_CHECK_MODULE([con], [${want_ecore_con}], [Con])
ECORE_CHECK_MODULE([con], [${want_ecore_con}], [Con], [${have_addrinfo}])
have_curl="no"
have_gnutls="no"

View File

@ -6,7 +6,9 @@
#include <time.h>
#include <libgen.h>
#ifdef HAVE_NETDB_H
#ifdef _WIN32
# include <ws2tcpip.h>
#else
# include <netdb.h>
#endif
#include <Eina.h>

View File

@ -37,11 +37,26 @@ void *alloca (size_t);
#ifdef __OpenBSD__
# include <sys/types.h>
#endif
#include <netinet/in.h>
#include <sys/socket.h>
#include <arpa/inet.h>
#include <arpa/nameser.h>
#include <netdb.h>
#ifdef HAVE_ARPA_INET_H
# include <arpa/inet.h>
#endif
#ifdef HAVE_ARPA_NAMESER_H
# include <arpa/nameser.h>
#endif
#ifdef HAVE_NETINET_IN_H
# include <netinet/in.h>
#endif
#ifdef HAVE_SYS_SOCKET_H
# include <sys/socket.h>
#endif
#ifdef HAVE_NETDB_H
# include <netdb.h>
#endif
#include "Ecore.h"
#include "ecore_private.h"