[jhbuild] Support PackageKit 1.0
- From: Kalev Lember <klember src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [jhbuild] Support PackageKit 1.0
- Date: Sat, 27 Sep 2014 14:34:50 +0000 (UTC)
commit 57409a4229b32043e2cb08b1d2412d4b1f8fb5b7
Author: Kalev Lember <kalevlember gmail com>
Date: Sat Sep 27 16:27:10 2014 +0200
Support PackageKit 1.0
https://bugzilla.gnome.org/show_bug.cgi?id=737481
jhbuild/utils/systeminstall.py | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/jhbuild/utils/systeminstall.py b/jhbuild/utils/systeminstall.py
index be36db8..a526e6a 100644
--- a/jhbuild/utils/systeminstall.py
+++ b/jhbuild/utils/systeminstall.py
@@ -189,7 +189,7 @@ class PKSystemInstall(SystemInstall):
properties = dbus.Interface(self._pkdbus, 'org.freedesktop.DBus.Properties')
self._pk_major = properties.Get('org.freedesktop.PackageKit', 'VersionMajor')
self._pk_minor = properties.Get('org.freedesktop.PackageKit', 'VersionMinor')
- if self._pk_major == 0 and self._pk_minor >= 8:
+ if self._pk_major == 1 or (self._pk_major == 0 and self._pk_minor >= 8):
txn_path = self._pkdbus.CreateTransaction()
txn = self._sysbus.get_object('org.freedesktop.PackageKit', txn_path)
else:
@@ -207,8 +207,8 @@ class PKSystemInstall(SystemInstall):
if uninstalled_pkgconfigs:
txn_tx, txn = self._get_new_transaction()
txn.connect_to_signal('Package', lambda info, pkid, summary: pk_package_ids.add(pkid))
- if self._pk_major == 0 and self._pk_minor >= 9:
- # PackageKit 0.9.x
+ if self._pk_major == 1 or (self._pk_major == 0 and self._pk_minor >= 9):
+ # PackageKit 1.0.x or 0.9.x
txn_tx.WhatProvides(PK_FILTER_ENUM_ARCH | PK_FILTER_ENUM_NEWEST |
PK_FILTER_ENUM_NOT_INSTALLED,
['pkgconfig(%s)' % pkg for modname, pkg in
@@ -231,7 +231,7 @@ class PKSystemInstall(SystemInstall):
if uninstalled_filenames:
txn_tx, txn = self._get_new_transaction()
txn.connect_to_signal('Package', lambda info, pkid, summary: pk_package_ids.add(pkid))
- if self._pk_major == 0 and self._pk_minor >= 8:
+ if self._pk_major == 1 or (self._pk_major == 0 and self._pk_minor >= 8):
txn_tx.SearchFiles(PK_FILTER_ENUM_ARCH | PK_FILTER_ENUM_NEWEST |
PK_FILTER_ENUM_NOT_INSTALLED,
[pkg for modname, pkg in
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]