From 42b3f10b5e461496aab1f74d24103d6902ebfcd5 Mon Sep 17 00:00:00 2001 From: Richard Levitte Date: Wed, 8 Jan 2020 11:52:38 +0100 Subject: [PATCH] When deprecated symbols are removed, ensure liblegacy has WHIRLPOOL The legacy module implements WHIRLPOOL, so we must ensure it has the full functionality, even when libcrypto stops exporting the symbols. Reviewed-by: Matt Caswell Reviewed-by: Tomas Mraz Reviewed-by: Paul Dale (Merged from https://github.com/openssl/openssl/pull/10779) --- crypto/whrlpool/build.info | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/crypto/whrlpool/build.info b/crypto/whrlpool/build.info index 6630a779f4..c489718858 100644 --- a/crypto/whrlpool/build.info +++ b/crypto/whrlpool/build.info @@ -17,13 +17,21 @@ IF[{- !$disabled{asm} -}] ENDIF ENDIF -SOURCE[../../libcrypto]=wp_dgst.c $WPASM - # Implementations are now spread across several libraries, so the defines # need to be applied to all affected libraries and modules. -DEFINE[../../libcrypto]=$WPDEF DEFINE[../../providers/libimplementations.a]=$WPDEF +SOURCE[../../libcrypto]=wp_dgst.c $WPASM +DEFINE[../../libcrypto]=$WPDEF + +# When all deprecated symbols are removed, libcrypto doesn't export the +# WHIRLPOOL functions, so we must include them directly in liblegacy.a +IF[{- $disabled{"deprecated"} + && (defined $config{"api"} && $config{"api"} >= 30000) -}] + SOURCE[../../providers/liblegacy.a]=wp_dgst.c $WPASM + DEFINE[../../providers/liblegacy.a]=$WPDEF +ENDIF + GENERATE[wp-mmx.s]=asm/wp-mmx.pl DEPEND[wp-mmx.s]=../perlasm/x86asm.pl -- 2.25.1