Joachim Schmitz wrote: > Problem with HOST_NAME_MAX (MAXHOSTNAMELEN is set to 64 in <arpa/nameser.h>, > added this to gllib/unistd.in.h, but don't think it belongs there): > char buf[HOST_NAME_MAX]; > ^ > "/usr/local/Floss/gnulib/testdir-posix/gltests/test-gethostname.c", line 38: > error(163): > incomplete type is not allowed > > > if (strlen (NOHOSTNAME) >= HOST_NAME_MAX) > ^ > "/usr/local/Floss/gnulib/testdir-posix/gltests/test-gethostname.c", line 41: > error(123): > expected an expression
What's going on here? If HOST_NAME_MAX is not defined in <limits.h>, HOST_NAME_MAX ought to be defined in config.h, after the code from m4/gethostname.m4 has been executed. A look in config.log should tell you what went on here (check out for "checking for HOST_NAME_MAX"). Bruno