Accepting request 54920 from home:FunkyPenguin:branches:GNOME:Factory

thanks

OBS-URL: https://build.opensuse.org/request/show/54920
OBS-URL: https://build.opensuse.org/package/show/GNOME:Factory/glib2?expand=0&rev=118
This commit is contained in:
Vincent Untz 2010-12-07 10:18:50 +00:00 committed by Git OBS Bridge
parent 10d1adf8ef
commit 4706401810
5 changed files with 28 additions and 184 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:c44177b635e88639361eb1daf7aaa33315a00aaf46db5accf2f11920c7ff1919
size 6780936

3
glib-2.27.4.tar.bz2 Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:71367cbf45998f736d7998282bc62fdefe13544a2c8ca523d9e5e9cc212758e6
size 6876218

View File

@ -1,177 +0,0 @@
From fb94859e84c0b7859a0a5425d461b18e67ea9ac7 Mon Sep 17 00:00:00 2001
From: Benjamin Otte <otte@redhat.com>
Date: Tue, 09 Nov 2010 12:19:19 +0000
Subject: API: Reinstate "gio-desktop-app-info-lookup" extension point
Removing an extension point is an API and ABI break. In particular, it
causes (older) gvfs versions to fail loading with a linkage error from
ld which in turn makes the desktop unusable.
So this reinstate the extension point and API provided by it, but
deprecates and does not use it. So no functionality is changed.
This reverts parts of commit 9b262f1c5fe5a6fd879f17cd7b80d8c54e33d80c.
Complaints-Also-To: Ryan Lortie <desrt@desrt.ca>
---
diff --git a/gio/gdesktopappinfo.c b/gio/gdesktopappinfo.c
index 8047d9c..99a6fb7 100644
--- a/gio/gdesktopappinfo.c
+++ b/gio/gdesktopappinfo.c
@@ -32,6 +32,8 @@
#include <crt_externs.h>
#endif
+#undef G_DISABLE_DEPRECATED
+
#include "gcontenttypeprivate.h"
#include "gdesktopappinfo.h"
#include "gfile.h"
@@ -2638,3 +2640,43 @@ get_all_desktop_entries_for_mime_type (const char *base_mime_type,
return desktop_entries;
}
+/* GDesktopAppInfoLookup interface: */
+
+typedef GDesktopAppInfoLookupIface GDesktopAppInfoLookupInterface;
+G_DEFINE_INTERFACE (GDesktopAppInfoLookup, g_desktop_app_info_lookup, G_TYPE_OBJECT)
+
+static void
+g_desktop_app_info_lookup_default_init (GDesktopAppInfoLookupInterface *iface)
+{
+}
+
+/**
+ * g_desktop_app_info_lookup_get_default_for_uri_scheme:
+ * @lookup: a #GDesktopAppInfoLookup
+ * @uri_scheme: a string containing a URI scheme.
+ *
+ * Gets the default application for launching applications
+ * using this URI scheme for a particular GDesktopAppInfoLookup
+ * implementation.
+ *
+ * The GDesktopAppInfoLookup interface and this function is used
+ * to implement g_app_info_get_default_for_uri_scheme() backends
+ * in a GIO module. There is no reason for applications to use it
+ * directly. Applications should use g_app_info_get_default_for_uri_scheme().
+ *
+ * Returns: (transfer full): #GAppInfo for given @uri_scheme or %NULL on error.
+ *
+ * Deprecated: The #GDesktopAppInfoLookup interface is deprecated and unused by gio.
+ */
+GAppInfo *
+g_desktop_app_info_lookup_get_default_for_uri_scheme (GDesktopAppInfoLookup *lookup,
+ const char *uri_scheme)
+{
+ GDesktopAppInfoLookupIface *iface;
+
+ g_return_val_if_fail (G_IS_DESKTOP_APP_INFO_LOOKUP (lookup), NULL);
+
+ iface = G_DESKTOP_APP_INFO_LOOKUP_GET_IFACE (lookup);
+
+ return (* iface->get_default_for_uri_scheme) (lookup, uri_scheme);
+}
diff --git a/gio/gdesktopappinfo.h b/gio/gdesktopappinfo.h
index d7703f7..6be9369 100644
--- a/gio/gdesktopappinfo.h
+++ b/gio/gdesktopappinfo.h
@@ -55,6 +55,46 @@ gboolean g_desktop_app_info_get_is_hidden (GDesktopAppInfo *info);
void g_desktop_app_info_set_desktop_env (const char *desktop_env);
+
+#ifndef G_DISABLE_DEPRECATED
+
+#define G_TYPE_DESKTOP_APP_INFO_LOOKUP (g_desktop_app_info_lookup_get_type ())
+#define G_DESKTOP_APP_INFO_LOOKUP(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), G_TYPE_DESKTOP_APP_INFO_LOOKUP, GDesktopAppInfoLookup))
+#define G_IS_DESKTOP_APP_INFO_LOOKUP(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), G_TYPE_DESKTOP_APP_INFO_LOOKUP))
+#define G_DESKTOP_APP_INFO_LOOKUP_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), G_TYPE_DESKTOP_APP_INFO_LOOKUP, GDesktopAppInfoLookupIface))
+
+/**
+ * G_DESKTOP_APP_INFO_LOOKUP_EXTENSION_POINT_NAME:
+ *
+ * Extension point for default handler to URI association. See
+ * <link linkend="extending-gio">Extending GIO</link>.
+ */
+#define G_DESKTOP_APP_INFO_LOOKUP_EXTENSION_POINT_NAME "gio-desktop-app-info-lookup"
+
+/**
+ * GDesktopAppInfoLookup:
+ *
+ * Interface that is used by backends to associate default
+ * handlers with URI schemes.
+ */
+typedef struct _GDesktopAppInfoLookup GDesktopAppInfoLookup;
+typedef struct _GDesktopAppInfoLookupIface GDesktopAppInfoLookupIface;
+
+struct _GDesktopAppInfoLookupIface
+{
+ GTypeInterface g_iface;
+
+ GAppInfo * (* get_default_for_uri_scheme) (GDesktopAppInfoLookup *lookup,
+ const char *uri_scheme);
+};
+
+GType g_desktop_app_info_lookup_get_type (void) G_GNUC_CONST;
+
+GAppInfo *g_desktop_app_info_lookup_get_default_for_uri_scheme (GDesktopAppInfoLookup *lookup,
+ const char *uri_scheme);
+
+#endif /* G_DISABLE_DEPRECATED */
+
G_END_DECLS
#endif /* __G_DESKTOP_APP_INFO_H__ */
diff --git a/gio/gio.symbols b/gio/gio.symbols
index eb79b70..90ea290 100644
--- a/gio/gio.symbols
+++ b/gio/gio.symbols
@@ -131,6 +131,8 @@ g_desktop_app_info_get_filename
g_desktop_app_info_get_type G_GNUC_CONST
g_desktop_app_info_get_is_hidden
g_desktop_app_info_set_desktop_env
+g_desktop_app_info_lookup_get_type G_GNUC_CONST
+g_desktop_app_info_lookup_get_default_for_uri_scheme
#endif
#endif
#endif
diff --git a/gio/giomodule.c b/gio/giomodule.c
index 86bf25e..d131893 100644
--- a/gio/giomodule.c
+++ b/gio/giomodule.c
@@ -36,14 +36,17 @@
#include "gsocks4aproxy.h"
#include "gsocks5proxy.h"
#include "gvfs.h"
-#ifdef G_OS_UNIX
-#include "gdesktopappinfo.h"
-#endif
#ifdef G_OS_WIN32
#include "gregistrysettingsbackend.h"
#endif
#include <glib/gstdio.h>
+#undef G_DISABLE_DEPRECATED
+
+#ifdef G_OS_UNIX
+#include "gdesktopappinfo.h"
+#endif
+
/**
* SECTION:giomodule
* @short_description: Loadable GIO Modules
@@ -523,6 +526,13 @@ _g_io_modules_ensure_extension_points_registered (void)
{
registered_extensions = TRUE;
+#ifdef G_OS_UNIX
+#if !GLIB_CHECK_VERSION (3, 0, 0)
+ ep = g_io_extension_point_register (G_DESKTOP_APP_INFO_LOOKUP_EXTENSION_POINT_NAME);
+ g_io_extension_point_set_required_type (ep, G_TYPE_DESKTOP_APP_INFO_LOOKUP);
+#endif
+#endif
+
ep = g_io_extension_point_register (G_LOCAL_DIRECTORY_MONITOR_EXTENSION_POINT_NAME);
g_io_extension_point_set_required_type (ep, G_TYPE_LOCAL_DIRECTORY_MONITOR);
--
cgit v0.8.3.1

View File

@ -1,3 +1,27 @@
-------------------------------------------------------------------
Mon Dec 6 21:03:22 UTC 2010 - awafaa@opensuse.org
- Update to version 2.27.4:
+ GIO
- Mounts are treated as hidden if they have a path element
that starts with a dot
- GAppInfo gained API to differentiate between recommended
and fallback mime handlers
- g_cancellable_create_source: creates a GSource that triggers
when the GCancellable is canceled
- GPollableInput/OutputStream: Interfaces for pollable streams
- TLS support has landed, with an extension point that is
implemented in glib-networking
+ GLib
- Mainloop sources can now have 'child sources'
- g_get_runtime_dir: New function to return the XDG_RUNTIME_DIR
+ Bugs fixed: bgo#530786, bgo#588189, bgo#630357, bgo#630559,
bgo#632445, bgo#634239, bgo#634241, bgo#634504, bgo#634613,
bgo#635640, bgo#635768, bgo#635882, bgo#635187
+ Updated translations: Galician, Italian, Norwegian bokmål,
Uyghur
- Remove glib2-add-back-extension-point.patch as merged upstream
-------------------------------------------------------------------
Wed Nov 24 18:50:14 CET 2010 - vuntz@opensuse.org

View File

@ -21,7 +21,7 @@
Name: glib2
%define _name glib
Version: 2.27.3
Version: 2.27.4
Release: 2
# FIXME: change zlib-devel to pkgconfig(zlib) once we have a recent enough version of zlib
# FIXME: find out if tapsets should really be in devel package or in main package
@ -40,8 +40,6 @@ Source5: macros.glib2
# Please update this file from the latest gtk-doc package:
Source6: gtk-doc.m4
Source99: baselibs.conf
# PATCH-FIX-UPSTREAM glib2-add-back-extension-point.patch bnc#655561 vuntz@opensuse.org -- Add back a gio extension point, to fix issues for modules using it. Taken from git.
Patch0: glib2-add-back-extension-point.patch
# PATCH-FIX-OPENSUSE glib2-bnc379332-desktop-su.patch bnc379332 vuntz@novell.com -- Use X-KDE-SubstituteUID
Patch8: glib2-bnc379332-desktop-su.patch
# PATCH-FEATURE-UPSTREAM glib2-bgo569829-gettext-gkeyfile.patch fate300461 bgo569829 vuntz@novell.com -- Look for translation of desktop entry strings via gettext, part that we share with Ubuntu and try to push upstream
@ -241,7 +239,6 @@ The GObject library provides an object-oriented framework for C.
%prep
%setup -q -n %{_name}-%{version}
translation-update-upstream
%patch0 -p1
%patch8
%patch10 -p1
%patch11 -p1