From 89dc47953394cbd86d303b939a7c77e1905a2af8 Mon Sep 17 00:00:00 2001 From: Fabian Groffen Date: Tue, 25 Apr 2023 16:49:09 +0200 Subject: dev-libs/libgcrypt-1.10.2: fix compilation on Darwin, #904083 Add patch as suggested on upstream bug to fix compilation on non-Linux. Closes: https://bugs.gentoo.org/904083 Signed-off-by: Fabian Groffen --- .../libgcrypt/files/libgcrypt-1.10.2-darwin.patch | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 dev-libs/libgcrypt/files/libgcrypt-1.10.2-darwin.patch (limited to 'dev-libs/libgcrypt/files') diff --git a/dev-libs/libgcrypt/files/libgcrypt-1.10.2-darwin.patch b/dev-libs/libgcrypt/files/libgcrypt-1.10.2-darwin.patch new file mode 100644 index 000000000000..6153f1840b97 --- /dev/null +++ b/dev-libs/libgcrypt/files/libgcrypt-1.10.2-darwin.patch @@ -0,0 +1,20 @@ +https://dev.gnupg.org/T6442 + +Patch as suggested by Werned in https://dev.gnupg.org/T6442#169396 + +--- a/random/rndgetentropy.c ++++ b/random/rndgetentropy.c +@@ -94,8 +94,13 @@ + * and might not be applicable on other FIPS modules not running + * RHEL kernel. + */ ++#ifdef GRND_RANDOM + nbytes = length < 32 ? length : 32; + ret = getrandom (buffer, nbytes, GRND_RANDOM); ++#else ++ ret = -1; ++ gpg_err_set_errno (ENOSYS); ++#endif + } + else + { -- cgit v1.2.3-65-gdbad