support for kfreebsd and old FreeBSD systems.

should fix issue #12