Support building recursor on GNU/kFreeBSD and GNU/Hurd

Based on Debian patches by Matthijs Möhlmann <matthijs@cacholong.nl>.

Please also merge this into Recursor 3.6.0.