PackageKit Desktop Integration
PackageKit is a simple system service that manages the users package tool. It exposes a low level DBus API that aplications and other frameworks can use.
gnome-packagekit builds on the low level DBus API with a high level interface. This allows programs on the desktop to automatically install applications, fonts, multimedia codecs and clipart.
- Name: Richard Hughes
- Targeted release: Fedora 11
- Last updated: 2009-02-05
- Percentage of completion: 77%
PackageKit and gnome-packagekit have been built in rawhide. rpm has been patched to generate automatic provides for gstreamer plugins since F10, but has now got support for mimehandlers in the last week. In the next few days the font handling code will be enabled.
For the automatic provides to be added, packages have to be rebuilt. It is expected that the rebuild due to GCC 4.4 will do most of this work for us automatically.
When a user gets sent a document in a foreign langauge, a media file in an unknown format or a file that nautilus does not recognise, then we shouldn't ask them to consult a wiki and then install packages manually. This stuff should just work. Adding automatic provides to the rpm's means that we can integrate with frameworks such as Pango, GStreamer and applications such as nautilus to make installing packages seamless.
Benefit to Fedora
Fedora just works for users. No configuring, no reading wiki pages, just confirming an install makes things "just work".
This feature depends on patches to rpm, with a full rebuild of all desktop programs and fonts. Most of the needed patches are in the rawhide build of rpm, and are heading upstream.
To work with KDE, kpackagekit will been to support the same session API. They are working on it, but are low on resources. This feature does not depend on the KPackageKit effort.
How To Test
- Try to open a file in a format for which no application is installed. To check which formats have applications associated with them, you can look at /usr/share/applications/defaults.list. Open the file using the "Open with Other Application..." menuitem in the nautilus context menu. Verify that nautilus offers to search for a suitable application that can be installed. Install one of the offered applications, and check that the installation succeeds and the file is opened with the newly installed application afterwards.
- Try to open the same file again and check that the newly installed application now shows up in the context menu as one "Open with" choice.
- Try to play mp3 with other repositories enabled, and without gstreamer mp3 codecs installed. Verify that rhythmbox offers to install the required codecs. Install them, and check that after the installation, the mp3 is actually played with the newly installed codec.
- Try to play the same mp3 again and verify that it plays without further questions this time.
- Open a document (for instance GLASS.txt) with multiple languages in abiword. Check that apiword offers to search for required fonts. Proceed to install those fonts, and verify that the document renders correctly now.
- Repeat the same tests, this time deciding against the installation in all cases. Verify that this choice is remembered and you are not asked over and over again until the next login.
There is a new popup when trying to play an unsupported media file:
There is a new popup when trying to open an unknown file:
There is a new popup when trying to open a document with other fonts:
- PackageKit >= 0.4.4: For the new provide names in rpm (Due Monday 9th Feb)
- Patches to rpm >= rpm-4.6.0-0.rc4 : (Mostly done, need work on the fonts patch)
- Rebuild of anything with a .ttf font or a .desktop file in the archive (Due for GCC 4.4 rebuild)
We turn off the auto-font and auto-mime handler in gnome-packagekit and do what we used to do (nothing).
Fedora 11 features a new version of rpm that generates much more metadata for fonts, codecs and applications. This extra metadata is used by PackageKit to automatically install fonts, applications and codecs when they are required.