Centos: Python 2.7 derleme
Yapılması gerekenler:
cd /opt wget http://www.python.org/ftp/python/2.7.3/Python-2.7.3.tar.bz2 tar xf Python-2.7.3.tar.bz2 cd Python-2.7.3 ./configure --prefix=/usr/local make && make altinstall
Buradaki önemli nokta altinstall kullanıyor olmamız. Neden?
Çünkü make install kullansaydık adı python olan 2 tane farklı versiyon olacaktı ve sistemde çakışma olacaktı.
cd /usr/local/bin ls -ltr python* ln -s /usr/local/bin/python2.7 /usr/local/bin/python
Setuptools Yükleme
cd /opt wget http://pypi.python.org/packages/source/d/distribute/distribute-0.6.27.tar.gz --no-check-certificate tar xf distribute-0.6.27.tar.gz cd distribute-0.6.27 python2.7 setup.py install
$ which easy_install /usr/local/bin/easy_install $ ls -ltr /usr/local/bin/easy_install* -rwxr-xr-x 1 root root 340 Jan 30 2013 /usr/local/bin/easy_install-2.7 -rwxr-xr-x 1 root root 332 Jan 30 2013 /usr/local/bin/easy_install easy_install-2.7 requests easy_install-2.7 psutil easy_install-2.7 paramiko
Tüm output şu şekilde:
[root@localhost distribute-0.6.27]# ls build DEVGUIDE.txt distribute_setup.py easy_install.py PKG-INFO README.txt setup.py tests CHANGES.txt dist distribute_setup.pyc launcher.c pkg_resources.py release.py setuptools CONTRIBUTORS.txt distribute.egg-info docs MANIFEST.in pkg_resources.pyc setup.cfg site.py [root@localhost distribute-0.6.27]# which easy_install /usr/local/bin/easy_install [root@localhost distribute-0.6.27]# ls -ltr /usr/local/bin/easy_install* -rwxr-xr-x. 1 root root 340 Feb 27 10:21 /usr/local/bin/easy_install-2.7 -rwxr-xr-x. 1 root root 332 Feb 27 10:21 /usr/local/bin/easy_install [root@localhost distribute-0.6.27]# easy_install-2.7 requests Searching for requests Reading http://pypi.python.org/simple/requests/ Best match: requests 2.2.1 Downloading https://pypi.python.org/packages/source/r/requests/requests-2.2.1.tar.gz#md5=ac27081135f58d1a43e4fb38258d6f4e Processing requests-2.2.1.tar.gz Writing /tmp/easy_install-yT662H/requests-2.2.1/setup.cfg Running requests-2.2.1/setup.py -q bdist_egg --dist-dir /tmp/easy_install-yT662H/requests-2.2.1/egg-dist-tmp-BvzmLb Adding requests 2.2.1 to easy-install.pth file Installed /usr/local/lib/python2.7/site-packages/requests-2.2.1-py2.7.egg Processing dependencies for requests Finished processing dependencies for requests [root@localhost distribute-0.6.27]# easy_install-2.7 psutil Searching for psutil Reading http://pypi.python.org/simple/psutil/ Best match: psutil 1.2.1 Downloading https://pypi.python.org/packages/source/p/psutil/psutil-1.2.1.tar.gz#md5=80c3b251389771ab472e554e6c729c36 Processing psutil-1.2.1.tar.gz Writing /tmp/easy_install-N3eiZb/psutil-1.2.1/setup.cfg Running psutil-1.2.1/setup.py -q bdist_egg --dist-dir /tmp/easy_install-N3eiZb/psutil-1.2.1/egg-dist-tmp-LYnshi zip_safe flag not set; analyzing archive contents... Adding psutil 1.2.1 to easy-install.pth file Installed /usr/local/lib/python2.7/site-packages/psutil-1.2.1-py2.7-linux-x86_64.egg Processing dependencies for psutil Finished processing dependencies for psutil [root@localhost distribute-0.6.27]# easy_install-2.7 paramiko Searching for paramiko Reading http://pypi.python.org/simple/paramiko/ Best match: paramiko 1.12.2 Downloading https://pypi.python.org/packages/source/p/paramiko/paramiko-1.12.2.tar.gz#md5=1453e37f868b76af84dd1319e08c53f9 Processing paramiko-1.12.2.tar.gz Writing /tmp/easy_install-0kEY6r/paramiko-1.12.2/setup.cfg Running paramiko-1.12.2/setup.py -q bdist_egg --dist-dir /tmp/easy_install-0kEY6r/paramiko-1.12.2/egg-dist-tmp-0WalvZ zip_safe flag not set; analyzing archive contents... Adding paramiko 1.12.2 to easy-install.pth file Installed /usr/local/lib/python2.7/site-packages/paramiko-1.12.2-py2.7.egg Processing dependencies for paramiko Searching for ecdsa Reading http://pypi.python.org/simple/ecdsa/ Best match: ecdsa 0.10 Downloading https://pypi.python.org/packages/source/e/ecdsa/ecdsa-0.10.tar.gz#md5=e95941b3bcbf1726472bb724d7478551 Processing ecdsa-0.10.tar.gz Writing /tmp/easy_install-4QwN7x/ecdsa-0.10/setup.cfg Running ecdsa-0.10/setup.py -q bdist_egg --dist-dir /tmp/easy_install-4QwN7x/ecdsa-0.10/egg-dist-tmp-j8AwUJ zip_safe flag not set; analyzing archive contents... Adding ecdsa 0.10 to easy-install.pth file Installed /usr/local/lib/python2.7/site-packages/ecdsa-0.10-py2.7.egg Searching for pycrypto>=2.1,!=2.4 Reading http://pypi.python.org/simple/pycrypto/ Best match: pycrypto 2.6.1 Downloading https://pypi.python.org/packages/source/p/pycrypto/pycrypto-2.6.1.tar.gz#md5=55a61a054aa66812daf5161a0d5d7eda Processing pycrypto-2.6.1.tar.gz Writing /tmp/easy_install-Y5ztak/pycrypto-2.6.1/setup.cfg Running pycrypto-2.6.1/setup.py -q bdist_egg --dist-dir /tmp/easy_install-Y5ztak/pycrypto-2.6.1/egg-dist-tmp-YOrGdS warning: GMP or MPIR library not found; Not building Crypto.PublicKey._fastmath. zip_safe flag not set; analyzing archive contents... Adding pycrypto 2.6.1 to easy-install.pth file Installed /usr/local/lib/python2.7/site-packages/pycrypto-2.6.1-py2.7-linux-x86_64.egg
Centos: python scrapy web crawler yükleme Bilgisayar Mühendisi Olmak