AC_CHECK_LIB([config], [config_init], [], [AC_MSG_ERROR([could not find libconfig])])
AS_IF([test "x$with_ssl" = xpolarssl], [
AC_CHECK_HEADERS([polarssl/ssl.h], [], [AC_MSG_ERROR([could not find polarssl/ssl.h])])
AC_CHECK_LIB([config], [config_init], [], [AC_MSG_ERROR([could not find libconfig])])
AS_IF([test "x$with_ssl" = xpolarssl], [
AC_CHECK_HEADERS([polarssl/ssl.h], [], [AC_MSG_ERROR([could not find polarssl/ssl.h])])