[Patches] Patch to src/Modules/mpzmodule.c
Andrew M. Kuchling
akuchlin@mems-exchange.org
Thu, 24 Feb 2000 10:32:18 -0500 (EST)
Peter Funk writes:
>This patch allows building the Python 'mpzmodule' under SuSE Linux
>without having to install the source package of the GMP-libary.
>The gmp-mparam.h seems to be an internal header file. The patch
>shouldn't hurt any other platforms.
>+ #if defined __GLIBC__ && __GLIBC__ >= 2 /*aid building on Linux distributions*/
>+ #define BITS_PER_MP_LIMB mp_bits_per_limb
>+ #else
> #include "gmp-mparam.h"
>+ #endif
This seems like the wrong fix, tying GMP to the version of glibc!
(They haven't rolled GMP into glibc, have they?) If GMP 2.0 exposes
an mp_bits_per_limb constant, then the correct patch may just be
changing BITS_PER_MP_LIMB to mp_bits_per_limb, inside an #ifdef GMP2
if necessary.
--
A.M. Kuchling http://starship.python.net/crew/amk/
"I'm your new assistant."
"Oh, *no*."
-- Jo Grant and the Doctor, in "Terror of the Autons"