Bug #75
closedbug when compile on HP-UX...
Description
for information have used this option to compile on hp-ux:
MYSQL_DIR=/opt/mysql LOCALDIR=/usr/local export CC=gcc export UNIX95=true export EGREP="grep -E" export CPP="gcc -E" export MYCFLAGS="-DHAVE_SOCKLEN_T -DHAVE_HTONL -DHAVE_MMAP \ -D_HPUX_SOURCE -D_XOPEN_SOURCE_EXTENDED \ -D_REENTRANT -D_POSIX_C_SOURCE=199506L" export CFLAGS="$MYCFLAGS -I$LOCALDIR/include/ -I$MYSQL_DIR/include" export CPPFLAGS="$MYCFLAGS -I$LOCALDIR/include/ -I$MYSQL_DIR/include" export LDFLAGS="-L$LOCALDIR/lib -lm" ./configure --prefix=/usr/local/lighttpd --with-ldap --with-attr --with-openssl --with-mysql=$MYSQL_DIR/bin/mysql_config --enable-lfs gmake [ $? -eq 0 ] && gmake install
hp-ux have symbol hsterror defined in here include but they not exist in library... hsterror seem to be bsd compliante... and strerror make the same thing and are ansi compliante...
have defined "hstrerror(x) strerror(x)" in file ./src/sys-socket.h after "#include <netdb.h>":
#ifdef _HPUX_SOURCE
#define hstrerror(x) strerror(x)
#endif
but i think is more clean to use strerror (you use it in the reste of the program!) than hstrerror is more compliante...
Best regards,
Mathieu
-- Mathieu CARBONNEAUX <info
Updated by Anonymous over 18 years ago
more readable patch:
#ifdef _HPUX_SOURCE #define hstrerror(x) strerror(x) #endif
-- Mathieu CARBONNEAUX <info
Updated by jan over 18 years ago
- Status changed from New to Fixed
- Resolution set to fixed
I have no reference found that strerror is able to handle it. I just removed hstrerror() from the code and just print the error-code.
FIxed in changeset r310
Also available in: Atom