Enable build on OpenBSD

Hi. Here is couple of patches from OpenBSD ports tree. They are needed for building ufoai.