First pass on getting build working on FreeBSD.