- subpackages for backends, build yum backend; rel 3
[packages/PackageKit.git] / PackageKit.spec
CommitLineData
d05d9108
MB
1# TODO:
2# - BASH command-not-found functionality disabled for now as it needs patched bash
3# (details in bash from Fedora Rawhide)
aa2113f5 4# - do not package browser plugin (it's flawed by concept)
6e66a3a4 5# - package: gir stuff (invert bcond if works)
aa2113f5
ER
6# /usr/lib/girepository-1.0/PackageKitGlib-1.0.typelib
7# /usr/share/gir-1.0/PackageKitGlib-1.0.gir
6e66a3a4
ER
8# - todo:
9# configure: WARNING: unrecognized options: --disable-ruck
d05d9108
MB
10#
11# Conditional build:
12%bcond_without qt # don't build packagekit-qt library
9b8153ef 13%bcond_without doc # build without docs
6e66a3a4 14%bcond_with gir # gobject introspection, time to time broken
0d5f415c
ER
15%bcond_without poldek # build poldek backend
16%bcond_without yum # build yum backend
dc10d5ba 17
0d5f415c 18# default backend, configurable at runtime
dc10d5ba 19%define backend poldek
48a22c3c 20
85d27e4f
JB
21Summary: System daemon that is a D-Bus abstraction layer for package management
22Summary(pl.UTF-8): Demon systemowy będący warstwą abstrakcji D-Bus do zarządzania pakietami
a2d83637 23Name: PackageKit
48a22c3c 24Version: 0.6.8
0d5f415c 25Release: 3
a2d83637 26License: GPL v2+
85d27e4f 27Group: Applications/System
74872af2 28Source0: http://www.packagekit.org/releases/%{name}-%{version}.tar.bz2
48a22c3c 29# Source0-md5: 47987b91826bd522de1202d5a1e2510d
d05d9108 30Patch1: %{name}-PLD.patch
36ca2380 31Patch2: bashism.patch
a2d83637
MB
32URL: http://www.packagekit.org/
33BuildRequires: NetworkManager-devel >= 0.6.5
d05d9108
MB
34%if %{with qt}
35BuildRequires: QtCore-devel >= 4.4.0
36BuildRequires: QtDBus-devel >= 4.4.0
37BuildRequires: QtGui-devel >= 4.4.0
27e89cfe
MB
38BuildRequires: QtSql-devel >= 4.4.0
39BuildRequires: QtXml-devel >= 4.4.0
d05d9108 40%endif
600be41c 41BuildRequires: autoconf >= 2.65
a2d83637 42BuildRequires: automake
d05d9108 43%{?with_qt:BuildRequires: cppunit-devel}
6808f644 44BuildRequires: dbus-devel >= 1.2.0
f5f5e3ff 45BuildRequires: dbus-glib-devel >= 0.76
bdd8c0ca 46BuildRequires: docbook-dtd412-xml
47BuildRequires: docbook-dtd42-xml
a2d83637 48BuildRequires: gettext-devel
9ed4ca79 49BuildRequires: glib2-devel >= 1:2.22.0
d05d9108
MB
50BuildRequires: gstreamer-plugins-base-devel
51BuildRequires: gtk+2-devel >= 2:2.14.0
9b8153ef 52%{?with_doc:BuildRequires: gtk-doc >= 1.9}
d05d9108 53BuildRequires: intltool >= 0.35.0
78293e06 54BuildRequires: libarchive-devel
a2d83637
MB
55BuildRequires: libtool
56BuildRequires: pkgconfig
bdd8c0ca 57BuildRequires: pm-utils
dc10d5ba 58%{?with_poldek:BuildRequires: poldek-devel >= 0.30-0.20080820.23.20}
9ed4ca79 59BuildRequires: polkit-devel >= 0.92
a2d83637 60BuildRequires: python-devel
d05d9108 61%{?with_qt:BuildRequires: qt4-build >= 4.4.0}
bdd8c0ca 62BuildRequires: readline-devel
a2d83637 63BuildRequires: rpm-pythonprov
85d27e4f 64BuildRequires: rpmbuild(macros) >= 1.311
a2d83637 65BuildRequires: sqlite3-devel
9ed4ca79 66BuildRequires: udev-glib-devel
bdd8c0ca 67BuildRequires: xorg-lib-libXt-devel
d05d9108 68BuildRequires: xulrunner-devel
fcd0bc5c 69Requires(post,postun): shared-mime-info
0d5f415c 70Requires: %{name}-backend
a2d83637 71Requires: %{name}-libs = %{version}-%{release}
9ed4ca79 72Requires: ConsoleKit
8d48627e 73Requires: crondaemon
9ed4ca79 74Requires: polkit >= 0.92
a2d83637
MB
75BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
76
77%description
78PackageKit is a D-Bus abstraction layer that allows the session user
79to manage packages in a secure way using a cross-distro,
80cross-architecture API.
81
85d27e4f
JB
82%description -l pl.UTF-8
83PackageKit to warstwa abstrakcji D-Bus pozwalająca użytkownikowi
84sesyjnemu w bezpieczny sposob zarządzać pakietami przy użyciu API
85zgodnego z wieloma dystrybucjami i architekturami.
86
a2d83637 87%package libs
d05d9108
MB
88Summary: packagekit-glib library
89Summary(pl.UTF-8): Biblioteka packagekit-glib
a2d83637 90Group: Libraries
9ed4ca79 91Requires: glib2 >= 1:2.22.0
a2d83637
MB
92
93%description libs
d05d9108 94packagekit-glib library.
a2d83637
MB
95
96%description libs -l pl.UTF-8
d05d9108 97Biblioteka packagekit-glib.
a2d83637
MB
98
99%package devel
d05d9108
MB
100Summary: Header files for packagekit-glib library
101Summary(pl.UTF-8): Pliki nagłówkowe biblioteki packagekit-glib
a2d83637
MB
102Group: Development/Libraries
103Requires: %{name}-libs = %{version}-%{release}
9ed4ca79
MB
104Requires: dbus-devel >= 1.2.0
105Requires: glib2-devel >= 1:2.22.0
106Requires: sqlite3-devel
a2d83637
MB
107
108%description devel
d05d9108 109Header files for packagekit-glib library.
a2d83637
MB
110
111%description devel -l pl.UTF-8
d05d9108 112Pliki nagłówkowe biblioteki packagekit-glib.
a2d83637
MB
113
114%package static
d05d9108
MB
115Summary: Static packagekit-glib library
116Summary(pl.UTF-8): Statyczna biblioteka packagekit-glib
a2d83637
MB
117Group: Development/Libraries
118Requires: %{name}-devel = %{version}-%{release}
119
120%description static
d05d9108 121Static packagekit-glib library.
a2d83637
MB
122
123%description static -l pl.UTF-8
d05d9108
MB
124Statyczna biblioteka packagekit-glib.
125
0d5f415c
ER
126%package backend-yum
127Summary: PackageKit YUM backend
128Group: Libraries
129Requires: %{name} = %{version}-%{release}
130Requires: python-packagekit = %{version}-%{release}
131Requires: yum >= 3.2.19
132Provides: %{name}-backend
133
134%description backend-yum
135A backend for PackageKit to enable yum functionality.
136
137%package backend-poldek
138Summary: PackageKit Poldek backend
139Group: Libraries
140Requires: %{name} = %{version}-%{release}
141Requires: poldek >= 0.30-0.20080820.23.20}
142Provides: %{name}-backend
143Conflicts: %{name} < 0.6.8-3
144
145%description backend-poldek
146A backend for PackageKit to enable Poldek functionality.
147
d05d9108
MB
148%package qt
149Summary: packagekit-qt library
150Summary(pl.UTF-8): Biblioteka packagekit-qt
151Group: Libraries
152Obsoletes: qpackagekit
153
154%description qt
155packagekit-qt library.
156
157%description qt -l pl.UTF-8
158Biblioteka packagekit-qt.
159
160%package qt-devel
161Summary: Header files for packagekit-qt library
162Summary(pl.UTF-8): Pliki nagłówkowe biblioteki packagekit-qt
163Group: Development/Libraries
164Requires: %{name}-qt = %{version}-%{release}
27e89cfe
MB
165Requires: QtCore-devel >= 4.4.0
166Requires: QtDBus-devel >= 4.4.0
167Requires: QtGui-devel >= 4.4.0
168Requires: QtSql-devel >= 4.4.0
169Requires: QtXml-devel >= 4.4.0
d05d9108
MB
170Obsoletes: qpackagekit-devel
171
172%description qt-devel
173Header files for packagekit-qt library.
174
175%description qt-devel -l pl.UTF-8
176Pliki nagłówkowe biblioteki packagekit-qt.
177
178%package qt-static
179Summary: Static packagekit-qt library
180Summary(pl.UTF-8): Statyczna biblioteka packagekit-qt
181Group: Development/Libraries
182Requires: %{name}-qt-devel = %{version}-%{release}
183
184%description qt-static
185Static packagekit-qt library.
186
187%description qt-static -l pl.UTF-8
188Statyczna biblioteka packagekit-qt.
a2d83637
MB
189
190%package apidocs
191Summary: PackageKit library API documentation
192Summary(pl.UTF-8): Dokumentacja API biblioteki PackageKit
193Group: Documentation
194Requires: gtk-doc-common
195
196%description apidocs
197PackageKit library API documentation.
198
199%description apidocs -l pl.UTF-8
200Dokumentacja API biblioteki PackageKit.
201
d05d9108
MB
202%package docs
203Summary: PackageKit documentation
204Summary(pl.UTF-8): Dokumentacja PackageKit
205Group: Documentation
206
207%description docs
208PackageKit documentation.
209
210%description docs -l pl.UTF-8
211Dokumentacja PackageKit.
212
213%package gstreamer-plugin
214Summary: GStreamer codecs installer
215Summary(pl.UTF-8): Instalator kodeków GStreamera
216Group: Applications
217Requires: %{name} = %{version}-%{release}
5baab3aa 218Requires: %{name}-gtk-module = %{version}-%{release}
d05d9108
MB
219
220%description gstreamer-plugin
221The PackageKit GStreamer plugin allows any GStreamer application to
222install codecs from configured repositories using PackageKit.
223
224%description gstreamer-plugin -l pl.UTF-8
225Wtyczka GStreamer pozwala każdej aplikacji używającej GStreamera
226zainstalować kodeki ze skonfigurowanych źródeł PackageKit.
227
228%package gtk-module
229Summary: GTK+ module to detect and install missing fonts
230Summary(pl.UTF-8): Moduł GTK+ do wykrywania i instalowania brakujących czcionek
231Group: X11/Libraries
232
233%description gtk-module
234The PackageKit GTK+ module allows any pango application to install
235missing fonts from configured repositories using PackageKit.
236
237%description gtk-module -l pl.UTF-8
238Moduł GTK+ pozwala każdej aplikacji używającej pango zainstalować
239brakującą czcionkę ze skonfigurowanych źródeł PackageKit.
240
a2d83637
MB
241%package -n bash-completion-packagekit
242Summary: bash-completion for PackageKit
243Summary(pl.UTF-8): bashowe uzupełnianie nazw dla PackageKit
244Group: Applications/Shells
245Requires: bash-completion
246
247%description -n bash-completion-packagekit
248This package provides bash-completion for PackageKit.
249
250%description -n bash-completion-packagekit -l pl.UTF-8
251Pakiet ten dostarcza bashowe uzupełnianie nazw dla PackageKit.
252
253%package -n pm-utils-packagekit
254Summary: PackageKit script for pm-utils
85d27e4f 255Summary(pl.UTF-8): Skrypt PackageKit dla pm-utils
a2d83637
MB
256Group: Applications/System
257Requires: pm-utils
258
259%description -n pm-utils-packagekit
260PackageKit script for pm-utils.
261
85d27e4f
JB
262%description -n pm-utils-packagekit -l pl.UTF-8
263Skrypt PackageKit dla pm-utils.
264
a2d83637
MB
265%package -n python-packagekit
266Summary: PackageKit Python bindings
267Summary(pl.UTF-8): Wiązania PackageKit dla Pythona
268Group: Development/Languages/Python
269Requires: python-dbus
270Requires: python-pygobject
271
272%description -n python-packagekit
273PackageKit Python bindings.
274
86086d14 275%description -n python-packagekit -l pl.UTF-8
a2d83637
MB
276Wiązania PackageKit dla Pythona.
277
278%prep
279%setup -q
d05d9108 280%patch1 -p1
36ca2380 281%patch2 -p1
a2d83637
MB
282
283%build
9b8153ef 284%if %{with doc}
d05d9108 285%{__gtkdocize}
d5617342 286%endif
58e98be4 287%{__intltoolize}
a2d83637 288%{__libtoolize}
d05d9108 289%{__aclocal} -I m4
a2d83637
MB
290%{__autoconf}
291%{__autoheader}
292%{__automake}
293%configure \
d05d9108
MB
294 --disable-dummy \
295 --disable-ruck \
296 --disable-command-not-found \
aa2113f5 297 --disable-browser-plugin \
6e66a3a4 298 %{!?with_gir:--disable-introspection} \
dc10d5ba 299 %{?with_poldek:--enable-poldek} \
6e66a3a4 300 %{?with_yum:--enable-yum} \
9b8153ef 301 --%{!?with_doc:dis}%{?with_doc:en}able-gtk-doc \
d05d9108 302 --%{?with_qt:en}%{!?with_qt:dis}able-qt \
fcd0bc5c 303 --with-html-dir=%{_gtkdocdir} \
dc10d5ba 304 --with-default-backend=%{backend}
a2d83637
MB
305%{__make}
306
307%install
308rm -rf $RPM_BUILD_ROOT
309
310%{__make} install \
311 DESTDIR=$RPM_BUILD_ROOT
312
d05d9108
MB
313# use pk-gstreamer-install as codec installer
314ln -s pk-gstreamer-install $RPM_BUILD_ROOT%{_libdir}/gst-install-plugins-helper
315
684bfa1d 316install -d $RPM_BUILD_ROOT%{_libdir}/pm-utils/sleep.d
aa2113f5 317install -p contrib/pm-utils/95packagekit $RPM_BUILD_ROOT%{_libdir}/pm-utils/sleep.d
684bfa1d 318
d05d9108
MB
319rm -f $RPM_BUILD_ROOT%{_libdir}/gtk-2.0/modules/*.{la,a}
320rm -f $RPM_BUILD_ROOT%{_libdir}/mozilla/plugins/*.{la,a}
a2d83637 321rm -f $RPM_BUILD_ROOT%{_libdir}/packagekit-backend/*.{la,a}
d05d9108 322rm -f $RPM_BUILD_ROOT%{_libdir}/packagekit-backend/libpk_backend_test_*.so
f058dba9 323rm -f $RPM_BUILD_ROOT%{_libdir}/polkit-1/extensions/*.{la,a}
d05d9108
MB
324rm -f $RPM_BUILD_ROOT%{_libdir}/PackageKitDbusTest.py
325rm -f $RPM_BUILD_ROOT%{_sysconfdir}/dbus-1/system.d/org.freedesktop.PackageKit{Apt,Test}Backend.conf
326rm -f $RPM_BUILD_ROOT%{_datadir}/dbus-1/system-services/org.freedesktop.PackageKit{Apt,Test}Backend.service
327rm -rf $RPM_BUILD_ROOT%{_datadir}/PackageKit/helpers/test_spawn
a2d83637 328
8c9d69e0
ER
329%if %{with yum}
330# yumBackend.py can't be compiled (invoked directly), other should be compiled
331%py_comp $RPM_BUILD_ROOT%{_datadir}/PackageKit/helpers/yum
332%py_ocomp $RPM_BUILD_ROOT%{_datadir}/PackageKit/helpers/yum
333rm -f $RPM_BUILD_ROOT%{_datadir}/PackageKit/helpers/yum/yum{Comps,Filter}.py
334rm -f $RPM_BUILD_ROOT%{_datadir}/PackageKit/helpers/yum/yumBackend.py[co]
335%endif
336
a2d83637
MB
337%py_postclean
338
6808f644
MB
339%find_lang %{name}
340
a2d83637
MB
341%clean
342rm -rf $RPM_BUILD_ROOT
343
fcd0bc5c
MB
344%post
345%update_mime_database
346
347%postun
348%update_mime_database
349
85d27e4f 350%post libs -p /sbin/ldconfig
a2d83637
MB
351%postun libs -p /sbin/ldconfig
352
d05d9108
MB
353%post qt -p /sbin/ldconfig
354%postun qt -p /sbin/ldconfig
355
6808f644 356%files -f %{name}.lang
a2d83637
MB
357%defattr(644,root,root,755)
358%doc AUTHORS ChangeLog HACKING NEWS README TODO
359%attr(755,root,root) %{_bindir}/packagekit-bugreport.sh
a2d83637 360%attr(755,root,root) %{_bindir}/pkcon
78293e06 361%attr(755,root,root) %{_bindir}/pkgenpack
a2d83637 362%attr(755,root,root) %{_bindir}/pkmon
a382d619 363%attr(755,root,root) %{_bindir}/pk-debuginfo-install
8d48627e 364%attr(750,root,root) /etc/cron.daily/packagekit-background.cron
a2d83637 365%dir %{_libdir}/packagekit-backend
f058dba9 366%attr(755,root,root) %{_libdir}/polkit-1/extensions/libpackagekit-action-lookup.so
aa2113f5 367%attr(755,root,root) %{_libdir}/packagekitd
9ed4ca79 368%attr(755,root,root) %{_sbindir}/pk-device-rebind
a2d83637
MB
369%dir %{_sysconfdir}/PackageKit
370%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/PackageKit/PackageKit.conf
d05d9108 371%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/PackageKit/Vendor.conf
5baab3aa
ER
372%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/packagekit-background
373/etc/dbus-1/system.d/org.freedesktop.PackageKit.conf
d05d9108 374%dir %{_datadir}/PackageKit
6e66a3a4 375%dir %{_datadir}/PackageKit/helpers
d05d9108 376%attr(755,root,root) %{_datadir}/PackageKit/pk-upgrade-distro.sh
f058dba9 377%{_datadir}/polkit-1/actions/org.freedesktop.packagekit.policy
a2d83637 378%{_datadir}/dbus-1/system-services/org.freedesktop.PackageKit.service
d05d9108 379%{_datadir}/mime/packages/packagekit-catalog.xml
08c67dac 380%{_datadir}/mime/packages/packagekit-package-list.xml
381%{_datadir}/mime/packages/packagekit-servicepack.xml
a2d83637 382%{_mandir}/man1/pkcon.1*
f058dba9 383%{_mandir}/man1/pk-debuginfo-install.1*
9ed4ca79 384%{_mandir}/man1/pk-device-rebind.1*
78293e06
MB
385%{_mandir}/man1/pkgenpack.1*
386%{_mandir}/man1/pkmon.1*
387%dir /var/cache/PackageKit
388%dir /var/cache/PackageKit/downloads
a2d83637 389%dir /var/lib/PackageKit
d05d9108 390%ghost /var/lib/PackageKit/transactions.db
a2d83637
MB
391
392%files libs
393%defattr(644,root,root,755)
74872af2 394%attr(755,root,root) %{_libdir}/libpackagekit-glib2.so.*.*.*
aa2113f5 395%attr(755,root,root) %ghost %{_libdir}/libpackagekit-glib2.so.14
08c67dac 396
a2d83637
MB
397%files devel
398%defattr(644,root,root,755)
74872af2 399%attr(755,root,root) %{_libdir}/libpackagekit-glib2.so
74872af2 400%{_libdir}/libpackagekit-glib2.la
74872af2 401%{_pkgconfigdir}/packagekit-glib2.pc
d05d9108
MB
402%dir %{_includedir}/PackageKit
403%{_includedir}/PackageKit/backend
74872af2 404%{_includedir}/PackageKit/packagekit-glib2
08c67dac 405
a2d83637
MB
406%files static
407%defattr(644,root,root,755)
74872af2 408%{_libdir}/libpackagekit-glib2.a
d05d9108 409
0d5f415c
ER
410%if %{with poldek}
411%files backend-poldek
412%defattr(644,root,root,755)
413%attr(755,root,root) %{_libdir}/packagekit-backend/libpk_backend_poldek.so
414%endif
415
416%if %{with yum}
417%files backend-yum
418%defattr(644,root,root,755)
419%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/PackageKit/Yum.conf
420%attr(755,root,root) %{_libdir}/packagekit-backend/libpk_backend_yum.so
421%dir %{_datadir}/PackageKit/helpers/yum
422%{_datadir}/PackageKit/helpers/yum/licenses.txt
423%{_datadir}/PackageKit/helpers/yum/yum-comps-groups.conf
424%attr(755,root,root) %{_datadir}/PackageKit/helpers/yum/yumBackend.py
425%{_datadir}/PackageKit/helpers/yum/yumComps.py[co]
426%{_datadir}/PackageKit/helpers/yum/yumFilter.py[co]
427
428# yum plugin
429%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/yum/pluginconf.d/refresh-packagekit.conf
430%{_prefix}/lib/yum-plugins/refresh-packagekit.py
431%endif
432
5424bc1f 433%if %{with qt}
d05d9108
MB
434%files qt
435%defattr(644,root,root,755)
436%attr(755,root,root) %{_libdir}/libpackagekit-qt.so.*.*.*
aa2113f5 437%attr(755,root,root) %ghost %{_libdir}/libpackagekit-qt.so.14
d05d9108
MB
438
439%files qt-devel
440%defattr(644,root,root,755)
441%attr(755,root,root) %{_libdir}/libpackagekit-qt.so
442%{_libdir}/libpackagekit-qt.la
443%{_pkgconfigdir}/packagekit-qt.pc
444%{_includedir}/PackageKit/packagekit-qt
445%{_datadir}/cmake/Modules/FindQPackageKit.cmake
446
447%files qt-static
448%defattr(644,root,root,755)
08c67dac 449%{_libdir}/libpackagekit-qt.a
5424bc1f 450%endif
a2d83637
MB
451
452%files apidocs
453%defattr(644,root,root,755)
454%{_gtkdocdir}/PackageKit
455
d05d9108
MB
456%files docs
457%defattr(644,root,root,755)
458%{_datadir}/PackageKit/website
459
460%files gstreamer-plugin
461%defattr(644,root,root,755)
462%doc contrib/gstreamer-plugin/README
463%attr(755,root,root) %{_libdir}/gst-install-plugins-helper
464%attr(755,root,root) %{_libdir}/pk-gstreamer-install
465
466%files gtk-module
467%defattr(644,root,root,755)
468%doc contrib/gtk-module/{GLASS.txt,README}
469%attr(755,root,root) %{_libdir}/gtk-2.0/modules/libpk-gtk-module.so
470
a2d83637
MB
471%files -n bash-completion-packagekit
472%defattr(644,root,root,755)
473%{_sysconfdir}/bash_completion.d/pk-completion.bash
474
475%files -n pm-utils-packagekit
476%defattr(644,root,root,755)
d05d9108 477%attr(755,root,root) %{_libdir}/pm-utils/sleep.d/95packagekit
a2d83637
MB
478
479%files -n python-packagekit
480%defattr(644,root,root,755)
481%dir %{py_sitescriptdir}/packagekit
482%{py_sitescriptdir}/packagekit/*.py[co]
This page took 0.113732 seconds and 4 git commands to generate.