Detect the presence of posix locks even without linked to libpthread.