Update to 1.3.2
This commit is contained in:
parent
a9d27a6f02
commit
f61908766f
3
.gitignore
vendored
3
.gitignore
vendored
@ -1,2 +1 @@
|
|||||||
/python-yubico-1.2.1.tar.gz
|
/python-yubico-1.3.2.tar.gz
|
||||||
/python-yubico-1.2.3.tar.gz
|
|
||||||
|
|||||||
@ -1,37 +1,23 @@
|
|||||||
%if 0%{?rhel} != 0 && 0%{?rhel} <= 6
|
%{!?_licensedir:%global license %%doc}
|
||||||
%{!?__python2: %global __python2 /usr/bin/python2}
|
|
||||||
%{!?python2_sitelib: %global python2_sitelib %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%if 0%{?rhel} != 0 && 0%{?rhel} <= 7
|
%global srcname yubico
|
||||||
# Do not build python3 subpackage for RHEL <= 7
|
|
||||||
%bcond_with python3
|
|
||||||
%else
|
|
||||||
%bcond_without python3
|
|
||||||
%endif
|
|
||||||
|
|
||||||
Name: python-yubico
|
Name: python-%{srcname}
|
||||||
Version: 1.2.3
|
Version: 1.3.2
|
||||||
Release: 6%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: Pure-python library for interacting with Yubikeys
|
Summary: Pure-python library for interacting with Yubikeys
|
||||||
|
|
||||||
License: BSD
|
License: BSD
|
||||||
URL: https://github.com/Yubico/python-yubico
|
URL: https://github.com/Yubico/%{name}
|
||||||
Source0: https://github.com/Yubico/python-yubico/archive/%{name}-%{version}.tar.gz
|
Source0: https://github.com/Yubico/%{name}/archive/%{name}-%{version}.tar.gz
|
||||||
|
|
||||||
Patch0: %{name}-python3.patch
|
|
||||||
Patch1: %{name}-python3_util_examples.patch
|
|
||||||
|
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
BuildRequires: python2-devel
|
BuildRequires: python2-devel
|
||||||
BuildRequires: python-setuptools
|
BuildRequires: python2-setuptools
|
||||||
%if 0%{?rhel} == 0 || 0%{?rhel} >= 7
|
BuildRequires: python2-nose
|
||||||
BuildRequires: python-nose
|
|
||||||
BuildRequires: pyusb
|
BuildRequires: pyusb
|
||||||
%endif
|
|
||||||
Requires: pyusb
|
|
||||||
|
|
||||||
%if %{with python3}
|
%if 0%{fedora}
|
||||||
BuildRequires: python3-devel
|
BuildRequires: python3-devel
|
||||||
BuildRequires: python3-setuptools
|
BuildRequires: python3-setuptools
|
||||||
BuildRequires: python3-nose
|
BuildRequires: python3-nose
|
||||||
@ -41,89 +27,50 @@ BuildRequires: python3-pyusb
|
|||||||
%description
|
%description
|
||||||
Pure-python library for interacting with Yubikeys
|
Pure-python library for interacting with Yubikeys
|
||||||
|
|
||||||
%if %{with python3}
|
%package -n python2-%{srcname}
|
||||||
%package -n python3-yubico
|
Summary: Pure-python library for interacting with Yubikeys
|
||||||
|
Requires: pyusb
|
||||||
|
|
||||||
|
%description -n python2-%{srcname}
|
||||||
|
Pure-python library for interacting with Yubikeys. For Python 2.
|
||||||
|
|
||||||
|
%package -n python3-%{srcname}
|
||||||
Summary: Pure-python library for interacting with Yubikeys
|
Summary: Pure-python library for interacting with Yubikeys
|
||||||
Requires: python3-pyusb
|
Requires: python3-pyusb
|
||||||
|
|
||||||
%description -n python3-yubico
|
%description -n python3-%{srcname}
|
||||||
Pure-python library for interacting with Yubikeys. For Python 3.
|
Pure-python library for interacting with Yubikeys. For Python 3.
|
||||||
%endif
|
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -qc
|
%autosetup -n %{name}-%{name}-%{version}
|
||||||
|
|
||||||
mv %{name}-%{name}-%{version} python2
|
|
||||||
|
|
||||||
pushd python2
|
|
||||||
sed -i 's|setup_requires=|tests_require=|' setup.py
|
|
||||||
popd
|
|
||||||
|
|
||||||
%if %{with python3}
|
|
||||||
cp -a python{2,3}
|
|
||||||
|
|
||||||
pushd python3
|
|
||||||
%patch0 -p1
|
|
||||||
%patch1 -p1
|
|
||||||
popd
|
|
||||||
%endif
|
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
pushd python2
|
%py2_build
|
||||||
%{__python2} setup.py build
|
%py3_build
|
||||||
popd
|
|
||||||
|
|
||||||
%if %{with python3}
|
|
||||||
pushd python3
|
|
||||||
%{__python3} setup.py build
|
|
||||||
popd
|
|
||||||
%endif
|
|
||||||
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
pushd python2
|
%py2_install
|
||||||
%{__python2} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
|
%py3_install
|
||||||
popd
|
|
||||||
|
|
||||||
%if %{with python3}
|
%files -n python2-%{srcname}
|
||||||
pushd python3
|
%license COPYING
|
||||||
%{__python3} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
|
%doc NEWS README
|
||||||
popd
|
|
||||||
%endif
|
|
||||||
|
|
||||||
|
|
||||||
%files
|
|
||||||
%{!?_licensedir:%global license %%doc}
|
|
||||||
%license python2/COPYING
|
|
||||||
%doc python2/NEWS python2/README
|
|
||||||
%{python2_sitelib}/*
|
%{python2_sitelib}/*
|
||||||
|
|
||||||
%if %{with python3}
|
%files -n python3-%{srcname}
|
||||||
%files -n python3-yubico
|
%license COPYING
|
||||||
%license python3/COPYING
|
%doc NEWS README
|
||||||
%doc python3/NEWS python3/README
|
|
||||||
%{python3_sitelib}/*
|
%{python3_sitelib}/*
|
||||||
%endif
|
|
||||||
|
|
||||||
%if 0%{?rhel} == 0 || 0%{?rhel} >= 7
|
|
||||||
%check
|
%check
|
||||||
|
nosetests-%{python2_version} -e test_challenge_response -e test_serial -e test_status
|
||||||
pushd python2
|
|
||||||
# Exclude tests that require a physical yubikey attached.
|
|
||||||
nosetests -e test_challenge_response -e test_serial -e test_status
|
|
||||||
popd
|
|
||||||
|
|
||||||
%if %{with python3}
|
|
||||||
pushd python3
|
|
||||||
# Exclude tests that require a physical yubikey attached.
|
|
||||||
nosetests-%{python3_version} -e test_challenge_response -e test_serial -e test_status
|
nosetests-%{python3_version} -e test_challenge_response -e test_serial -e test_status
|
||||||
popd
|
|
||||||
%endif # with python3
|
|
||||||
|
|
||||||
%endif # rhel
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue May 10 2016 Nathaniel McCallum <npmccallum@redhat.com> - 1.3.2-1
|
||||||
|
- Cleanup obsolete conditions (like RHEL 6)
|
||||||
|
- Update to v1.3.2
|
||||||
|
|
||||||
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.3-6
|
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.3-6
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user