Description:
make[2]: Entering directory `/usr/src/redhat/BUILD/mysql-4.0.17/libmysql_r'
source='libmysql.c' object='libmysql.lo' libtool=yes \
depfile='.deps/libmysql.Plo' tmpdepfile='.deps/libmysql.TPlo' \
depmode=gcc3 /bin/sh ../depcomp \
/bin/sh ../libtool --mode=compile gcc -DDEFAULT_CHARSET_HOME="\"/\"" -DDATADIR="\"/var/lib/mysql\"" -DSHAREDIR="\"/usr/share/mysql\"" -DDONT_USE_RAID -I. -I. -I.. -I./../include -I../include -I./.. -I.. -I.. -O3 -DDBUG_OFF -O2 -g -march=i386 -mcpu=i686 -c -o libmysql.lo `test -f libmysql.c || echo './'`libmysql.crm -f .libs/libmysql.lo
gcc -DDEFAULT_CHARSET_HOME=\"/\" -DDATADIR=\"/var/lib/mysql\" -DSHAREDIR=\"/usr/share/mysql\" -DDONT_USE_RAID -I. -I. -I.. -I./../include -I../include -I./.. -I.. -I.. -O3 -DDBUG_OFF -O2 -g -march=i386 -mcpu=i686 -c libmysql.c -MT libmysql.lo -MD -MP -MF .deps/libmysql.TPlo -fPIC -DPIC -o .libs/libmysql.lo
libmysql.c: In function `mysql_real_connect':
libmysql.c:1797: warning: passing arg 5 of `gethostbyname_r' from incompatible pointer type
libmysql.c:1797: too few arguments to function `gethostbyname_r'
libmysql.c:1797: warning: assignment makes pointer from integer without a cast
make[2]: *** [libmysql.lo] Error 1
make[2]: Leaving directory `/usr/src/redhat/BUILD/mysql-4.0.17/libmysql_r'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/redhat/BUILD/mysql-4.0.17'
make: *** [all] Error 2
How to repeat:
rpmbuild --rebuild MySQL-4.0.17.src.rpm
Using the src.rpm from MySQL.com
Suggested fix:
According to the gethostbyname_r documentation the structure is now:
int gethostbyname_r (const char *name,
struct hostent *ret, char *buf, size_t buflen,
struct hostent **result, int *h_errnop);
I'll see if I can get a fix for libmysql_r/libmysql.c and include/my_net.h