Make changes so that this runs on FreeBSD.