Bug 3311 - %__python_version expands to nothing if puthon is not installed
: %__python_version expands to nothing if puthon is not installed
Status: CLOSED FIXED
: Sisyphus
(All bugs in Sisyphus/rpm)
: unstable
: all Linux
: P2 major
Assigned To:
:
:
:
:
:
  Show dependency tree
 
Reported: 2003-11-24 13:11 by
Modified: 2008-06-13 12:15 (History)


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2003-11-24 13:11:48
GLobal macro %__python_version expands to empty string if puthon is not
installed. This causes parse errors in sandman while doing it's pre-commit check
on specfiles containing something like:

Requires: python >= %__python_version

This macro should look like this:

%__python_version %((%__python -c 'import sys; print sys.version' 2>/dev/null ||
echo "unknown") |head -1 |cut -d' ' -f1 |cut -d. -f1,2)

This will not cause any errors in build process since python-devel package is
often BuildRequire'd in such packages.
------- Comment #1 From 2003-11-24 18:09:16 -------
Applied in upcoming rpm-4.0.4-alt28