This is a short walk-through on compiling PyMOL on Linux Fedora 9.
First make sure you have administrator privileges on your Fedora system, i.e. that you are a
sudoer. We also need Subversion to be able to check out the PyMOL source.
$ sudo yum -y install svn
Then we need to install for dependencies.
$ sudo yum -y install python-devel libpng-devel freeglut-devel freetype-devel tk-devel tcl-devel tkinter numpy
We also need to install the Python MegaWidgets (Pmw). Pmw will probably be available in Fedora 10 as 'python-pmw' but is as of yet not included in the Fedora 9 repositories. For now we have to install it manually.
Download the Pmw source from
Sourceforge.
Then extract it and move it to a directory that Python can access. I happened to download the 1.3.2 version of Pmw and the current version of Python in Fedora 9 is 2.5 so
$ tar -xvzf Pmw.1.3.2.tar.gz
$ sudo mv Pmw.1.3.2/src/Pmw /usr/lib/python2.5/site-packages/
Create an install directory somewhere on your system.
$ sudo mkdir /usr/local/share/viewers
Now we're finally ready to compile and install PyMOL. Check out the PyMOL source with Subversion.
$ svn co https://pymol.svn.sourceforge.net/svnroot/pymol pymol
Then copy the trunk to the install directory.
$ sudo cp -r pymol/trunk/pymol /usr/local/share/viewers/
We can remove the rest, it won't be needed.
$ rm -fr pymol
Now we move over to the install directory and ask configure to check that we have all we need to compile PyMOL and create a Makefile.
$ cd /usr/local/share/viewers/pymol
$ sudo ./configure
Let's compile it.
$ sudo make install
While it compiles check for errors. If there are none then clean up this directory.
$ sudo make clean
Create a symbolic link to somewhere in your path.
$ sudo ln -s /usr/local/share/viewers/pymol/pymol /usr/local/bin/pymol
Ok, all done. Now give it a try.
$ pymol &
There are a few example files located in the pymol/data/demo directory. You can load them by e.g. typing the following at the PyMOL prompt.
> load /usr/local/share/viewers/pymol/data/demo/1tii.pdb
Now let's try a fancy view of the protein.
> show cartoon, all
> hide lines, all
Remove the crystal waters.
> select resn HOH
> remove sele
Throw in some fancy colors by clicking on the rainbow colored 'C' button right next to the '1tii' bar, then on 'by chain'>'by chain(e. c)'
Now ray-trace and save the image to file.
> ray 2000,2000
> png ~/fancy_protein_view.png
And there you have it! =)

You need to be a member of MIX to add comments!
Join this social network