среда, 13 октября 2010 г.

enable debug symbols in libc

в freebsd release не включен debug в libc , из-за чего нет возможности эффективно использовать gdb


cd /usr/src/lib/libc
make cleandir obj
make DEBUG_FLAGS=-g && make install

понедельник, 4 октября 2010 г.

php 5.3.3 freebsd 8.1 build error

error while build
main/spprintf.c:186 static declaration of 'strnlen' follows non-static declaration  freebsd
/usr/include/string.h:105: error: previous declaration of 'strnlen' was here

go to the line 186 in main/spprintf.c

find  this block of code and comment it
static size_t strnlen(const char *s, size_t maxlen) {
  char *r = memchr(s, '\0', maxlen);
  return r ? r-s : maxlen;
}