]> git.pld-linux.org Git - packages/librsvg.git/blob - librsvg.spec
- allow build without vala installed (bindings are not built here anyway)
[packages/librsvg.git] / librsvg.spec
1 #
2 # Conditional build
3 %bcond_without  apidocs         # disable gtk-doc
4 %bcond_without  gtk2            # legacy gtk+2 support
5 %bcond_without  libcroco        # build without CSS support through libcroco
6 %bcond_without  static_libs     # don't build static library
7 #
8
9 %define         ver     2.36
10 %define         pver    2
11
12 Summary:        A Raph's Library for Rendering SVG Data
13 Summary(pl.UTF-8):      Biblioteka Raph's SVG do renderowania danych SVG
14 Summary(pt_BR.UTF-8):   Biblioteca SVG
15 Summary(ru.UTF-8):      SVG библиотека
16 Summary(uk.UTF-8):      SVG бібліотека
17 Name:           librsvg
18 Version:        %{ver}.%{pver}
19 Release:        1
20 Epoch:          1
21 License:        LGPL v2+
22 Group:          X11/Libraries
23 Source0:        http://ftp.gnome.org/pub/GNOME/sources/librsvg/%{ver}/%{name}-%{version}.tar.xz
24 # Source0-md5:  8e2e7640d26322d6ab5426d27147b04e
25 Source1:        rsvg
26 URL:            http://librsvg.sourceforge.net/
27 BuildRequires:  autoconf
28 BuildRequires:  automake >= 1:1.9
29 BuildRequires:  cairo-devel >= 1.2.0
30 BuildRequires:  docbook-dtd412-xml
31 BuildRequires:  gdk-pixbuf2-devel >= 2.0
32 BuildRequires:  glib2-devel >= 1:2.24.0
33 BuildRequires:  gobject-introspection-devel >= 0.10.8
34 %{?with_gtk2:BuildRequires:     gtk+2-devel >= 2:2.16.0}
35 BuildRequires:  gtk+3-devel >= 3.0.0
36 %{?with_apidocs:BuildRequires:  gtk-doc >= 1.13}
37 %{?with_apidocs:BuildRequires:  gtk-doc-automake >= 1.13}
38 %{?with_libcroco:BuildRequires: libcroco-devel >= 0.6.1}
39 BuildRequires:  libtool >= 2:2.0
40 BuildRequires:  libxml2-devel >= 1:2.7.0
41 BuildRequires:  pango-devel >= 1:1.16.0
42 BuildRequires:  pkgconfig
43 BuildRequires:  rpm-pythonprov
44 BuildRequires:  sed >= 4.0
45 BuildRequires:  tar >= 1:1.22
46 BuildRequires:  xz
47 Requires(post,postun):  /sbin/ldconfig
48 Requires(post,postun):  gdk-pixbuf2 >= 2.0
49 Requires:       cairo >= 1.2.0
50 Requires:       gdk-pixbuf2 >= 2.0
51 Requires:       glib2 >= 1:2.24.0
52 %{?with_libcroco:Requires:      libcroco >= 0.6.1}
53 Requires:       libxml2 >= 1:2.7.0
54 Requires:       pango >= 1:1.16.0
55 Obsoletes:      browser-plugin-librsvg
56 Obsoletes:      librsvg0
57 Obsoletes:      mozilla-plugin-rsvg
58 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
59
60 # see gdk-pixbuf2.spec for source of these ifdefs
61 %if "%{_lib}" != "lib"
62 %define         libext          %(lib="%{_lib}"; echo ${lib#lib})
63 %define         pqext           -%{libext}
64 %else
65 %define         pqext           %{nil}
66 %endif
67
68 %description
69 An library to render SVG (scalable vector graphics), databased upon
70 libart.
71
72 %description -l pl.UTF-8
73 Biblioteka do renderowania SVG (skalowalnej grafiki wektorowej) oparta
74 na kodzie libart.
75
76 %description -l ru.UTF-8
77 Библиотека SVG, базирующаяся на libart.
78
79 %description -l uk.UTF-8
80 Бібліотека SVG, базована на libart.
81
82 %package devel
83 Summary:        Include files for developing with librsvg
84 Summary(pl.UTF-8):      Pliki nagłówkowe do tworzenia oprogramowania z użyciem librsvg
85 Summary(pt_BR.UTF-8):   Bibliotecas e arquivos de inclusão para desenvolvimento com a librsvg
86 Summary(ru.UTF-8):      Библиотечные линки и файлы заголовков для разработки с librsvg
87 Summary(uk.UTF-8):      Бібліотечні лінки та файли заголовків для розробки з librsvg
88 Group:          X11/Development/Libraries
89 Requires:       %{name} = %{epoch}:%{version}-%{release}
90 Requires:       cairo-devel >= 1.2.0
91 Requires:       gdk-pixbuf2-devel >= 2.0
92 Requires:       glib2-devel >= 1:2.24.0
93 Requires:       gtk+3-devel >= 3.0.0
94 %{?with_libcroco:Requires:      libcroco-devel >= 0.6.1}
95 Requires:       libxml2-devel >= 1:2.7.0
96 Requires:       pango-devel >= 1:1.16.0
97 Obsoletes:      librsvg0-devel
98
99 %description devel
100 This package provides the necessary development libraries and include
101 files to allow you to develop with librsvg.
102
103 %description devel -l pl.UTF-8
104 Pakiet zawiera pliki nagłówkowe potrzebne do tworzenia oprogramowania
105 z wykorzystaniem librsvg.
106
107 %description devel -l pt_BR.UTF-8
108 Este pacote contém os arquivos necessários para desenvolver com base
109 na biblioteca librsvg.
110
111 %description devel -l ru.UTF-8
112 Этот пакет содержит необходимые файлы для разработки программ с
113 использованием librsvg.
114
115 %description devel -l uk.UTF-8
116 Цей пакет містить необхідні файли для розробки програм з використанням
117 librsvg.
118
119 %package static
120 Summary:        Static libraries for developing with librsvg
121 Summary(es.UTF-8):      Archivos estáticos necesarios para el desarrollo de aplicaciones con librsvg
122 Summary(pl.UTF-8):      Statyczne biblioteki librsvg
123 Summary(pt_BR.UTF-8):   Arquivos estáticos necessários para o desenvolvimento de aplicações com librsvg
124 Group:          X11/Development/Libraries
125 Requires:       %{name}-devel = %{epoch}:%{version}-%{release}
126
127 %description static
128 This package contains static version of librsvg libraries.
129
130 %description static -l pl.UTF-8
131 Statyczna wersja bibliotek librsvg.
132
133 %description static -l pt_BR.UTF-8
134 Bibliotecas estáticas para o desenvolvimento de aplicações com
135 librsvg.
136
137 %package apidocs
138 Summary:        librsvg API documentation
139 Summary(pl.UTF-8):      Dokumentacja API biblioteki librsvg
140 Group:          Documentation
141 Requires:       gtk-doc-common
142
143 %description apidocs
144 librsvg API documentation.
145
146 %description apidocs -l pl.UTF-8
147 Dokumentacja API biblioteki librsvg.
148
149 %package gtk+2
150 Summary:        librsvg/GTK+2 based SVG theme engine and viewer
151 Summary(pl.UTF-8):      Silnik motywów oraz przeglądarka plików SVG oparte na bibliotekach librsvg/GTK+2
152 Group:          X11/Libraries
153 Requires:       %{name} = %{epoch}:%{version}-%{release}
154 Requires:       gtk+2 >= 2:2.16.0
155
156 %description gtk+2
157 librsvg/GTK+2 based SVG theme engine and viewer.
158
159 %description gtk+2 -l pl.UTF-8
160 Silnik motywów oraz przeglądarka plików SVG oparte na bibliotekach
161 librsvg/GTK+2.
162
163 %package gtk+3
164 Summary:        librsvg/GTK+3 based SVG theme and viewer
165 Summary(pl.UTF-8):      Motyw i przeglądarka plików SVG oparte na bibliotekach librsvg/GTK+3
166 Group:          X11/Libraries
167 Requires:       %{name} = %{epoch}:%{version}-%{release}
168 Requires:       gtk+3 >= 3.0.0
169
170 %description gtk+3
171 librsvg/GTK+3 based SVG theme and viewer.
172
173 %description gtk+3 -l pl.UTF-8
174 Motyw i przeglądarka plików SVG oparte na bibliotekach librsvg/GTK+3.
175
176 %prep
177 %setup -q
178
179 %if %{without apidocs}
180 echo 'CLEANFILES=' > gtk-doc.make
181 echo 'AC_DEFUN([GTK_DOC_CHECK],[])' >> acinclude.m4
182 %endif
183
184 # vala not ready yet here
185 echo 'AC_DEFUN([VAPIGEN_CHECK],[AM_CONDITIONAL([ENABLE_VAPIGEN], [false])])' >> acinclude.m4
186
187 %build
188 mkdir m4
189 %{?with_apidocs:%{__gtkdocize}}
190 %{__libtoolize}
191 %{__aclocal}
192 %{__autoconf}
193 %{__autoheader}
194 %{__automake}
195 %configure \
196         --disable-silent-rules \
197         %{__enable_disable static_libs static} \
198         %{__enable_disable apidocs gtk-doc} \
199         --enable-introspection \
200         %{__with_without libcroco croco} \
201         --with-html-dir=%{_gtkdocdir}/%{name}
202 %{__make}
203
204 %install
205 rm -rf $RPM_BUILD_ROOT
206
207 %{__make} install \
208         DESTDIR=$RPM_BUILD_ROOT \
209         pkgconfigdir=%{_pkgconfigdir}
210
211 %{__rm} $RPM_BUILD_ROOT%{_libdir}/gtk-2.0/2.*/engines/*.{la,a}
212 %{__rm} $RPM_BUILD_ROOT%{_libdir}/gdk-pixbuf-2.0/2.*.*/loaders/*.{la,a}
213 %{__rm} $RPM_BUILD_ROOT%{_libdir}/librsvg-2.la
214
215 %{__ln_s} rsvg-view-3 $RPM_BUILD_ROOT%{_bindir}/rsvg-view
216
217 install %{SOURCE1} $RPM_BUILD_ROOT%{_bindir}
218
219 %clean
220 rm -rf $RPM_BUILD_ROOT
221
222 %post
223 /sbin/ldconfig
224 umask 022
225 %{_bindir}/gdk-pixbuf-query-loaders%{pqext} --update-cache || :
226
227 %postun
228 /sbin/ldconfig
229 umask 022
230 if [ -x %{_bindir}/gdk-pixbuf-query-loaders%{pqext} ]; then
231         %{_bindir}/gdk-pixbuf-query-loaders%{pqext} --update-cache
232 fi
233
234 %files
235 %defattr(644,root,root,755)
236 %doc ChangeLog AUTHORS NEWS
237 %attr(755,root,root) %{_bindir}/rsvg
238 %attr(755,root,root) %{_bindir}/rsvg-convert
239 %attr(755,root,root) %{_libdir}/librsvg-2.so.*.*.*
240 %attr(755,root,root) %ghost %{_libdir}/librsvg-2.so.2
241 %{_libdir}/girepository-1.0/Rsvg-2.0.typelib
242 %attr(755,root,root) %{_libdir}/gdk-pixbuf-2.0/2.*.*/loaders/libpixbufloader-svg.so
243 %dir %{_datadir}/themes/bubble
244 %{_mandir}/man1/rsvg-convert.1*
245
246 %files devel
247 %defattr(644,root,root,755)
248 %attr(755,root,root) %{_libdir}/librsvg-2.so
249 %{_includedir}/librsvg-2.0
250 %{_datadir}/gir-1.0/Rsvg-2.0.gir
251 %{_pkgconfigdir}/librsvg-2.0.pc
252
253 %if %{with static_libs}
254 %files static
255 %defattr(644,root,root,755)
256 %{_libdir}/librsvg-2.a
257 %endif
258
259 %if %{with apidocs}
260 %files apidocs
261 %defattr(644,root,root,755)
262 %{_gtkdocdir}/%{name}
263 %endif
264
265 %if %{with gtk2}
266 %files gtk+2
267 %defattr(644,root,root,755)
268 %attr(755,root,root) %{_libdir}/gtk-2.0/2.*/engines/libsvg.so
269 %{_datadir}/themes/bubble/gtk-2.0
270 %endif
271
272 %files gtk+3
273 %defattr(644,root,root,755)
274 %attr(755,root,root) %{_bindir}/rsvg-view-3
275 %attr(755,root,root) %{_bindir}/rsvg-view
This page took 0.056523 seconds and 4 git commands to generate.