]>
Commit | Line | Data |
---|---|---|
79fcc918 JB |
1 | # |
2 | # Conditional build: | |
9f933f96 | 3 | %bcond_without apidocs # disable gtk-doc |
dd4d1358 | 4 | %bcond_with glitz # build with glitz backend |
b2aa6d0c | 5 | %bcond_without xcb # XCB backend |
d71997d7 | 6 | %bcond_with tests # perform tests (can fail due to out of memory) |
6e13550b | 7 | %bcond_without lcd # use own LCD filtering instead of freetype's |
79fcc918 | 8 | # |
b7ccdbe1 | 9 | Summary: Cairo - multi-platform 2D graphics library |
beb0026f | 10 | Summary(pl.UTF-8): Cairo - wieloplatformowa biblioteka graficzna 2D |
8c7ef450 | 11 | Name: cairo |
24497aea | 12 | Version: 1.4.10 |
8000abd0 | 13 | Release: 1 |
9b33cbb5 | 14 | License: LGPL v2.1 or MPL v1.1 |
b7ccdbe1 | 15 | Group: Libraries |
0b5be3e0 | 16 | Source0: http://cairographics.org/releases/%{name}-%{version}.tar.gz |
24497aea | 17 | # Source0-md5: 5598a5e500ad922e37b159dee72fc993 |
c9185d93 | 18 | Patch0: %{name}-link.patch |
44c917c9 JB |
19 | # updated from http://david.freetype.org/lcd/cairo-1.2.4-lcd-filter-1.patch |
20 | Patch1: cairo-1.2.4-lcd-filter-1.patch | |
8c7ef450 | 21 | URL: http://cairographics.org/ |
79fcc918 | 22 | BuildRequires: autoconf >= 2.54 |
c9185d93 | 23 | BuildRequires: automake >= 1:1.7 |
9bc5a16c | 24 | BuildRequires: fontconfig-devel |
6e13550b | 25 | %{?with_lcd:BuildRequires: freetype-devel >= 1:2.3.0} |
26 | %{!?with_lcd:BuildRequires: freetype-devel >= 1:2.1.10} | |
2e75f7d0 | 27 | %{?with_glitz:BuildRequires: glitz-devel >= 0.5.1} |
9f933f96 | 28 | %{?with_apidocs:BuildRequires: gtk-doc >= 1.3} |
9bc5a16c | 29 | BuildRequires: libpng-devel |
b7ccdbe1 JB |
30 | BuildRequires: libtool |
31 | BuildRequires: pkgconfig | |
b2aa6d0c | 32 | %if %{with xcb} |
fe1a27be JB |
33 | BuildRequires: libxcb-devel >= 0.9.92 |
34 | BuildRequires: xcb-util-devel >= 0.2 | |
b2aa6d0c | 35 | %endif |
ddb9a7c6 | 36 | BuildRequires: xorg-lib-libXrender-devel >= 0.6 |
9bc5a16c | 37 | BuildRequires: zlib-devel |
89b0db42 JB |
38 | %{!?with_lcd:Requires: freetype >= 1:2.1.10} |
39 | %{?with_lcd:Requires: freetype >= 1:2.3.0} | |
2e75f7d0 | 40 | %{?with_glitz:Requires: glitz >= 0.5.1} |
b7ccdbe1 | 41 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
8c7ef450 | 42 | |
43 | %description | |
b7ccdbe1 JB |
44 | Cairo provides anti-aliased vector-based rendering for X. Paths |
45 | consist of line segments and cubic splines and can be rendered at any | |
46 | width with various join and cap styles. All colors may be specified | |
47 | with optional translucence (opacity/alpha) and combined using the | |
48 | extended Porter/Duff compositing algebra as found in the X Render | |
49 | Extension. | |
50 | ||
51 | Cairo exports a stateful rendering API similar in spirit to the path | |
52 | construction, text, and painting operators of PostScript, (with the | |
53 | significant addition of translucence in the imaging model). When | |
54 | complete, the API is intended to support the complete imaging model of | |
55 | PDF 1.4. | |
56 | ||
65aac246 JR |
57 | %description -l pl.UTF-8 |
58 | Cairo obsługuje oparty na wektorach rendering z antyaliasingiem dla X. | |
59 | Ścieżki składają się z odcinków i splajnów kubicznych, a renderowane | |
60 | mogą być z dowolną grubością i różnymi stylami połączeń i zakończeń. | |
61 | Wszystkie kolory mogą być podane z opcjonalną półprzezroczystością | |
62 | (podaną przez współczynnik nieprzezroczystości lub alpha) i łączone | |
63 | przy użyciu rozszerzonego algorytmu mieszania Portera-Duffa, który | |
64 | można znaleźć w rozszerzeniu X Render. | |
65 | ||
66 | Cairo eksportuje stanowe API renderujące w duchu podobne do operatorów | |
67 | konstruowania ścieżek, tekstu i rysowania z PostScriptu (ze znacznym | |
68 | dodatkiem półprzezroczystości w modelu obrazu). Kiedy API zostanie | |
69 | ukończone, ma obsługiwać pełny model obrazu z PDF w wersji 1.4. | |
70 | ||
8c7ef450 | 71 | %package devel |
b7ccdbe1 | 72 | Summary: Development files for Cairo library |
beb0026f | 73 | Summary(pl.UTF-8): Pliki programistyczne biblioteki Cairo |
4233927e | 74 | Group: Development/Libraries |
b7ccdbe1 | 75 | Requires: %{name} = %{version}-%{release} |
9bc5a16c | 76 | Requires: fontconfig-devel |
df2e7d34 | 77 | Requires: freetype-devel >= 1:2.1.10 |
2e75f7d0 | 78 | %{?with_glitz:Requires: glitz-devel >= 0.5.1} |
9bc5a16c | 79 | Requires: libpng-devel |
fe1a27be JB |
80 | %{?with_xcb:Requires: libxcb-devel >= 0.9.92} |
81 | %{?with_xcb:Requires: xcb-util-devel >= 0.2} | |
ddb9a7c6 | 82 | Requires: xorg-lib-libXrender-devel >= 0.6 |
8c7ef450 | 83 | |
84 | %description devel | |
b7ccdbe1 JB |
85 | Development files for Cairo library. |
86 | ||
65aac246 | 87 | %description devel -l pl.UTF-8 |
b7ccdbe1 | 88 | Pliki programistyczne biblioteki Cairo. |
8c7ef450 | 89 | |
90 | %package static | |
b7ccdbe1 | 91 | Summary: Static Cairo library |
beb0026f | 92 | Summary(pl.UTF-8): Statyczna biblioteka Cairo |
4233927e | 93 | Group: Development/Libraries |
b7ccdbe1 | 94 | Requires: %{name}-devel = %{version}-%{release} |
8c7ef450 | 95 | |
96 | %description static | |
b7ccdbe1 JB |
97 | Static Cairo library. |
98 | ||
65aac246 | 99 | %description static -l pl.UTF-8 |
b7ccdbe1 | 100 | Statyczna biblioteka Cairo. |
8c7ef450 | 101 | |
ecad233f | 102 | %package apidocs |
103 | Summary: Cairo API documentation | |
beb0026f | 104 | Summary(pl.UTF-8): Dokumentacja API Cairo |
ecad233f | 105 | Group: Documentation |
106 | Requires: gtk-doc-common | |
107 | ||
108 | %description apidocs | |
109 | Cairo API documentation. | |
110 | ||
65aac246 | 111 | %description apidocs -l pl.UTF-8 |
ecad233f | 112 | Dokumentacja API Cairo. |
113 | ||
8c7ef450 | 114 | %prep |
56de7934 | 115 | %setup -q |
c9185d93 | 116 | %patch0 -p1 |
6e13550b | 117 | %{?with_lcd:%patch1 -p1} |
8c7ef450 | 118 | |
119 | %build | |
2e75f7d0 | 120 | %{?with_apidocs:%{__gtkdocize}} |
b7ccdbe1 | 121 | %{__libtoolize} |
8c7ef450 | 122 | %{__aclocal} |
123 | %{__autoheader} | |
8c7ef450 | 124 | %{__autoconf} |
b7ccdbe1 | 125 | %{__automake} |
7fdf57cf | 126 | %configure \ |
9f933f96 | 127 | %{?with_apidocs:--enable-gtk-doc} \ |
79fcc918 | 128 | %{?with_xcb:--enable-xcb} \ |
dd4d1358 | 129 | %{?with_glitz:--enable-glitz} \ |
0b5be3e0 | 130 | --enable-ps \ |
131 | --enable-pdf \ | |
7fdf57cf | 132 | --with-html-dir=%{_gtkdocdir} |
8c7ef450 | 133 | %{__make} |
d71997d7 | 134 | %{?with_tests:%{__make} check} |
8c7ef450 | 135 | |
136 | %install | |
137 | rm -rf $RPM_BUILD_ROOT | |
8c7ef450 | 138 | |
139 | %{__make} install \ | |
140 | DESTDIR=$RPM_BUILD_ROOT | |
141 | ||
142 | %clean | |
143 | rm -rf $RPM_BUILD_ROOT | |
144 | ||
b7ccdbe1 JB |
145 | %post -p /sbin/ldconfig |
146 | %postun -p /sbin/ldconfig | |
8c7ef450 | 147 | |
b7ccdbe1 JB |
148 | %files |
149 | %defattr(644,root,root,755) | |
9b33cbb5 | 150 | # COPYING contains only notes, not LGPL/MPL texts |
f5c18fd7 | 151 | %doc AUTHORS COPYING ChangeLog NEWS README TODO |
b7ccdbe1 | 152 | %attr(755,root,root) %{_libdir}/lib*.so.*.*.* |
8c7ef450 | 153 | |
154 | %files devel | |
155 | %defattr(644,root,root,755) | |
b7ccdbe1 JB |
156 | %attr(755,root,root) %{_libdir}/lib*.so |
157 | %{_libdir}/lib*.la | |
8c7ef450 | 158 | %{_includedir}/* |
b7ccdbe1 JB |
159 | %{_pkgconfigdir}/*.pc |
160 | ||
161 | %files static | |
162 | %defattr(644,root,root,755) | |
163 | %{_libdir}/lib*.a | |
ecad233f | 164 | |
165 | %files apidocs | |
166 | %defattr(644,root,root,755) | |
167 | %{_gtkdocdir}/cairo |