]> git.pld-linux.org Git - packages/python-pyusb.git/blame - python-pyusb.spec
rebuild with python 3.10
[packages/python-pyusb.git] / python-pyusb.spec
CommitLineData
279ffc8b
JB
1#
2# Conditional build:
3%bcond_without python2 # CPython 2.x module
4%bcond_without python3 # CPython 3.x module
5
699c8ec6
AM
6%define module pyusb
7Summary: PyUSB provides USB access on the Python language
aeccd4dd 8Summary(pl.UTF-8): PyUSB - dostęp do USB z poziomu języka Python
699c8ec6 9Name: python-%{module}
e212a934 10Version: 1.0.2
51e1d7e4 11Release: 6
07b11337 12License: BSD
699c8ec6 13Group: Development/Languages/Python
0efd3ed6 14Source0: http://downloads.sourceforge.net/pyusb/%{module}-%{version}.tar.gz
e212a934 15# Source0-md5: 95bf0adc0f25bfb70daf86605cff2b3f
cd5eea44 16URL: http://pyusb.sourceforge.net/
e8cc6ead 17BuildRequires: rpm-pythonprov
279ffc8b
JB
18BuildRequires: rpmbuild(macros) >= 1.714
19%if %{with python2}
20BuildRequires: python-devel >= 1:2.5
64c86985 21BuildRequires: python-setuptools
279ffc8b
JB
22%endif
23%if %{with python3}
24BuildRequires: python3-devel >= 1:3.2
64c86985 25BuildRequires: python3-setuptools
279ffc8b
JB
26%endif
27Requires: python-libs >= 1:2.5
28Requires: libusb >= 1.0.0
29BuildArch: noarch
699c8ec6
AM
30BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32%description
33PyUSB provides USB access on the Python language.
34
171e7b53
JR
35%description -l pl.UTF-8
36PyUSB daje dostęp do USB z poziomu języka Python.
8093ecad 37
279ffc8b
JB
38%package -n python3-%{module}
39Summary: PyUSB provides USB access on the Python language
40Summary(pl.UTF-8): PyUSB - dostęp do USB z poziomu języka Python
41Group: Development/Languages/Python
42Requires: python3-libs >= 1:3.2
43Requires: libusb >= 1.0.0
44
45%description -n python3-%{module}
46PyUSB provides USB access on the Python language.
47
48%description -n python3-%{module} -l pl.UTF-8
49PyUSB daje dostęp do USB z poziomu języka Python.
50
699c8ec6 51%prep
07b11337 52%setup -q -n %{module}-%{version}
699c8ec6
AM
53
54%build
279ffc8b 55%if %{with python2}
516fd20d 56%py_build
279ffc8b
JB
57%endif
58
59%if %{with python3}
60%py3_build
61%endif
699c8ec6
AM
62
63%install
64rm -rf $RPM_BUILD_ROOT
65
279ffc8b
JB
66%if %{with python2}
67%py_install
68
69%py_postclean
70%endif
71
72%if %{with python3}
73%py3_install
74%endif
699c8ec6
AM
75
76%clean
77rm -rf $RPM_BUILD_ROOT
78
279ffc8b 79%if %{with python2}
699c8ec6
AM
80%files
81%defattr(644,root,root,755)
e212a934 82%doc ACKNOWLEDGEMENTS LICENSE README.rst docs/*.rst
279ffc8b
JB
83%{py_sitescriptdir}/usb
84%{py_sitescriptdir}/pyusb-%{version}-py*.egg-info
85%endif
86
87%if %{with python3}
88%files -n python3-%{module}
89%defattr(644,root,root,755)
e212a934 90%doc ACKNOWLEDGEMENTS LICENSE README.rst docs/*.rst
279ffc8b
JB
91%{py3_sitescriptdir}/usb
92%{py3_sitescriptdir}/pyusb-%{version}-py*.egg-info
93%endif
This page took 0.085427 seconds and 4 git commands to generate.