From c495301bf8cd3a05512e702af212631abab52b88 Mon Sep 17 00:00:00 2001 From: Darren Tucker Date: Thu, 16 Mar 2006 08:14:34 +1100 Subject: [PATCH] - (dtucker) [configure.ac md-sha256.c] NetBSD has sha2.h in /usr/include/crypto. Hint from djm@. --- ChangeLog | 4 +++- configure.ac | 5 +++-- md-sha256.c | 8 ++++++-- 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 308f9d1ec..1c4fdef89 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,7 @@ 20060316 - (dtucker) [entropy.c] Add headers for WIFEXITED and friends. + - (dtucker) [configure.ac md-sha256.c] NetBSD has sha2.h in + /usr/include/crypto. Hint from djm@. 20060315 - (djm) OpenBSD CVS Sync: @@ -4176,4 +4178,4 @@ - (djm) Trim deprecated options from INSTALL. Mention UsePAM - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu -$Id: ChangeLog,v 1.4225 2006/03/15 20:21:35 dtucker Exp $ +$Id: ChangeLog,v 1.4226 2006/03/15 21:14:34 dtucker Exp $ diff --git a/configure.ac b/configure.ac index f8faa2660..9e037ab0e 100644 --- a/configure.ac +++ b/configure.ac @@ -1,4 +1,4 @@ -# $Id: configure.ac,v 1.337 2006/03/15 11:28:17 dtucker Exp $ +# $Id: configure.ac,v 1.338 2006/03/15 21:14:34 dtucker Exp $ # # Copyright (c) 1999-2004 Damien Miller # @@ -15,7 +15,7 @@ # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. AC_INIT(OpenSSH, Portable, openssh-unix-dev@mindrot.org) -AC_REVISION($Revision: 1.337 $) +AC_REVISION($Revision: 1.338 $) AC_CONFIG_SRCDIR([ssh.c]) AC_CONFIG_HEADER(config.h) @@ -669,6 +669,7 @@ dnl Checks for header files. AC_CHECK_HEADERS( \ bstring.h \ crypt.h \ + crypto/sha2.h \ dirent.h \ endian.h \ features.h \ diff --git a/md-sha256.c b/md-sha256.c index ff7f38157..0b1ed5828 100644 --- a/md-sha256.c +++ b/md-sha256.c @@ -22,8 +22,12 @@ #include #include -#if defined(HAVE_SHA2_H) && defined(HAVE_SHA256_UPDATE) -# include +#ifdef HAVE_SHA256_UPDATE +# ifdef HAVE_SHA2_H +# include +# elif defined(HAVE_CRYPTO_SHA2_H) +# include +# endif #endif RCSID("$OpenBSD: md-sha256.c,v 1.1 2006/03/07 09:07:40 djm Exp $");