]> git.pld-linux.org Git - packages/spice-gtk.git/blob - spice-gtk.spec
- release 2 (by relup.sh)
[packages/spice-gtk.git] / spice-gtk.spec
1 #
2 # Conditional build:
3 %bcond_without  gtk2            # GTK+ 2 interfaces
4 %bcond_without  gtk3            # GTK+ 3 interfaces
5 %bcond_without  smartcard       # Smartcard support
6 %bcond_without  usbredir        # USB redirection
7 #
8 Summary:        A GTK+ client and libraries for SPICE remote desktop servers
9 Summary(pl.UTF-8):      Klient i biblioteki GTK+ dla serwerów zdalnych pulpitów SPICE
10 Name:           spice-gtk
11 Version:        0.14
12 Release:        2
13 License:        LGPL v2.1+
14 Group:          X11/Applications
15 Source0:        http://spice-space.org/download/gtk/%{name}-%{version}.tar.bz2
16 # Source0-md5:  c105e3b7f9c9eb293b0d6a8d35f6a5fd
17 Patch0:         %{name}-sh.patch
18 Patch1:         %{name}-builddir.patch
19 Patch2:         %{name}-usbredir.patch
20 URL:            http://spice-space.org/
21 BuildRequires:  autoconf >= 2.57
22 BuildRequires:  automake >= 1.6
23 BuildRequires:  cairo-devel >= 1.2.0
24 BuildRequires:  celt051-devel >= 0.5.1.1
25 BuildRequires:  cyrus-sasl-devel >= 2.0
26 BuildRequires:  gcc >= 5:3.0
27 BuildRequires:  gettext-devel >= 0.17
28 BuildRequires:  gobject-introspection-devel >= 0.9.4
29 BuildRequires:  glib2-devel >= 1:2.22
30 BuildRequires:  gtk-doc >= 1.14
31 %{?with_gtk2:BuildRequires:     gtk+2-devel >= 2:2.18.0}
32 %{?with_gtk3:BuildRequires:     gtk+3-devel >= 3.0}
33 BuildRequires:  intltool >= 0.40.0
34 %{?with_smartcard:BuildRequires:        libcacard-devel >= 0.1.2}
35 BuildRequires:  libjpeg-devel
36 BuildRequires:  libstdc++-devel
37 BuildRequires:  libtool >= 2:2.0
38 BuildRequires:  openssl-devel
39 BuildRequires:  perl-Text-CSV
40 BuildRequires:  perl-base >= 1:5.8.1
41 BuildRequires:  pixman-devel >= 0.17.7
42 BuildRequires:  pkgconfig
43 BuildRequires:  pulseaudio-devel
44 BuildRequires:  sed >= 4.0
45 BuildRequires:  spice-protocol >= 0.10.1
46 BuildRequires:  xorg-lib-libX11-devel
47 BuildRequires:  xorg-lib-libXrandr-devel
48 BuildRequires:  zlib-devel
49 %if %{with gtk2}
50 BuildRequires:  gtk+2-devel >= 2:2.18.0
51 BuildRequires:  python-devel >= 2.0
52 BuildRequires:  python-pygtk-devel >= 2:2.0.0
53 %endif
54 %if %{with usbredir}
55 BuildRequires:  acl-devel
56 BuildRequires:  libusb-devel >= 1.0.9
57 BuildRequires:  polkit-devel >= 0.96
58 BuildRequires:  udev-glib-devel
59 BuildRequires:  usbredir-devel >= 0.5.2
60 %endif
61 %{?with_smartcard:Requires:     libcacard >= 0.1.2}
62 Requires:       spice-glib = %{version}-%{release}
63 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
64
65 %description
66 A GTK+ client and libraries for SPICE remote desktop servers.
67
68 %description -l pl.UTF-8
69 Klient i biblioteki GTK+ dla serwerów zdalnych pulpitów SPICE.
70
71 %package devel
72 Summary:        Header files for SPICE GTK 3.0 client library
73 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki klienckiej SPICE GTK 3.0
74 Group:          X11/Development/Libraries
75 Requires:       %{name} = %{version}-%{release}
76 Requires:       spice-glib-devel = %{version}-%{release}
77 Requires:       gtk+3-devel >= 3.0
78
79 %description devel
80 Header files for SPICE GTK 3.0 client library.
81
82 %description devel -l pl.UTF-8
83 Pliki nagłówkowe biblioteki klienckiej SPICE GTK 3.0.
84
85 %package static
86 Summary:        Static SPICE GTK 3.0 client library
87 Summary(pl.UTF-8):      Statyczna biblioteka kliencka SPICE GTK 3.0
88 Group:          X11/Development/Libraries
89 Requires:       %{name}-devel = %{version}-%{release}
90
91 %description static
92 Static SPICE GTK 3.0 client library.
93
94 %description static -l pl.UTF-8
95 Statyczna biblioteka kliencka SPICE GTK 3.0.
96
97 %package apidocs
98 Summary:        SPICE GTK API documentation
99 Summary(pl.UTF-8):      Dokumentacja API bibliotek SPICE GTK
100 Group:          Documentation
101
102 %description apidocs
103 API documentation for SPICE GTK libraries.
104
105 %description apidocs -l pl.UTF-8
106 Dokumentacja API bibliotek SPICE GTK.
107
108 %package -n spice-glib
109 Summary:        SPICE Client GLib library
110 Summary(pl.UTF-8):      Biblioteka kliencka SPICE GLib
111 Group:          Libraries
112 Requires:       celt051 >= 0.5.1.1
113 Requires:       glib2 >= 1:2.22
114 %{?with_smartcard:Requires:     libcacard >= 0.1.2}
115 Requires:       pixman >= 0.17.7
116 %if %{with usbredir}
117 Requires:       libusb >= 1.0.9
118 Requires:       usbredir >= 0.5.2
119 %endif
120
121 %description -n spice-glib
122 SPICE Client GLib library.
123
124 %description -n spice-glib -l pl.UTF-8
125 Biblioteka kliencka SPICE GLib.
126
127 %package -n spice-glib-devel
128 Summary:        Header files for SPICE Client GLib library
129 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki klienckiej SPICE GLib
130 Group:          Development/Libraries
131 Requires:       celt051-devel >= 0.5.1.1
132 Requires:       cyrus-sasl-devel >= 2.0
133 Requires:       glib2-devel >= 1:2.22
134 %{?with_smartcard:Requires:     libcacard-devel >= 0.1.2}
135 Requires:       libjpeg-devel
136 Requires:       openssl-devel
137 Requires:       pixman-devel >= 0.17.7
138 Requires:       pulseaudio-devel
139 Requires:       spice-glib = %{version}-%{release}
140 Requires:       spice-protocol >= 0.10.1
141 %if %{with usbredir}
142 Requires:       libusb-devel >= 1.0.9
143 Requires:       udev-glib-devel
144 Requires:       usbredir-devel >= 0.5.2
145 %endif
146
147 %description -n spice-glib-devel
148 Header files for SPICE Client GLib library.
149
150 %description -n spice-glib-devel -l pl.UTF-8
151 Pliki nagłówkowe biblioteki klienckiej SPICE GLib.
152
153 %package -n spice-glib-static
154 Summary:        SPICE Client GLib static library
155 Summary(pl.UTF-8):      Statyczna biblioteka kliencka SPICE GLib
156 Group:          Development/Libraries
157 Requires:       spice-glib-devel = %{version}-%{release}
158
159 %description -n spice-glib-static
160 SPICE Client GLib static library.
161
162 %description -n spice-glib-static -l pl.UTF-8
163 Statyczna biblioteka kliencka SPICE GLib.
164
165 %package -n spice-glib-usb
166 Summary:        USB redirection ACL helper for SPICE Client GLib library
167 Summary(pl.UTF-8):      Program pomocniczy ACL do przekierowań USB dla biblioteki klienckiej SPICE GLib
168 Group:          Applications/System
169 Requires:       spice-glib = %{version}-%{release}
170 Requires:       polkit >= 0.96
171
172 %description -n spice-glib-usb
173 USB redirection ACL helper for SPICE Client GLib library.
174
175 %description -n spice-glib-usb -l pl.UTF-8
176 Program pomocniczy ACL do przekierowań USB dla biblioteki klienckiej
177 SPICE GLib.
178
179 %package -n spice-gtk2
180 Summary:        SPICE Client GTK 2.0 library
181 Summary(pl.UTF-8):      Biblioteka kliencka SPICE GTK 2.0
182 Group:          X11/Libraries
183 Requires:       gtk+2 >= 2:2.18.0
184 Requires:       spice-glib = %{version}-%{release}
185
186 %description -n spice-gtk2
187 SPICE Client GTK 2.0 library.
188
189 %description -n spice-gtk2 -l pl.UTF-8
190 Biblioteka kliencka SPICE GTK 2.0.
191
192 %package -n spice-gtk2-devel
193 Summary:        Header files for SPICE Client GTK 2.0 library
194 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki klienckiej SPICE GTK 2.0
195 Group:          X11/Development/Libraries
196 Requires:       gtk+2-devel >= 2:2.18.0
197 Requires:       spice-glib-devel = %{version}-%{release}
198
199 %description -n spice-gtk2-devel
200 Header files for SPICE Client GTK 2.0 library.
201
202 %description -n spice-gtk2-devel -l pl.UTF-8
203 Pliki nagłówkowe biblioteki klienckiej SPICE GTK 2.0.
204
205 %package -n spice-gtk2-static
206 Summary:        SPICE Client GTK 2.0 static library
207 Summary(pl.UTF-8):      Statyczna biblioteka kliencka SPICE GTK 2.0
208 Group:          X11/Development/Libraries
209 Requires:       spice-gtk2-devel = %{version}-%{release}
210
211 %description -n spice-gtk2-static
212 SPICE Client GTK 2.0 static library.
213
214 %description -n spice-gtk2-static -l pl.UTF-8
215 Statyczna biblioteka kliencka SPICE GTK 2.0.
216
217 %package -n python-spice-gtk
218 Summary:        Python interface to SPICE client GTK library
219 Summary(pl.UTF-8):      Pythonowy interfejs do biblioteki klienckiej SPICE GTK
220 Group:          Libraries/Python
221 Requires:       spice-gtk2 = %{version}-%{release}
222
223 %description -n python-spice-gtk
224 Python interface to SPICE client GTK library.
225
226 %description -n python-spice-gtk -l pl.UTF-8
227 Pythonowy interfejs do biblioteki klienckiej SPICE GTK.
228
229 %package -n vala-spice-protocol
230 Summary:        Vala API for SPICE client library
231 Summary(pl.UTF-8):      Interfejs języka Vala do biblioteki klienckiej SPICE
232 Group:          Development/Libraries
233 Requires:       spice-protocol >= 0.10.1
234 Requires:       vala >= 0.14
235
236 %description -n vala-spice-protocol
237 Vala API for SPICE client library.
238
239 %description -n vala-spice-protocol -l pl.UTF-8
240 Interfejs języka Vala do biblioteki klienckiej SPICE.
241
242 %prep
243 %setup -q
244 %patch0 -p1
245 %patch1 -p1
246 %patch2 -p1
247
248 # kill am portability warning (there is -Werror)
249 sed -i -e '/AC_PROG_LIBTOOL/aAM_PROG_AR' configure.ac
250
251 mkdir %{?with_gtk2:gtk2} %{?with_gtk3:gtk3}
252
253 %build
254 %{__intltoolize}
255 %{__libtoolize}
256 %{__aclocal} -I m4
257 %{__autoconf}
258 %{__autoheader}
259 %{__automake}
260
261 %if %{with gtk2}
262 cd gtk2
263 ../%configure \
264         --disable-silent-rules \
265         %{!?with_smartcard:--disable-smartcard} \
266         %{!?with_usbredir:--disable-usbredir} \
267         --with-gtk=2.0 \
268         --with-html-dir=%{_gtkdocdir}
269 %{__make}
270 cd ..
271 %endif
272
273 %if %{with gtk3}
274 cd gtk3
275 ../%configure \
276         --disable-silent-rules \
277         %{!?with_smartcard:--disable-smartcard} \
278         %{!?with_usbredir:--disable-usbredir} \
279         --enable-gtk-doc \
280         --with-gtk=3.0 \
281         --with-html-dir=%{_gtkdocdir}
282 %{__make}
283 %endif
284
285 %install
286 rm -rf $RPM_BUILD_ROOT
287
288 # gtk2 first, so executables will use gtk3 libs
289 %if %{with gtk2}
290 %{__make} -C gtk2 install -j1 \
291         DESTDIR=$RPM_BUILD_ROOT
292 %endif
293
294 %if %{with gtk3}
295 %{__make} -C gtk3 install -j1 \
296         DESTDIR=$RPM_BUILD_ROOT
297 %endif
298
299 %{__rm} $RPM_BUILD_ROOT%{py_sitedir}/SpiceClientGtk.{la,a}
300 # obsoleted by pkg-config
301 %{__rm} $RPM_BUILD_ROOT%{_libdir}/lib*.la
302
303 %find_lang %{name}
304
305 %clean
306 rm -rf $RPM_BUILD_ROOT
307
308 %post   -p /sbin/ldconfig
309 %postun -p /sbin/ldconfig
310
311 %post   -n spice-glib -p /sbin/ldconfig
312 %postun -n spice-glib -p /sbin/ldconfig
313
314 %post   -n spice-gtk2 -p /sbin/ldconfig
315 %postun -n spice-gtk2 -p /sbin/ldconfig
316
317 %if %{with gtk3}
318 %files -f %{name}.lang
319 %defattr(644,root,root,755)
320 %doc AUTHORS NEWS README THANKS TODO
321 %attr(755,root,root) %{_bindir}/snappy
322 %attr(755,root,root) %{_bindir}/spicy
323 %attr(755,root,root) %{_bindir}/spicy-stats
324 %attr(755,root,root) %{_libdir}/libspice-client-gtk-3.0.so.*.*.*
325 %attr(755,root,root) %ghost %{_libdir}/libspice-client-gtk-3.0.so.4
326 %{_libdir}/girepository-1.0/SpiceClientGtk-3.0.typelib
327
328 %files devel
329 %defattr(644,root,root,755)
330 %attr(755,root,root) %{_libdir}/libspice-client-gtk-3.0.so
331 %{_includedir}/spice-client-gtk-3.0
332 %{_pkgconfigdir}/spice-client-gtk-3.0.pc
333 %{_datadir}/gir-1.0/SpiceClientGtk-3.0.gir
334
335 %files static
336 %defattr(644,root,root,755)
337 %{_libdir}/libspice-client-gtk-3.0.a
338
339 %files apidocs
340 %defattr(644,root,root,755)
341 %{_gtkdocdir}/spice-gtk
342 %endif
343
344 %files -n spice-glib
345 %defattr(644,root,root,755)
346 %attr(755,root,root) %{_libdir}/libspice-client-glib-2.0.so.*.*.*
347 %attr(755,root,root) %ghost %{_libdir}/libspice-client-glib-2.0.so.8
348 %attr(755,root,root) %{_libdir}/libspice-controller.so.*.*.*
349 %attr(755,root,root) %ghost %{_libdir}/libspice-controller.so.0
350 %{_libdir}/girepository-1.0/SpiceClientGLib-2.0.typelib
351
352 %files -n spice-glib-devel
353 %defattr(644,root,root,755)
354 %attr(755,root,root) %{_libdir}/libspice-client-glib-2.0.so
355 %attr(755,root,root) %{_libdir}/libspice-controller.so
356 %{_includedir}/spice-client-glib-2.0
357 %{_includedir}/spice-controller
358 %{_pkgconfigdir}/spice-client-glib-2.0.pc
359 %{_pkgconfigdir}/spice-controller.pc
360 %{_datadir}/gir-1.0/SpiceClientGLib-2.0.gir
361
362 %files -n spice-glib-static
363 %defattr(644,root,root,755)
364 %{_libdir}/libspice-client-glib-2.0.a
365 %{_libdir}/libspice-controller.a
366
367 %if %{with usbredir}
368 %files -n spice-glib-usb
369 %defattr(644,root,root,755)
370 %attr(755,root,root) %{_bindir}/spice-client-glib-usb-acl-helper
371 %{_datadir}/polkit-1/actions/org.spice-space.lowlevelusbaccess.policy
372 %endif
373
374 %if %{with gtk2}
375 %files -n spice-gtk2
376 %defattr(644,root,root,755)
377 %attr(755,root,root) %{_libdir}/libspice-client-gtk-2.0.so.*.*.*
378 %attr(755,root,root) %ghost %{_libdir}/libspice-client-gtk-2.0.so.4
379 %{_libdir}/girepository-1.0/SpiceClientGtk-2.0.typelib
380
381 %files -n spice-gtk2-devel
382 %defattr(644,root,root,755)
383 %attr(755,root,root) %{_libdir}/libspice-client-gtk-2.0.so
384 %{_includedir}/spice-client-gtk-2.0
385 %{_pkgconfigdir}/spice-client-gtk-2.0.pc
386 %{_datadir}/gir-1.0/SpiceClientGtk-2.0.gir
387
388 %files -n spice-gtk2-static
389 %defattr(644,root,root,755)
390 %{_libdir}/libspice-client-gtk-2.0.a
391
392 %files -n python-spice-gtk
393 %defattr(644,root,root,755)
394 %attr(755,root,root) %{py_sitedir}/SpiceClientGtk.so
395 %endif
396
397 %files -n vala-spice-protocol
398 %defattr(644,root,root,755)
399 %{_datadir}/vala/vapi/spice-protocol.vapi
This page took 0.083354 seconds and 4 git commands to generate.