mirror of https://github.com/postgres/postgres
machines without IPv6. Or at least it works on HPUX 10.20 ...WIN32_DEV
parent
f8a15f632d
commit
1da6eb7fda
@ -1,28 +1,32 @@ |
|||||||
|
/*-------------------------------------------------------------------------
|
||||||
|
* |
||||||
|
* ip.h |
||||||
|
* Definitions for IPv6-aware network access. |
||||||
|
* |
||||||
|
* Copyright (c) 2003, PostgreSQL Global Development Group |
||||||
|
* |
||||||
|
* $Id: ip.h,v 1.3 2003/04/02 00:49:28 tgl Exp $ |
||||||
|
* |
||||||
|
*------------------------------------------------------------------------- |
||||||
|
*/ |
||||||
#ifndef IP_H |
#ifndef IP_H |
||||||
#define IP_H |
#define IP_H |
||||||
#include "c.h" |
|
||||||
#include <sys/socket.h> |
|
||||||
#include <netdb.h> |
|
||||||
#include "libpq/pqcomm.h" |
|
||||||
#ifndef HAVE_GETADDRINFO |
|
||||||
#include "getaddrinfo.h" |
#include "getaddrinfo.h" |
||||||
#endif |
#include "libpq/pqcomm.h" |
||||||
|
|
||||||
|
|
||||||
|
extern int getaddrinfo2(const char *hostname, const char *servname, |
||||||
|
const struct addrinfo *hintp, |
||||||
|
struct addrinfo **result); |
||||||
|
extern void freeaddrinfo2(int hint_ai_family, struct addrinfo *ai); |
||||||
|
|
||||||
int getaddrinfo2(const char *hostname, const char *servname, |
extern char *SockAddr_ntop(const SockAddr *sa, char *dst, size_t cnt, |
||||||
const struct addrinfo *hintp, struct addrinfo **result); |
int v4conv); |
||||||
void freeaddrinfo2(int hint_ai_family, struct addrinfo *ai); |
extern int SockAddr_pton(SockAddr *sa, const char *src); |
||||||
|
|
||||||
char *SockAddr_ntop(const SockAddr *sa, char *dst, size_t cnt, int v4conv); |
extern int isAF_INETx(const int family); |
||||||
int SockAddr_pton(SockAddr *sa, const char *src); |
extern int rangeSockAddr(const SockAddr *addr, const SockAddr *netaddr, |
||||||
int isAF_INETx(const int family); |
const SockAddr *netmask); |
||||||
int rangeSockAddr(const SockAddr *addr, const SockAddr *netaddr, |
|
||||||
const SockAddr *netmask); |
|
||||||
int rangeSockAddrAF_INET(const SockAddr *addr, const SockAddr *netaddr,
|
|
||||||
const SockAddr *netmask); |
|
||||||
#ifdef HAVE_IPV6 |
|
||||||
int rangeSockAddrAF_INET6(const SockAddr *addr, const SockAddr *netaddr,
|
|
||||||
const SockAddr *netmask); |
|
||||||
void convSockAddr6to4(const SockAddr *src, SockAddr *dst); |
|
||||||
#endif |
|
||||||
|
|
||||||
#endif /* IP_H */ |
#endif /* IP_H */ |
||||||
|
@ -1,6 +1,8 @@ |
|||||||
if test "$GCC" = yes ; then |
if test "$GCC" = yes ; then |
||||||
CFLAGS=-O2 |
CPPFLAGS="-D_XOPEN_SOURCE_EXTENDED" |
||||||
|
CFLAGS="-O2" |
||||||
else |
else |
||||||
CC="$CC -Ae" |
CC="$CC -Ae" |
||||||
CFLAGS=+O2 |
CPPFLAGS="-D_XOPEN_SOURCE_EXTENDED" |
||||||
|
CFLAGS="+O2" |
||||||
fi |
fi |
||||||
|
Loading…
Reference in new issue