OS X / gmpy
[
Front page
] [
New
|
List of pages
|
Search
|
Recent changes
]
Start:
[[labs.beatcraft.com]]~
[[OS X]]~
#Contents
* Installing gmpy on Mac OS X [#qa0993fb]
** About gmpy [#s5593703]
>
gmpy is a Python extension module, which enables Python t...
Searching for gmpy by pip, several kinds of gmpy are foun...
$ pip search gmpy
gmpy2 - GMP/MPIR, MPFR, and MPC inte...
gmpy - GMP or MPIR interface to Pyt...
gmpy_cffi - GMP CFFI wrapper
>
For the details of gmpy, please visit the URLs below.~
For gmpy [[https://code.google.com/p/gmpy/]]~
For gmpy2 [[https://pypi.python.org/pypi/gmpy2]]~
~
The development of gmpy has been shifted from gmpy to gmp...
~
According to the webpage of GMPY, GMPY and GMPY2 are Pyth...
** Installing gmpy on Mac OS X [#rfe80ddf]
>
In this article, since both MPFR and MPC are already inst...
This article also uses Mac OS X Mavericks 10.9.3.~
To install gmpy2, [[pip>https://pypi.python.org/pypi/pip]...
$ sudo pip install gmpy2
Password:
Downloading/unpacking gmpy2
Downloading gmpy2-2.0.3.zip (279kB): 279kB downloaded
Running setup.py (path:/private/tmp/pip_build_root/gmp...
Installing collected packages: gmpy2
Running setup.py install for gmpy2
building 'gmpy2' extension
cc -fno-strict-aliasing -fno-common -dynamic -arch x...
-DENABLE_DTRACE -DMACOSX -DNDEBUG -Wall -Wstrict-pro...
-DENABLE_DTRACE -arch x86_64 -arch i386 -pipe -DWITH...
-I/System/Library/Frameworks/Python.framework/Versio...
In file included from src/gmpy2.c:508:
./src/gmpy_mpz_prp.c:1043:33: warning: implicit conv...
for (j = mpz_sizeinbase(s,2)-1; j >= 1; j--) {
~ ~~~~~~~~~~~~~~~~~~~^~
In file included from src/gmpy2.c:519:
./src/gmpy_mpz.c:1915:5: warning: implicit conversio...
PARSE_ONE_MPZ_OPT_CLONG(&reps,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./src/gmpy_args.h:123:20: note: expanded from macro ...
*var = clong_From_Integer(PyTuple_GET_IT...
~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~...
In file included from src/gmpy2.c:519:
./src/gmpy_mpz.c:1915:5: warning: implicit conversio...
PARSE_ONE_MPZ_OPT_CLONG(&reps,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./src/gmpy_args.h:137:20: note: expanded from macro ...
*var = clong_From_Integer(PyTuple_GET_IT...
~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~...
3 warnings generated.
In file included from src/gmpy2.c:480:
./src/mpz_pylong.c:55:10: warning: shift count >= wi...
if ((x >> 32) != 0) { x >>= 32; cnt += 32; }
^ ~~
./src/mpz_pylong.c:55:27: warning: shift count >= wi...
if ((x >> 32) != 0) { x >>= 32; cnt += 32; }
^ ~~
2 warnings generated.
cc -bundle -undefined dynamic_lookup -arch x86_64 -a...
-L/usr/local/lib -L/usr/local/lib -lgmp -lmpfr -lmpc...
ld: warning: ignoring file /usr/local/lib/libgmp.dyl...
ld: warning: ignoring file /usr/local/lib/libmpfr.dy...
ld: warning: ignoring file /usr/local/lib/libmpc.dyl...
Successfully installed gmpy2
Cleaning up...
>
During the installation process, several warnings will ap...
~
To check whether gmpy2 is installed correctly or not, try...
$ python
Python 2.7.5 (default, Mar 9 2014, 22:15:05)
[GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.0.68)] o...
Type "help", "copyright", "credits" or "license" for mor...
>>> import gmpy2
>>> gmpy2.mpfr("1.2")
mpfr('1.2')
>>> gmpy2.sqrt(gmpy2.mpfr("3.2"))
mpfr('1.7888543819998317')
>>> gmpy2.sin(gmpy2.mpfr(".5"))
mpfr('0.47942553860420301')
>>>
>
The details of this sample program are described at [[the...
* Revision History [#vc729c92]
>
- 2015/01/06 This article is initially uploaded
End:
[[labs.beatcraft.com]]~
[[OS X]]~
#Contents
* Installing gmpy on Mac OS X [#qa0993fb]
** About gmpy [#s5593703]
>
gmpy is a Python extension module, which enables Python t...
Searching for gmpy by pip, several kinds of gmpy are foun...
$ pip search gmpy
gmpy2 - GMP/MPIR, MPFR, and MPC inte...
gmpy - GMP or MPIR interface to Pyt...
gmpy_cffi - GMP CFFI wrapper
>
For the details of gmpy, please visit the URLs below.~
For gmpy [[https://code.google.com/p/gmpy/]]~
For gmpy2 [[https://pypi.python.org/pypi/gmpy2]]~
~
The development of gmpy has been shifted from gmpy to gmp...
~
According to the webpage of GMPY, GMPY and GMPY2 are Pyth...
** Installing gmpy on Mac OS X [#rfe80ddf]
>
In this article, since both MPFR and MPC are already inst...
This article also uses Mac OS X Mavericks 10.9.3.~
To install gmpy2, [[pip>https://pypi.python.org/pypi/pip]...
$ sudo pip install gmpy2
Password:
Downloading/unpacking gmpy2
Downloading gmpy2-2.0.3.zip (279kB): 279kB downloaded
Running setup.py (path:/private/tmp/pip_build_root/gmp...
Installing collected packages: gmpy2
Running setup.py install for gmpy2
building 'gmpy2' extension
cc -fno-strict-aliasing -fno-common -dynamic -arch x...
-DENABLE_DTRACE -DMACOSX -DNDEBUG -Wall -Wstrict-pro...
-DENABLE_DTRACE -arch x86_64 -arch i386 -pipe -DWITH...
-I/System/Library/Frameworks/Python.framework/Versio...
In file included from src/gmpy2.c:508:
./src/gmpy_mpz_prp.c:1043:33: warning: implicit conv...
for (j = mpz_sizeinbase(s,2)-1; j >= 1; j--) {
~ ~~~~~~~~~~~~~~~~~~~^~
In file included from src/gmpy2.c:519:
./src/gmpy_mpz.c:1915:5: warning: implicit conversio...
PARSE_ONE_MPZ_OPT_CLONG(&reps,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./src/gmpy_args.h:123:20: note: expanded from macro ...
*var = clong_From_Integer(PyTuple_GET_IT...
~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~...
In file included from src/gmpy2.c:519:
./src/gmpy_mpz.c:1915:5: warning: implicit conversio...
PARSE_ONE_MPZ_OPT_CLONG(&reps,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./src/gmpy_args.h:137:20: note: expanded from macro ...
*var = clong_From_Integer(PyTuple_GET_IT...
~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~...
3 warnings generated.
In file included from src/gmpy2.c:480:
./src/mpz_pylong.c:55:10: warning: shift count >= wi...
if ((x >> 32) != 0) { x >>= 32; cnt += 32; }
^ ~~
./src/mpz_pylong.c:55:27: warning: shift count >= wi...
if ((x >> 32) != 0) { x >>= 32; cnt += 32; }
^ ~~
2 warnings generated.
cc -bundle -undefined dynamic_lookup -arch x86_64 -a...
-L/usr/local/lib -L/usr/local/lib -lgmp -lmpfr -lmpc...
ld: warning: ignoring file /usr/local/lib/libgmp.dyl...
ld: warning: ignoring file /usr/local/lib/libmpfr.dy...
ld: warning: ignoring file /usr/local/lib/libmpc.dyl...
Successfully installed gmpy2
Cleaning up...
>
During the installation process, several warnings will ap...
~
To check whether gmpy2 is installed correctly or not, try...
$ python
Python 2.7.5 (default, Mar 9 2014, 22:15:05)
[GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.0.68)] o...
Type "help", "copyright", "credits" or "license" for mor...
>>> import gmpy2
>>> gmpy2.mpfr("1.2")
mpfr('1.2')
>>> gmpy2.sqrt(gmpy2.mpfr("3.2"))
mpfr('1.7888543819998317')
>>> gmpy2.sin(gmpy2.mpfr(".5"))
mpfr('0.47942553860420301')
>>>
>
The details of this sample program are described at [[the...
* Revision History [#vc729c92]
>
- 2015/01/06 This article is initially uploaded
Page: