Add test for krb5 thread safety

This adds a test that checks the return value of krb5_is_thread_safe()
to see if krb5 is thread safe (during build) and issues a warning if it
is not.

nslcd does not directly link to krb5 but the library may be loaded (by
GSSAPI) if Kerberos is used to authenticate nslcd to the LDAP server.