Fix pthread barries broken on previous commit
Also compile on FreeBSD 5.4