Fix detection of gethostbyaddr{,_r} to not prefer the non-thread safe BSD version
Add discriminiation of gethostbyname{,_r} similar to gethostbyaddr{,_r}
Make BSDSTYLE an actual value.
Make ip_getaddr() use a threadsafe gethostbyname_r if available.
Based (almost completely) on a patch by Oliver Graf <ograf@rz-online.net>:
http://lists.cistron.nl/archives/freeradius-users/2003/06/msg00686.html
With correction by Paul Hampson <Paul.Hampson@Pobox.Com> as mentioned:
http://lists.cistron.nl/archives/freeradius-users/2003/06/msg00702.html