- New upstream version

- Also add two upstream patches to fix pkcon issues.
This commit is contained in:
Richard Hughes 2008-08-27 13:12:35 +00:00
parent 32a4dec7a7
commit 30d707f66f
6 changed files with 142 additions and 56 deletions

View File

@ -1 +1 @@
PackageKit-0.3.0.tar.gz
PackageKit-0.3.1.tar.gz

View File

@ -7,24 +7,27 @@
Summary: System daemon that is a DBUS abstraction layer for package management
Name: PackageKit
Version: 0.3.0
Release: 2%{?dist}
Version: 0.3.1
Release: 1%{?dist}
License: GPLv2+
Group: System Environment/Libraries
URL: http://packagekit.freedesktop.org
Source0: http://www.packagekit.org/releases/%{name}-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
#upstream, 771d297a4e6e551a7c559c7eb6b77e54f7d62c37
Patch0: pk-fix-build-plugin.patch
# upstream, c71eaadafd4115f0d8cf1c39c882f678ce1f004a
Patch0: pk-fix-pkcon-filters.patch
# upstream, 962d677afcd9a9cfed9f08b4c862b7e3bb175a8c
Patch1: pk-fix-multiarch-resolve.patch
Requires: dbus >= %{dbus_version}
Requires: dbus-glib >= %{dbus_glib_version}
Requires: PackageKit-libs = %{version}-%{release}
Requires: yum-packagekit = %{version}-%{release}
Requires: yum >= 3.2.6
Requires: libtar-devel
Requires: libarchive
Requires: shared-mime-info
Requires: python-sqlite2
BuildRequires: glib2-devel >= %{glib2_version}
BuildRequires: dbus-devel >= %{dbus_version}
@ -44,7 +47,7 @@ BuildRequires: perl(XML::Parser)
BuildRequires: intltool
BuildRequires: gettext
BuildRequires: xulrunner-devel
BuildRequires: libtar-devel
BuildRequires: libarchive-devel
%description
PackageKit is a D-Bus abstraction layer that allows the session user
@ -116,6 +119,7 @@ using PackageKit.
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%build
%configure --enable-yum --enable-yum2 --with-default-backend=yum --disable-local
@ -220,6 +224,10 @@ update-mime-database %{_datadir}/mime &> /dev/null || :
%{_includedir}/*
%changelog
* Wed Aug 27 2008 Richard Hughes <rhughes@redhat.com> - 0.3.1-1
- New upstream version
- Also add two upstream patches to fix pkcon issues.
* Mon Aug 22 2008 Richard Hughes <rhughes@redhat.com> - 0.3.0-2
- Bump as the make tag step failed in an obscure way.

View File

@ -1,48 +0,0 @@
commit 771d297a4e6e551a7c559c7eb6b77e54f7d62c37
Author: Richard Hughes <hughsie@localhost.localdomain>
Date: Tue Aug 19 22:04:32 2008 +0100
bugfix: fix compiling the browser plugins where HAVE_GDK_APP_LAUNCH_CONTEXT_NEW is defined -- re-apply as I think git got itself in a tizz (trivial)
diff --git a/contrib/packagekit-plugin/src/contents.cpp b/contrib/packagekit-plugin/src/contents.cpp
index 9d51ac9..3be68fb 100644
--- a/contrib/packagekit-plugin/src/contents.cpp
+++ b/contrib/packagekit-plugin/src/contents.cpp
@@ -598,6 +598,9 @@ void
PkpContents::runApplication (Time time)
{
GError *error = NULL;
+#ifdef HAVE_GDK_APP_LAUNCH_CONTEXT_NEW
+ GdkAppLaunchContext *context;
+#endif
if (mAppInfo == 0) {
g_warning("Didn't find application to launch");
@@ -607,20 +610,22 @@ PkpContents::runApplication (Time time)
if (time == 0)
time = get_server_timestamp();
- GAppLaunchContext *context = 0;
#ifdef HAVE_GDK_APP_LAUNCH_CONTEXT_NEW
context = gdk_app_launch_context_new();
- gdk_app_launch_context_set_timestamp(time);
+ gdk_app_launch_context_set_timestamp(context, time);
+ if (!g_app_info_launch(mAppInfo, NULL, G_APP_LAUNCH_CONTEXT (context), &error)) {
+#else
+ if (!g_app_info_launch(mAppInfo, NULL, NULL, &error)) {
#endif
-
- if (!g_app_info_launch(mAppInfo, NULL, context, &error)) {
g_warning("%s\n", error->message);
g_clear_error(&error);
return;
}
- if (context != 0)
+#ifdef HAVE_GDK_APP_LAUNCH_CONTEXT_NEW
+ if (context != NULL)
g_object_unref(context);
+#endif
}
void

View File

@ -0,0 +1,18 @@
commit 962d677afcd9a9cfed9f08b4c862b7e3bb175a8c
Author: Richard Hughes <hughsie@localhost.localdomain>
Date: Wed Aug 27 13:36:37 2008 +0100
yum: don't always prefer the first package returned from returnNewestByNameArch() as this will be i386 on x64, and hence the wrong thing will be installed on multiarch
diff --git a/backends/yum/helpers/yumBackend.py b/backends/yum/helpers/yumBackend.py
index 4e3926f..3dd2b2f 100644
--- a/backends/yum/helpers/yumBackend.py
+++ b/backends/yum/helpers/yumBackend.py
@@ -814,7 +814,6 @@ class PackageKitYumBackend(PackageKitBaseBackend):
show = False
if show:
self._show_package(pkg,INFO_AVAILABLE)
- break
@handle_repo_error
def install_packages(self,package_ids):

108
pk-fix-pkcon-filters.patch Normal file
View File

@ -0,0 +1,108 @@
commit c71eaadafd4115f0d8cf1c39c882f678ce1f004a
Author: Richard Hughes <hughsie@localhost.localdomain>
Date: Wed Aug 27 13:28:43 2008 +0100
bugfix: fix pkcon to treat the filters as bitfields, not enums
diff --git a/client/pk-console.c b/client/pk-console.c
index 91cee17..2bb8bf2 100644
--- a/client/pk-console.c
+++ b/client/pk-console.c
@@ -506,6 +506,7 @@ pk_console_perhaps_resolve (PkClient *client, PkBitfield filter, const gchar *pa
/* we need to resolve it */
packages = pk_package_ids_from_id (package);
+
ret = pk_client_resolve (client_task, filter, packages, error);
g_strfreev (packages);
if (!ret) {
@@ -585,7 +586,7 @@ pk_console_install_stuff (PkClient *client, gchar **packages, GError **error)
if (is_local) {
g_ptr_array_add (array_files, g_strdup (packages[i]));
} else {
- package_id = pk_console_perhaps_resolve (client, PK_FILTER_ENUM_NOT_INSTALLED, packages[i], error);
+ package_id = pk_console_perhaps_resolve (client, pk_bitfield_value (PK_FILTER_ENUM_NOT_INSTALLED), packages[i], error);
if (package_id == NULL) {
*error = g_error_new (1, 0, "%s: %s", _("Could not find package to install"), packages[i]);
ret = FALSE;
@@ -691,7 +692,7 @@ pk_console_remove_packages (PkClient *client, gchar **packages, GError **error)
list = pk_package_list_new ();
length = g_strv_length (packages);
for (i=2; i<length; i++) {
- package_id = pk_console_perhaps_resolve (client, PK_FILTER_ENUM_INSTALLED, packages[i], error);
+ package_id = pk_console_perhaps_resolve (client, pk_bitfield_value (PK_FILTER_ENUM_INSTALLED), packages[i], error);
if (package_id == NULL) {
*error = g_error_new (1, 0, "%s:%s\n", _("Could not find package to remove"), packages[i]);
ret = FALSE;
@@ -725,7 +726,7 @@ pk_console_remove_packages (PkClient *client, gchar **packages, GError **error)
pk_debug ("Getting installed requires for %s", package_ids[0]);
/* see if any packages require this one */
- ret = pk_client_get_requires (client_task, PK_FILTER_ENUM_INSTALLED, package_ids, TRUE, error);
+ ret = pk_client_get_requires (client_task, pk_bitfield_value (PK_FILTER_ENUM_INSTALLED), package_ids, TRUE, error);
if (!ret) {
pk_warning ("failed to get requires");
goto out;
@@ -797,7 +798,7 @@ pk_console_download_packages (PkClient *client, gchar **packages, const gchar *d
array_packages = g_ptr_array_new ();
length = g_strv_length (packages);
for (i=3; i<length; i++) {
- package_id = pk_console_perhaps_resolve (client, PK_FILTER_ENUM_NONE, packages[i], error);
+ package_id = pk_console_perhaps_resolve (client, pk_bitfield_value (PK_FILTER_ENUM_NONE), packages[i], error);
if (package_id == NULL) {
*error = g_error_new (1, 0, "%s: %s", _("Could not find package to download"), packages[i]);
ret = FALSE;
@@ -848,7 +849,7 @@ pk_console_update_package (PkClient *client, const gchar *package, GError **erro
gchar *package_id;
gchar **package_ids;
- package_id = pk_console_perhaps_resolve (client, PK_FILTER_ENUM_INSTALLED, package, error);
+ package_id = pk_console_perhaps_resolve (client, pk_bitfield_value (PK_FILTER_ENUM_INSTALLED), package, error);
if (package_id == NULL) {
*error = g_error_new (1, 0, "%s: %s", _("Could not find package to update"), package);
return FALSE;
@@ -870,7 +871,7 @@ pk_console_get_requires (PkClient *client, PkBitfield filters, const gchar *pack
gboolean ret;
gchar *package_id;
gchar **package_ids;
- package_id = pk_console_perhaps_resolve (client, PK_FILTER_ENUM_NONE, package, error);
+ package_id = pk_console_perhaps_resolve (client, pk_bitfield_value (PK_FILTER_ENUM_NONE), package, error);
if (package_id == NULL) {
*error = g_error_new (1, 0, "%s %s", _("Could not find what packages require"), package);
return FALSE;
@@ -891,7 +892,7 @@ pk_console_get_depends (PkClient *client, PkBitfield filters, const gchar *packa
gboolean ret;
gchar *package_id;
gchar **package_ids;
- package_id = pk_console_perhaps_resolve (client, PK_FILTER_ENUM_NONE, package, error);
+ package_id = pk_console_perhaps_resolve (client, pk_bitfield_value (PK_FILTER_ENUM_NONE), package, error);
if (package_id == NULL) {
*error = g_error_new (1, 0, "%s %s", _("Could not get dependencies for"), package);
return FALSE;
@@ -912,7 +913,7 @@ pk_console_get_details (PkClient *client, const gchar *package, GError **error)
gboolean ret;
gchar *package_id;
gchar **package_ids;
- package_id = pk_console_perhaps_resolve (client, PK_FILTER_ENUM_NONE, package, error);
+ package_id = pk_console_perhaps_resolve (client, pk_bitfield_value (PK_FILTER_ENUM_NONE), package, error);
if (package_id == NULL) {
*error = g_error_new (1, 0, "%s %s", _("Could not find details for"), package);
return FALSE;
@@ -935,7 +936,7 @@ pk_console_get_files (PkClient *client, const gchar *package, GError **error)
gchar **package_ids;
GError *error_local = NULL;
- package_id = pk_console_perhaps_resolve (client, PK_FILTER_ENUM_NONE, package, &error_local);
+ package_id = pk_console_perhaps_resolve (client, pk_bitfield_value (PK_FILTER_ENUM_NONE), package, &error_local);
if (package_id == NULL) {
*error = g_error_new (1, 0, "%s (%s)", _("Could not find the files for this package"), error_local->message);
g_error_free (error_local);
@@ -961,7 +962,7 @@ pk_console_get_update_detail (PkClient *client, const gchar *package, GError **e
gboolean ret;
gchar *package_id;
gchar **package_ids;
- package_id = pk_console_perhaps_resolve (client, PK_FILTER_ENUM_INSTALLED, package, error);
+ package_id = pk_console_perhaps_resolve (client, pk_bitfield_value (PK_FILTER_ENUM_INSTALLED), package, error);
if (package_id == NULL) {
*error = g_error_new (1, 0, "%s %s", _("Could not find the update details for"), package);
return FALSE;

View File

@ -1 +1 @@
26c092d1ebbce4e9f772085d2aa81bbb PackageKit-0.3.0.tar.gz
e7586a3560e76966d2968946fbe7f846 PackageKit-0.3.1.tar.gz