ASPN ActiveState Programmer Network
  ASPN
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups | Web Services
SEARCH
advanced | search help

Reference
ActivePython 2.2
ActivePython User's Guide
What's Included in ActivePython
Installation Guide for ActivePython
The Python Package Manager (PyPPM)

MyASPN >> Reference >> ActivePython 2.2 >> ActivePython User's Guide
ActivePython User Guide

ActivePython Installation Guide

Table of Contents

Installing ActivePython on Windows (x86)

Before You Start

  • Windows Installer Engine (MSI) Windows 9x and NT users must have the Microsoft Windows Installer engine installed on their system. (Note: Windows NT users must be logged in as an administrator in order to install the MSI engine.) The MSI engine package can be downloaded from:
  • Directory Name Do not install ActivePython to a directory that contains spaces in the name. This causes problems on some variants of Windows with some service pack levels. We recommend you use the default directory suggested during the installation.
  • Directory Contents If you are installing ActivePython to an existing directory, ActivePython's setup may overwrite files in that directory. We recommend that you install ActivePython to a new or empty directory.
  • Other Python 2.2 Installations On Windows, ActivePython 2.2 cannot coexist with other Python 2.2 installations (for example, the reference implementation of Python 2.2). Uninstall any other Python 2.2 installations before installing ActivePython 2.2.

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

Installing ActivePython using Windows

To install ActivePython, download the installation package and run it by double-clicking on 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:

  • The Python ActiveX scripting engine feature will be unavailable.
  • Windows NT/2000 users will not be able to write Services.
  • Environment variables cannot be set.
  • File associations for Python files cannot be set.
  • Any registry entries created are under HKEY_CURRENT_USER and not under HKEY_LOCAL_MACHINE.

Installing ActivePython from the Command Line

You can install ActivePython 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. (MSI command options are passed via the '/v' option.) For example:

  • Running the ActivePython Installer in Silent Mode

    You can have the ActivePython installer run with a reduced user interface. For example, the following will install silently and only pop up a dialog when the installation is complete.

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

    The following will install with no user interface at all.

    c:\> msiexec.exe /i ActivePython-<version>.msi /q
  • Turning on Logging During ActivePython Installation

    You can generate a log of the ActivePython installation with the following command. Note that 'l', here, is a lower case letter 'L' (and not the number '1'). The following command will generate a log of the install in "install.log".

    c:\> msiexec.exe /i ActivePython-<version>.msi /l*v install.log
  • Controlling the Install Directory

    Command line options can be used to configure ActivePython installation properties. For example, the following will install ActivePython to "D:\myapps\Python", instead of the default:

    c:\> msiexec.exe /i ActivePython-<version>.msi INSTALLDIR=D:\myapps\Python
  • Controlling Which Features Get Installed

    ActivePython is divided into a number of distinct features. In the "Custom Setup" dialog you can select which features to install. You can also do this on the command line with the ADDLOCAL property. For example, the following command will install just the core ActivePython functionality (i.e. not the PyWin32 extensions or the documentation.

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

    The current set of ActivePython features are

        core
            pywin32
            documentation
    
    where the hierarchy denotes dependencies, I.e. to install pywin32 you must install the core.

  • A Complex Example

    These command line options can all be brought together. For example, the following command will silently install just the ActivePython core and documentation to "C:\myapps\Python".

    c:\> msiexec /i ActivePython-<version>.msi /qn+ INSTALLDIR=C:\myapps\Python ADDLOCAL=core,documentation

Installing ActivePython on RedHat Linux (x86)

RedHat

The RedHat-compatible package is in RPM format. This package has been tested with RedHat 7.3, but is expected to be compatible with other RedHat 7.x, 8.x and 9.x compatible installations. It should be installed as root, using the following command:

% rpm -i ActivePython-<version>.rpm

ActivePython is installed into the /usr/local/ActivePython-2.2 directory. Add the /usr/local/ActivePython-2.2/bin directory to your PATH environment variable for quicker access. For example, in the Bash shell:

% export PATH=/usr/local/ActivePython-2.2/bin:$PATH

Installing ActivePython on Linux

Linux

The generic ActivePython "AS package" installer allows you to install the package anywhere that the user has write permission. Download the distribution to a temporary directory, extract the files, change to the ActivePython directory and then run the script 'install.sh'. The installation script will prompt you for the target installation directory.

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

Add the bin directory to your PATH environment variable for quicker access. For example, in the Bash shell (assuming you installed into /home/guido/ActivePython-2.2):

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

Installing ActivePython on Solaris (sparc)

Solaris

To install the gzip'ed native Solaris package containing the "ASpy22" package run the following commands as root:

% gunzip ActivePython-<version>.gz
% pkgadd -d ActivePython-<version>

ActivePython is installed into the /opt/ASpy22 directory. Add /opt/ASpy22/bin directory to your PATH environment variable for quicker access. For example, in the Bash shell:

% export PATH=/opt/ASpy22/bin:$PATH

Generic AS Package for Solaris (sparc)

The generic ActivePython "AS package" installer allows you to install the package anywhere that you have write permission. I.e., you do not have to be root to install this package. Download the distribution to a temporary directory, extract the files, change to the ActivePython directory and then run the script 'install.sh'. The installation script will prompt you for the target installation directory.

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

Add the bin directory to your PATH environment variable for quicker access. For example, in the Bash shell (assuming you installed into /home/guido/local/ActivePython-2.2):

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


Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState 2004 All rights reserved