[PATCH] mini-gmp: Use long long limb on WIN64

Jonas Hahnfeld hahnjo at hahnjo.de
Sun Feb 15 10:32:01 CET 2026


This matches the configure choice.

diff -r b54d1f94b4ee -r c9ba5a8af3ce mini-gmp/mini-gmp.h
--- a/mini-gmp/mini-gmp.h       Wed Sep 24 15:34:54 2025 +0200
+++ b/mini-gmp/mini-gmp.h       Sun Feb 15 10:25:19 2026 +0100
@@ -54,8 +54,13 @@
                              void (**) (void *, size_t));
 
 #ifndef MINI_GMP_LIMB_TYPE
+#ifdef _WIN64
+/* On Windows, long is always 32 bits even on 64-bit */
+#define MINI_GMP_LIMB_TYPE long long
+#else
 #define MINI_GMP_LIMB_TYPE long
 #endif
+#endif
 
 typedef unsigned MINI_GMP_LIMB_TYPE mp_limb_t;
 typedef long mp_size_t;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mini-gmp-long-long.patch
Type: text/x-patch
Size: 829 bytes
Desc: not available
URL: <https://gmplib.org/list-archives/gmp-devel/attachments/20260215/56297166/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: This is a digitally signed message part
URL: <https://gmplib.org/list-archives/gmp-devel/attachments/20260215/56297166/attachment-0001.bin>


More information about the gmp-devel mailing list