python-asn1crypto/python-asn1crypto.spec

114 lines
3.1 KiB
RPMSpec
Raw Normal View History

2017-06-27 16:25:01 +00:00
# Created by pyp2rpm-3.2.2
%global pypi_name asn1crypto
2017-10-12 09:22:00 +00:00
%if 0%{?fedora}
%global with_python3 1
%endif
%{!?python3_pkgversion:%global python3_pkgversion 3}
2017-06-27 16:25:01 +00:00
Name: python-%{pypi_name}
2017-10-12 09:22:00 +00:00
Version: 0.23.0
Release: 2%{?dist}
2017-06-27 16:25:01 +00:00
Summary: Fast Python ASN.1 parser and serializer
License: MIT
URL: https://github.com/wbond/asn1crypto
Source0: https://files.pythonhosted.org/packages/source/a/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
BuildArch: noarch
2017-06-27 16:30:35 +00:00
2017-06-27 16:25:01 +00:00
BuildRequires: python2-devel
2017-10-12 09:22:00 +00:00
BuildRequires: python2-setuptools
2017-06-27 16:30:35 +00:00
2017-10-12 09:22:00 +00:00
%if 0%{?with_python3}
2017-08-03 09:58:18 +00:00
BuildRequires: python%{python3_pkgversion}-devel
BuildRequires: python%{python3_pkgversion}-setuptools
2017-10-12 09:22:00 +00:00
%endif
2017-06-27 16:25:01 +00:00
%description
Fast ASN.1 parser and serializer with definitions for private keys,
public keys, certificates, CRL, OCSP, CMS, PKCS#3, PKCS#7, PKCS#8,
PKCS#12, PKCS#5, X.509 and TSP.
%package -n python2-%{pypi_name}
Summary: %{summary}
%{?python_provide:%python_provide python2-%{pypi_name}}
%description -n python2-%{pypi_name}
Fast ASN.1 parser and serializer with definitions for private keys,
public keys, certificates, CRL, OCSP, CMS, PKCS#3, PKCS#7, PKCS#8,
PKCS#12, PKCS#5, X.509 and TSP.
2017-10-12 09:22:00 +00:00
%if 0%{?with_python3}
2017-08-03 09:58:18 +00:00
%package -n python%{python3_pkgversion}-%{pypi_name}
2017-06-27 16:25:01 +00:00
Summary: %{summary}
2017-08-03 09:58:18 +00:00
%{?python_provide:%python_provide python%{python3_pkgversion}-%{pypi_name}}
2017-06-27 16:25:01 +00:00
2017-08-03 09:58:18 +00:00
%description -n python%{python3_pkgversion}-%{pypi_name}
2017-06-27 16:25:01 +00:00
Fast ASN.1 parser and serializer with definitions for private keys,
public keys, certificates, CRL, OCSP, CMS, PKCS#3, PKCS#7, PKCS#8,
PKCS#12, PKCS#5, X.509 and TSP.
2017-10-12 09:22:00 +00:00
%endif
2017-06-27 16:25:01 +00:00
%prep
%autosetup -n %{pypi_name}-%{version}
# Remove bundled egg-info
rm -rf %{pypi_name}.egg-info
%build
%py2_build
2017-10-12 09:22:00 +00:00
%if 0%{?with_python3}
2017-06-27 16:25:01 +00:00
%py3_build
2017-10-12 09:22:00 +00:00
%endif
2017-06-27 16:25:01 +00:00
%install
# Must do the subpackages' install first because the scripts in /usr/bin are
# overwritten with every setup.py install.
2017-10-12 09:22:00 +00:00
%if 0%{?with_python3}
2017-06-27 16:25:01 +00:00
%py3_install
2017-10-12 09:22:00 +00:00
%endif
2017-06-27 16:25:01 +00:00
%py2_install
%check
# asn1crypto source distribution doesn't come with tests
2017-06-27 16:30:35 +00:00
# {__python2} setup.py test
2017-10-12 09:22:00 +00:00
%if 0%{?with_python3}
2017-06-27 16:30:35 +00:00
# {__python3} setup.py test
2017-10-12 09:22:00 +00:00
%endif
2017-06-27 16:25:01 +00:00
%files -n python2-%{pypi_name}
2017-06-27 16:30:35 +00:00
%doc
2017-06-27 16:25:01 +00:00
%{python2_sitelib}/%{pypi_name}
%{python2_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info
2017-10-12 09:22:00 +00:00
%if 0%{?with_python3}
2017-08-03 09:58:18 +00:00
%files -n python%{python3_pkgversion}-%{pypi_name}
2017-06-27 16:30:35 +00:00
%doc
2017-06-27 16:25:01 +00:00
%{python3_sitelib}/%{pypi_name}
%{python3_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info
2017-10-12 09:22:00 +00:00
%endif
2017-06-27 16:25:01 +00:00
%changelog
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.23.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
2017-10-12 09:22:00 +00:00
* Thu Oct 12 2017 Christian Heimes <cheimes@redhat.com> - 0.23-1
- New upstream release 0.23.0
* Fri Aug 04 2017 Christian Heimes <cheimes@redhat.com> - 0.22.0-5
- Use python2-setuptools, add with_python3
2017-08-03 09:58:18 +00:00
* Thu Aug 03 2017 Christian Heimes <cheimes@redhat.com> - 0.22.0-4
- Modernize spec
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.22.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
2017-06-27 16:30:35 +00:00
* Tue Jun 27 2017 Christian Heimes <cheimes@redhat.com> - 0.22.0-2
- Address rpmlint issues
2017-06-27 16:25:01 +00:00
* Tue Jun 27 2017 Christian Heimes <cheimes@redhat.com> - 0.22.0-1
- Initial package.