fix compilation under FreeBSD