title: Installing gmpy on Mac OS X Mountain Lion
body: <p>I cannot install gmpy (1 or 2) on OS X Mountain Lion without warnings. I tried <code>pip</code>, I tried compiling, I installed gcc 4.2.1 and tried to compile gmp with i386 arch (though my Mac is 64bit), none of them are working!</p>
  
  <p>The thing is I can setup gmpy with Python 3+ without warnings but not with Python 2.7.</p>
  
  <p>The verbose I get when I use:</p>
  
  <p><code>python setup.py install</code> for gmpy2 is:</p>
  
  <pre><code>running install
  running build
  running build_ext
  building 'gmpy2' extension
  creating build/temp.macosx-10.6-intel-2.7
  creating build/temp.macosx-10.6-intel-2.7/src
  gcc-4.2 -fno-strict-aliasing -fno-common -dynamic -arch i386 -arch x86_64 -g -O2 -DNDEBUG -g -O3 -DWITHMPFR=1 -DWITHMPC=1 -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c src/gmpy2.c -o build/temp.macosx-10.6-intel-2.7/src/gmpy2.o
  In file included from src/gmpy2.c:455:
  src/mpz_pylong.c: In function ‘mpn_sizebits’:
  src/mpz_pylong.c:55: warning: right shift count &gt;= width of type
  src/mpz_pylong.c:55: warning: right shift count &gt;= width of type
  creating build/lib.macosx-10.6-intel-2.7
  gcc-4.2 -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -g build/temp.macosx-10.6-intel-2.7/src/gmpy2.o -lgmp -lmpfr -lmpc -o build/lib.macosx-10.6-intel-2.7/gmpy2.so
  ld: warning: ignoring file /usr/local/lib/libgmp.dylib, file was built for unsupported file format ( 0xcf 0xfa 0xed 0xfe 0x 7 0x 0 0x 0 0x 1 0x 3 0x 0 0x 0 0x 0 0x 6 0x 0 0x 0 0x 0 ) which is not the architecture being linked (i386): /usr/local/lib/libgmp.dylib
  ld: warning: ignoring file /usr/local/lib/libmpfr.dylib, file was built for unsupported file format ( 0xcf 0xfa 0xed 0xfe 0x 7 0x 0 0x 0 0x 1 0x 3 0x 0 0x 0 0x 0 0x 6 0x 0 0x 0 0x 0 ) which is not the architecture being linked (i386): /usr/local/lib/libmpfr.dylib
  ld: warning: ignoring file /usr/local/lib/libmpc.dylib, file was built for unsupported file format ( 0xcf 0xfa 0xed 0xfe 0x 7 0x 0 0x 0 0x 1 0x 3 0x 0 0x 0 0x 0 0x 6 0x 0 0x 0 0x 0 ) which is not the architecture being linked (i386): /usr/local/lib/libmpc.dylib
  running install_lib
  copying build/lib.macosx-10.6-intel-2.7/gmpy2.so -&gt; /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages
  running install_egg_info
  Writing /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/gmpy2-2.0.0b4-py2.7.egg-info
  </code></pre>