rpms/PackageKit/devel PackageKit-0.4.5-allow-disable-icon-cache.patch, NONE, 1.1 PackageKit-0.4.5-filter-dup-updates.patch, NONE, 1.1 PackageKit.spec, 1.94, 1.95

Richard Hughes rhughes at fedoraproject.org
Mon Mar 16 15:32:27 UTC 2009


Author: rhughes

Update of /cvs/pkgs/rpms/PackageKit/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv30090

Modified Files:
	PackageKit.spec 
Added Files:
	PackageKit-0.4.5-allow-disable-icon-cache.patch 
	PackageKit-0.4.5-filter-dup-updates.patch 
Log Message:
* Mon Mar 16 2009 Richard Hughes  <rhughes at redhat.com> - 0.4.5-2
- Add two patches from upstream:
 - Allow users to turn off update cache to try to debug #20559
 - Filter out duplicate updates to fix #488509


PackageKit-0.4.5-allow-disable-icon-cache.patch:

--- NEW FILE PackageKit-0.4.5-allow-disable-icon-cache.patch ---
commit f5af9b0477899e2c246ca8ff8fe5b42ba02e8009
Author: Richard Hughes <richard at hughsie.com>
Date:   Mon Mar 16 15:16:43 2009 +0000

    feature: add a UseUpdateCache config variable to be able to turn off the updates cache for debugging

diff --git a/etc/PackageKit.conf.in b/etc/PackageKit.conf.in
index bc0bea2..c2f1303 100644
--- a/etc/PackageKit.conf.in
+++ b/etc/PackageKit.conf.in
@@ -104,3 +104,11 @@ UpdateCheckProcesses=true
 # default=true
 CheckTestingRepos=true
 
+# Use update cache when possible to avoid using the backend
+#
+# NOTE: Don't disable this unless you're trying to find bugs in packagekitd
+# and you want your backend to service every request.
+#
+# default=true
+UseUpdateCache=true
+
diff --git a/src/pk-transaction.c b/src/pk-transaction.c
index 89f4c04..be79ae4 100644
--- a/src/pk-transaction.c
+++ b/src/pk-transaction.c
@@ -2497,7 +2497,8 @@ pk_transaction_get_updates (PkTransaction *transaction, const gchar *filter, DBu
 
 	/* try and reuse cache */
 	updates_cache = pk_cache_get_updates (transaction->priv->cache);
-	if (updates_cache != NULL) {
+	ret = pk_conf_get_bool (transaction->priv->conf, "UseUpdateCache");
+	if (ret && updates_cache != NULL) {
 		const PkPackageObj *obj;
 		const gchar *info_text;
 		guint i;

PackageKit-0.4.5-filter-dup-updates.patch:

--- NEW FILE PackageKit-0.4.5-filter-dup-updates.patch ---
commit 7b13b2aa13fbb2d374a895a895025441a387e600
Author: Richard Hughes <richard at hughsie.com>
Date:   Mon Mar 9 11:57:57 2009 +0000

    yum: don't output duplicated updates. Fixes rh#488509

diff --git a/backends/yum/yumBackend.py b/backends/yum/yumBackend.py
index e33779f..9b47614 100755
--- a/backends/yum/yumBackend.py
+++ b/backends/yum/yumBackend.py
@@ -2157,7 +2157,7 @@ class PackageKitYumBackend(PackageKitBaseBackend, PackagekitPackage):
         except Exception, e:
             self.error(ERROR_INTERNAL_ERROR, _format_str(traceback.format_exc()))
         md = self.updateMetadata
-        for pkg in pkgs:
+        for pkg in unique(pkgs):
             if pkgfilter.pre_process(pkg):
                 # Get info about package in updates info
                 notice = md.get_notice((pkg.name, pkg.version, pkg.release))


Index: PackageKit.spec
===================================================================
RCS file: /cvs/pkgs/rpms/PackageKit/devel/PackageKit.spec,v
retrieving revision 1.94
retrieving revision 1.95
diff -u -r1.94 -r1.95
--- PackageKit.spec	9 Mar 2009 10:19:56 -0000	1.94
+++ PackageKit.spec	16 Mar 2009 15:31:57 -0000	1.95
@@ -8,7 +8,7 @@
 Summary:   Package management service
 Name:      PackageKit
 Version:   0.4.5
-Release:   1%{?dist}
+Release:   2%{?dist}
 License:   GPLv2+
 Group:     System Environment/Libraries
 URL:       http://www.packagekit.org
@@ -19,6 +19,8 @@
 # Set Vendor.conf up for Fedora.
 Patch0:    PackageKit-0.3.8-Fedora-Vendor.conf.patch
 Patch1:    PackageKit-0.4.4-Fedora-turn-off-time.conf.patch
+Patch2:    PackageKit-0.4.5-allow-disable-icon-cache.patch
+Patch3:    PackageKit-0.4.5-filter-dup-updates.patch
 
 Requires: dbus >= %{dbus_version}
 Requires: dbus-glib >= %{dbus_glib_version}
@@ -219,6 +221,8 @@
 %setup -q
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
+%patch3 -p1
 
 %build
 %configure --enable-yum --enable-smart --with-default-backend=yum --disable-local --disable-ruck
@@ -413,6 +417,11 @@
 %{_includedir}/PackageKit/backend/*.h
 
 %changelog
+* Mon Mar 16 2009 Richard Hughes  <rhughes at redhat.com> - 0.4.5-2
+- Add two patches from upstream:
+ - Allow users to turn off update cache to try to debug #20559
+ - Filter out duplicate updates to fix #488509
+
 * Mon Mar 09 2009 Richard Hughes  <rhughes at redhat.com> - 0.4.5-1
 - New upstream version
 - Add proper error handling to avoid exiting the script on correctable errors




More information about the fedora-extras-commits mailing list