As libssl depends on libcrypto, -lssl needs to precede -lcrypto in linker invocations or else the build will fail with static OpenSSL libraries. Adjust m4/ax_check_openssl.m4 to prevent this issue from getting triggered when pkg-config files for OpenSSL are not available.