]> git.pld-linux.org Git - packages/fonttools.git/blame_incremental - fonttools.spec
- updated to 4.38.0
[packages/fonttools.git] / fonttools.spec
... / ...
CommitLineData
1#
2# Conditional build:
3%bcond_without python2 # CPython 2.x module
4%bcond_without python3 # CPython 3.x module
5%bcond_without doc # Sphinx documentation
6%bcond_without tests # pytest tests
7
8Summary: A tool to convert TrueType/OpenType fonts to XML and back
9Summary(pl.UTF-8): Narzędzie do konwersji fontów TrueType/OpenType do/z XML-a
10Name: fonttools
11Version: 3.24.1
12Release: 2
13# basic license is BSD
14# FontTools includes Adobe AGL & AGLFN, which is under 3-clauses BSD license
15License: MIT, BSD
16Group: Development/Tools
17#Source0Download: https://github.com/fonttools/fonttools/releases
18Source0: https://github.com/fonttools/fonttools/archive/%{version}/%{name}-%{version}.tar.gz
19# Source0-md5: 4e807a6b0dd9aad6fec202e73b6db7c2
20URL: https://github.com/fonttools/fonttools
21%if %(locale -a | grep -q '^C\.utf8$'; echo $?)
22BuildRequires: glibc-localedb-all
23%endif
24%if %{with python2}
25BuildRequires: python-devel >= 1:2.7
26BuildRequires: python-setuptools
27%if %{with tests}
28BuildRequires: python-pytest >= 3.0
29%endif
30%if %{with doc}
31BuildRequires: sphinx-pdg-2
32%endif
33%endif
34%if %{with python3}
35BuildRequires: python3-devel >= 1:3.4
36%if %{with tests}
37BuildRequires: python3-pytest >= 3.0
38%endif
39%endif
40BuildRequires: rpmbuild(macros) >= 1.714
41%if %{with python2}
42Requires: python-fonttools = %{version}-%{release}
43Requires: python-setuptools
44%else
45Requires: python3-fonttools = %{version}-%{release}
46Requires: python3-setuptools
47%endif
48Provides: ttx = %{version}-%{release}
49BuildArch: noarch
50BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
51
52%description
53TTX/FontTools is a tool for manipulating TrueType and OpenType fonts.
54It is written in Python and has a BSD-style, open-source license. TTX
55can dump TrueType and OpenType fonts to an XML-based text format and
56vice versa.
57
58%description -l pl.UTF-8
59TTX/FontTools to narzędzie do operacji na fontach TrueType i OpenType.
60Zostało napisane w Pythonie i ma otwartą licencję w stylu BSD. TTX
61potrafi wykonywać zrzuty fontów TrueType i OpenType do formatu
62tekstowego opartego na XML-u oraz dokonać operacji odwrotnej.
63
64%package -n python-fonttools
65Summary: Python 2 tools to manipulate font files
66Summary(pl.UTF-8): Narzędzia do manipulacji na plikach fontów dla Pythona 2
67Group: Libraries/Python
68Requires: python-modules >= 1:2.7
69Requires: python-brotli >= 1.0.1
70Requires: python-munkres >= 1.0.10
71Requires: python-unicodedata2 >= 10.0.0
72
73%description -n python-fonttools
74Python 2 tools to manipulate font files.
75
76%description -n python-fonttools -l pl.UTF-8
77Narzędzia do manipulacji na plikach fontów dla Pythona 2.
78
79%package -n python-fonttools-apidocs
80Summary: Documentation for Python fonttools module
81Summary(pl.UTF-8): Dokumentacja modułu Pythona fonttools
82Group: Documentation
83
84%description -n python-fonttools-apidocs
85Documentation for Python fonttools module.
86
87%description -n python-fonttools-apidocs -l pl.UTF-8
88Dokumentacja modułu Pythona fonttools.
89
90%package -n python3-fonttools
91Summary: Python 3 tools to manipulate font files
92Summary(pl.UTF-8): Narzędzia do manipulacji na plikach fontów dla Pythona 3
93Group: Libraries/Python
94Requires: python3-modules >= 1:3.4
95Requires: python3-brotli >= 1.0.1
96Requires: python3-munkres >= 1.0.10
97Requires: python3-unicodedata2 >= 10.0.0
98
99%description -n python3-fonttools
100Python 3 tools to manipulate font files.
101
102%description -n python3-fonttools -l pl.UTF-8
103Narzędzia do manipulacji na plikach fontów dla Pythona 3.
104
105%prep
106%setup -q
107
108%build
109export LC_ALL=C.UTF-8
110%if %{with python2}
111%py_build %{?with_tests:test}
112%if %{with doc}
113PYTHONPATH=$(pwd)/build-2/lib \
114%{__make} -C Doc html \
115 SPHINXBUILD=sphinx-build-2
116%endif
117%endif
118
119%if %{with python3}
120%py3_build %{?with_tests:test}
121%endif
122
123%install
124rm -rf $RPM_BUILD_ROOT
125
126%if %{with python3}
127%py3_install
128%endif
129
130%if %{with python2}
131%py_install
132
133%py_postclean
134%endif
135
136%clean
137rm -rf $RPM_BUILD_ROOT
138
139%files
140%defattr(644,root,root,755)
141%doc LICENSE LICENSE.external NEWS.rst README.rst
142%attr(755,root,root) %{_bindir}/fonttools
143%attr(755,root,root) %{_bindir}/pyftinspect
144%attr(755,root,root) %{_bindir}/pyftmerge
145%attr(755,root,root) %{_bindir}/pyftsubset
146%attr(755,root,root) %{_bindir}/ttx
147%{_mandir}/man1/ttx.1*
148
149%if %{with python2}
150%files -n python-fonttools
151%defattr(644,root,root,755)
152%{py_sitescriptdir}/fontTools
153%{py_sitescriptdir}/fonttools-%{version}-py*.egg-info
154
155%if %{with doc}
156%files -n python-fonttools-apidocs
157%defattr(644,root,root,755)
158%doc Doc/build/html/{_static,designspaceLib,misc,pens,ttLib,varLib,*.html,*.js}
159%endif
160%endif
161
162%if %{with python3}
163%files -n python3-fonttools
164%defattr(644,root,root,755)
165%{py3_sitescriptdir}/fontTools
166%{py3_sitescriptdir}/fonttools-%{version}-py*.egg-info
167%endif
This page took 0.06287 seconds and 4 git commands to generate.