[PackageKit-commit] packagekit: Branch 'master' - 7 commits

Richard Hughes hughsient at kemper.freedesktop.org
Thu Jun 19 08:02:51 PDT 2008


 backends/alpm/pk-backend-alpm.c          |  133 ++++++++++++++++++++++++++--
 backends/conary/helpers/conaryBackend.py |    2 
 docs/html/pk-faq.html                    |    1 
 libpackagekit/pk-enum.c                  |    1 
 libpackagekit/pk-enum.h                  |    1 
 po/ca.po                                 |  147 ++++++++++++++++---------------
 6 files changed, 207 insertions(+), 78 deletions(-)

New commits:
commit 524314bd2d1d492f2561af140975ea0123f352d5
Merge: 1c3e6df... c99246b...
Author: Valeriy Lyasotskiy <onestep at ukr.net>
Date:   Thu Jun 19 13:28:55 2008 +0300

    Merge branch 'master' of git+ssh://onestep_ua@git.packagekit.org/srv/git/PackageKit

commit 1c3e6df49ffe9cb63466fd92ce352bcdf2d0cc7b
Author: Valeriy Lyasotskiy <onestep at ukr.net>
Date:   Thu Jun 19 13:28:21 2008 +0300

    alpm: added backend_get_updates, added backend_get_update_detail

diff --git a/backends/alpm/pk-backend-alpm.c b/backends/alpm/pk-backend-alpm.c
index 38e8e3e..50fc2a8 100644
--- a/backends/alpm/pk-backend-alpm.c
+++ b/backends/alpm/pk-backend-alpm.c
@@ -1069,7 +1069,7 @@ backend_get_repo_list (PkBackend *backend, PkFilterEnum filters)
 
 	// Iterate on repository list
 	alpm_list_t *iterator;
-	for (iterator = repos; iterator; iterator = alpm_list_next(iterator)) {
+	for (iterator = repos; iterator; iterator = alpm_list_next (iterator)) {
 		pmdb_t *db = alpm_list_getdata (repos);
 		pk_backend_repo_detail (backend, alpm_db_get_name (db), alpm_db_get_name (db), TRUE);
 		repos = alpm_list_next (repos);
@@ -1078,6 +1078,57 @@ backend_get_repo_list (PkBackend *backend, PkFilterEnum filters)
 	pk_backend_finished (backend);
 }
 
+static void
+backend_get_update_detail (PkBackend *backend, const gchar *package_id)
+{
+	pk_backend_set_status (backend, PK_STATUS_ENUM_QUERY);
+	pk_backend_set_allow_cancel (backend, FALSE);
+
+	// TODO: add changelog code here
+	PkPackageId *pk_package_id = pk_package_id_new_from_string (package_id);
+
+	pmpkg_t *obsolete_pkg = alpm_db_get_pkg (alpm_option_get_localdb (), pk_package_id->name);
+
+	gchar *obsolete_package_id = obsolete_pkg ? pkg_to_package_id_str (obsolete_pkg, ALPM_LOCAL_DB_ALIAS) : NULL;
+	pk_backend_update_detail (backend, package_id, obsolete_package_id, "", "", "", "", PK_RESTART_ENUM_NONE,
+		obsolete_pkg ? "Update to latest available version" : "Install as a dependency for another update");
+	g_free (obsolete_package_id);
+
+	pk_backend_finished (backend);
+}
+
+/**
+ * backend_get_updates:
+ */
+static void
+backend_get_updates (PkBackend *backend, PkFilterEnum filters)
+{
+	pk_backend_set_status (backend, PK_STATUS_ENUM_QUERY);
+	pk_backend_set_allow_cancel (backend, FALSE);
+
+	// iterate through list installed packages to find update for each
+	alpm_list_t *iterator;
+	for (iterator = alpm_db_getpkgcache (alpm_option_get_localdb ()); iterator; iterator = alpm_list_next (iterator)) {
+		pmpkg_t *pkg = alpm_list_getdata (iterator);
+
+		alpm_list_t *db_iterator;
+		for (db_iterator = alpm_option_get_syncdbs (); db_iterator; db_iterator = alpm_list_next (db_iterator)) {
+			pmdb_t *db = alpm_list_getdata (db_iterator);
+			pmpkg_t *repo_pkg = alpm_db_get_pkg (db, alpm_pkg_get_name (pkg));
+
+			if (repo_pkg != NULL && alpm_pkg_vercmp (alpm_pkg_get_version (pkg), alpm_pkg_get_version (repo_pkg)) < 0) {
+				gchar *package_id_str = pkg_to_package_id_str (repo_pkg, alpm_db_get_name (db));
+				pk_backend_package (backend, PK_INFO_ENUM_NORMAL, package_id_str, alpm_pkg_get_desc (repo_pkg));
+				g_free (package_id_str);
+
+				break;
+			}
+		}
+	}
+
+	pk_backend_finished (backend);
+}
+
 /**
  * backend_install_files_thread:
  */
@@ -1502,8 +1553,8 @@ PK_BACKEND_OPTIONS (
 		backend_get_packages,				/* get_packages */
 		backend_get_repo_list,				/* get_repo_list */
 		NULL,						/* get_requires */
-		NULL,						/* get_update_detail */
-		NULL,						/* get_updates */
+		backend_get_update_detail,			/* get_update_detail */
+		backend_get_updates,				/* get_updates */
 		backend_install_files,				/* install_files */
 		backend_install_packages,			/* install_packages */
 		NULL,						/* install_signature */
commit c99246b005309ba8c55a636046e01d87581bed2f
Author: Xavier Conde <xavi.conde at gmail.com>
Date:   Thu Jun 19 09:16:09 2008 +0000

    2008-06-19  Xavier Conde <xavi.conde at gmail.com> (via xconde at fedoraproject.org)
    
      * po/ca.po: Updated catalan ca.po

diff --git a/po/ca.po b/po/ca.po
index fe8b47c..c3b1d8e 100644
--- a/po/ca.po
+++ b/po/ca.po
@@ -19,8 +19,9 @@
 msgid ""
 msgstr ""
 "Project-Id-Version: packagekit\n"
-"POT-Creation-Date: \n"
-"PO-Revision-Date: 2008-06-06 16:45+0100\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2008-06-11 09:38+0000\n"
+"PO-Revision-Date: 2008-06-14 12:27+0100\n"
 "Last-Translator: Pere Argelich <bakidok at gmail.com>\n"
 "Language-Team: Catalan <fedora at softcatala.net>\n"
 "MIME-Version: 1.0\n"
@@ -28,243 +29,247 @@ msgstr ""
 "Content-Transfer-Encoding: 8bit\n"
 "Plural-Forms: nplurals=2; plural=n != 1;\n"
 
-#: ../client/pk-console.c:224
+#: ../client/pk-console.c:223
 msgid "Update detail"
 msgstr "Detalls de l'actualització"
 
-#: ../client/pk-console.c:425
+#: ../client/pk-console.c:424
 msgid "A system restart is required"
 msgstr "Es requereix reiniciar el sistema"
 
-#: ../client/pk-console.c:427
+#: ../client/pk-console.c:426
 msgid "A logout and login is required"
 msgstr "Es requereix sortir de la sessió"
 
-#: ../client/pk-console.c:429
+#: ../client/pk-console.c:428
 msgid "An application restart is required"
 msgstr "Es requereix reiniciar l'aplicació"
 
-#: ../client/pk-console.c:474
+#: ../client/pk-console.c:473
 #, c-format
 msgid "Please enter a number from 1 to %i: "
 msgstr "Si us plau, introduïu un valor d'1 a %i:"
 
-#: ../client/pk-console.c:524
+#: ../client/pk-console.c:533
 msgid "Could not find a package match"
 msgstr "No s'han trobat coincidències en cap paquet"
 
-#: ../client/pk-console.c:538
+#: ../client/pk-console.c:547
 msgid "There are multiple package matches"
 msgstr "Existeixen coincidències amb múltiples paquets"
 
 #. find out what package the user wants to use
-#: ../client/pk-console.c:545
+#: ../client/pk-console.c:554
 msgid "Please enter the package number: "
 msgstr "Si us plau, introduïu el número de paquet:"
 
-#: ../client/pk-console.c:561
+#: ../client/pk-console.c:589
 msgid "Could not find a package with that name to install, or package already installed"
 msgstr "No s'ha pogut trobar un paquet amb aquest nom per instal·lar, o el paquet ja es troba instal·lat"
 
-#: ../client/pk-console.c:643
-msgid "Could not find a package with that name to remove"
-msgstr "No s'ha pogut trobar un paquet amb aquest nom per eliminar"
+#: ../client/pk-console.c:737
+msgid "Could not find a package to remove"
+msgstr "No s'ha trobat cap paquet per a eliminar"
 
-#: ../client/pk-console.c:683
+#: ../client/pk-console.c:806
 msgid "The following packages have to be removed"
 msgstr "Els següents paquets seran eliminats"
 
 #. get user input
-#: ../client/pk-console.c:692
+#: ../client/pk-console.c:815
 msgid "Okay to remove additional packages?"
 msgstr "Esteu d'acord en eliminar els paquets adicionals?"
 
-#: ../client/pk-console.c:696
+#: ../client/pk-console.c:819
 msgid "Cancelled!"
 msgstr "Cancel·lat"
 
-#: ../client/pk-console.c:718
+#: ../client/pk-console.c:844
 msgid "Could not find a package with that name to update"
 msgstr "No s'ha pogut trobar un paquet amb aquest nom per actualitzar"
 
-#: ../client/pk-console.c:736
+#: ../client/pk-console.c:862
 msgid "Could not find what packages require this package"
 msgstr "No s'han pogut trobar els paquets requerits per a aquest paquet"
 
-#: ../client/pk-console.c:754
+#: ../client/pk-console.c:880
 msgid "Could not get dependencies for this package"
 msgstr "No s'han pogut obtenir les dependències per a aquest paquet"
 
-#: ../client/pk-console.c:772
+#: ../client/pk-console.c:898
 msgid "Could not find details for this package"
 msgstr "No s'han pogut trobar els detalls per a aquest paquet"
 
-#: ../client/pk-console.c:790
+#: ../client/pk-console.c:916
 msgid "Could not find the files for this package"
 msgstr "No s'han pogut trobar els fitxers per a aquest paquet"
 
-#: ../client/pk-console.c:870
+#: ../client/pk-console.c:996
 msgid "Package description"
 msgstr "Descripció del paquet"
 
-#: ../client/pk-console.c:893
+#: ../client/pk-console.c:1019
 msgid "Package files"
 msgstr "Fitxers del paquet"
 
-#: ../client/pk-console.c:901
+#: ../client/pk-console.c:1027
 msgid "No files"
 msgstr "No hi ha fitxers"
 
 #. get user input
-#: ../client/pk-console.c:933
+#: ../client/pk-console.c:1059
 msgid "Okay to import key?"
 msgstr "Esteu d'acord en importar la clau?"
 
-#: ../client/pk-console.c:936
+#: ../client/pk-console.c:1062
 msgid "Did not import key"
 msgstr "No importis la clau"
 
 #. get user input
-#: ../client/pk-console.c:976
+#: ../client/pk-console.c:1102
 msgid "Do you agree?"
 msgstr "Esteu d'acord?"
 
-#: ../client/pk-console.c:979
+#: ../client/pk-console.c:1105
 msgid "Did not agree to licence, task will fail"
 msgstr "La llicència no ha estat acceptada, la tasca fallarà"
 
-#: ../client/pk-console.c:1008
+#: ../client/pk-console.c:1134
 msgid "The daemon crashed mid-transaction!"
 msgstr "El servei ha fallat a meitat de la transacció!"
 
 #. header
-#: ../client/pk-console.c:1061
+#: ../client/pk-console.c:1187
 msgid "PackageKit Console Interface"
 msgstr "Interfície de consola de PackageKit"
 
-#: ../client/pk-console.c:1061
+#: ../client/pk-console.c:1187
 msgid "Subcommands:"
 msgstr "Subordres:"
 
-#: ../client/pk-console.c:1165
+#: ../client/pk-console.c:1290
 #: ../client/pk-monitor.c:104
 #: ../src/pk-main.c:189
 msgid "Show extra debugging information"
 msgstr "Mostra la informació extra de la depuració"
 
-#: ../client/pk-console.c:1167
+#: ../client/pk-console.c:1292
 #: ../client/pk-monitor.c:106
 msgid "Show the program version and exit"
 msgstr "Mostra la versió del programa i surt"
 
-#: ../client/pk-console.c:1169
+#: ../client/pk-console.c:1294
 msgid "Set the filter, e.g. installed"
 msgstr "Defineix el filtre, p.ex. instal·lat"
 
-#: ../client/pk-console.c:1171
+#: ../client/pk-console.c:1296
 msgid "Exit without waiting for actions to complete"
 msgstr "Surt sense esperar que es completin les accions"
 
-#: ../client/pk-console.c:1194
+#: ../client/pk-console.c:1319
 msgid "Could not connect to system DBUS."
 msgstr "No s'ha pogut connectar al sistema DBUS."
 
-#: ../client/pk-console.c:1288
+#: ../client/pk-console.c:1413
 msgid "You need to specify a search type"
 msgstr "Cal que especifiqueu un tipus de cerca"
 
-#: ../client/pk-console.c:1293
-#: ../client/pk-console.c:1300
-#: ../client/pk-console.c:1307
-#: ../client/pk-console.c:1314
-#: ../client/pk-console.c:1421
-#: ../client/pk-console.c:1428
-#: ../client/pk-console.c:1435
-#: ../client/pk-console.c:1442
+#: ../client/pk-console.c:1418
+#: ../client/pk-console.c:1425
+#: ../client/pk-console.c:1432
+#: ../client/pk-console.c:1439
+#: ../client/pk-console.c:1538
+#: ../client/pk-console.c:1545
+#: ../client/pk-console.c:1552
+#: ../client/pk-console.c:1559
 msgid "You need to specify a search term"
 msgstr "Cal que especifiqueu un terme per a la cerca"
 
-#: ../client/pk-console.c:1319
+#: ../client/pk-console.c:1444
 msgid "Invalid search type"
 msgstr "El tipus de cerca no és vàlid"
 
-#: ../client/pk-console.c:1324
+#: ../client/pk-console.c:1449
 msgid "You need to specify a package or file to install"
 msgstr "Cal que especifiqueu un paquet o un fitxer a instal·lar"
 
-#: ../client/pk-console.c:1339
+#: ../client/pk-console.c:1456
 msgid "You need to specify a type, key_id and package_id"
 msgstr "Cal que especifiqueu un tipus, un identificador de clau i un identificador de paquet"
 
-#: ../client/pk-console.c:1346
+#: ../client/pk-console.c:1463
 msgid "You need to specify a package to remove"
 msgstr "Cal que especifiqueu un paquet a eliminar"
 
-#: ../client/pk-console.c:1353
+#: ../client/pk-console.c:1470
 msgid "You need to specify a eula-id"
 msgstr "Cal que especifiqueu un identificador de EULA"
 
-#: ../client/pk-console.c:1369
+#: ../client/pk-console.c:1486
 msgid "You need to specify a package name to resolve"
 msgstr "Cal que especifiqueu un nom de paquet a resoldre"
 
-#: ../client/pk-console.c:1376
-#: ../client/pk-console.c:1383
+#: ../client/pk-console.c:1493
+#: ../client/pk-console.c:1500
 msgid "You need to specify a repo name"
 msgstr "Cal que especifiqueu un nom de repositori"
 
-#: ../client/pk-console.c:1390
+#: ../client/pk-console.c:1507
 msgid "You need to specify a repo name/parameter and value"
 msgstr "Cal que especifiqueu un nom / paràmetre de repositori i un valor"
 
-#: ../client/pk-console.c:1403
+#: ../client/pk-console.c:1520
 msgid "You need to specify a time term"
 msgstr "Cal que especifiqueu un valor per a l'hora"
 
-#: ../client/pk-console.c:1408
+#: ../client/pk-console.c:1525
 msgid "You need to specify a correct role"
 msgstr "Cal que especifiqueu un rol correcte"
 
-#: ../client/pk-console.c:1413
+#: ../client/pk-console.c:1530
 msgid "Failed to get last time"
 msgstr "S'ha produït un error en obtenir l'última hora"
 
-#: ../client/pk-console.c:1449
+#: ../client/pk-console.c:1566
 msgid "You need to specify a package to find the details for"
 msgstr "Cal que especifiqueu un paquet per cercar-ne els detalls"
 
-#: ../client/pk-console.c:1456
+#: ../client/pk-console.c:1573
 msgid "You need to specify a package to find the files for"
 msgstr "Cal que especifiqueu un paquet per cercar-ne fitxers"
 
-#: ../client/pk-console.c:1503
+#: ../client/pk-console.c:1622
 #, c-format
 msgid "Option '%s' not supported"
 msgstr "L'opció '%s' no està disponible"
 
-#: ../client/pk-console.c:1514
+#: ../client/pk-console.c:1633
 msgid "Command failed"
 msgstr "L'ordre ha fallat"
 
-#: ../client/pk-console.c:1518
+#: ../client/pk-console.c:1637
 msgid "You don't have the necessary privileges for this operation"
 msgstr "No teniu suficients privilegis per a aquesta operació"
 
-#: ../client/pk-monitor.c:117
-msgid "PackageKit Monitor"
-msgstr "Monitorització de Packagekit"
-
-#: ../client/pk-import-desktop.c:293
-#: ../client/pk-import-specspo.c:169
+#: ../client/pk-import-desktop.c:298
+#: ../client/pk-import-specspo.c:173
 #, c-format
 msgid "Could not open database: %s"
 msgstr "No s'ha pogut obrir la base de dades: %s"
 
-#: ../client/pk-import-desktop.c:294
-#: ../client/pk-import-specspo.c:170
+#: ../client/pk-import-desktop.c:299
+#: ../client/pk-import-specspo.c:174
 msgid "You probably need to run this program as the root user"
 msgstr "És probable que necessiteu executar aquesta aplicació com a administrador"
 
+#: ../client/pk-monitor.c:117
+msgid "PackageKit Monitor"
+msgstr "Monitorització de Packagekit"
+
+#: ../data/packagekit-catalog.xml.in.h:1
+msgid "PackageKit Catalog"
+msgstr "Catàleg del Packagekit"
+
 #: ../src/pk-main.c:83
 msgid "Startup failed due to security policies on this machine."
 msgstr "L'inici ha fallat a causa de les polítiques de seguretat d'aquesta màquina."
commit 6679c05980b5aec8ac8a6f6454c2bddce68c3c14
Author: Ken VanDine <ken at vandine.org>
Date:   Thu Jun 19 01:00:28 2008 -0400

    updated the get_details call to reflect the proper usage of the API

diff --git a/backends/conary/helpers/conaryBackend.py b/backends/conary/helpers/conaryBackend.py
index a612ebf..d6735cd 100644
--- a/backends/conary/helpers/conaryBackend.py
+++ b/backends/conary/helpers/conaryBackend.py
@@ -541,7 +541,7 @@ class PackageKitConaryBackend(PackageKitBaseBackend):
             categories = self._get_metadata(id, 'categories') or "unknown"
 
             # Package size goes here, but I don't know how to find that for conary packages.
-            self.details(shortDesc, id, categories, longDesc, url, 0)
+            self.details(id, None,  categories, longDesc, url, 0)
         else:
             self.error(ERROR_PACKAGE_NOT_FOUND,'Package was not found')
 
commit 7da4f057e44a6a7cfaa30122ef9cd2f8259d7ee0
Author: Valeriy Lyasotskiy <onestep at ukr.net>
Date:   Wed Jun 18 23:41:36 2008 +0300

    alpm: added backend_get_depends

diff --git a/backends/alpm/pk-backend-alpm.c b/backends/alpm/pk-backend-alpm.c
index a61672e..38e8e3e 100644
--- a/backends/alpm/pk-backend-alpm.c
+++ b/backends/alpm/pk-backend-alpm.c
@@ -67,7 +67,7 @@ package_source_free (PackageSource *source)
 }
 
 gchar *
-pkg_to_package_id_str (pmpkg_t *pkg, gchar *repo)
+pkg_to_package_id_str (pmpkg_t *pkg, const gchar *repo)
 {
 	gchar *arch = (gchar *) alpm_pkg_get_arch (pkg);
 	if (arch == NULL)
@@ -83,7 +83,7 @@ pkg_from_package_id_str (const gchar *package_id_str)
 
 	/* do all this fancy stuff */
 	pmdb_t *repo = NULL;
-	if (strcmp ("installed", pkg_id->data) == 0)
+	if (strcmp (ALPM_LOCAL_DB_ALIAS, pkg_id->data) == 0)
 		repo = alpm_option_get_localdb ();
 	else {
 		alpm_list_t *iterator;
@@ -889,12 +889,79 @@ backend_get_cancel (PkBackend *backend)
 }
 
 /**
+ * backend_get_depends:
+ */
+static void
+backend_get_depends (PkBackend *backend, PkFilterEnum filters, const gchar *package_id, gboolean recursive)
+{
+	pk_backend_set_status (backend, PK_STATUS_ENUM_QUERY);
+	pk_backend_set_allow_cancel (backend, FALSE);
+
+	pmpkg_t *pkg = pkg_from_package_id_str (package_id);
+	if (pkg == NULL) {
+		pk_backend_error_code (backend, PK_ERROR_ENUM_REPO_NOT_FOUND, alpm_strerrorlast ());
+		pk_backend_finished (backend);
+		return;
+	}
+
+	pk_debug ("alpm: filters is: %i", filters);
+
+	alpm_list_t *iterator;
+	for (iterator = alpm_pkg_get_depends (pkg); iterator; iterator = alpm_list_next (iterator)) {
+		pmdepend_t *dep = alpm_list_getdata (iterator);
+		pmpkg_t *dep_pkg;
+		gboolean found = FALSE;
+
+		if (!pk_enums_contain (filters, PK_FILTER_ENUM_INSTALLED)) {
+			/* search in sync dbs */
+			alpm_list_t *db_iterator;
+			for (db_iterator = alpm_option_get_syncdbs (); found == FALSE && db_iterator; db_iterator = alpm_list_next (db_iterator)) {
+				pmdb_t *syncdb = alpm_list_getdata (db_iterator);
+
+				pk_debug ("alpm: searching for %s in %s", alpm_dep_get_name (dep), alpm_db_get_name (syncdb));
+
+				dep_pkg = alpm_db_get_pkg (syncdb, alpm_dep_get_name (dep));
+				if (dep_pkg && alpm_depcmp (dep_pkg, dep)) {
+					found = TRUE;
+					gchar *dep_package_id_str = pkg_to_package_id_str (dep_pkg, alpm_db_get_name (syncdb));
+					pk_backend_package (backend, PK_INFO_ENUM_AVAILABLE, dep_package_id_str, alpm_pkg_get_desc (dep_pkg));
+					g_free (dep_package_id_str);
+				}
+			}
+		}
+
+		if (!pk_enums_contain (filters, PK_FILTER_ENUM_NOT_INSTALLED)) {
+			pk_debug ("alpm: searching for %s in local db", alpm_dep_get_name (dep));
+
+			/* search in local db */
+			dep_pkg = alpm_db_get_pkg (alpm_option_get_localdb (), alpm_dep_get_name (dep));
+			if (dep_pkg && alpm_depcmp (dep_pkg, dep)) {
+				found = TRUE;
+				gchar *dep_package_id_str = pkg_to_package_id_str (dep_pkg, ALPM_LOCAL_DB_ALIAS);
+				pk_backend_package (backend, PK_INFO_ENUM_INSTALLED, dep_package_id_str, alpm_pkg_get_desc (dep_pkg));
+				g_free (dep_package_id_str);
+			}
+		}
+
+		if (found == FALSE) {
+			pk_backend_error_code (backend, PK_ERROR_ENUM_REPO_NOT_FOUND, alpm_strerrorlast ());
+			pk_backend_finished (backend);
+			return;
+		}
+	}
+
+	pk_backend_finished (backend);
+}
+
+/**
  * backend_get_details:
  */
 static void
 backend_get_details (PkBackend *backend, const gchar *package_id)
 {
 	pk_backend_set_status (backend, PK_STATUS_ENUM_QUERY);
+	pk_backend_set_allow_cancel (backend, FALSE);
+
 	pmpkg_t *pkg = pkg_from_package_id_str (package_id);
 	if (pkg == NULL) {
 		pk_backend_error_code (backend, PK_ERROR_ENUM_REPO_NOT_FOUND, alpm_strerrorlast ());
@@ -918,6 +985,7 @@ backend_get_details (PkBackend *backend, const gchar *package_id)
 	gchar *licenses = g_string_free (licenses_str, FALSE);
 
 	pk_backend_details (backend, package_id, licenses, PK_GROUP_ENUM_OTHER, alpm_pkg_get_desc (pkg), alpm_pkg_get_url(pkg), alpm_pkg_get_size (pkg));
+	g_free (licenses);
 	pk_backend_finished (backend);
 }
 
@@ -928,6 +996,8 @@ static void
 backend_get_files (PkBackend *backend, const gchar *package_id)
 {
 	pk_backend_set_status (backend, PK_STATUS_ENUM_QUERY);
+	pk_backend_set_allow_cancel (backend, FALSE);
+
 	pmpkg_t *pkg = pkg_from_package_id_str (package_id);
 	if (pkg == NULL) {
 		pk_backend_error_code (backend, PK_ERROR_ENUM_REPO_NOT_FOUND, alpm_strerrorlast ());
@@ -1426,7 +1496,7 @@ PK_BACKEND_OPTIONS (
 		backend_get_groups,				/* get_groups */
 		backend_get_filters,				/* get_filters */
 		backend_get_cancel,				/* cancel */
-		NULL,						/* get_depends */
+		backend_get_depends,				/* get_depends */
 		backend_get_details,				/* get_details */
 		backend_get_files,				/* get_files */
 		backend_get_packages,				/* get_packages */
commit 772f0c95493a22d58a20dc14076d3f1f0c1b39af
Author: Richard Hughes <richard at hughsie.com>
Date:   Tue Jun 17 14:00:11 2008 +0100

    Add a note in the docs about InstallFont

diff --git a/docs/html/pk-faq.html b/docs/html/pk-faq.html
index 888d150..20e2151 100644
--- a/docs/html/pk-faq.html
+++ b/docs/html/pk-faq.html
@@ -278,6 +278,7 @@ The methods available on this interface are:
 <li><code>InstallProvideFile("/usr/share/fonts/sarai/Sarai_07.ttf")</code></li>
 <li><code>InstallLocalFile("/home/dave/Desktop/lirc-0.6.6-4.rhfc1.dag.i686.rpm")</code></li>
 <li><code>InstallMimeType("application/x-rpm")</code></li>
+<li><code>InstallFont("lang(en_GB)")</code></li>
 </ul>
 <p>
 Please email me or the
commit e6f3629dc2a6ef9639dac197089d550b3b17b8ab
Author: Richard Hughes <richard at hughsie.com>
Date:   Tue Jun 17 13:54:47 2008 +0100

    Add another provide enum, PK_PROVIDES_ENUM_FONT

diff --git a/libpackagekit/pk-enum.c b/libpackagekit/pk-enum.c
index 55a15a2..6a79fbb 100644
--- a/libpackagekit/pk-enum.c
+++ b/libpackagekit/pk-enum.c
@@ -282,6 +282,7 @@ static PkEnumMatch enum_provides[] = {
 	{PK_PROVIDES_ENUM_MODALIAS,		"modalias"},
 	{PK_PROVIDES_ENUM_CODEC,		"codec"},
 	{PK_PROVIDES_ENUM_MIMETYPE,		"mimetype"},
+	{PK_PROVIDES_ENUM_FONT,			"font"},
 	{0, NULL}
 };
 
diff --git a/libpackagekit/pk-enum.h b/libpackagekit/pk-enum.h
index cc7cd7b..9481d44 100644
--- a/libpackagekit/pk-enum.h
+++ b/libpackagekit/pk-enum.h
@@ -368,6 +368,7 @@ typedef enum {
 	PK_PROVIDES_ENUM_MODALIAS,
 	PK_PROVIDES_ENUM_CODEC,
 	PK_PROVIDES_ENUM_MIMETYPE,
+	PK_PROVIDES_ENUM_FONT,
 	PK_PROVIDES_ENUM_UNKNOWN
 } PkProvidesEnum;
 


More information about the PackageKit-commit mailing list