Use AC_CHECK_LIB for ssl and crypto
diff --git a/configure.ac b/configure.ac
index 4bcfd0f..5cfd9ca 100644
--- a/configure.ac
+++ b/configure.ac
@@ -12,7 +12,10 @@
AC_LANG([C++])
AX_CXX_COMPILE_STDCXX_11(, optional)
-AX_CHECK_OPENSSL
+AC_CHECK_LIB([ssl], [SSL_library_init], [],
+ [AC_MSG_FAILURE([can't find openssl ssl lib])])
+AC_CHECK_LIB([crypto], [EVP_EncryptInit], [],
+ [AC_MSG_FAILURE([can't find openssl crypto lib])])
AC_MSG_CHECKING([for std::shared_ptr])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM(