Fixes required to build the game on FreeBSD