fix freebsd support
Merge pull request #2 from myfreeweb/master

fix freebsd support