-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpython3-tinycss2.spec
More file actions
92 lines (77 loc) · 2.29 KB
/
python3-tinycss2.spec
File metadata and controls
92 lines (77 loc) · 2.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
#
# Conditional build:
%bcond_without doc # Sphinx documentation
%bcond_without tests # unit tests
Summary: Low-level CSS parser for Python
Summary(pl.UTF-8): Niskopoziomowy parser CSS dla Pythona
Name: python3-tinycss2
Version: 1.5.1
Release: 2
License: BSD
Group: Libraries/Python
#Source0Download: https://pypi.org/simple/tinycss2/
Source0: https://files.pythonhosted.org/packages/source/t/tinycss2/tinycss2-%{version}.tar.gz
# Source0-md5: 003d9f446bddb3dfc76d0f3db0f38fea
URL: https://pypi.org/project/tinycss2/
BuildRequires: python3-build
BuildRequires: python3-flit_core >= 3.2
BuildRequires: python3-flit_core < 4
BuildRequires: python3-installer
BuildRequires: python3-modules >= 1:3.10
%if %{with tests}
BuildRequires: python3-pytest
BuildRequires: python3-pytest-cov
BuildRequires: python3-webencodings >= 0.4
%endif
%if %{with doc}
BuildRequires: python3-furo
BuildRequires: sphinx-pdg-3
%endif
BuildRequires: rpm-pythonprov
BuildRequires: rpmbuild(macros) >= 2.044
BuildRequires: sed >= 4.0
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
tinycss2 is a modern, low-level CSS parser for Python. tinycss2 is a
rewrite of tinycss with a simpler API, based on the more recent CSS
Syntax Level 3 specification.
%description -l pl.UTF-8
tinycss2 to nowoczesny, niskopoziomowy parser CSS dla Ptyhona. Jest to
napisany od początku tinycss z prostszym API, oparty na nowszej
specyfikacji CSS Syntax Level 3.
%package apidocs
Summary: API documentation for Python tinycss2 module
Summary(pl.UTF-8): Dokumentacja API modułu Pythona tinycss2
Group: Documentation
%description apidocs
API documentation for Python tinycss2 module.
%description apidocs -l pl.UTF-8
Dokumentacja API modułu Pythona tinycss2.
%prep
%setup -q -n tinycss2-%{version}
%build
%py3_build_pyproject
%if %{with tests}
PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
%{__python3} -m pytest -v
%endif
%if %{with doc}
PYTHONPATH=$(pwd) \
sphinx-build-3 -b html docs docs/build/html
%endif
%install
rm -rf $RPM_BUILD_ROOT
%py3_install_pyproject
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(644,root,root,755)
%doc LICENSE README.rst
%{py3_sitescriptdir}/tinycss2
%{py3_sitescriptdir}/tinycss2-%{version}.dist-info
%if %{with doc}
%files apidocs
%defattr(644,root,root,755)
%doc docs/build/html/{_static,*.html,*.js}
%endif