3 %bcond_without python2 # CPython 2.x module
4 %bcond_without python3 # CPython 3.x module
7 %define egg_name tlslite
8 Summary: Open source Python library that implements SSL and TLS
13 Group: Libraries/Python
14 Source0: https://pypi.python.org/packages/source/t/%{module}/%{module}-%{version}.tar.gz
15 # Source0-md5: 9f3b3797f595dd66cd36a65c83a87869
16 URL: http://trevp.net/tlslite
17 BuildRequires: rpm-pythonprov
18 BuildRequires: rpmbuild(macros) >= 1.714
20 BuildRequires: python-modules >= 1:2.6
21 BuildRequires: python-setuptools
24 BuildRequires: python3-modules >= 1:3.2
25 BuildRequires: python3-setuptools
28 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31 TLS Lite is an open source Python library that implements SSL and TLS.
32 TLS Lite supports RSA and SRP cipher suites. TLS Lite is pure Python,
33 however it can use other libraries for faster crypto operations. TLS
34 Lite integrates with several stdlib networking libraries.
36 %package -n python3-%{module}
37 Summary: Open source Python library that implements SSL and TLS
38 Group: Libraries/Python
40 %description -n python3-%{module}
41 TLS Lite is an open source Python library that implements SSL and TLS.
42 TLS Lite supports RSA and SRP cipher suites. TLS Lite is pure Python,
43 however it can use other libraries for faster crypto operations. TLS
44 Lite integrates with several stdlib networking libraries.
47 %setup -q -n %{module}-%{version}
51 # and remove their executable permission so that they don't drag in more
52 # dependencies, and lint doesn't throw a warning
53 chmod -x scripts/tls*.py
64 rm -rf $RPM_BUILD_ROOT
73 # scripts are of limited usefulness, put them only in docs
74 rm $RPM_BUILD_ROOT%{_bindir}/tls*.py
77 rm -rf $RPM_BUILD_ROOT
81 %defattr(644,root,root,755)
82 %doc README LICENSE scripts/tls*.py
83 %{py_sitescriptdir}/%{module}
84 %{py_sitescriptdir}/%{egg_name}-%{version}-py*.egg-info
88 %files -n python3-%{module}
89 %defattr(644,root,root,755)
90 %doc README LICENSE scripts/tls*.py
91 %{py3_sitescriptdir}/%{module}
92 %{py3_sitescriptdir}/%{egg_name}-%{version}-py*.egg-info