Build fix: Check if pthread_setname_np() is available.