Python 2.6 on the eeePC


Recently, I purchased an eeePC because they were on sale and I wanted a small netbook that I could use as my primary solving computer for Cryptograms.  I’m new to Linux so starting out was a little rough.  I really wanted to get Python 2.6 running so that I could use the latest features of the language (Native SQLite support). Below are the steps I took to get everything working the way I wanted it to.

Download the latest ActivePython Installation file to your /home/user directory.

Open a Terminal by pressing Ctrl + Alt + t.  In the Terminal type the following commands (Taken from the ActivePython Installation Notes):

tar xzf ActivePython-version.tar.gz
cd ActivePython-version
./install.sh

When prompted for the directory that you want to install ActivePython into, type:

/home/user/bin/ActivePython-2.6

ActivePython is now installed but it is not the default python that would execute when you type python in a console.  In the Terminal, type:

kwrite /home/user/.bashrc

Add the following line as the very last line of the file and then save:

export PATH=/home/user/bin/ActivePython-2.6/bin:$PATH

Close the Terminal and restart it.  If you type “which python”  you should see /home/user/bin/ActivePython-2.6.  You can now run Python as normal.   If you just want to use Python then you are done.  I like to install the easy_install package and IPython (A python interactive console on steroids. You can do so much extra stuff with it.  See http://ipython.scipy.org/ for more information.)

In the Terminal window type the following:

wget http://peak.telecommunity.com/dist/ez_setup.py
python ez_setup.py

wget downloads the ez_setup.py file to your hard drive.   Then we run the ez_setup.py program to install easy_install.

We can now install IPython very easily by typing the following in the Terminal:

easy_install ipython

That is it!  Python and ipython are installed.  You can now type “python” or “ipython” to start the interactive interpreters.

Disclaimer:  I am new to linux and I know there are proably tons of better ways to do the previous steps more efficiently (ie: using nano instead of kwrite, etc.) but this was the quickest and easiest way to explain to a new linux user like myself.

Advertisements

2 thoughts on “Python 2.6 on the eeePC”

  1. Hi, was curious how it’s going with the Python and ACA cryptograms? I also have just started both Python and ACA (last Sept) and got into Python to help write aids for solving. For myself, I had no previous programming experience to speak of. I am using Python 3.1x and an old eMachines laptop with WinXP Home.

    1. emato,

      I’ve been having a lot of success with Python and ACA cryptograms. I created my own interactive solver for Aristocrats and Patristocrats. It isn’t perfect but it works and is extensible for the other con types in the future. I’ve thought about blogging about how to create an interactive solver but I’m not sure how many people would be interested in it. I think Python is a perfect language for the ACA stuff because it is clean, easy to read, not a massive learning curve, and easily accessible on any operating system (Most Mac and Linux computers have it pre-installed). If you ever have any programming questions don’t hesitate to ask. I am not an expert but I have been programming professionally in a variety of languages for the past 11 years.

      Code Penguin

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s