build: support older GMP versions
authorPádraig Brady <P@draigBrady.com>
Mon, 8 Oct 2012 10:38:41 +0000 (11:38 +0100)
committerPádraig Brady <P@draigBrady.com>
Mon, 8 Oct 2012 22:40:08 +0000 (23:40 +0100)
commitcf9cd8958bbf294c30b82c2d5e9ea64ef14f37b9
treec3cccfcf3679cb335ec7406c3d93ea5835a9a9e0
parent231e40a6ba29b892daca1e4a2e464c315874e155
build: support older GMP versions

The new factor code introduced usage of mpz_inits() and
mpz_clears(), which are only available since GMP >= 5,
and will result in a compile error when missing.

* m4/gmp.m4 (cu_GMP): Define HAVE_DECL_MPZ_INITS appropriately.
* src/factor (mpz_inits): New function, defined where missing.
(mpz_clears): Likewise.
m4/gmp.m4
src/factor.c