(wrist blog)

twitterはこちら http://twitter.com/wrist

pip install scipyしてコケる時

mountain lionでpip install scipyしたのにranlib: archive member: build/temp.macosx-10.8-x86_64-2.7/libarpack_scipy.a(znaup2.o) cputype (7) does not match previous archive members cputype (16777223) (all members must match)と表示されてscipyのインストールが成功しないときは

$ export CC=clang; export CXX=clang; export FFLAGS=-ff2c
$ pip install scipy

で無事インストールされる(公式にちゃんと載ってる)。

7/6追記

この情報は最早古く上記リンク先にはexportの記述は見当たらなくなっている。 brew install gfortranでgfortranを入れた上でpip install scipyを実行したら普通にインストールされた。 なお手元の環境ではbrew linkしろと言われたのでbrew link --overwrite gfortranシンボリックリンクを作成した上でpipを実行した。