]> git.pld-linux.org Git - packages/cairo.git/blame - cairo.spec
drop "ps" bcond
[packages/cairo.git] / cairo.spec
CommitLineData
79fcc918
JB
1#
2# Conditional build:
9f933f96 3%bcond_without apidocs # disable gtk-doc
555786d4 4%bcond_without pdf # PDF surface backend
170c8276 5%bcond_without svg # SVG surface backend
75cc31b6 6%bcond_without xcb # XCB backend
75cc31b6 7%bcond_with tests # perform tests (can fail due to out of memory)
052e014b 8
b7ccdbe1 9Summary: Cairo - multi-platform 2D graphics library
beb0026f 10Summary(pl.UTF-8): Cairo - wieloplatformowa biblioteka graficzna 2D
8c7ef450 11Name: cairo
170c8276
JB
12Version: 1.18.0
13Release: 1
9b33cbb5 14License: LGPL v2.1 or MPL v1.1
b7ccdbe1 15Group: Libraries
f965b14a 16Source0: https://www.cairographics.org/releases/%{name}-%{version}.tar.xz
170c8276 17# Source0-md5: 3f0685fbadc530606f965b9645bb51d9
f965b14a 18URL: https://www.cairographics.org/
fde28cff 19BuildRequires: binutils-devel
3396a3ae 20BuildRequires: fontconfig-devel >= 2.2.95
170c8276
JB
21%if %{with tests}
22# ttx
23BuildRequires: fonttools
24%endif
25# pkgconfig(freetype2) >= 25.0.19
26BuildRequires: freetype-devel >= 1:2.13.0
acd7ce6e 27BuildRequires: glib2-devel >= 1:2.14
ba356974 28BuildRequires: gtk+2-devel >= 1:2.0
543a7c78 29%{?with_apidocs:BuildRequires: gtk-doc >= 1.15}
42ecc17e 30BuildRequires: libpng-devel >= 2:1.4.0
555786d4 31%if %{with svg} && %{with tests}
7932577f 32BuildRequires: librsvg-devel >= 2.35.0
555786d4 33%endif
fd24878b 34%if %{with tests}
3396a3ae 35BuildRequires: libspectre-devel >= 0.2.0
555786d4 36%endif
543a7c78 37%{?with_xcb:BuildRequires: libxcb-devel >= 1.6}
7932577f 38BuildRequires: lzo-devel >= 2
170c8276
JB
39BuildRequires: meson >= 0.59.0
40BuildRequires: ninja >= 1.5
41BuildRequires: pixman-devel >= 0.36.0
5a53c090 42BuildRequires: pkgconfig >= 1:0.18
555786d4
JB
43%if %{with pdf} && %{with tests}
44BuildRequires: poppler-glib-devel >= 0.17.4
45%endif
68f80d0c 46BuildRequires: rpm >= 4.4.9-56
170c8276 47BuildRequires: rpmbuild(macros) >= 1.736
0c4a4f34 48BuildRequires: sed >= 4.0
543a7c78 49BuildRequires: tar >= 1:1.22
3396a3ae 50BuildRequires: xorg-lib-libX11-devel%{?with_xcb: >= 1.1}
555786d4 51BuildRequires: xorg-lib-libXext-devel
ddb9a7c6 52BuildRequires: xorg-lib-libXrender-devel >= 0.6
543a7c78 53BuildRequires: xz
9bc5a16c 54BuildRequires: zlib-devel
555786d4 55Requires: fontconfig-libs >= 2.2.95
170c8276 56Requires: freetype >= 1:2.13.0
fde28cff 57%{?with_xcb:Requires: libxcb >= 1.6}
170c8276 58Requires: pixman >= 0.36.0
b7ccdbe1 59BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
8c7ef450 60
61%description
76666767 62Cairo provides anti-aliased vector-based rendering for X. Paths
b7ccdbe1
JB
63consist of line segments and cubic splines and can be rendered at any
64width with various join and cap styles. All colors may be specified
65with optional translucence (opacity/alpha) and combined using the
66extended Porter/Duff compositing algebra as found in the X Render
67Extension.
68
69Cairo exports a stateful rendering API similar in spirit to the path
70construction, text, and painting operators of PostScript, (with the
71significant addition of translucence in the imaging model). When
72complete, the API is intended to support the complete imaging model of
73PDF 1.4.
74
65aac246
JR
75%description -l pl.UTF-8
76Cairo obsługuje oparty na wektorach rendering z antyaliasingiem dla X.
77Ścieżki składają się z odcinków i splajnów kubicznych, a renderowane
78mogą być z dowolną grubością i różnymi stylami połączeń i zakończeń.
79Wszystkie kolory mogą być podane z opcjonalną półprzezroczystością
80(podaną przez współczynnik nieprzezroczystości lub alpha) i łączone
9c95588d 81przy użyciu rozszerzonego algorytmu składania Portera-Duffa, który
65aac246
JR
82można znaleźć w rozszerzeniu X Render.
83
84Cairo eksportuje stanowe API renderujące w duchu podobne do operatorów
85konstruowania ścieżek, tekstu i rysowania z PostScriptu (ze znacznym
86dodatkiem półprzezroczystości w modelu obrazu). Kiedy API zostanie
87ukończone, ma obsługiwać pełny model obrazu z PDF w wersji 1.4.
88
8c7ef450 89%package devel
b7ccdbe1 90Summary: Development files for Cairo library
beb0026f 91Summary(pl.UTF-8): Pliki programistyczne biblioteki Cairo
4233927e 92Group: Development/Libraries
b7ccdbe1 93Requires: %{name} = %{version}-%{release}
3396a3ae 94Requires: fontconfig-devel >= 2.2.95
170c8276 95Requires: freetype-devel >= 1:2.13.0
42ecc17e 96Requires: libpng-devel >= 2:1.4.0
fde28cff 97%{?with_xcb:Requires: libxcb-devel >= 1.6}
737c5d82 98Requires: lzo-devel >= 2
170c8276 99Requires: pixman-devel >= 0.36.0
3396a3ae 100Requires: xorg-lib-libX11-devel%{?with_xcb: >= 1.1}
555786d4 101Requires: xorg-lib-libXext-devel
ddb9a7c6 102Requires: xorg-lib-libXrender-devel >= 0.6
555786d4 103Requires: zlib-devel
8c7ef450 104
105%description devel
b7ccdbe1
JB
106Development files for Cairo library.
107
65aac246 108%description devel -l pl.UTF-8
b7ccdbe1 109Pliki programistyczne biblioteki Cairo.
8c7ef450 110
111%package static
b7ccdbe1 112Summary: Static Cairo library
beb0026f 113Summary(pl.UTF-8): Statyczna biblioteka Cairo
4233927e 114Group: Development/Libraries
b7ccdbe1 115Requires: %{name}-devel = %{version}-%{release}
8c7ef450 116
117%description static
b7ccdbe1
JB
118Static Cairo library.
119
65aac246 120%description static -l pl.UTF-8
b7ccdbe1 121Statyczna biblioteka Cairo.
8c7ef450 122
8f628762
JB
123%package gobject
124Summary: GObject functions library for Cairo graphics library
125Summary(pl.UTF-8): Biblioteka funkcji GObject dla biblioteki graficznej Cairo
126Group: Libraries
127Requires: %{name} = %{version}-%{release}
7932577f 128Requires: glib2 >= 1:2.14
8f628762
JB
129
130%description gobject
131GObject functions library for Cairo graphics library.
132
133%description gobject -l pl.UTF-8
134Biblioteka funkcji GObject dla biblioteki graficznej Cairo.
135
136%package gobject-devel
137Summary: Header files for Cairo GObject library
138Summary(pl.UTF-8): Pliki nagłówkowe biblioteki Cairo GObject
139Group: Development/Libraries
140Requires: %{name}-devel = %{version}-%{release}
141Requires: %{name}-gobject = %{version}-%{release}
acd7ce6e 142Requires: glib2-devel >= 1:2.14
8f628762
JB
143
144%description gobject-devel
145Header files for Cairo GObject library.
146
147%description gobject-devel -l pl.UTF-8
148Pliki nagłówkowe biblioteki Cairo GObject.
149
150%package gobject-static
151Summary: Static Cairo GObject library
152Summary(pl.UTF-8): Statyczna biblioteka Cairo GObject
153Group: Development/Libraries
154Requires: %{name}-gobject-devel = %{version}-%{release}
155
156%description gobject-static
157Static Cairo GObject library.
158
159%description gobject-static -l pl.UTF-8
160Statyczna biblioteka Cairo GObject.
161
162%package trace
fde28cff
JB
163Summary: Cairo calls tracing utilities
164Summary(pl.UTF-8): Narzędzia do śledzenia wywołań Cairo
8f628762
JB
165Group: Development/Tools
166Requires: %{name} = %{version}-%{release}
c0a654a7 167Requires: binutils-libs >= 2.21.53
8f628762
JB
168
169%description trace
fde28cff 170Cairo calls tracing utilities.
8f628762
JB
171
172%description trace -l pl.UTF-8
fde28cff 173Narzędzia do śledzenia wywołań Cairo.
8f628762 174
ecad233f 175%package apidocs
176Summary: Cairo API documentation
beb0026f 177Summary(pl.UTF-8): Dokumentacja API Cairo
ecad233f 178Group: Documentation
179Requires: gtk-doc-common
052e014b 180BuildArch: noarch
ecad233f 181
182%description apidocs
183Cairo API documentation.
184
65aac246 185%description apidocs -l pl.UTF-8
d55df9d3 186Dokumentacja API Cairo.
ecad233f 187
8c7ef450 188%prep
56de7934 189%setup -q
8c7ef450 190
170c8276
JB
191#%if %{without tests}
192#%{__sed} -i -e '/SUBDIRS += boilerplate test perf/d' Makefile.am
193#%endif
5028e0d5 194
8c7ef450 195%build
170c8276
JB
196%meson build \
197 -Dfontconfig=enabled \
198 -Dfreetype=enabled \
199 -Dgtk2-utils=enabled \
200 -Dgtk_doc=%{__true_false apidocs} \
201 -Dpng=enabled \
fd24878b 202 -Dspectre=%{__enabled_disabled tests} \
170c8276
JB
203 -Dtee=enabled \
204 -Dtests=disabled \
205 -Dxcb=%{__enabled_disabled xcb} \
206 -Dxlib=enabled \
207 -Dzlib=enabled
208
209%ninja_build -C build
210
211%{?with_tests:%ninja_test -C build}
8c7ef450 212
213%install
214rm -rf $RPM_BUILD_ROOT
8c7ef450 215
170c8276 216%ninja_install -C build
8c7ef450 217
8f628762 218# LD_PRELOADable library
170c8276 219%{__rm} $RPM_BUILD_ROOT%{_libdir}/cairo/libcairo-{fdr,trace}.a
8452c411 220
8c7ef450 221%clean
222rm -rf $RPM_BUILD_ROOT
223
b7ccdbe1
JB
224%post -p /sbin/ldconfig
225%postun -p /sbin/ldconfig
8c7ef450 226
8f628762
JB
227%post gobject -p /sbin/ldconfig
228%postun gobject -p /sbin/ldconfig
229
b7ccdbe1
JB
230%files
231%defattr(644,root,root,755)
9b33cbb5 232# COPYING contains only notes, not LGPL/MPL texts
170c8276 233%doc AUTHORS BUGS COPYING NEWS README.md
daa7aa2f
JB
234%attr(755,root,root) %{_libdir}/libcairo.so.*.*.*
235%attr(755,root,root) %ghost %{_libdir}/libcairo.so.2
1fb61c53
PZ
236%attr(755,root,root) %{_libdir}/libcairo-script-interpreter.so.*.*.*
237%attr(755,root,root) %ghost %{_libdir}/libcairo-script-interpreter.so.2
8c7ef450 238
239%files devel
240%defattr(644,root,root,755)
daa7aa2f 241%attr(755,root,root) %{_libdir}/libcairo.so
1fb61c53 242%attr(755,root,root) %{_libdir}/libcairo-script-interpreter.so
daa7aa2f 243%{_includedir}/cairo
8f628762 244%exclude %{_includedir}/cairo/cairo-gobject.h
daa7aa2f 245%{_pkgconfigdir}/cairo.pc
1fb61c53 246%{_pkgconfigdir}/cairo-fc.pc
daa7aa2f 247%{_pkgconfigdir}/cairo-ft.pc
555786d4 248%{?with_pdf:%{_pkgconfigdir}/cairo-pdf.pc}
daa7aa2f 249%{_pkgconfigdir}/cairo-png.pc
fd24878b 250%{_pkgconfigdir}/cairo-ps.pc
fde28cff 251%{_pkgconfigdir}/cairo-script.pc
170c8276 252%{_pkgconfigdir}/cairo-script-interpreter.pc
0ecd672c 253%{?with_svg:%{_pkgconfigdir}/cairo-svg.pc}
e9726ad7 254%{_pkgconfigdir}/cairo-tee.pc
8452c411 255%{?with_xcb:%{_pkgconfigdir}/cairo-xcb.pc}
1fb61c53 256%{?with_xcb:%{_pkgconfigdir}/cairo-xcb-shm.pc}
daa7aa2f
JB
257%{_pkgconfigdir}/cairo-xlib.pc
258%{_pkgconfigdir}/cairo-xlib-xrender.pc
b7ccdbe1
JB
259
260%files static
261%defattr(644,root,root,755)
daa7aa2f 262%{_libdir}/libcairo.a
1fb61c53 263%{_libdir}/libcairo-script-interpreter.a
ecad233f 264
8f628762
JB
265%files gobject
266%defattr(644,root,root,755)
267%attr(755,root,root) %{_libdir}/libcairo-gobject.so.*.*.*
268%attr(755,root,root) %ghost %{_libdir}/libcairo-gobject.so.2
269
270%files gobject-devel
271%defattr(644,root,root,755)
272%attr(755,root,root) %{_libdir}/libcairo-gobject.so
8f628762
JB
273%{_includedir}/cairo/cairo-gobject.h
274%{_pkgconfigdir}/cairo-gobject.pc
275
276%files gobject-static
277%defattr(644,root,root,755)
278%{_libdir}/libcairo-gobject.a
279
280%files trace
281%defattr(644,root,root,755)
282%attr(755,root,root) %{_bindir}/cairo-trace
283%dir %{_libdir}/cairo
170c8276 284%attr(755,root,root) %{_libdir}/cairo/libcairo-fdr.so
8f628762
JB
285%attr(755,root,root) %{_libdir}/cairo/libcairo-trace.so*
286
8452c411 287%if %{with apidocs}
ecad233f 288%files apidocs
289%defattr(644,root,root,755)
290%{_gtkdocdir}/cairo
8452c411 291%endif
This page took 0.259606 seconds and 4 git commands to generate.