Fix stack_t.ss_sp type difference for FreeBSD.
Fix file data syncing for FreeBSD.
Fix build error in javascript driver.

Protoc-js does not always create folder for given output path. We need
to create it explicitly in build procedure.
Fix GCC48 linking error on FreeBSD.
Fix NULL casting error for clang.

When using clang3.1/-std=c++0x, the casting of NULL will cause error:
 reinterpret_cast from 'nullptr_t' to 'memcached_value_t *' is not
 allowed.

For c++11, NULL (nullptr) is defined as nullptr_t and should not be
re-casted to other pointer types.
Add missing header for time_t in utils.hpp.
Fix "gmake install" on FreeBSD.

install(1) on FreeBSD does not allow reading file content from
/dev/stdin, so we must create a real file in build directory before
calling install.
Support systems without python in /usr/bin (Ex, FreeBSD).
Add -pthread for FreeBSD build procedure.

Required by boost library.
Add FreeBSD build environment settings.
Support FreeBSD 9.x clang / libc++ ABI v1.

The C++ ABI v1 on FreeBSD 9.x clang is different with GCC 4.x ABI v1.
Support clang/c++11 on FreeBSD.

Requires FreeBSD 9.1 (clang 3.1+) and the libc++ from
/usr/src/lib/libc++.
Fix configure default LD search path.

For systems using ldconfig with different syntax (ex, FreeBSD or
MacOSX), we need to fallback LD path to defaults.
Add FreeBSD into configure host list.

Tested on FreeBSD 9.1 with following steps:

 # For dependency
 pkg_add -r wget protobuf protobuf-c v8 openjdk7 boost-all gmake
 pkg_add -r bash node npm py-yaml gcc48
 npm install -g less coffee-script handlebars

 # To build with GCC48:
 CXX=gcc48 ./configure --ccache
 # Edit config.mk to add "ALLOW_WARNINGS := 1"

 # To build with system clang 3.1:
 CXX=clang ./configure --ccache
 # You have to install system libc++ by:
 #  cd /usr/src/lib/libc++; sudo make install
 # Then edit config.mk to add "ALLOW_WARNINGS := 1"

 # To build
 gmake