]> git.pld-linux.org Git - packages/python-fontMath.git/blob - python-fontMath.spec
2957538f066d8717600d0d749992a0ccae09a563
[packages/python-fontMath.git] / python-fontMath.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # unit tests
4 %bcond_without  python2 # CPython 2.x module
5 %bcond_without  python3 # CPython 3.x module
6
7 Summary:        Set of objects for performing math operations on font data
8 Summary(pl.UTF-8):      Zbiór obiektów do wykonywania operacji matematycznych na danych fontów
9 Name:           python-fontMath
10 Version:        0.8.1
11 Release:        1
12 License:        MIT
13 Group:          Libraries/Python
14 #Source0Download: https://pypi.org/simple/fontmath/
15 Source0:        https://files.pythonhosted.org/packages/source/f/fontmath/fontMath-%{version}.zip
16 # Source0-md5:  86560af85a530245e456835b37994a16
17 URL:            https://pypi.org/project/fontmath/
18 %if %{with python2}
19 BuildRequires:  python-modules >= 1:2.7
20 BuildRequires:  python-setuptools
21 BuildRequires:  python-setuptools_scm
22 %if %{with tests}
23 BuildRequires:  python-fonttools >= 3.32.0
24 BuildRequires:  python-pytest >= 3.0.3
25 %endif
26 %endif
27 %if %{with python3}
28 BuildRequires:  python3-modules >= 1:3.4
29 BuildRequires:  python3-setuptools
30 BuildRequires:  python3-setuptools_scm
31 %if %{with tests}
32 BuildRequires:  python3-fonttools >= 3.32.0
33 BuildRequires:  python3-pytest >= 3.0.3
34 %endif
35 %endif
36 BuildRequires:  rpm-pythonprov
37 BuildRequires:  rpmbuild(macros) >= 1.714
38 BuildRequires:  unzip
39 Requires:       python-modules >= 1:2.7
40 BuildArch:      noarch
41 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
42
43 %description
44 A collection of objects that implement fast font, glyph, etc. math.
45
46 %description -l pl.UTF-8
47 Zbiór obiektów implementujących szybkie operacje matematyczne na
48 fontach, glifach itp.
49
50 %package -n python3-fontMath
51 Summary:        Set of objects for performing math operations on font data
52 Summary(pl.UTF-8):      Zbiór obiektów do wykonywania operacji matematycznych na danych fontów
53 Group:          Libraries/Python
54 Requires:       python3-modules >= 1:3.4
55
56 %description -n python3-fontMath
57 A collection of objects that implement fast font, glyph, etc. math.
58
59 %description -n python3-fontMath -l pl.UTF-8
60 Zbiór obiektów implementujących szybkie operacje matematyczne na
61 fontach, glifach itp.
62
63 %prep
64 %setup -q -n fontMath-%{version}
65
66 %build
67 %if %{with python2}
68 %py_build
69
70 %if %{with tests}
71 PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
72 %{__python} -m pytest Lib/fontMath
73 %endif
74 %endif
75
76 %if %{with python3}
77 %py3_build
78
79 %if %{with tests}
80 PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
81 %{__python3} -m pytest Lib/fontMath
82 %endif
83 %endif
84
85 %install
86 rm -rf $RPM_BUILD_ROOT
87
88 %if %{with python2}
89 %py_install
90
91 %{__rm} -r $RPM_BUILD_ROOT%{py_sitescriptdir}/fontMath/test
92 %py_postclean
93 %endif
94
95 %if %{with python3}
96 %py3_install
97
98 %{__rm} -r $RPM_BUILD_ROOT%{py3_sitescriptdir}/fontMath/test
99 %endif
100
101 %clean
102 rm -rf $RPM_BUILD_ROOT
103
104 %if %{with python2}
105 %files
106 %defattr(644,root,root,755)
107 %doc License.txt README.md
108 %{py_sitescriptdir}/fontMath
109 %{py_sitescriptdir}/fontMath-%{version}-py*.egg-info
110 %endif
111
112 %if %{with python3}
113 %files -n python3-fontMath
114 %defattr(644,root,root,755)
115 %doc License.txt README.md
116 %{py3_sitescriptdir}/fontMath
117 %{py3_sitescriptdir}/fontMath-%{version}-py*.egg-info
118 %endif
This page took 0.113663 seconds and 2 git commands to generate.