Skip to content

Commit

Permalink
update libwolfssl search for older tools and static library
Browse files Browse the repository at this point in the history
  • Loading branch information
JacobBarthelmeh committed Mar 11, 2024
1 parent f92b076 commit 710d7e5
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ AC_ARG_WITH([liboqs],
)

#wolfssl
AC_MSG_CHECKING([for wolfSSL])
if test "x$prefix" = "xNONE"
then
wcpath=$ac_default_prefix
Expand All @@ -125,7 +124,20 @@ AC_ARG_WITH(wolfssl,
]
)

AC_CHECK_LIB([wolfssl],[wolfCrypt_Init],,[AC_MSG_ERROR([libwolfssl is required for ${PACKAGE}. It can be obtained from https://www.wolfssl.com/download.html/ .])])
HAVE_WOLFSSL="0"
AC_CHECK_LIB([wolfssl],[wolfCrypt_Init],[HAVE_WOLFSSL="1"],)

# Double check if is a static library
if test ${HAVE_WOLFSSL} = "0" ; then
AC_MSG_CHECKING([for libwolfssl.a])
if test -f "${wcpath}/lib/libwolfssl.a"; then
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
AC_MSG_ERROR([libwolfssl is required for ${PACKAGE}. It can be obtained from https://www.wolfssl.com/download.html/ .])
fi
fi

AC_CHECK_FUNCS([gethostbyname getaddrinfo gettimeofday inet_ntoa memset socket wc_ecc_set_rng])
AC_CHECK_DECLS([[pread],[pwrite]],,[unistd.h])

Expand Down

0 comments on commit 710d7e5

Please sign in to comment.