FreeBSD needs to link against pthread