2013-04-12 56 views

回答

1

我做了一個錯誤,方法如下:

  • 安裝python3到/ opt/python3 /與

    • yum install openssl-devel bzip2-devel expat-devel gdbm-devel readline-devel sqlite-devel
    • wget http://www.python.org/ftp/python/3.3.2/Python-3.3.2.tar.bz2
    • bzip2 -cd Python-3.3.2.tar.bz2 | tar xvf -
    • cd Python-3.3.2 && ./configure --prefix=/opt/python3
    • make && make install
    • ln -s /opt/python3/bin/python3 /usr/bin/python3

    • 安裝分發

    • wget http://pypi.python.org/packages/source/d/distribute/distribute-0.6.43.tar.gz#md5=a216a46dc9bec5835fa3c6041f1c77c2

    • tar xvf distribute-0.6.43.tar.gz && cd distribute-0.6.43 && python3 setup.py install

    • 和一點點PIP不會傷害:

    • cd /opt/pytnon3/bin && ./easy_install pip

    • 最後,進入ipython3

    • cd ~ && wget pypi.python.org/packages/source/i/ipython/ipython-0.13.2.tar.gz#md5=ead3b7eb70c653b537fb9d96d71b8b2a

    • tar xvf ipython-0.13.2.tar.gz && cd ipython-0.13.2
    • python3 setup.py install

因爲它指出無處不在網絡上,python 2yum利用,你不想破壞它,這樣你把python3仔細一邊。

[[email protected] bin]# cat /etc/*release* 
CentOS release 6.4 (Final) 
CentOS release 6.4 (Final) 
CentOS release 6.4 (Final) 
cpe:/o:centos:linux:6:GA 

[[email protected] bin]# ls -la /opt/python3/bin/ipython3 
-rwxr-xr-x. 1 root root 307 May 27 03:18 /opt/python3/bin/ipython3 

[[email protected] bin]# ./ipython3 
Python 3.3.2 (default, May 26 2013, 23:38:41) 
Type "copyright", "credits" or "license" for more information. 

IPython 0.13.2 -- An enhanced Interactive Python. 
?   -> Introduction and overview of IPython's features. 
%quickref -> Quick reference. 
help  -> Python's own help system. 
object? -> Details about 'object', use 'object??' for extra details. 

In [1]: