Only #include <sys/tls.h> on NetBSD

Sponsored by: EMC / Isilon Storage Division
#include libutil.h for fparseln on FreeBSD

Sponsored by: EMC / Isilon Storage Division