build: fix building under windows with thread support Fixes: 972289f3 ("Detect existence of pthread_mutexattr_setprotocol()")