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

Use of gethostbyaddr_r on openSUSE



HI!

I'm still fighting with building newer OpenLDAP RPMs for openSUSE.

Originally Ralf Haferkamp generated the .spec files several years ago but is
not involved anymore.

He added this patch:

https://build.opensuse.org/package/view_file/home:stroeder:branches:network:ldap/openldap2/0004-libldap-use-gethostbyname_r.dif?expand=1

This patch seems to fail now (see below). I'm inclined to remove it but I
wonder whether it might be still needed/useful today.

Ciao, Michael.

------------------------ snip ------------------------
[   85s] configure:20167: cc -c -Wno-format-extra-args -fno-strict-aliasing
-DSLAP_CONFIG_DELETE -DSLAP_SCHEMA_EXPOSE -DLDAP_COLLECTIVE_ATTRIBUTES
conftest.c >&5
[   85s] configure:20167: $? = 0
[   85s] configure:20189: result: 6
[   85s] configure:20204: checking number of arguments of gethostbyaddr_r
[   85s] configure:20229: cc -c -Wno-format-extra-args -fno-strict-aliasing
-DSLAP_CONFIG_DELETE -DSLAP_SCHEMA_EXPOSE -DLDAP_COLLECTIVE_ATTRIBUTES
conftest.c >&5
[   85s] conftest.c: In function 'main':
[   85s] conftest.c:139:43: warning: passing argument 7 of 'gethostbyaddr_r'
from incompatible pointer type [-Wincompatible-pointer-types]
[   85s]     alen, AF_INET, &hent, buffer, bufsize, &h_errno);
[   85s]                                            ^
[   85s] In file included from conftest.c:129:0:
[   85s] /usr/include/netdb.h:172:12: note: expected 'struct hostent **
restrict' but argument is of type 'int *'
[   85s]  extern int gethostbyaddr_r (const void *__restrict __addr,
__socklen_t __len,
[   85s]             ^
[   85s] conftest.c:138:9: error: too few arguments to function 'gethostbyaddr_r'
[   85s]    (void)gethostbyaddr_r( (void *)&(add.s_addr),
[   85s]          ^
[   85s] In file included from conftest.c:129:0:
[   85s] /usr/include/netdb.h:172:12: note: declared here
[   85s]  extern int gethostbyaddr_r (const void *__restrict __addr,
__socklen_t __len,
[   85s]             ^
[   85s] configure:20229: $? = 1
[   85s] configure: failed program was:
[   85s] | /* confdefs.h */

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature