]> git.pld-linux.org Git - packages/python-pyglet.git/blame - python-pyglet.spec
- rebuild with python 3.8
[packages/python-pyglet.git] / python-pyglet.spec
CommitLineData
4bdc2559
JR
1#
2# Conditional build:
3%bcond_without python2 # CPython 2.x module
4%bcond_without python3 # CPython 3.x module
eb8b39fb 5%bcond_with tests # unit tests (display required)
4bdc2559
JR
6
7%define module pyglet
770077cd 8Summary: A cross-platform windowing and multimedia library for Python
9Summary(pl.UTF-8): Międzyplatformowa biblioteka Pythona do obsługi okien i multimediów
10Name: python-%{module}
eb8b39fb 11Version: 1.4.4
4120a779 12Release: 2
fad7263f 13License: BSD
770077cd 14Group: Development/Languages/Python
eb8b39fb
JB
15#Source0Download: https://pypi.org/simple/pyglet/
16Source0: https://files.pythonhosted.org/packages/source/p/pyglet/%{module}-%{version}.zip
17# Source0-md5: ebd53b60f55b5d50e63f86e7df121e7a
770077cd 18URL: http://www.pyglet.org/
4bdc2559 19%if %{with python2}
eb8b39fb
JB
20BuildRequires: python-devel >= 1:2.7
21BuildRequires: python-setuptools
22%if %{with tests}
23BuildRequires: OpenGL >= 3
24BuildRequires: python-mock
25BuildRequires: python-pytest
26%endif
4bdc2559
JR
27%endif
28%if %{with python3}
eb8b39fb
JB
29BuildRequires: python3-devel >= 1:3.4
30BuildRequires: python3-setuptools
31%if %{with tests}
32BuildRequires: OpenGL >= 3
33BuildRequires: python3-pytest
34%endif
4bdc2559 35%endif
770077cd 36BuildRequires: rpm-pythonprov
eb8b39fb
JB
37BuildRequires: rpmbuild(macros) >= 1.714
38Requires: python-modules >= 1:2.7
770077cd 39BuildArch: noarch
40BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41
42%description
43pyglet provides an object-oriented programming interface for
44developing games and other visually-rich applications.
45
46%description -l pl.UTF-8
47pyglet dostarcza interfejs do programowania zorientowanego obiektowo
48dla rozwoju gier i innych aplikacji wizualnych.
49
4bdc2559
JR
50%package -n python3-%{module}
51Summary: A cross-platform windowing and multimedia library for Python
52Summary(pl.UTF-8): Międzyplatformowa biblioteka Pythona do obsługi okien i multimediów
53Group: Libraries/Python
eb8b39fb 54Requires: python3-modules >= 1:3.4
4bdc2559
JR
55
56%description -n python3-%{module}
57pyglet provides an object-oriented programming interface for
58developing games and other visually-rich applications.
59
60%description -n python3-%{module} -l pl.UTF-8
61pyglet dostarcza interfejs do programowania zorientowanego obiektowo
62dla rozwoju gier i innych aplikacji wizualnych.
63
770077cd 64%prep
65%setup -q -n %{module}-%{version}
66
67%build
4bdc2559 68%if %{with python2}
9b4ed0a6 69%py_build
eb8b39fb
JB
70
71%if %{with tests}
72%{__python} -m pytest tests
73%endif
4bdc2559
JR
74%endif
75
76%if %{with python3}
9b4ed0a6 77%py3_build
eb8b39fb
JB
78
79%if %{with tests}
80%{__python3} -m pytest tests
81%endif
4bdc2559 82%endif
770077cd 83
84%install
85rm -rf $RPM_BUILD_ROOT
4bdc2559
JR
86
87%if %{with python2}
9b4ed0a6 88%py_install
770077cd 89
770077cd 90%py_postclean
4bdc2559
JR
91%endif
92
93%if %{with python3}
9b4ed0a6 94%py3_install
4bdc2559 95%endif
770077cd 96
97%clean
98rm -rf $RPM_BUILD_ROOT
99
4bdc2559 100%if %{with python2}
770077cd 101%files
102%defattr(644,root,root,755)
eb8b39fb
JB
103%doc LICENSE NOTICE README.rst RELEASE_NOTES
104%{py_sitescriptdir}/pyglet
105%{py_sitescriptdir}/pyglet-%{version}-py*.egg-info
4bdc2559
JR
106%endif
107
108%if %{with python3}
109%files -n python3-%{module}
110%defattr(644,root,root,755)
eb8b39fb
JB
111%doc LICENSE NOTICE README.rst RELEASE_NOTES
112%{py3_sitescriptdir}/pyglet
113%{py3_sitescriptdir}/pyglet-%{version}-py*.egg-info
4bdc2559 114%endif
This page took 0.063238 seconds and 4 git commands to generate.