On Sun, Feb 10, 2002 at 02:08:56PM +1100, Donovan Baarda wrote: > On Sat, Feb 09, 2002 at 07:41:31PM +0000, Julian Gilbey wrote: > > I have a suggestion, which may already have been thought of. > > > > Need: a python-module (pure Python) providing package should provide > > byte-compiled versions for all installed python versions (as long as > > there are no version dependency issues) > > Actually, it is slightly more complex than this. For starters, forgetting > that not all python modules are compatible with all versions of python, > there is a second need;
Not a problem. > Need-2: installing a new version of Python should byte-compile all > pre-installed Python modules for the newly installed Python version. That's the whole cleverness of the emacsen solution -- see below. > This makes it a bit tricky because it's hard to know where the "compile all > for all" scripts should go; in the versioned Python packages, in the > "Python" default wrapper, or in the modules themselves. The moment you think > it's obvious, you dig deeper and find it introduces some dependancy nastys. Quite -- but it's really good that the emacsen team have already solved this problem, so the python team doesn't have to reinvent the wheel. > I'm not 100% sure of the details of the emacsen approach, but doesn't it use > some sort of module-registration database? I can't help but think that it's > a bit sad that you need to introduce _another_ database of installed stuff > when you already have the dpkg database. However, perhaps that's the only > way to get a truely "perfect" solution. Yes, emacsen-common reads a database of install/remove command files. See the /usr/lib/emacsen-common directory. It allows the packages to be a little bit clever for a relatively small maintainer cost, as the extra files are mostly boilerplate. This allows installing/removing emacs packages to be performed orthogonally to installing/removing different versions of emacs, and means that any version-independent emacs packages can work with all installed emacsen without having to be aware of which particular ones are installed, and without having to have a separate version for each emacs package. Julian -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Julian Gilbey, Dept of Maths, Debian GNU/Linux Developer Queen Mary, Univ. of London see http://people.debian.org/~jdg/ http://www.maths.qmul.ac.uk/~jdg/ or http://www.debian.org/ Visit http://www.thehungersite.com/ to help feed the hungry