Installing PyXML

Once Python is installed, additional packages may be added with relative ease. PyXML takes advantage of the Python Distribution Utilities, or distutils. To get the PyXML package, visit the project’s SourceForge project page and look at the available downloads for the most recent version (0.6.6 at the time of this writing). The web page is at http://pyxml.sourceforge.net/.

For Windows, there is a selection of installers; one for each supported Python version. For bug-fix releases of Python (such as 2.1.1), use the installer for the corresponding feature enhancement for Python (2.1 for this example), as binary compatibility is maintained. Download the installer and run it like any other Windows installer; it locates all the Python installations of the appropriate version as you select the installation to which you want to add PyXML. Once you’ve done so, installation proceeds and PyXML is available for that Python interpreter.

For Unix, retrieve the .tar.gz archive containing the version of PyXML you’ve selected and unpack it just as you did the Python source distribution. Change your working directory to be the top-level directory of the unpacked distribution. That directory contains a Python script named setup.py; run that with the Python interpreter for which you’re installing PyXML and the command-line parameter build:

$> python setup.py build

This builds all the components of PyXML from their Python or C source code. Once this is complete, install the package so that Python can use it; this usually needs to be done by a privileged user:

$> su
Password:
%> python setup.py install

Be sure that the privileged user is using the same Python interpreter as the user who built the PyXML package.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.138.123.106