Installing Pyrite
---------------------

Rob Tillotson <robt@debian.org>


Pyrite requires Python 1.5 or newer, and the pilot-link library
(libpisock) version 0.8.11 or newer.

Installing Pyrite from source additionally requires a C compiler,
the Python development headers and libraries, and the pilot-link
development headers and libraries.

The other parts of pilot-link (the command-line utilities, interfaces
to other languages, etc.) are not required by Pyrite.  In
particular, you don't need to build the Python interface included in
the pilot-link source; Pyrite is a complete replacement for its
functionality.

If you have problems installing Pyrite, please let me know.


Pre-built binaries:

  Pyrite is part of the Debian GNU/Linux distribution, starting
  with 2.1 "slink".  The current version can be installed over the
  network from the "unstable" distribution; earlier versions may be
  available in "stable" and/or "frozen".

  Binaries for other Linux distributions, and for other platforms,
  will be available as soon as I can find someone to make them.  If
  you want to package Pyrite for your favorite platform, please
  let me know and I'll help in any way I can.


** 1. Set up compilation environment

  Run the "configure" script.  It is executable Python code, so if
  simply typing "configure" at the shell prompt doesn't work, try
  "python configure".

  The configure script will try to find the pilot-link libraries in
  a few standard locations.  If it has trouble finding them, you can
  specify a prefix:

    $ configure --pilot-link-prefix=/usr

  The default configuration assumes you want to build the dynamically
  loadable, shared C modules.  If your platform doesn't support dynamic
  loading of Python extensions, you can configure Pyrite for static
  linking with the "static" option:

    $ configure --static

  If you select the "static" option, you will build a complete Python
  interpreter with the Pyrite extensions (and probably pilot-link,
  too) frozen into it.  This option has not been proven to work, and in
  fact it may not.  If you try it, please let me know the results.


** 2. Build the extension modules

  Type "make" at the shell prompt, and the C modules will be compiled.


** 3. Install Pyrite

  Type "make install".  Pyrite will be copied into your Python
  library, under the site-packages directory.  Note that you probably
  need to do this as root.

  If you want to install Pyrite somewhere else (eg. in your private
  Python library), just copy everything into a directory called
  "PDA/Palm".  For example, if your private Python library is ~/python,
  then you would "mkdir ~/python/PDA", then "mkdir ~/python/PDA/Palm",
  then "cp * ~/python/PDA/Palm" or perhaps "mv * ~/python/PDA/Palm".
  (Pyrite actually doesn't care where the documentation and example
  files end up; the important part is that all the Python modules end up
  in the same arrangement that they have in the distribution tree, and
  that they end up under PDA/Palm in some directory on your Python
  path.)



What the configure script actually does (not necessarily in this order):

  - locates your Python library (from sys.prefix)
  - determines what platform you are on (from sys.platform)
  - locates the pilot-link library
  - creates a Setup.in file, as required by Makefile.pre.in (the
    standard Python module builder)
  - creates a Makefile from Makefile.in
  - makes a platform-specific directory "plat-<whatever>"
  - changes into the platform directory, and runs Makefile.pre.in

