pythonbrewで--configure="--enable-shared"したときの注意

--configure="--enable-shared"するとsetuptoolsのインストールで止まる。
.soファイルのリンクが辿れない感じ。

だいたいここに書いてあることと一緒。
build - Problems compiling Python 3.2 and 2.7 using pythonbrew

$ pythonbrew install --configure="--with-threads --enable-shared" --no-setuptools 2.7.2
$ sudo vim /etc/ld.so.conf.d/python2.7.2.conf
/home/あなた様/.pythonbrew/pythons/Python-2.7.2/lib
$ sudo ldconfig

$ pythonbrew use 2.7.2
$ wget http://python-distribute.org/distribute_setup.py
$ python distribute_setup.py
$ easy_install pip

setuptools(easy_install, pip)を自分で共有ライブラリ設定した後に手動で入れる。
これでOpenCV(python support)のビルドも上手くいった。