[Python-bugs-list] [ python-Bugs-493631 ] Problem with mpz module (gmp4)

noreply@sourceforge.net noreply@sourceforge.net
Sat, 15 Dec 2001 04:17:08 -0800


Bugs item #493631, was opened at 2001-12-15 04:17
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=493631&group_id=5470

Category: Extension Modules
Group: Python 2.2
Status: Open
Resolution: None
Priority: 5
Submitted By: Damien Wyart (chlick)
Assigned to: Nobody/Anonymous (nobody)
Summary: Problem with mpz module (gmp4)

Initial Comment:
Trying to compile latest Python-2.2 (rc1), I found
the following problem : I can't compile mpzmodule.c
without modifying it.

I use gcc-3.0.2 and gmp-4.0. I am not a gmp not a
Python expert, but the problems seems to come
mainly from lack of clear support of gmp-4 in
mpzmodule.c.

MPZ_GET_STR_BUG is obsolete now, and should not be
used with gmp-4. #ifdef cases with 
MPZ_GET_STR_BUG defined uses obsolete struct field
calls and leads to compilation problems.

In fact, gmp-mparam.h should be included in all cases
(not only when MPZ_GET_STR_BUG defined), and the whole
file should be cleaned a bit to fully support gmp4.
including longlong.h is not necessary.

For now, there are two alternatives : gmp is gmp-2 and
is really bogus, or gmp is not 2 and is bogus with
respect to MPZ_GET_STR_BUG. The alternative "gmp-4"
(not bogus) should be added.

----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=493631&group_id=5470