[TurboGears] * Tue Aug 3 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 1.0.9-6 - Fix building on python-2.7

Toshio くらとみ toshio at fedoraproject.org
Wed Aug 4 02:11:41 UTC 2010


commit 7238d92e1b08897fb14a88cce25bdac77ab04ab4
Author: Toshio Kuratomi <toshio at fedoraproject.org>
Date:   Tue Aug 3 22:11:10 2010 -0400

    * Tue Aug 3 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 1.0.9-6
    - Fix building on python-2.7

 TurboGears.spec |   19 ++++++++++++-------
 1 files changed, 12 insertions(+), 7 deletions(-)
---
diff --git a/TurboGears.spec b/TurboGears.spec
index 92982d3..67933b2 100644
--- a/TurboGears.spec
+++ b/TurboGears.spec
@@ -1,9 +1,8 @@
-%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
-%{!?pyver: %define pyver %(%{__python} -c "import sys ; print sys.version[:3]")}
+%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
 
 Name:           TurboGears
 Version:        1.0.9
-Release:        5%{?dist}
+Release:        6%{?dist}
 Summary:        Back-to-front web development in Python
 
 Group:          Development/Languages
@@ -32,10 +31,10 @@ BuildRequires: python-paste-script python-sqlobject python-sqlalchemy
 
 %if 0%{?fedora} || 0%{?rhel} > 5
 Requires:       python-cherrypy2
-BuildRequires:	python-cherrypy2
+BuildRequires:  python-cherrypy2
 %else
 BuildRequires:  python-elementtree >= 1.2.6
-BuildRequires:	python-cherrypy
+BuildRequires:  python-cherrypy
 Requires:       python-elementtree >= 1.2.6
 Requires:       python-cherrypy
 %endif
@@ -90,7 +89,10 @@ rm -rf %{buildroot}
 %{__python} setup.py install --skip-build --root %{buildroot}
 
 %check
-PYTHONPATH=$(pwd) nosetests -q
+cp %{_bindir}/nosetests .
+sed -i 's/__requires__ =\(.*\)/__requires__ = [\1, "CherryPy \< 3.0a1"]/' nosetests 
+
+PYTHONWARNINGS=default PYTHONPATH=$(pwd) ./nosetests -q
 
 %clean
 rm -rf %{buildroot}
@@ -99,10 +101,13 @@ rm -rf %{buildroot}
 %defattr(0644,root,root,0755)
 %doc CHANGELOG.txt LICENSE.txt
 %attr(0755,root,root) %{_bindir}/tg-admin
-%{python_sitelib}/%{name}-%{version}-py%{pyver}.egg-info/
+%{python_sitelib}/%{name}-%{version}-py*.egg-info/
 %{python_sitelib}/turbogears/
 
 %changelog
+* Tue Aug 3 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 1.0.9-6
+- Fix building on python-2.7
+
 * Wed Jul 21 2010 David Malcolm <dmalcolm at redhat.com> - 1.0.9-5
 - Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
 


More information about the scm-commits mailing list