glibc-2.8 no loner provides the ARG_MAX macro. --- tnftp-20070806/libnetbsd/glob.c +++ tnftp-20070806/libnetbsd/glob.c @@ -55,6 +55,8 @@ * Number of matches in the current invocation of glob. */ +#include + #include "tnftp.h" #undef TILDE /* XXX: AIX 4.1.5 has this in */ @@ -720,7 +722,7 @@ } pathv[pglob->gl_offs + pglob->gl_pathc] = NULL; - if ((pglob->gl_flags & GLOB_LIMIT) && (newsize + *limit) >= ARG_MAX) { + if ((pglob->gl_flags & GLOB_LIMIT) && (newsize + *limit) >= sysconf(_SC_ARG_MAX)) { errno = 0; return(GLOB_NOSPACE); }