Skip to content

Commit 95acb13

Browse files
committed
Merge branch 'bc/csprng-mktemps'
Build fix. * bc/csprng-mktemps: git-compat-util: really support openssl as a source of entropy
2 parents 327933f + 5b52d9f commit 95acb13

File tree

3 files changed

+6
-1
lines changed

3 files changed

+6
-1
lines changed

Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1972,6 +1972,7 @@ endif
19721972

19731973
ifneq ($(findstring openssl,$(CSPRNG_METHOD)),)
19741974
BASIC_CFLAGS += -DHAVE_OPENSSL_CSPRNG
1975+
EXTLIBS += -lcrypto -lssl
19751976
endif
19761977

19771978
ifneq ($(PROCFS_EXECUTABLE_PATH),)

git-compat-util.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -525,6 +525,10 @@ void warning_errno(const char *err, ...) __attribute__((format (printf, 1, 2)));
525525
#include <openssl/x509v3.h>
526526
#endif /* NO_OPENSSL */
527527

528+
#ifdef HAVE_OPENSSL_CSPRNG
529+
#include <openssl/rand.h>
530+
#endif
531+
528532
/*
529533
* Let callers be aware of the constant return value; this can help
530534
* gcc with -Wuninitialized analysis. We restrict this trick to gcc, though,

imap-send.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
#include "exec-cmd.h"
2828
#include "run-command.h"
2929
#include "parse-options.h"
30-
#ifdef NO_OPENSSL
30+
#if defined(NO_OPENSSL) && !defined(HAVE_OPENSSL_CSPRNG)
3131
typedef void *SSL;
3232
#endif
3333
#ifdef USE_CURL_FOR_IMAP_SEND

0 commit comments

Comments
 (0)