Edit report at https://bugs.php.net/bug.php?id=55172&edit=1
ID: 55172
User updated by: josh at joshbutts dot com
Reported by: josh at joshbutts dot com
Summary: Compile fails on sprintf.lo
Status: Open
Type: Bug
Package: Compile Failure
Operating System: MacOS 10.7
PHP Version: 5.3.6
Block user comment: N
Private report: N
New Comment:
Wonder if this might be a problem with detecting the presence of strnlen().
Commenting this in main/sprintf.c fixes the problem:
#if !HAVE_STRNLEN
static size_t strnlen(const char *s, size_t maxlen) {
char *r = memchr(s, '\0', maxlen);
return r ? r-s : maxlen;
}
#endif
Previous Comments:
------------------------------------------------------------------------
[2011-07-10 21:16:13] josh at joshbutts dot com
Description:
------------
When downloading the source tarball for 5.3.6, a vanilla ./configure followed
by a make fails.
gcc info:
i686-apple-darwin11-llvm-gcc-4.2
Expected result:
----------------
No error
Actual result:
--------------
/Users/josh/php-5.3.6/main/spprintf.c:186: error: static declaration of
âstrnlenâ follows non-static declaration
/usr/include/string.h:143: error: previous declaration of âstrnlenâ was here
make: *** [main/spprintf.lo] Error 1
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=55172&edit=1