Forums

I am trying to install gmpy2 but it's showing error

I am trying to install python package gmpy2 using pip. But it's showing the following error.

1.Failed building wheel for gmpy2

2.Command "/home/soniya/.virtualenvs/django19/bin/python2.7 -u -c "import setuptools, tokenize;file='/tmp/pip-build-jsMT34/gmpy2/setup.py';exec(co mpile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" install --record /tmp/pip-XQkd7X-record/install-re cord.txt --single-version-externally-managed --compile --install-headers /home/soniya/.virtualenvs/django19/include/site/python2.7/gmpy2" failed wit h error code 1 in /tmp/pip-build-jsMT34/gmpy2/

That is because one of gmpy2 requires some system level libraries that we don't have installed.

We will look into getting these installed in our next system image build. In the meantime, you should be able to compile those binaries yourself: see the detailed instructions part here.

By the way, we do have gmpy installed. Would that work?

Thanks. I will go through the link.

I am calculating fibonacci number for large range and to compress the fibonacci number gmpy2 is helping.