python 2.6.1 をコンパイルする

Pythonに興味はないけど、Tracを使ってみたいので、Python

さて、Solaris上でのコンパイルですが、初心者の方はSunStudioは諦めましょう。私は挫折しました。コンパイルが通らんものは通らんのだ。。。

なので、gcc & Python 2.6.1 を普通にいれて終わり。


$ pfexec pkg install SUNWgcc
...
$ wget http://www.python.org/ftp/python/2.6.1/Python-2.6.1.tar.bz2
$ tar jxf Python-2.6.1.tar.bz2
$ cd Python-2.6.1
$ ./configure --prefix=/usr/local
$ make
...
Failed to find the necessary bits to build these modules:
bsddb185 gdbm linuxaudiodev
ossaudiodev readline

Failed to build these modules:
_curses _curses_panel _tkinter
sunaudiodev
...
$ pfexec make install

いくつかbuildに失敗するが、無視。後で必要なら考えます。
で、Eggからモジュールを追加するのに便利な setuptoolsを入れて本日は終わり。


$ wget http://pypi.python.org/packages/2.6/s/setuptools/setuptools-0.6c9-py2.6.egg
$ pfexec sh setuptools-0.6c9-py2.6.egg
Processing setuptools-0.6c9-py2.6.egg
Copying setuptools-0.6c9-py2.6.egg to /usr/local/lib/python2.6/site-packages
Adding setuptools 0.6c9 to easy-install.pth file
Installing easy_install script to /usr/local/bin
Installing easy_install-2.6 script to /usr/local/bin

Installed /usr/local/lib/python2.6/site-packages/setuptools-0.6c9-py2.6.egg
Processing dependencies for setuptools==0.6c9
Finished processing dependencies for setuptools==0.6c9
$

普段使わない言語って、モジュールの追加とかいろいろわからんことだらけです。