[Fedora-packaging] python version grabbing

Ville Skyttä ville.skytta at iki.fi
Tue Mar 1 20:04:30 UTC 2005


On Tue, 2005-03-01 at 20:25 +0100, Michael Schwendt wrote:
> On Tue, 01 Mar 2005 13:34:17 -0500, seth vidal wrote:
> 
> > Hey,
> >  Do you think it'd be worth it to have a section on getting the python
> > version for site-packages for rpm building? Maybe with the  standard
> > routines?
> 
> Good idea, IMO. Also a section for python-abi and perl MODULE_COMPAT
> stuff.

Using the python version for the site-packages directories is
unnecessary, and leads to various problems (because it sort of
encourages to use manual %{_libdir} which will break noarch packages
built on x86_64).  Quite a few packages have required related fixes
lately in Extras.

It is much cleaner to ask python itself, and use the python_sitelib and
python_sitearch macros present for example
in /usr/share/fedora/spectemplate-python.spec (from fedora-rpmdevtools).

Related RFE @ https://bugzilla.redhat.com/beta/show_bug.cgi?id=120635

python-abi is a separate beast; for that a version is clearly needed.
Some of that stuff will be sometime later handled automagically by rpm.
But there's at least one thing to be aware of, and if possible, it'd be
good to "solve" this naming issue:

- Current FC python packages provide "python-abi = $version", and that 
  is also being used in python extension packages' Requires.

- scripts/pythondeps.sh in rpm CVS generates "python(abi) = $version"
  provides/requires.  I personally find also the method in which it 
  does it somewhat weird but it'll probably work ok as long as only the
  python package shipping with a distro is installed.





More information about the Fedora-packaging mailing list