Je cherche à installer rpy2 en utilisant pip avec:erreur installation rpy2 sur OS X 10.6: impossible d'exécuter gcc 4.0
$ sudo pip install rpy2
qui sort avec une erreur:
gcc-4.0 -fno-strict-aliasing -fno-common -dynamic -arch ppc -arch i386 -g -O2 -DNDEBUG -g -O3 -DR_INTERFACE_PTRS=1 -DHAVE_POSIX_SIGJMP=1 -DCSTACK_DEFNS=1 -DRIF_HAS_RSIGHAND=1 -I./rpy/rinterface -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -I/opt/local/lib/R/include/x86_64 -I/opt/local/lib/R/include -c ./rpy/rinterface/_rinterface.c -o build/temp.macosx-10.3-fat-2.7/./rpy/rinterface/_rinterface.o
unable to execute gcc-4.0: No such file or directory
error: command 'gcc-4.0' failed with exit status 1
J'ai essayé Pour installer également rpy2 avec macports, l'installation est terminée, mais rpy2 ne sera pas importé. J'ai installé XCode, version 4.0.2 Build 4A2002a, et gcc est installé.
$ which gcc
retours:
/usr/bin/gcc
et
$ gcc
retourne:
i686-apple-darwin10-gcc-4.2.1: no input files
Il semble qu'il est à la recherche d'une ancienne version de gcc et je ne sais pas comment le pointer dans le bon endroit e. Toute aide serait grandement appréciée.
Remerciez est pour l'aide. J'ai suivi votre lien et a atterri [ici] (http://stackoverflow.com/questions/5967065/python-distutils-not-using-correct-version-of-gcc/5968410#5968410). Cependant, je ne pouvais pas faire fonctionner ça. Dans un environnement de python, je reçois: >>> de distutils importer sysconfig >>> sysconfig.get_config_var ('LDSHARED') 'gcc 4.0 -bundle -undefined dynamic_lookup -arch ppc -arch i386 -g' > >> sysconfig.get_config_var ('CC') 'gcc-4.0' (Désolé, la mise en forme ne semble pas fonctionner), mais je semble incapable de changer la variable 'CC' – user865819