3 %bcond_with tests # do not perform "make test"
4 %bcond_without python2 # CPython 2.x module
5 %bcond_with python3 # CPython 3.x module
7 %define module social_core
8 %define pypi_name social-auth-core
9 %define egg_name social_auth_core
10 Summary: Python Social Auth - Core
11 Name: python-%{pypi_name}
15 Group: Libraries/Python
16 Source0: https://files.pythonhosted.org/packages/source/s/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
17 # Source0-md5: 7adc1a6f92a7847c09692b2ecb831891
18 URL: https://python-social-auth-docs.readthedocs.io/
19 BuildRequires: rpm-pythonprov
20 BuildRequires: rpmbuild(macros) >= 1.714
22 BuildRequires: python-modules
23 BuildRequires: python-setuptools
25 BuildRequires: python-mock = 1.0.1
26 BuildRequires: python-saml >= 2.2.1
30 BuildRequires: python3-modules
31 BuildRequires: python3-setuptools
33 BuildRequires: python3-mock = 1.0.1
34 BuildRequires: python3-saml >= 2.2.1
37 Requires: python-modules
39 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
42 Python Social Auth is an easy to setup social
43 authentication/registration mechanism with support for several
44 frameworks and auth providers.
46 This is the core component of the python-social-auth ecosystem, it
47 implements the common interface to define new authentication backends
48 to third parties services, implement integrations with web frameworks
49 and storage solutions.
51 %package -n python3-%{pypi_name}
52 Summary: Python Social Auth - Core
53 Group: Libraries/Python
55 %description -n python3-%{pypi_name}
56 Python Social Auth is an easy to setup social
57 authentication/registration mechanism with support for several
58 frameworks and auth providers.
60 This is the core component of the python-social-auth ecosystem, it
61 implements the common interface to define new authentication backends
62 to third parties services, implement integrations with web frameworks
63 and storage solutions.
66 %setup -q -n %{pypi_name}-%{version}
70 %py_build %{?with_tests:test}
74 %py3_build %{?with_tests:test}
78 rm -rf $RPM_BUILD_ROOT
83 # rm tests (or subpackage?)
84 %{__rm} -r $RPM_BUILD_ROOT%{py_sitescriptdir}/social_core/tests
90 # rm tests (or subpackage?)
91 %{__rm} -r $RPM_BUILD_ROOT%{py3_sitescriptdir}/social_core/tests
95 rm -rf $RPM_BUILD_ROOT
99 %defattr(644,root,root,755)
100 %doc README.md LICENSE
101 %{py_sitescriptdir}/%{module}
102 %{py_sitescriptdir}/%{egg_name}-%{version}-py*.egg-info
106 %files -n python3-%{pypi_name}
107 %defattr(644,root,root,755)
108 %doc README.md LICENSE
109 %{py3_sitescriptdir}/%{module}
110 %{py3_sitescriptdir}/%{egg_name}-%{version}-py*.egg-info