Skip to content

Commit e8c19ac

Browse files
authored
Merge pull request #178 from elms/autotools/fix_prefix
Fix default prefix
2 parents 2b3ebea + 24fd0c9 commit e8c19ac

1 file changed

Lines changed: 9 additions & 3 deletions

File tree

configure.ac

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,13 @@ fi
129129
# wolfSSL/wolfCrypt
130130
AC_MSG_CHECKING([for wolfSSL/wolfCrypt
131131
])
132-
wcpath=$prefix
132+
if test "x$prefix" = "xNONE"
133+
then
134+
wcpath=$ac_default_prefix
135+
else
136+
wcpath=$prefix
137+
fi
138+
AC_MSG_NOTICE([prefix ${prefix}])
133139
WOLFSSL_URL="http://www.wolfssl.com/download.html"
134140
AC_ARG_WITH(wolfcrypt,
135141
[AC_HELP_STRING([--with-wolfcrypt=PATH], [PATH to wolfssl install (default /usr/local)])],
@@ -171,9 +177,9 @@ then
171177
LIBS="$save_LIBS"
172178
])
173179

174-
if test "x$ac_cv_libwolfssl" = "xno" && test "x$ENABLED_WOLFCRYPT" = "xno"; then
180+
if test "x$ac_cv_libwolfssl" = "xno" && test "x$ENABLED_WOLFCRYPT" != "xno"; then
175181
AC_MSG_ERROR([WolfSSL library not found. You can get it from $WOLFSSL_URL
176-
If it's already installed, specify its path using --with-wolfcrypt=/dir/])
182+
If it's already installed, specify its path using --with-wolfcrypt=/dir or --prefix=/dir])
177183
fi
178184
else
179185
AM_CFLAGS="$AM_CFLAGS -DWOLFTPM2_NO_WOLFCRYPT"

0 commit comments

Comments
 (0)