[PATCH] Final FreeBSD compile fixups

It actually builds now!
6 files changed