summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Groffen <grobian@gentoo.org>2023-04-25 16:49:09 +0200
committerFabian Groffen <grobian@gentoo.org>2023-04-25 16:50:14 +0200
commit89dc47953394cbd86d303b939a7c77e1905a2af8 (patch)
treecffe64318766702c546ac7f0c87b74d2c297912e /dev-libs/libgcrypt/files
parentapp-emacs/shut-up: Keyword 0.3.3 sparc, #905075 (diff)
downloadgentoo-89dc47953394cbd86d303b939a7c77e1905a2af8.tar.gz
gentoo-89dc47953394cbd86d303b939a7c77e1905a2af8.tar.bz2
gentoo-89dc47953394cbd86d303b939a7c77e1905a2af8.zip
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 <grobian@gentoo.org>
Diffstat (limited to 'dev-libs/libgcrypt/files')
-rw-r--r--dev-libs/libgcrypt/files/libgcrypt-1.10.2-darwin.patch20
1 files changed, 20 insertions, 0 deletions
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
+ {