Quick port to OS X.

TCP_NODELAY is probably not quite like TCP_CORK, and there's no mallinfo(),
but the main benefit is to have easy access to more modern gcc/clang.
Limit all the waits to 60 sec.