[python-logilab-common/el6] - Rebase on upstream v0.62.1

Brian C. Lane bcl at fedoraproject.org
Thu Oct 16 18:28:50 UTC 2014


commit 4a580f5fae3478f429d9f8317cf982b45b8d698e
Author: Brian C. Lane <bcl at redhat.com>
Date:   Thu Oct 16 09:31:54 2014 -0700

    - Rebase on upstream v0.62.1

 .gitignore                 |    3 +-
 python-logilab-common.spec |   83 ++++++++++++++++++++++++++++++++++++-------
 sources                    |    2 +-
 3 files changed, 71 insertions(+), 17 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 6d37a04..ab0775c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1 @@
-logilab-common-0.49.0.tar.gz
-/logilab-common-0.50.3.tar.gz
+/logilab-common-0.62.1.tar.gz
diff --git a/python-logilab-common.spec b/python-logilab-common.spec
index 4576554..07edd90 100644
--- a/python-logilab-common.spec
+++ b/python-logilab-common.spec
@@ -1,10 +1,13 @@
-%{!?_python_sitelib: %define _python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
+%if 0%{?fedora} > 12
+%global with_python3 1
+%else
+%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print (get_python_lib())")}
+%endif
 
 Name:           python-logilab-common
-Version:        0.50.3
+Version:        0.62.1
 Release:        1%{?dist}
 Summary:        Common libraries for Logilab projects
-
 Group:          Development/Libraries
 License:        GPLv2+
 URL:            http://www.logilab.org/projects/common
@@ -12,41 +15,93 @@ Source0:        ftp://ftp.logilab.org/pub/common/logilab-common-%{version}.tar.g
 BuildArch:      noarch
 BuildRoot:      %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
 
-BuildRequires:  python-devel python-setuptools
-Requires:       mx
-
+Requires:       python-unittest2
+BuildRequires:  python-devel python-setuptools python-tools
+%if 0%{?with_python3}
+BuildRequires:  python3-devel python3-setuptools python3-tools
+%endif # if with_python3
 
 %description
-This package contains several modules providing low level functionality 
+This package contains several modules providing low level functionality
 shared among some python projects developed by logilab.
 
+%if 0%{?with_python3}
+%package -n python3-logilab-common
+Summary:        Common libraries for Logilab projects
+Group:          Development/Libraries
+
+%description -n python3-logilab-common
+This package contains several modules providing low level functionality
+shared among some python projects developed by logilab.
+%endif # if with_python3
 
 %prep
 %setup -q -n logilab-common-%{version}
 
+%if 0%{?with_python3}
+rm -rf %{py3dir}
+cp -a . %{py3dir}
+%endif # with_python3
 
 %build
 %{__python} setup.py build
 
+%if 0%{?with_python3}
+pushd %{py3dir}
+%{__python3} setup.py build
+popd
+%endif # with_python3
 
 %install
-rm -rf $RPM_BUILD_ROOT
-%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
-rm -rf $RPM_BUILD_ROOT%{_python_sitelib}/logilab/common/test
-
+rm -rf %{buildroot}
+
+%if 0%{?with_python3}
+pushd %{py3dir}
+%{__python3} setup.py install -O1 --skip-build --root %{buildroot}
+rm -rf %{buildroot}%{python3_sitelib}/logilab/common/test
+# Add python3- to the binaries
+for FILE in %{buildroot}%{_bindir}/*; do
+    NAME=$(basename $FILE)
+    mv $FILE %{buildroot}%{_bindir}/python3-$NAME
+done
+popd
+%endif # with_python3
+
+%{__python} setup.py install -O1 --skip-build --root %{buildroot}
+rm -rf %{buildroot}%{python_sitelib}/logilab/common/test
+
+%check
+%{__python} setup.py test
+
+%if 0%{?with_python3}
+pushd %{py3dir}
+%{__python3} setup.py test
+popd
+%endif # with_python3
 
 %clean
-rm -rf $RPM_BUILD_ROOT
+rm -rf %{buildroot}
 
 
 %files
 %defattr(-,root,root,-)
 %doc README ChangeLog COPYING
-%{_python_sitelib}/logilab*
-%{_bindir}/*
+%{python_sitelib}/logilab*
+%{_bindir}/pytest
 
+%if 0%{?with_python3}
+%files -n python3-logilab-common
+%defattr(-,root,root,-)
+%doc README ChangeLog COPYING
+%{python3_sitelib}/logilab*
+%{_bindir}/python3-pytest
+%endif # with_python3
 
 %changelog
+* Thu Oct 16 2014 Brian C. Lane <bcl at redhat.com> 0.62.1-1
+- Rebase on upstream v0.62.1
+- Add python-unittest2 requirement for python2.6
+
 * Tue Oct 05 2010 Brian C. Lane <bcl at redhat.com> - 0.50.3-1
 - Update to new upstream version
 
diff --git a/sources b/sources
index 32c1f1d..a8ccde5 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-b3ac2d2d3cc690c9446749048c177560  logilab-common-0.50.3.tar.gz
+7ebecdcc41c94f8d951717e78db48dca  logilab-common-0.62.1.tar.gz


More information about the scm-commits mailing list