[PATCH] build: fix logic for enabling libssh/libssh2 checks