Installation directory for extensions on Unix
otsaloma at cc.hut.fi
Fri Feb 6 20:39:51 CET 2009
I have written an extension (a.k.a. plugin or add-on, not C-extension)
system for my application and I'm going to ship two extensions with it.
Each extension is in a directory of its own and that directory contains
Python files and various data files, e.g. Glade XML files and PNG icons.
Where should I install these extension directories on a Unix system?
$PREFIX/share/foo or $PREFIX/lib/foo? How do I handle compiling with
distutils if installing Python code outside the default site-packages
Importing these extensions is handled by listing the contents of the
extension directory and using __import__ on the specified files, so the
installation directory does not need to be anywhere near $PYTHONPATH.
Osmo Salomaa <otsaloma at cc.hut.fi>
More information about the Python-list