Blame SPECS/python-httplib2.spec

d5958a
%if 0%{?fedora} >= 13
d5958a
%global with_python3 1
d5958a
%else
d5958a
%if 0%{?rhel} > 7
d5958a
%global with_python3 1
d5958a
%endif
d5958a
%endif
d5958a
d5958a
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
d5958a
d5958a
Name:           python-httplib2
d5958a
Version:        0.9.1
d5958a
Release:        3%{?dist}
d5958a
Summary:        A comprehensive HTTP client library
d5958a
Group:          System Environment/Libraries
d5958a
License:        MIT
d5958a
URL:            https://pypi.python.org/pypi/httplib2
d5958a
Source0:        https://pypi.python.org/packages/source/h/httplib2/httplib2-%{version}.tar.gz
d5958a
# See also the 'locater plugin' system httplib2 now allows, and
d5958a
# https://github.com/dreamhost/httplib2-ca_certs_locater
d5958a
# It's kind of problematic, though: https://github.com/jcgregorio/httplib2/issues/293
d5958a
Patch1:         %{name}.certfile.patch
d5958a
Patch2:         %{name}.getCertHost.patch
d5958a
Patch3:         %{name}.rfc2459.patch
d5958a
#
d5958a
# Fix proxy with plain http
d5958a
# https://bugzilla.redhat.com/show_bug.cgi?id=857514
d5958a
# https://github.com/jcgregorio/httplib2/issues/228
d5958a
# 
d5958a
Patch4:         python-httplib2-0.9-proxy-http.patch
d5958a
#
d5958a
# Fix for python2 invalid ssl cert hostname on second run
d5958a
# https://bugzilla.redhat.com/show_bug.cgi?id=958638
d5958a
#
d5958a
Patch5:         python-httplib2-0.9-cve-2013-2037.patch
d5958a
d5958a
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
d5958a
BuildRequires:  python-setuptools
d5958a
BuildRequires:  python-devel
d5958a
BuildArch:      noarch
d5958a
d5958a
%if 0%{?with_python3}
d5958a
BuildRequires:  python3-devel
d5958a
%endif # if with_python3
d5958a
d5958a
%description
d5958a
A comprehensive HTTP client library that supports many features left out of
d5958a
other HTTP libraries.
d5958a
d5958a
%if 0%{?with_python3}
d5958a
%package -n python3-httplib2
d5958a
Summary:        A comprehensive HTTP client library
d5958a
Group:          System Environment/Libraries
d5958a
d5958a
%description -n python3-httplib2
d5958a
A comprehensive HTTP client library that supports many features left out of
d5958a
other HTTP libraries.
d5958a
%endif # with_python3
d5958a
d5958a
%prep
d5958a
%setup -q -n httplib2-%{version}
d5958a
%patch1 -p1 -b .certfile
d5958a
%patch2 -p0 -b .getCertHost
d5958a
%patch3 -p0 -b .rfc2459
d5958a
%patch4 -p1
d5958a
%patch5 -p1
d5958a
d5958a
%if 0%{?with_python3}
d5958a
rm -rf %{py3dir}
d5958a
cp -a . %{py3dir}
d5958a
find %{py3dir} -name '*.py' | xargs sed -i '1s|^#!/usr/bin/python|#!%{__python3}|'
d5958a
%endif # with_python3
d5958a
d5958a
%build
d5958a
CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build
d5958a
d5958a
%if 0%{?with_python3}
d5958a
pushd %{py3dir}
d5958a
%{__python3} setup.py build
d5958a
popd
d5958a
%endif # with_python3
d5958a
d5958a
%install
d5958a
rm -rf $RPM_BUILD_ROOT
d5958a
%{__python} setup.py install --skip-build --root $RPM_BUILD_ROOT
d5958a
d5958a
%if 0%{?with_python3}
d5958a
pushd %{py3dir}
d5958a
%{__python3} setup.py install --skip-build --root $RPM_BUILD_ROOT
d5958a
popd
d5958a
%endif # with_python3
d5958a
d5958a
%clean
d5958a
rm -rf $RPM_BUILD_ROOT
d5958a
d5958a
%files
d5958a
%defattr(-,root,root,-)
d5958a
%{python_sitelib}/*
d5958a
d5958a
%if 0%{?with_python3}
d5958a
%files -n python3-httplib2
d5958a
%defattr(-,root,root,-)
d5958a
%{python3_sitelib}/*
d5958a
%endif # with_python3
d5958a
d5958a
%changelog
d5958a
* Tue May 16 2017 Pavel Cahyna <pcahyna@redhat.com> 0.9.1-3
d5958a
- Rebuild for RHEL 7.4 Extras
d5958a
d5958a
* Fri Oct 23 2015 Jon Schlueter <jschluet@redhat.com> 0.9.1-2.1
d5958a
- change guard for rhel 7 to exclude python 3
d5958a
d5958a
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.1-2
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
d5958a
d5958a
* Sun Apr 12 2015 Kevin Fenzi <kevin@scrye.com> 0.9.1-1
d5958a
- Update to 0.9.1 and drop upstreamed patches
d5958a
d5958a
* Fri Apr 03 2015 Kevin Fenzi <kevin@scrye.com> 0.9-6
d5958a
- Add patch to fix http over proxy. Fixes bug #857514
d5958a
- Add patch to fix CVE-2013-2037. Fixes bug #958640
d5958a
- Add patch to fix binary headers in python3. Fixes bug #1205127
d5958a
d5958a
* Mon Jan 12 2015 Adam Williamson <awilliam@redhat.com> - 0.9-5
d5958a
- certfile.patch: use /etc/pki/tls not /etc/ssl/certs, patch python3 too
d5958a
d5958a
* Mon Jun 30 2014 Toshio Kuratomi <toshio@fedoraproject.org> - 0.9-4
d5958a
- Replace python-setuptools-devel BR with python-setuptools
d5958a
d5958a
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9-3
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
d5958a
d5958a
* Wed May 28 2014 Kalev Lember <kalevlember@gmail.com> - 0.9-2
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Changes/Python_3.4
d5958a
d5958a
* Fri May 23 2014 Kevin Fenzi <kevin@scrye.com> 0.9-1
d5958a
- Update to 0.9
d5958a
d5958a
* Wed May 14 2014 Bohuslav Kabrda <bkabrda@redhat.com> - 0.7.7-4
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Changes/Python_3.4
d5958a
d5958a
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.7.7-3
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
d5958a
d5958a
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.7.7-2
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
d5958a
d5958a
* Wed Jan 02 2013 Ding-Yi Chen <dchen at redhat.com> - 0.7.7-1
d5958a
- Upstream update to 0.7.7
d5958a
d5958a
* Sat Aug 04 2012 David Malcolm <dmalcolm@redhat.com> - 0.7.4-7
d5958a
- rebuild for https://fedoraproject.org/wiki/Features/Python_3.3
d5958a
d5958a
* Fri Jul 27 2012 Ding-Yi Chen <dchen at redhat.com> - 0.7.4-6
d5958a
- Fixed Bug 840968 - SSL errors when the site certificate contains
d5958a
  subjectAltName but DNS is not in it
d5958a
d5958a
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.7.4-5
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
d5958a
d5958a
* Fri Jun 22 2012 Ding-Yi Chen <dchen at redhat.com> - 0.7.4-4
d5958a
- Unify the spec file between EPEL and Fedora.
d5958a
d5958a
* Thu Jun 21 2012 Ding-Yi Chen <dchen at redhat.com> - 0.7.4-3
d5958a
- Applied patch suggested by richardfearn@gmail.com regarding issue 208
d5958a
- Fixed: Bug 832344 - Certification validation fails due to multiple 'dns' entries in subjectAltName
d5958a
d5958a
* Fri Jun 01 2012 Ding-Yi Chen <dchen at redhat.com> - 0.7.4-2
d5958a
- Upstream update for Fedora
d5958a
d5958a
* Thu May 03 2012 Ding-Yi Chen <dchen at redhat.com> - 0.7.4-1
d5958a
- Upstream update to 0.7.4
d5958a
- Applied patch suggested in issue 208
d5958a
d5958a
* Fri Feb 24 2012 Ding-Yi Chen <dchen at redhat.com> - 0.7.2-1
d5958a
- Upstream update to 0.7.2
d5958a
  Which may fixed http://code.google.com/p/httplib2/issues/detail?id=62
d5958a
  Note this version uses fedora's cert file bundle instead of httplib2
d5958a
  default.
d5958a
d5958a
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-6
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
d5958a
d5958a
* Fri Jul 29 2011 Ding-Yi Chen <dchen at redhat.com>  - 0.4.0-5.el6
d5958a
- Apply that address python-httplib2 (GoogleCode Hosted) issue 39
d5958a
  http://code.google.com/p/httplib2/issues/detail?id=39
d5958a
d5958a
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-5
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
d5958a
d5958a
* Wed Aug 25 2010 Thomas Spura <tomspur@fedoraproject.org> - 0.6.0-4
d5958a
- rebuild with python3.2
d5958a
  http://lists.fedoraproject.org/pipermail/devel/2010-August/141368.html
d5958a
d5958a
* Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 0.6.0-3
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
d5958a
d5958a
* Tue Apr 20 2010 Tom "spot" Callaway <tcallawa@redhat.com>
d5958a
- minor spec cleanups
d5958a
- enable python3 support
d5958a
d5958a
* Fri Apr 02 2010 Andreas Bierfert <andreas.bierfert[AT]lowlatency.de> - 0.6.0-1
d5958a
- version upgrade (#566721)
d5958a
d5958a
* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.0-4
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
d5958a
d5958a
* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.0-3
d5958a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
d5958a
d5958a
* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.4.0-2
d5958a
- Rebuild for Python 2.6
d5958a
d5958a
* Thu Dec 27 2007 Andreas Bierfert <andreas.bierfert[AT]lowlatency.de> - 0.4.0-1
d5958a
- initial version