You are here: ActivePython User Guide » Installation Guide

ActivePython 2.6 Installation Guide

Table of Contents

Windows: Installing the MSI

ActivePython requires Windows XP or later.

Before You Start

If you have problems importing certain modules after installation, please check these things before submitting a bug report.

Installing the MSI

To install ActivePython, download the .msi installation package and run it by double-clicking it. Follow the prompts.

It is recommended that you run the ActivePython installation file from an account with administrative privileges. This will allow other users to use ActivePython, and will ensure that all of ActivePython's features function. Installing ActivePython without administrative privileges has the following limitations:

You might like to read the Getting Started page in this guide for a general introduction to ActivePython on your platform, and pointers to documentation that will be most useful to you.

Installing the MSI from the Command Line

You can install the ActivePython MSI from the command line. For example:

c:\> msiexec.exe /i ActivePython-<version>.msi

ActivePython's installer uses Windows Installer technology. This allows you to partially control the install from the command line. For example:

Uninstalling the MSI

The ActivePython for Windows can be uninstalled using the Modify, Repair or Uninstall ActivePython shortcut in the ActiveState ActivePython 2.6 program group in the Windows Start menu. Alternatively, you may uninstall the ActivePython MSI from Add/Remove Programs in the Control Panel.

Mac OS X: Installing the OS X Package

ActivePython is distributed on Mac OS X as a disk image (.dmg file). The disk image contains an installer package (.pkg bundle) that you run to install ActivePython.

Other Python Distributions

Both ActivePython and MacPython (another Python distribution for Mac OS X) install to the same location on disk (/Library/Frameworks/Python.framework/... with some links in /usr/local/bin), therefore ActivePython and MacPython installations of the same versions can collide. The ActivePython installer will properly install over a MacPython installation of the same version. However it is recommended that you first uninstall MacPython 2.6 before installing ActivePython 2.6. For more details, consult the ActivePython FAQ in this guide.

Prerequisites

Installing the OS X Package (GUI)

To install ActivePython:

ActivePython installs a python link in /usr/local/bin. By default this directory is not on your PATH environment variable. Refer to Getting Started on Mac OS X in this guide for instructions on putting python on your path and for a general introduction to ActivePython on Mac OS X.

Installing the OS X Package Non-Interactively

Mac OS X includes a command-line tool, installer, for installing OS X packages non-interactively from the command line. This can be useful for remote administration (e.g. on Apple Xserve hardware). To install ActivePython non-interactively from the command line:

ActivePython installs a python link in /usr/local/bin. By default this directory is not on your PATH environment variable. Refer to Getting Started on Mac OS X in this guide for instructions on putting python on your path and for a general introduction to ActivePython on Mac OS X.

Uninstalling the OS X Package

Apple does not provide a standard uninstallation tool or mechanism. You may, however, use the uninstall script that comes with ActivePython to uninstall ActivePython:

sudo /Library/Frameworks/Python.framework/Versions/2.6/Resources/Scripts/uninstall

Note: ActivePython's uninstall will restore an older Python installation in /Library/Frameworks/Python.framework if one exists (using pythonselect). This means, for example, that if you have ActivePython 2.4 install then install and uninstall ActivePython 2.5, your original ActivePython 2.4 will be restored to its full working state.

Installing the Generic ActivePython "AS Package" Installer ( AIX, HP-UX, Linux, Solaris)

The ActivePython "AS package" installer package is a generic installer for many platforms. It allows you to install ActivePython as a non-root (non-Administrator) user. To install: Download the package to a temporary directory, extract the files, and run the install.sh install script (install.bat on Windows). For Unix platforms, glibc-2.3+ is required.

The "AS package" is a standard tarball (*.tar.gz) for Linux and other Unix-family systems, and a zip file, (*.zip) for Windows. Note: Solaris and HP-UX users must use GNU tar to unpack the tarball, as the default 'tar' on those platforms will not work. Binary packages of GNU tar are available here:

After installing ActivePython, you might like to read the Getting Started page in this guide for a general introduction to ActivePython on your platform (in particular, getting your newly installed python on your path), and pointers to documentation that will be most useful to you.

Interactive Install

To install interactively, simple run the install script without arguments. The install script will prompt your for an installation directory. On Unix:

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

or on Windows, unzip ActivePython-version.zip with WinZip or equivalent and:

C:\> cd .../ActivePython-version
C:\...\ActivePython-version> install.bat

You can add the bin directory to your PATH environment variable for quicker access. For example, if you use the Bash shell on Unix, you could place this in your ~/.bash_profile file (assuming you installed into /home/guido/ActivePython-2.6):

% export PATH=/home/guido/ActivePython-2.6/bin:$PATH

Non-Interactive Install

By default the install script will prompt you for an install directory. You can avoid this interaction by specifying the install directory with the -I <installdir> option. Use the -h option for full usage information.

Uninstalling the "AS Package"

Uninstalling an "AS Package" installation is as simple as removing the directory to which you installed, because the ActivePython installation is fully contained in that install location.