]>
Commit | Line | Data |
---|---|---|
578a8396 | 1 | # |
fc18e843 | 2 | # Conditional build |
165436e0 | 3 | %bcond_without apidocs # disable gtk-doc |
3f3d0e1a | 4 | %bcond_without static_libs # don't build static library |
775f4438 | 5 | %bcond_without vala # Vala API (vala up to 0.38.x already contains librsvg-2.0.vapi) |
c2e97a8f | 6 | |
f20df4f5 | 7 | %define mver 2.46 |
3ecde336 | 8 | %define pver 3 |
b05ca4c9 | 9 | Summary: A Raph's Library for Rendering SVG Data |
a0a0a705 ER |
10 | Summary(pl.UTF-8): Biblioteka Raph's SVG do renderowania danych SVG |
11 | Summary(pt_BR.UTF-8): Biblioteca SVG | |
12 | Summary(ru.UTF-8): SVG библиотека | |
13 | Summary(uk.UTF-8): SVG бібліотека | |
2d89ab37 | 14 | Name: librsvg |
41efbe2b | 15 | Version: %{mver}.%{pver} |
600e799f | 16 | Release: 1 |
cfb03eca | 17 | Epoch: 1 |
3e8d876b | 18 | License: LGPL v2+ |
adb8dade | 19 | Group: X11/Libraries |
41efbe2b | 20 | Source0: http://ftp.gnome.org/pub/GNOME/sources/librsvg/%{mver}/%{name}-%{version}.tar.xz |
3ecde336 | 21 | # Source0-md5: 4fb6d55e13b3faf008a0d8a837e64233 |
c2e97a8f | 22 | Source1: rsvg |
daf1fb3b | 23 | Patch0: x32.patch |
f20df4f5 | 24 | Patch1: %{name}-gtkdoc.patch |
5e6c47d1 | 25 | URL: http://librsvg.sourceforge.net/ |
5bf5690c | 26 | BuildRequires: autoconf >= 2.50 |
9e46e2bc | 27 | BuildRequires: automake >= 1:1.9 |
f20df4f5 JB |
28 | BuildRequires: cairo-devel >= 1.16.0 |
29 | BuildRequires: cairo-gobject-devel >= 1.16.0 | |
fc65f7f1 | 30 | BuildRequires: cargo |
f20df4f5 JB |
31 | BuildRequires: docbook-dtd43-xml |
32 | BuildRequires: fontconfig-devel | |
fc65f7f1 JB |
33 | # pkgconfig(freetype) >= 20.0.14 |
34 | BuildRequires: freetype-devel >= 1:2.8 | |
41efbe2b | 35 | BuildRequires: gdk-pixbuf2-devel >= 2.20 |
f20df4f5 | 36 | BuildRequires: gettext-tools >= 0.19.8 |
fc65f7f1 | 37 | BuildRequires: glib2-devel >= 1:2.48.0 |
17f42d6a | 38 | BuildRequires: gobject-introspection-devel >= 0.10.8 |
9e46e2bc | 39 | %{?with_apidocs:BuildRequires: gtk-doc >= 1.13} |
60409033 | 40 | %{?with_apidocs:BuildRequires: gtk-doc-automake >= 1.13} |
274a8440 | 41 | BuildRequires: libcroco-devel >= 0.6.1 |
17f42d6a | 42 | BuildRequires: libtool >= 2:2.0 |
6a2651b7 JB |
43 | BuildRequires: libxml2-devel >= 1:2.9.0 |
44 | BuildRequires: pango-devel >= 1:1.38.0 | |
c4caf50c | 45 | BuildRequires: pkgconfig |
836d8cf1 | 46 | BuildRequires: rpm-pythonprov |
f20df4f5 | 47 | BuildRequires: rust >= 1.34 |
7d99b20d | 48 | BuildRequires: sed >= 4.0 |
2628f610 | 49 | BuildRequires: tar >= 1:1.22 |
5bf5690c | 50 | %{?with_vala:BuildRequires: vala >= 2:0.18} |
2628f610 | 51 | BuildRequires: xz |
1723e4f4 | 52 | Requires(post,postun): /sbin/ldconfig |
f20df4f5 | 53 | Requires: cairo-gobject >= 1.16.0 |
fc65f7f1 | 54 | Requires: freetype >= 1:2.8 |
41efbe2b | 55 | Requires: gdk-pixbuf2 >= 2.20 |
fc65f7f1 | 56 | Requires: glib2 >= 1:2.48.0 |
274a8440 | 57 | Requires: libcroco >= 0.6.1 |
6a2651b7 JB |
58 | Requires: libxml2 >= 1:2.9.0 |
59 | Requires: pango >= 1:1.38.0 | |
6681b37f | 60 | Obsoletes: browser-plugin-librsvg |
41efbe2b | 61 | Obsoletes: librsvg-gtk+2 |
f20df4f5 | 62 | Obsoletes: librsvg-gtk+3 |
29233d8a | 63 | Obsoletes: librsvg0 |
7fc8862e | 64 | Obsoletes: mozilla-plugin-rsvg |
2c6dfdc7 | 65 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
2d89ab37 | 66 | |
d2f85f61 | 67 | # see gdk-pixbuf2.spec for source of these ifdefs |
cc871572 AM |
68 | %if "%{_lib}" != "lib" |
69 | %define libext %(lib="%{_lib}"; echo ${lib#lib}) | |
cc871572 AM |
70 | %define pqext -%{libext} |
71 | %else | |
cc871572 AM |
72 | %define pqext %{nil} |
73 | %endif | |
74 | ||
cc99da29 | 75 | %description |
11e37f78 JB |
76 | An library to render SVG (scalable vector graphics), databased upon |
77 | libart. | |
cc99da29 | 78 | |
1ad972be | 79 | %description -l pl.UTF-8 |
27f39052 JB |
80 | Biblioteka do renderowania SVG (skalowalnej grafiki wektorowej) oparta |
81 | na kodzie libart. | |
080ab56a | 82 | |
1ad972be JR |
83 | %description -l ru.UTF-8 |
84 | Библиотека SVG, базирующаяся на libart. | |
a3344f74 | 85 | |
1ad972be JR |
86 | %description -l uk.UTF-8 |
87 | Бібліотека SVG, базована на libart. | |
a3344f74 | 88 | |
cc99da29 | 89 | %package devel |
0780b304 | 90 | Summary: Include files for developing with librsvg |
a0a0a705 ER |
91 | Summary(pl.UTF-8): Pliki nagłówkowe do tworzenia oprogramowania z użyciem librsvg |
92 | Summary(pt_BR.UTF-8): Bibliotecas e arquivos de inclusão para desenvolvimento com a librsvg | |
93 | Summary(ru.UTF-8): Библиотечные линки и файлы заголовков для разработки с librsvg | |
94 | Summary(uk.UTF-8): Бібліотечні лінки та файли заголовків для розробки з librsvg | |
adb8dade | 95 | Group: X11/Development/Libraries |
cfb03eca | 96 | Requires: %{name} = %{epoch}:%{version}-%{release} |
f20df4f5 | 97 | Requires: cairo-gobject-devel >= 1.16.0 |
fc65f7f1 | 98 | Requires: freetype-devel >= 1:2.8 |
41efbe2b | 99 | Requires: gdk-pixbuf2-devel >= 2.20 |
fc65f7f1 | 100 | Requires: glib2-devel >= 1:2.48.0 |
274a8440 | 101 | Requires: libcroco-devel >= 0.6.1 |
6a2651b7 JB |
102 | Requires: libxml2-devel >= 1:2.9.0 |
103 | Requires: pango-devel >= 1:1.38.0 | |
080ab56a | 104 | Obsoletes: librsvg0-devel |
cc99da29 KT |
105 | |
106 | %description devel | |
d4c0a792 MM |
107 | This package provides the necessary development libraries and include |
108 | files to allow you to develop with librsvg. | |
e03e3432 | 109 | |
1ad972be JR |
110 | %description devel -l pl.UTF-8 |
111 | Pakiet zawiera pliki nagłówkowe potrzebne do tworzenia oprogramowania | |
0780b304 | 112 | z wykorzystaniem librsvg. |
cc99da29 | 113 | |
1ad972be JR |
114 | %description devel -l pt_BR.UTF-8 |
115 | Este pacote contém os arquivos necessários para desenvolver com base | |
080ab56a | 116 | na biblioteca librsvg. |
117 | ||
1ad972be JR |
118 | %description devel -l ru.UTF-8 |
119 | Этот пакет содержит необходимые файлы для разработки программ с | |
120 | использованием librsvg. | |
a3344f74 | 121 | |
1ad972be JR |
122 | %description devel -l uk.UTF-8 |
123 | Цей пакет містить необхідні файли для розробки програм з використанням | |
a3344f74 | 124 | librsvg. |
125 | ||
944586bf | 126 | %package static |
0780b304 | 127 | Summary: Static libraries for developing with librsvg |
a0a0a705 ER |
128 | Summary(es.UTF-8): Archivos estáticos necesarios para el desarrollo de aplicaciones con librsvg |
129 | Summary(pl.UTF-8): Statyczne biblioteki librsvg | |
130 | Summary(pt_BR.UTF-8): Arquivos estáticos necessários para o desenvolvimento de aplicações com librsvg | |
adb8dade | 131 | Group: X11/Development/Libraries |
cfb03eca | 132 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
944586bf PG |
133 | |
134 | %description static | |
0780b304 | 135 | This package contains static version of librsvg libraries. |
944586bf | 136 | |
1ad972be | 137 | %description static -l pl.UTF-8 |
0780b304 | 138 | Statyczna wersja bibliotek librsvg. |
944586bf | 139 | |
1ad972be JR |
140 | %description static -l pt_BR.UTF-8 |
141 | Bibliotecas estáticas para o desenvolvimento de aplicações com | |
080ab56a | 142 | librsvg. |
143 | ||
4983a7a9 MB |
144 | %package apidocs |
145 | Summary: librsvg API documentation | |
146 | Summary(pl.UTF-8): Dokumentacja API biblioteki librsvg | |
147 | Group: Documentation | |
148 | Requires: gtk-doc-common | |
3e59e9a7 ER |
149 | %if "%{_rpmversion}" >= "5" |
150 | BuildArch: noarch | |
151 | %endif | |
4983a7a9 MB |
152 | |
153 | %description apidocs | |
154 | librsvg API documentation. | |
155 | ||
156 | %description apidocs -l pl.UTF-8 | |
157 | Dokumentacja API biblioteki librsvg. | |
158 | ||
5bf5690c JB |
159 | %package -n vala-librsvg |
160 | Summary: Vala API for librsvg library | |
161 | Summary(pl.UTF-8): API języka Vala do biblioteki librsvg | |
162 | Group: Development/Libraries | |
194cbae9 | 163 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
fc65f7f1 | 164 | Requires: vala >= 2:0.40 |
5bf5690c JB |
165 | |
166 | %description -n vala-librsvg | |
167 | Vala API for librsvg library. | |
168 | ||
169 | %description -n vala-librsvg -l pl.UTF-8 | |
170 | API języka Vala do biblioteki librsvg. | |
171 | ||
cc99da29 | 172 | %prep |
e4690d22 | 173 | %setup -q |
daf1fb3b | 174 | %patch0 -p1 |
1e016fce | 175 | %patch1 -p1 |
d0d37948 | 176 | |
17f42d6a | 177 | %if %{without apidocs} |
3f3d0e1a KK |
178 | echo 'CLEANFILES=' > gtk-doc.make |
179 | echo 'AC_DEFUN([GTK_DOC_CHECK],[])' >> acinclude.m4 | |
180 | %endif | |
181 | ||
cc99da29 | 182 | %build |
934cfd64 | 183 | %{?with_apidocs:%{__gtkdocize}} |
094e0ffa | 184 | %{__libtoolize} |
1e016fce | 185 | %{__aclocal} -I m4 |
094e0ffa | 186 | %{__autoconf} |
adb8dade | 187 | %{__autoheader} |
094e0ffa | 188 | %{__automake} |
d4f197ce | 189 | %configure \ |
ff22cf0f | 190 | %{__enable_disable apidocs gtk-doc} \ |
cfdffb08 | 191 | --enable-introspection \ |
5bf5690c JB |
192 | --disable-silent-rules \ |
193 | %{__enable_disable static_libs static} \ | |
194 | %{?with_vala:--enable-vala} \ | |
cfb03eca | 195 | --with-html-dir=%{_gtkdocdir}/%{name} |
c4caf50c | 196 | %{__make} |
197 | ||
cc99da29 | 198 | %install |
2d89ab37 | 199 | rm -rf $RPM_BUILD_ROOT |
2aca8b1a | 200 | |
d4c0a792 MM |
201 | %{__make} install \ |
202 | DESTDIR=$RPM_BUILD_ROOT \ | |
cfb03eca | 203 | pkgconfigdir=%{_pkgconfigdir} |
2aca8b1a | 204 | |
b4109bb7 | 205 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/gdk-pixbuf-2.0/2.*.*/loaders/*.{la,a} |
47b8d8a4 | 206 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/librsvg-2.la |
9cf84f83 | 207 | |
e64a7c86 | 208 | cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_bindir} |
c2e97a8f | 209 | |
f20df4f5 JB |
210 | %find_lang %{name} |
211 | ||
2aca8b1a PG |
212 | %clean |
213 | rm -rf $RPM_BUILD_ROOT | |
214 | ||
3974ae74 | 215 | %post |
216 | /sbin/ldconfig | |
f9f85140 | 217 | umask 022 |
47b8d8a4 | 218 | %{_bindir}/gdk-pixbuf-query-loaders%{pqext} --update-cache || : |
3974ae74 | 219 | |
220 | %postun | |
221 | /sbin/ldconfig | |
f9f85140 | 222 | umask 022 |
3f3d0e1a | 223 | if [ -x %{_bindir}/gdk-pixbuf-query-loaders%{pqext} ]; then |
9e46e2bc | 224 | %{_bindir}/gdk-pixbuf-query-loaders%{pqext} --update-cache |
3f3d0e1a | 225 | fi |
094e0ffa | 226 | |
f20df4f5 | 227 | %files -f %{name}.lang |
2d89ab37 | 228 | %defattr(644,root,root,755) |
775f4438 | 229 | %doc AUTHORS NEWS |
adb8dade PZ |
230 | %attr(755,root,root) %{_bindir}/rsvg |
231 | %attr(755,root,root) %{_bindir}/rsvg-convert | |
edb6ae5a | 232 | %attr(755,root,root) %{_libdir}/librsvg-2.so.*.*.* |
2a1baa24 | 233 | %attr(755,root,root) %ghost %{_libdir}/librsvg-2.so.2 |
cfdffb08 | 234 | %{_libdir}/girepository-1.0/Rsvg-2.0.typelib |
d2f85f61 | 235 | %attr(755,root,root) %{_libdir}/gdk-pixbuf-2.0/2.*.*/loaders/libpixbufloader-svg.so |
0adb73af | 236 | %{_datadir}/thumbnailers/librsvg.thumbnailer |
725978de | 237 | %{_mandir}/man1/rsvg-convert.1* |
cc99da29 KT |
238 | |
239 | %files devel | |
2d89ab37 | 240 | %defattr(644,root,root,755) |
edb6ae5a | 241 | %attr(755,root,root) %{_libdir}/librsvg-2.so |
9e46e2bc | 242 | %{_includedir}/librsvg-2.0 |
cfdffb08 | 243 | %{_datadir}/gir-1.0/Rsvg-2.0.gir |
d2f85f61 | 244 | %{_pkgconfigdir}/librsvg-2.0.pc |
944586bf | 245 | |
3f3d0e1a | 246 | %if %{with static_libs} |
944586bf PG |
247 | %files static |
248 | %defattr(644,root,root,755) | |
edb6ae5a | 249 | %{_libdir}/librsvg-2.a |
3f3d0e1a | 250 | %endif |
4983a7a9 MB |
251 | |
252 | %if %{with apidocs} | |
253 | %files apidocs | |
254 | %defattr(644,root,root,755) | |
255 | %{_gtkdocdir}/%{name} | |
256 | %endif | |
d2f85f61 | 257 | |
5bf5690c JB |
258 | %if %{with vala} |
259 | %files -n vala-librsvg | |
260 | %defattr(644,root,root,755) | |
261 | %{_datadir}/vala/vapi/librsvg-2.0.vapi | |
262 | %endif |