Linux Install

From PyMOLWiki
Jump to: navigation, search

This page describes how to install open-source PyMOL on Linux.


Install distribution specific binary package

Many Linux distributions provide binary packages for open-source PyMOL. They often do not provide the latest version, but if the provided package fits your needs this is the most convenient way to install PyMOL.

Command line install examples for some popular distributions:

# Debian/Ubuntu/Mint
sudo apt-get install pymol
# Fedora
yum install pymol
# Gentoo
emerge -av pymol
# openSUSE (12.1 and later)
sudo zypper install pymol
# CentOS with EPEL
rpm -i
yum --enablerepo=epel install pymol

Install from source

Installation from source gives you the latest version and is the generic way to install PyMOL.


Libraries as well as development files (headers) of the following software is required:

On many Linux systems, one of the following commands installs all requirements:

# Debian/Ubuntu/Mint
sudo apt-get install subversion build-essential python-dev python-pmw libglew-dev \
  freeglut3-dev libpng-dev libfreetype6-dev libxml2-dev
# Fedora/CentOS
yum install subversion gcc gcc-c++ kernel-devel python-devel tkinter python-pmw glew-devel \
  freeglut-devel libpng-devel freetype-devel libxml2-devel
# Gentoo
emerge -av dev-vcs/subversion dev-lang/python dev-python/pmw media-libs/glew \
  media-libs/freeglut media-libs/libpng media-libs/freetype
# openSUSE
sudo zypper install python-devel freeglut-devel gcc-c++ glew-devel libpng-devel python-pmw subversion

Get latest source from SVN

This will download the latest source to /tmp/pymol:

cd /tmp
svn co svn://
cd pymol

Compile and install

This will install PyMOL as normal user into /opt/pymol-svn. If you don't have write permissions to /opt, change the prefix variable to something like $HOME/pymol-svn.

#!/bin/bash -e
# enable c++11
export CPPFLAGS="-std=c++0x"
# If you want to install as root, then split this line up in "build"
# and "install" and run the "install" with "sudo"
python build install \
    --home=$prefix \
    --install-lib=$modules \

Now launch PyMOL like this:


Optionally, in order to allow running the command pymol from the terminal to launch the program do:

sudo ln -s /opt/pymol-svn/pymol /usr/bin/pymol


To update the installation merely run:

sudo rm -r /opt/pymol-svn/pymol
rm -r /tmp/pymol

and redo the installation from the beginning with the latest release.


sudo apt-get install build-essential gcc-4.4 g++-4.4
export CC=/usr/bin/gcc-4.4

Customized Installations

Personal tools