New (optional) python egg dependency generator for RPM

Toshio Kuratomi a.badger at gmail.com
Tue Nov 17 15:43:02 UTC 2015


On Nov 17, 2015 6:47 AM, "Neal Gompa" <ngompa13 at gmail.com> wrote:
>
> On Tue, Nov 17, 2015 at 9:44 AM, Toshio Kuratomi <a.badger at gmail.com>
wrote:
> > One thing I would change, though: instead of python2dist(name) use
> > python2.7dist(name).  A module built for python 2.7 won't be able to
import
> > a module built for python2.6 (the python interpreter won't look in the
> > directories in which the files are placed) so without both the
major.minor
> > numbers we won't be able to rely on the auto generated requires in the
spec
> > file.
> >
> > -Toshio
>
> That's already guaranteed by the auto-generated python(abi) requires,
> and that would also make it hugely problematic to use in spec files in
> any distro agnostic manner, so I don't think I will do that.
>
I could  just be being dumb here but it doesn't seem like it would.  The
python(abi) will require a specific major.minor of the python package
itself.  It will not require a python-setuptools (for instance) that was
built for the same version of python as the package you are installing.  If
it was true, then you wouldn't need the separate python2dist and
python3dist as python(abi) would take care of the difference between
packages built for python2 and python3.


example autogenerated deps:

python-setuptools

  Provides: python2dist(setuptools)

  Requires: python(abi) = 2.7

python2.6-setuptools

  Provides: python2dist(setuptools)

  Requires: python(abi) = 2.6

python2.6-foo

  Requires: python2dist(setuptools)

  Requires: python(abi) = 2.6


On my system, I have installed, python-2.7.0 (which provides
python(abi)==2.7), python2.6-2.6.0 (which provides python(abi)==2.6), and
python-setuptools (deps listed above).  I want to install python2.6foo.
The depsolver will satisfy python2dist(setuptools) with my already
installed python-setuptools package and python(abi) == 2.6 with
python2.6-2.6.0.  Thus, the library will not function correctly because
python-2.6 will not be able to import setuptools.


-Toshio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.fedoraproject.org/pipermail/python-devel/attachments/20151117/c8edcfd1/attachment.html>


More information about the python-devel mailing list