use libcrypt before libcrypto
Albert Chin
openssh-unix-dev at thewrittenword.com
Tue Jun 25 12:25:17 EST 2002
On Tue, Jun 25, 2002 at 10:58:58AM +0900, Jun-ichiro itojun Hagino wrote:
> these days many unix-based systems contain crypt() with more than
> DES support (for instance, MD5 in freebsd/openbsd/netbsd, bcrypt in
> openbsd/netbsd). we need to use crypt() in libcrypt, not in licrypto,
> as much as possible.
>
> itojun
>
> --- configure.ac.orig Tue Jun 25 10:56:47 2002
> +++ configure.ac Tue Jun 25 10:57:25 2002
> @@ -697,6 +702,9 @@
> )
> fi
>
> +# use libcrypt if there is
> +AC_CHECK_LIB(crypt, crypt, LIBS="$LIBS -lcrypt")
> +
AC_CHECK_LIB(crypt, crypt) will automatically add -lcrypt to $LIBS. It
will also define HAVE_LIBCRYPT (is this what you're trying to avoid)?
Anyway, I'd prefer:
AC_CHECK_FUNCS(crypt, , AC_CHECK_LIB(crypt, crypt))
This way we check if crypt is resolvable using the existing $LIBS and,
if not, use $LIBS+-lcrypt.
--
albert chin (china at thewrittenword.com)
More information about the openssh-unix-dev
mailing list