diff options
| author | Peter Eisentraut | 2003-03-29 11:31:52 +0000 |
|---|---|---|
| committer | Peter Eisentraut | 2003-03-29 11:31:52 +0000 |
| commit | 82a91eb54ed0c6561050a0ae01661ea6302445ba (patch) | |
| tree | 8c22569ca08a298eeb613ba4ba417ce2df0b6a83 /configure.in | |
| parent | bf7ca0a7697551aba8e1d8a130c803d4f2c011d4 (diff) | |
Simplify the socket handling code by supplying a replacement getaddrinfo()
function if the OS doesn't provide one.
Diffstat (limited to 'configure.in')
| -rw-r--r-- | configure.in | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/configure.in b/configure.in index 99a8d9d9713..a7d961ecb14 100644 --- a/configure.in +++ b/configure.in @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -dnl $Header: /cvsroot/pgsql/configure.in,v 1.239 2003/03/21 17:18:34 petere Exp $ +dnl $Header: /cvsroot/pgsql/configure.in,v 1.240 2003/03/29 11:31:51 petere Exp $ dnl dnl Developers, please strive to achieve this order: dnl @@ -791,14 +791,12 @@ AC_CHECK_FUNCS([cbrt dlopen fcvt fdatasync getpeereid memmove poll pstat setproc AC_CHECK_DECLS(fdatasync, [], [], [#include <unistd.h>]) -# This exports HAVE_IPV6 to both C files and Makefiles -AC_CHECK_FUNC(getaddrinfo, - [AC_CHECK_TYPE(struct sockaddr_in6, - [HAVE_IPV6="yes"; AC_DEFINE(HAVE_IPV6, 1)], - [], +AC_CHECK_TYPE([struct sockaddr_in6], + [AC_CHECK_FUNC(inet_ntop, + [AC_DEFINE(HAVE_IPV6, 1)])], + [], [$ac_includes_default -#include <netinet/in.h>])]) -AC_SUBST(HAVE_IPV6) +#include <netinet/in.h>]) AC_CACHE_CHECK([for PS_STRINGS], [pgac_cv_var_PS_STRINGS], [AC_TRY_LINK( @@ -849,7 +847,7 @@ else AC_CHECK_FUNCS([fpclass fp_class fp_class_d class], [break]) fi -AC_REPLACE_FUNCS([fseeko gethostname getopt_long getrusage inet_aton random srandom strcasecmp strdup strerror strtol strtoul]) +AC_REPLACE_FUNCS([fseeko getaddrinfo gethostname getopt_long getrusage inet_aton random srandom strcasecmp strdup strerror strtol strtoul]) # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos # We override the previous test that said fseeko/ftello didn't exist |
