LoginSignup
41
42

More than 5 years have passed since last update.

Cent OS 6で手軽にPython 2.7を使う方法

Posted at

インストール

Software Collectionsを使うと比較的新しいソフトウエアを使うことが出来ます.たとえば Python 2.7 を Cent OS 6 で使いたいときには以下のようにします.

sudo yum install centos-release-scl-rh
sudo yum install python27

使用する

Software Collectionsはインストールしただけでは利用可能にはなりません.実際に利用するには以下のコマンドを実行します.

scl enable python27 bash

こうすることで新しいbashが起動され,Python 2.7.8が使えるようになります.もし,常に使える状態にしておきたいときにはsource /opt/rh/python27/enable.bashrcに書いておくとよいでしょう.

41
42
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
41
42