]> git.pld-linux.org Git - packages/python-requests-oauthlib.git/blob - python-requests-oauthlib.spec
Version: 0.8.0
[packages/python-requests-oauthlib.git] / python-requests-oauthlib.spec
1 # Conditional build:
2 %bcond_without  python2         # build python 2 module
3 %bcond_without  python3         # build python 3 module
4
5 %define         module          requests_oauthlib
6 %define         egg_name        requests_oauthlib
7 %define         pypi_name       requests-oauthlib
8 Summary:        First-class OAuth library support for python-requests
9 Name:           python-%{pypi_name}
10 Version:        0.8.0
11 Release:        1
12 License:        ISC
13 Group:          Development/Languages/Python
14 Source0:        https://files.pythonhosted.org/packages/source/r/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
15 # Source0-md5:  4358a879a4377393bcfd37d0f9ae6d4d
16 URL:            https://github.com/requests/requests-oauthlib
17 %if %{with python2}
18 BuildRequires:  python-setuptools
19 %endif
20 %if %{with python3}
21 BuildRequires:  python3-setuptools
22 %endif
23 BuildRequires:  rpm-pythonprov
24 BuildRequires:  rpmbuild(macros) >= 1.710
25 Requires:       python-modules >= 1:2.6
26 Requires:       python-oauthlib >= 0.4.2
27 Requires:       python-requests >= 1.0.0
28 Obsoletes:      python-requests_oauthlib < 0.6.1-3
29 BuildArch:      noarch
30 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32 %description
33 First-class OAuth library support for python-requests.
34
35 %package -n python3-%{pypi_name}
36 Summary:        First-class OAuth library support for python-requests
37 Group:          Development/Languages/Python
38 Requires:       python3-modules >= 3.2
39 Requires:       python3-oauthlib >= 0.4.2
40 Requires:       python3-requests >= 1.0.0
41 Obsoletes:      python3-requests_oauthlib < 0.6.1-3
42
43 %description -n python3-%{pypi_name}
44 First-class OAuth library support for python-requests.
45
46 %prep
47 %setup -q -n %{pypi_name}-%{version}
48
49 %build
50 %if %{with python2}
51 %py_build
52 %endif
53
54 %if %{with python3}
55 %py3_build
56 %endif
57
58 %install
59 rm -rf $RPM_BUILD_ROOT
60 %if %{with python2}
61 %py_install
62 %py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir}
63 %py_comp $RPM_BUILD_ROOT%{py_sitescriptdir}
64 %py_postclean
65 %endif
66
67 %if %{with python3}
68 %py3_install
69 %endif
70
71 %clean
72 rm -rf $RPM_BUILD_ROOT
73
74 %if %{with python2}
75 %files
76 %defattr(644,root,root,755)
77 %doc README.rst
78 %{py_sitescriptdir}/%{module}
79 %{py_sitescriptdir}/%{egg_name}-%{version}-py*.egg-info
80 %endif
81
82 %if %{with python3}
83 %files -n python3-%{pypi_name}
84 %defattr(644,root,root,755)
85 %doc README.rst
86 %{py3_sitescriptdir}/%{module}
87 %{py3_sitescriptdir}/%{egg_name}-%{version}-py*.egg-info
88 %endif
This page took 0.121975 seconds and 4 git commands to generate.