|
|
060a8c2 |
%if 0%{?fedora}
|
|
|
060a8c2 |
%global with_python3 1
|
|
Ian Weller |
802216d |
%endif
|
|
Ian Weller |
802216d |
|
|
|
060a8c2 |
%if 0%{?rhel} && 0%{?rhel} <= 6
|
|
|
060a8c2 |
%{!?__python2: %global __python2 /usr/bin/python2}
|
|
|
060a8c2 |
%{!?python2_sitelib: %global python2_sitelib %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
|
|
|
060a8c2 |
%endif
|
|
|
060a8c2 |
|
|
|
060a8c2 |
%global srcname iso8601
|
|
Ian Weller |
802216d |
|
|
|
060a8c2 |
Name: python-%{srcname}
|
|
|
b3d8b90 |
Version: 0.1.10
|
|
|
060a8c2 |
Release: 2%{?dist}
|
|
Ian Weller |
802216d |
Summary: Simple module to parse ISO 8601 dates
|
|
Ian Weller |
802216d |
|
|
Ian Weller |
802216d |
Group: Development/Languages
|
|
Ian Weller |
802216d |
License: MIT
|
|
|
060a8c2 |
URL: http://pypi.python.org/pypi/%{srcname}/
|
|
|
060a8c2 |
Source0: http://pypi.python.org/packages/source/i/%{srcname}/%{srcname}-%{version}.tar.gz
|
|
Ian Weller |
802216d |
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
Ian Weller |
802216d |
|
|
Ian Weller |
802216d |
BuildArch: noarch
|
|
|
6025529 |
BuildRequires: python2-devel python-setuptools
|
|
|
060a8c2 |
%if 0%{?with_python3}
|
|
|
060a8c2 |
BuildRequires: python3-devel python3-setuptools
|
|
|
060a8c2 |
%endif
|
|
Ian Weller |
802216d |
|
|
Ian Weller |
802216d |
%description
|
|
|
060a8c2 |
This module parses the most common forms of ISO 8601 date strings
|
|
|
060a8c2 |
(e.g. 2007-01-14T20:34:22+00:00) into datetime objects.
|
|
Ian Weller |
802216d |
|
|
|
060a8c2 |
%if 0%{?with_python3}
|
|
|
060a8c2 |
%package -n python3-%{srcname}
|
|
|
060a8c2 |
Summary: Simple module to parse ISO 8601 dates
|
|
|
060a8c2 |
Group: Development/Languages
|
|
|
060a8c2 |
|
|
|
060a8c2 |
%description -n python3-%{srcname}
|
|
|
060a8c2 |
This module parses the most common forms of ISO 8601 date strings
|
|
|
060a8c2 |
(e.g. 2007-01-14T20:34:22+00:00) into datetime objects.
|
|
|
060a8c2 |
%endif
|
|
Ian Weller |
802216d |
|
|
Ian Weller |
802216d |
%prep
|
|
|
060a8c2 |
%setup -qn %{srcname}-%{version}
|
|
|
060a8c2 |
|
|
|
060a8c2 |
%if 0%{?with_python3}
|
|
|
060a8c2 |
cp -a . %{py3dir}
|
|
|
060a8c2 |
%endif
|
|
Ian Weller |
802216d |
|
|
Ian Weller |
802216d |
|
|
Ian Weller |
802216d |
%build
|
|
|
060a8c2 |
%{__python2} setup.py build
|
|
Ian Weller |
802216d |
|
|
|
060a8c2 |
%if 0%{?with_python3}
|
|
|
060a8c2 |
pushd %{py3dir}
|
|
|
060a8c2 |
%{__python3} setup.py build
|
|
|
060a8c2 |
popd
|
|
|
060a8c2 |
%endif
|
|
Ian Weller |
802216d |
|
|
Ian Weller |
802216d |
%install
|
|
|
060a8c2 |
%{__python2} setup.py install -O1 --skip-build --root %{buildroot}
|
|
Ian Weller |
802216d |
|
|
|
060a8c2 |
%if 0%{?with_python3}
|
|
|
060a8c2 |
pushd %{py3dir}
|
|
|
060a8c2 |
%{__python3} setup.py install --skip-build --root %{buildroot}
|
|
|
060a8c2 |
popd
|
|
|
060a8c2 |
%endif
|
|
Ian Weller |
802216d |
|
|
Ian Weller |
802216d |
%files
|
|
Ian Weller |
802216d |
%defattr(-,root,root,-)
|
|
|
6025529 |
%doc LICENSE README.rst
|
|
|
060a8c2 |
%{python2_sitelib}/*
|
|
Ian Weller |
802216d |
|
|
|
060a8c2 |
%if 0%{?with_python3}
|
|
|
060a8c2 |
%files -n python3-%{srcname}
|
|
|
060a8c2 |
%defattr(-,root,root,-)
|
|
|
060a8c2 |
%doc LICENSE README.rst
|
|
|
060a8c2 |
%{python3_sitelib}/*
|
|
|
060a8c2 |
%endif
|
|
Ian Weller |
802216d |
|
|
Ian Weller |
802216d |
%changelog
|
|
|
060a8c2 |
* Wed Apr 23 2014 Pádraig Brady <pbrady@redhat.com> - 0.1.10-2
|
|
|
060a8c2 |
- Add python3 package
|
|
|
060a8c2 |
|
|
|
b3d8b90 |
* Thu Mar 27 2014 Pádraig Brady <pbrady@redhat.com> - 0.1.10-1
|
|
|
b3d8b90 |
- Latest upstream
|
|
|
b3d8b90 |
|
|
|
6025529 |
* Tue Nov 12 2013 Pádraig Brady <pbrady@redhat.com> - 0.1.8-1
|
|
|
6025529 |
- Latest upstream
|
|
|
6025529 |
|
|
|
a7b823e |
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.4-7
|
|
|
a7b823e |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
|
|
|
a7b823e |
|
|
|
5f44268 |
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.4-6
|
|
|
5f44268 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
|
|
5f44268 |
|
|
|
339de64 |
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.4-5
|
|
|
339de64 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
|
|
|
339de64 |
|
|
|
dfc4912 |
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.4-4
|
|
|
dfc4912 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
|
|
dfc4912 |
|
|
|
73ec692 |
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.4-3
|
|
|
73ec692 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
|
|
|
73ec692 |
|
|
Ian Weller |
802216d |
* Fri Jul 9 2010 Ian Weller <iweller@redhat.com> - 0.1.4-2
|
|
Ian Weller |
802216d |
- Correct python_sitelib macro
|
|
Ian Weller |
802216d |
|
|
Ian Weller |
802216d |
* Mon Jun 28 2010 Ian Weller <iweller@redhat.com> - 0.1.4-1
|
|
Ian Weller |
802216d |
- Initial package build
|