[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: OpenLDAP ITS - Build/964 (ITS#1025)



I don't know what to suggest to fix configure's problem with Solaris-2.7
and GETADDRINFO, but here is some more information.

==========================================================
/bin/sh /var/stage/openldap-2.0.7/libtool  --mode=compile gcc -g -O2 -I../../include -I../../include   -I/usr/local/include -I/usr/local/ssl/include -I/usr/local/BerkeleyDB/include   -c os-ip.c
rm -f .libs/os-ip.lo
gcc -g -O2 -I../../include -I../../include -I/usr/local/include -I/usr/local/ssl/include -I/usr/local/BerkeleyDB/include -c os-ip.c  -fPIC -DPIC -o .libs/os-ip.lo
os-ip.c: In function `ldap_connect_to_host':
os-ip.c:303: storage size of `hints' isn't known
os-ip.c:318: dereferencing pointer to incomplete type
os-ip.c:328: dereferencing pointer to incomplete type
os-ip.c:342: dereferencing pointer to incomplete type
os-ip.c:349: dereferencing pointer to incomplete type
os-ip.c:349: dereferencing pointer to incomplete type
os-ip.c:355: dereferencing pointer to incomplete type
*** Error code 1
make: Fatal error: Command failed for target `os-ip.lo'
Current working directory /var/stage/openldap-2.0.7/libraries/libldap
*** Error code 1
make: Fatal error: Command failed for target `all-common'
Current working directory /var/stage/openldap-2.0.7/libraries
*** Error code 1
make: Fatal error: Command failed for target `all-common'
        osip_debug(ld, "ldap_connect_to_host\n",0,0,0);


==================== os-ip.c =================
        if (host != NULL) {
#ifdef HAVE_GETADDRINFO
                char serv[7];
                int err;
         303--> struct addrinfo hints, *res, *sai;

                memset( &hints, '\0', sizeof(hints) );
                hints.ai_family = AF_UNSPEC;
                hints.ai_socktype = SOCK_STREAM;

                snprintf(serv, sizeof serv, "%d", ntohs(port));
                if ( err = getaddrinfo(host, serv, &hints, &res) ) {
                        osip_debug(ld, "ldap_connect_to_host: getaddrinfo failed: %
s\n", AC_GAI_STRERROR(err), 0, 0);
                        return -1;
                }
                sai = res;
                rc = -1;
                do {
"os-ip.c" [Read only] line 303 of 652 --46%-- 


============== config.log =============
configure:5459: checking for getaddrinfo
configure:5488: gcc -o conftest -g -O2 -I/usr/local/include -I/usr/local/ssl/inc
lude -I/usr/local/BerkeleyDB/include -L/usr/local/lib -L/usr/local/ssl/libso -L/
usr/local/BerkeleyDB/lib conftest.c -lbind -lgen -lnsl -lsocket  1>&5


============== config.status ==========
${ac_uA}HAVE_RES_QUERY${ac_uB}HAVE_RES_QUERY${ac_uC}1${ac_uD}
${ac_eA}HAVE_RES_QUERY${ac_eB}HAVE_RES_QUERY${ac_eC}1${ac_eD}
${ac_dA}HAVE_GETADDRINFO${ac_dB}HAVE_GETADDRINFO${ac_dC}1${ac_dD}
${ac_uA}HAVE_GETADDRINFO${ac_uB}HAVE_GETADDRINFO${ac_uC}1${ac_uD}
${ac_eA}HAVE_GETADDRINFO${ac_eB}HAVE_GETADDRINFO${ac_eC}1${ac_eD}
CEOF


============== configure ==============
for ac_func in getaddrinfo
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
echo "configure:5459: checking for $ac_func" >&5
if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
#line 5464 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char $ac_func();
char (*f)();

int main() {
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

; return 0; }
EOF
if { (eval echo configure:5488: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && t
est -s conftest${ac_exeext}; then
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=no"
fi
rm -f conftest*



======================================
Sun Microsystems Inc.   SunOS 5.8       Generic February 2000

man getaddrinfo
Network Functions                            getaddrinfo(3SOCKET)



NAME
     getaddrinfo,  getnameinfo,  freeaddrinfo,   gai_strerror   -
     translate between node name and address

SYNOPSIS
     cc [flag ...] file ... -lsocket -lnsl [library ...]
     #include <sys/socket.h>
     #include <netdb.h>

     int getaddrinfo(const char *nodename, const char  *servname,
     const struct addrinfo *hints, struct addrinfo **res);

     int getnameinfo(const struct sockaddr *sa, socklen_t  salen,
     char  *host, size_t hostlen, char *serv, size_t servlen, int
     flags);

     void freeaddrinfo(struct addrinfo *ai);

     char *gai_strerror(int errcode);



====================== Solaris 2.8 ==================
grep getaddrinfo /usr/include/* | more
/usr/include/netdb.h:int                getaddrinfo(const char *, const char *,
/usr/include/netdb.h:int                getaddrinfo();
grep getaddrinfo /usr/include/sys/* | more

ll /usr/include/netdb.h
-rw-r--r--   1 root     bin        13891 Jan  5  2000 /usr/include/netdb.h


======================= Solaris 2.7 ================
man getaddrinfo
No manual entry for getaddrinfo.

grep getaddr /usr/include/*
grep getaddr /usr/include/sys/*
/usr/include/sys/sunndi.h:ndi_dc_getaddr(struct devctl_iocdata *dcp);

ll /usr/include/netdb*
-rw-r--r--   1 bin      bin        10667 Sep  1  1998 /usr/include/netdb.h