[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: new dh_python proposal



On 15.01.2010 14:19, Luca Falavigna wrote:
* broken modules that use __file__ incorrectly will work without problems,

OK, I'd still warn loudly if that happens, though.

there are other cases where some modules/extensions do encode paths in generated "config" files, like sip and the qt/kde bindings. to avoid such problems it's safe to call setup.py install with --install-layout=deb to have the files in the final installation location.

* user installs new pythonX.Y package:
   - bytecompile related symlinks (pycompile -V X.Y) - no need for a list of
     files to compile at this point - all .py files in
     /usr/lib/pythonX.Y/{site,dist}-packages will have to be byte-compiled,

Suppose I have foo package installed, then I install pythonX.Y, so
symlinks will be byte-compiled for X.Y. What happens if I remove foo
package? Will byte-compiled files for X.Y be removed as well?

that's my understanding. byte-compiled files shouldn't exist for a python runtime which is currently not installed on the system, and there shouldn't exist byte-compiled files on the system without a corresponding source file (at least in the public site directory).

     byte compilation will not fail as it was already tested at build time,

What about cases when code is no longer supported in a given Python
release? I think of "except YourFavouriteException, e:" code with 3.1
(but feel free to use a better example), byte-compilation will fail.

the source code for python3 is almost always different compared to python2.x, although the transformation can be done automatically by the new distribute tools on installation time. Adding another copy of python (source) code into the same package would enlarge the package, so it would be the best to have a separate binary package python3-* (which could be built from the same source package).

  Matthias


Reply to: