Define %python_version *before* its needed (#237826)

This commit is contained in:
Jarod Wilson 2007-04-25 15:46:34 +00:00
parent 250cc0dd8d
commit 19329b9e22
1 changed files with 8 additions and 4 deletions

View File

@ -7,7 +7,7 @@
Summary: Round Robin Database Tool to store and display time-series data
Name: rrdtool
Version: 1.2.19
Release: 1%{?dist}
Release: 2%{?dist}
License: GPL
Group: Applications/Databases
URL: http://people.ee.ethz.ch/~oetiker/webtools/%{name}/
@ -59,6 +59,10 @@ Provides: perl-%{name} = %{version}-%{release}
The Perl RRDtool bindings
%if %{with_python}
%{!?python_sitearch: %define python_sitearch %(%{__python} -c 'from distutils import sysconfig; print sysconfig.get_python_lib(1)')}
# eval to 2.3 if python isn't yet present, workaround for no python in fc4 minimal buildroot
%{!?python_version: %define python_version %(%{__python} -c 'import sys; print sys.version.split(" ")[0]' || echo "2.3")}
%package python
Summary: Python RRDtool bindings
Group: Development/Languages
@ -67,9 +71,6 @@ Requires: python >= %{python_version}
Requires: %{name} = %{version}-%{release}
Obsoletes: python-%{name} < %{version}-%{release}
Provides: python-%{name} = %{version}-%{release}
%{!?python_sitearch: %define python_sitearch %(%{__python} -c 'from distutils import sysconfig; print sysconfig.get_python_lib(1)')}
# eval to 2.3 if python isn't yet present, workaround for no python in fc4 minimal buildroot
%{!?python_version: %define python_version %(%{__python} -c 'import sys; print sys.version.split(" ")[0]' || echo "2.3")}
%description python
Python RRDtool bindings.
@ -271,6 +272,9 @@ find examples/ -type f -exec chmod 0644 {} \;
%endif
%changelog
* Wed Apr 25 2007 Jarod Wilson <jwilson@redhat.com> 1.2.19-2
- Define %%python_version *before* its needed (#237826)
* Mon Apr 09 2007 Jarod Wilson <jwilson@redhat.com> 1.2.19-1
- New upstream release