]> git.pld-linux.org Git - packages/python-oauthlib.git/blob - python-oauthlib.spec
5ee82e6eafad801cc4b14a340a78c5ae710cf8e1
[packages/python-oauthlib.git] / python-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  oauthlib
6 Summary:        A generic, spec-compliant, thorough implementation of the OAuth request-signing logic
7 Name:           python-%{module}
8 Version:        2.0.7
9 Release:        2
10 License:        BSD
11 Group:          Development/Languages/Python
12 Source0:        https://pypi.python.org/packages/source/o/oauthlib/%{module}-%{version}.tar.gz
13 # Source0-md5:  1fca21cda1c106ff4c5110cc355dca22
14 URL:            https://pypi.python.org/pypi/oauthlib
15 %if %{with python2}
16 BuildRequires:  python-setuptools
17 BuildRequires:  python-modules >= 1:2.6
18 %endif
19 %if %{with python3}
20 BuildRequires:  python3-setuptools
21 BuildRequires:  python3-modules >= 3.2
22 %endif
23 BuildRequires:  rpm-pythonprov
24 BuildRequires:  rpmbuild(macros) >= 1.710
25 BuildArch:      noarch
26 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28 %description
29 OAuthLib is a generic utility which implements the logic of OAuth
30 without assuming a specific HTTP request object. Use it to graft OAuth
31 support onto your favorite HTTP library. If you're a maintainer of
32 such a library, write a thin veneer on top of OAuthLib and get OAuth
33 support for very little effort.
34
35 %package -n python3-oauthlib
36 Summary:        A generic, spec-compliant, thorough implementation of the OAuth request-signing logic
37 Group:          Development/Languages/Python
38
39 %description -n python3-oauthlib
40 OAuthLib is a generic utility which implements the logic of OAuth
41 without assuming a specific HTTP request object. Use it to graft OAuth
42 support onto your favorite HTTP library. If you're a maintainer of
43 such a library, write a thin veneer on top of OAuthLib and get OAuth
44 support for very little effort.
45
46 %prep
47 %setup -q -n %{module}-%{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
61 %if %{with python2}
62 %py_install
63 %py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir}
64 %py_comp $RPM_BUILD_ROOT%{py_sitescriptdir}
65 %py_postclean
66 %endif
67
68 %if %{with python3}
69 %py3_install
70 %endif
71
72 %clean
73 rm -rf $RPM_BUILD_ROOT
74
75 %if %{with python2}
76 %files
77 %defattr(644,root,root,755)
78 %doc README.rst CHANGELOG.rst
79 %{py_sitescriptdir}/%{module}
80 %if "%{py_ver}" > "2.4"
81 %{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
82 %endif
83 %endif
84
85 %if %{with python3}
86 %files -n python3-oauthlib
87 %defattr(644,root,root,755)
88 %doc README.rst CHANGELOG.rst
89 %{py3_sitescriptdir}/%{module}
90 %{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
91 %endif
This page took 0.047757 seconds and 2 git commands to generate.