2009年9月5日

Mac Python2.6.2 Universal Binary のビルド

本家で配布されている Python2.6.2 には x86_64 のバイナリが含まれない。
自分で作成する場合の Python2.6.2 Universal Binary の作成手順。

curl -O http://www.python.org/ftp/python/2.6.2/Python-2.6.2.tar.bz2
tar xvfj Python-2.6.2.tar.bz2
cd Python-2.6.2
unset DYLD_LIBRARY_PATH
unset LD_LIBRARY_PATH
./configure --enable-framework --enable-universalsdk=/ MACOSX_DEPLOYMENT_TARGET=10.5 --with-universal-archs=all --with-readline-dir=/usr/local --with-threads --with-gcc=gcc-4.0 CC=gcc-4.0 CXX=g++-4.0
make
sudo make frameworkinstall
sudo ln -s /Library/Frameworks/Python.framework/Versions/2.6/bin/python /usr/local/bin/python
file /Library/Frameworks/Python.framework/Versions/2.6/Python 

blog comments powered by Disqus