Add support for musl libc
musl does not support pthread_rwlockattr_setkind_np. Don't use it if it is
not available.
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 1ce4ddf..9b1a93a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -188,6 +188,7 @@
set(CMAKE_REQUIRED_LIBRARIES pthread)
check_include_file(stdatomic.h HAVE_STDATOMIC)
check_function_exists(pthread_mutex_timedlock HAVE_PTHREAD_MUTEX_TIMEDLOCK)
+check_function_exists(pthread_rwlockattr_setkind_np HAVE_PTHREAD_RWLOCKATTR_SETKIND_NP)
# dependencies - openssl
if(ENABLE_TLS OR ENABLE_DNSSEC OR ENABLE_SSH)