public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] proj/gnome:gnome-next commit in: media-libs/grilo/, media-plugins/grilo-plugins/files/, ...
@ 2011-08-04  4:52 Alexandre Restovtsev
  0 siblings, 0 replies; 2+ messages in thread
From: Alexandre Restovtsev @ 2011-08-04  4:52 UTC (permalink / raw
  To: gentoo-commits

commit:     c8db98873f2ef9038dc71915ae7b06a9f16eebfb
Author:     Alexandre Rostovtsev <tetromino <AT> gmail <DOT> com>
AuthorDate: Thu Aug  4 04:51:31 2011 +0000
Commit:     Alexandre Restovtsev <tetromino <AT> gmail <DOT> com>
CommitDate: Thu Aug  4 04:51:31 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/gnome.git;a=commit;h=c8db9887

media-libs/grilo, media-plugins/grilo-plugins: add 0.1.16

Used by totem-3.1.4

---
 media-libs/grilo/files/grilo-0.1.16-constants.py   |   50 ++++++
 .../grilo-0.1.16-media-source-infinite-loop.patch  |   48 ++++++
 media-libs/grilo/grilo-0.1.16.ebuild               |   63 +++++++
 .../grilo-plugins-0.1.16-local-metadata-leak.patch |   23 +++
 .../files/grilo-plugins-0.1.16-youtube-c90.patch   |  178 ++++++++++++++++++++
 ...grilo-plugins-0.1.16-youtube-libgdata-0.9.patch |  178 ++++++++++++++++++++
 ...grilo-plugins-0.1.16-youtube-missing-case.patch |   20 +++
 ...plugins-0.1.16-youtube-variable-shadowing.patch |   25 +++
 .../grilo-plugins/grilo-plugins-0.1.16.ebuild      |   80 +++++++++
 9 files changed, 665 insertions(+), 0 deletions(-)

diff --git a/media-libs/grilo/files/grilo-0.1.16-constants.py b/media-libs/grilo/files/grilo-0.1.16-constants.py
new file mode 100644
index 0000000..e8e2690
--- /dev/null
+++ b/media-libs/grilo/files/grilo-0.1.16-constants.py
@@ -0,0 +1,50 @@
+KEY_NONEXISTING = 'nonexisting-key'
+KEY_ALBUM = 'album'
+KEY_ARTIST = 'artist'
+KEY_AUTHOR = 'author'
+KEY_BITRATE = 'bitrate'
+KEY_CERTIFICATE = 'certificate'
+KEY_CHILDCOUNT = 'childcount'
+KEY_DATE = 'date'
+KEY_DESCRIPTION = 'description'
+KEY_DURATION = 'duration'
+KEY_EXTERNAL_PLAYER = 'external-player'
+KEY_EXTERNAL_URL = 'external-url'
+KEY_FRAMERATE = 'framerate'
+KEY_GENRE = 'genre'
+KEY_HEIGHT = 'height'
+KEY_ID = 'id'
+KEY_LAST_PLAYED = 'last-played'
+KEY_LAST_POSITION = 'last-position'
+KEY_LICENSE = 'license'
+KEY_LYRICS = 'lyrics'
+KEY_MIME = 'mime'
+KEY_PLAY_COUNT = 'play-count'
+KEY_RATING = 'rating'
+KEY_SITE = 'site'
+KEY_SOURCE = 'source'
+KEY_STUDIO = 'studio'
+KEY_THUMBNAIL = 'thumbnail'
+KEY_TITLE = 'title'
+KEY_URL = 'url'
+KEY_WIDTH = 'width'
+
+REGISTERED_KEYS = [KEY_ALBUM, KEY_ARTIST, KEY_AUTHOR, KEY_BITRATE,
+                   KEY_CERTIFICATE, KEY_CHILDCOUNT, KEY_DATE,
+                   KEY_DESCRIPTION, KEY_DURATION, KEY_EXTERNAL_PLAYER,
+                   KEY_EXTERNAL_URL, KEY_FRAMERATE, KEY_GENRE, KEY_HEIGHT,
+                   KEY_ID, KEY_LAST_PLAYED, KEY_LAST_POSITION, KEY_LICENSE,
+                   KEY_LYRICS, KEY_MIME, KEY_PLAY_COUNT, KEY_RATING,
+                   KEY_SITE, KEY_SOURCE, KEY_STUDIO, KEY_THUMBNAIL,
+                   KEY_TITLE, KEY_URL, KEY_WIDTH]
+
+SUPPORTED_OPS = []
+try:
+    from gi.repository import Grl
+    SUPPORTED_OPS = [Grl.SupportedOps.NONE, Grl.SupportedOps.METADATA,
+                     Grl.SupportedOps.RESOLVE, Grl.SupportedOps.BROWSE,
+                     Grl.SupportedOps.SEARCH, Grl.SupportedOps.QUERY,
+                     Grl.SupportedOps.STORE, Grl.SupportedOps.STORE_PARENT,
+                     Grl.SupportedOps.REMOVE, Grl.SupportedOps.SET_METADATA]
+except:
+    pass

diff --git a/media-libs/grilo/files/grilo-0.1.16-media-source-infinite-loop.patch b/media-libs/grilo/files/grilo-0.1.16-media-source-infinite-loop.patch
new file mode 100644
index 0000000..755faac
--- /dev/null
+++ b/media-libs/grilo/files/grilo-0.1.16-media-source-infinite-loop.patch
@@ -0,0 +1,48 @@
+From df228459d4332f3cb675d28d1d4185ae22929b81 Mon Sep 17 00:00:00 2001
+From: Lionel Landwerlin <lionel.g.landwerlin@linux.intel.com>
+Date: Wed, 29 Jun 2011 13:13:38 +0000
+Subject: media-source: manage end of search/browse with splitted sources
+
+When running in splitted modes (usually when dealing with websites),
+if you get less results than what the user would like to get, we
+currently end up in an infinite loop with the core of grilo keeping
+asking for new items from a source which can't deliver anymore.
+
+To manage this specific case, we just check whether the plugin has
+returned a remaining results number equals to 0 as well as a null
+item.
+
+Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@linux.intel.com>
+---
+diff --git a/src/grl-media-source.c b/src/grl-media-source.c
+index 459e29c..00494c3 100644
+--- a/src/grl-media-source.c
++++ b/src/grl-media-source.c
+@@ -643,8 +643,6 @@ browse_result_relay_cb (GrlMediaSource *source,
+ 
+   brc = (struct BrowseRelayCb *) user_data;
+ 
+-  plugin_remaining = remaining;
+-
+   /* --- operation cancel management --- */
+ 
+   /* Check if operation is still valid , otherwise do not emit the result
+@@ -697,9 +695,13 @@ browse_result_relay_cb (GrlMediaSource *source,
+     as_info->count--;
+     as_info->chunk_consumed++;
+ 
+-    /* FIXME: If we received less than we requested we should
+-       not do an extra query */
+-    remaining = as_info->count;
++    /* When auto split, if less results than what a chunk should give,
++     * that means we've reached the end of the results. */
++    if ((plugin_remaining == 0) &&
++        (as_info->chunk_consumed < as_info->chunk_requested))
++      remaining = 0;
++    else
++      remaining = as_info->count;
+   }
+ 
+   /* --- relay operation  --- */
+--
+cgit v0.9

diff --git a/media-libs/grilo/grilo-0.1.16.ebuild b/media-libs/grilo/grilo-0.1.16.ebuild
new file mode 100644
index 0000000..c07ea5b
--- /dev/null
+++ b/media-libs/grilo/grilo-0.1.16.ebuild
@@ -0,0 +1,63 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-libs/grilo/grilo-0.1.15.ebuild,v 1.2 2011/06/15 16:37:18 pacho Exp $
+
+EAPI="4"
+GNOME2_LA_PUNT="yes"
+#GNOME_TARBALL_SUFFIX="bz2"
+
+inherit autotools eutils gnome2
+
+DESCRIPTION="A framework for easy media discovery and browsing"
+HOMEPAGE="https://live.gnome.org/Grilo"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="doc +introspection +network test test-ui vala"
+
+RDEPEND="
+	>=dev-libs/glib-2.22:2
+	dev-libs/libxml2:2
+	network? ( >=net-libs/libsoup-2.33.4:2.4 )
+	test-ui? ( >=x11-libs/gtk+-3.0:3 )
+	introspection? ( >=dev-libs/gobject-introspection-0.9 )"
+DEPEND="${RDEPEND}
+	>=dev-util/pkgconfig-0.9
+	doc? ( >=dev-util/gtk-doc-1.10 )
+	vala? ( dev-lang/vala:0.12[vapigen] )
+	test? (
+		dev-python/pygobject:2[introspection?]
+		media-plugins/grilo-plugins )"
+
+pkg_setup() {
+	DOCS="AUTHORS NEWS README TODO"
+	# --enable-debug only changes CFLAGS, useless for us
+	G2CONF="${G2CONF}
+		--disable-maintainer-mode
+		--disable-static
+		--disable-debug
+		VALAC=$(type -P valac-0.12)
+		VALA_GEN_INTROSPECT=$(type -P vala-gen-introspect-0.12)
+		VAPIGEN=$(type -P vapigen-0.12)
+		$(use_enable introspection)
+		$(use_enable network grl-net)
+		$(use_enable test tests)
+		$(use_enable test-ui)
+		$(use_enable vala)"
+}
+
+src_prepare() {
+	# Various patches from upstream trunk
+	epatch "${FILESDIR}/${P}-media-source-infinite-loop.patch"
+	# Build system doesn't install this file with the tarball
+	cp "${FILESDIR}/${PN}-0.1.16-constants.py" "${S}/tests/python/constants.py"
+	eautoreconf
+
+	gnome2_src_prepare
+}
+
+src_test() {
+	cd tests/
+	emake check
+}

diff --git a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-local-metadata-leak.patch b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-local-metadata-leak.patch
new file mode 100644
index 0000000..b674e07
--- /dev/null
+++ b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-local-metadata-leak.patch
@@ -0,0 +1,23 @@
+From 9c1ccee8cadddeb6dd5d61e90ca65b3e951e326f Mon Sep 17 00:00:00 2001
+From: Lionel Landwerlin <lionel.g.landwerlin@linux.intel.com>
+Date: Sun, 03 Jul 2011 01:46:53 +0000
+Subject: local-metadata: fix memory leak on picture resolve
+
+A reference was still hold on a GFile object.
+
+Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@linux.intel.com>
+---
+diff --git a/src/metadata/local-metadata/grl-local-metadata.c b/src/metadata/local-metadata/grl-local-metadata.c
+index 0ba1fcc..d1e3208 100644
+--- a/src/metadata/local-metadata/grl-local-metadata.c
++++ b/src/metadata/local-metadata/grl-local-metadata.c
+@@ -570,6 +570,7 @@ resolve_image (GrlMetadataSource *source,
+     g_file_query_info_async (file, G_FILE_ATTRIBUTE_THUMBNAIL_PATH,
+                              G_FILE_QUERY_INFO_NONE, G_PRIORITY_DEFAULT, cancellable,
+                              (GAsyncReadyCallback)got_file_info, rs);
++    g_object_unref (file);
+   }
+ }
+ 
+--
+cgit v0.9

diff --git a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-c90.patch b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-c90.patch
new file mode 100644
index 0000000..d29ea3d
--- /dev/null
+++ b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-c90.patch
@@ -0,0 +1,178 @@
+From 0e425f129194593c3b7d3155aa8fc8f1a650cf06 Mon Sep 17 00:00:00 2001
+From: Philip Withnall <philip@tecnocode.co.uk>
+Date: Mon, 04 Jul 2011 21:53:18 +0000
+Subject: youtube: Fix ISO C90 warnings
+
+Can't mix declarations and code.
+---
+diff --git a/src/media/youtube/grl-youtube.c b/src/media/youtube/grl-youtube.c
+index eadd506..2057ec5 100644
+--- a/src/media/youtube/grl-youtube.c
++++ b/src/media/youtube/grl-youtube.c
+@@ -250,6 +250,7 @@ grl_youtube_plugin_init (GrlPluginRegistry *registry,
+   gchar *api_key;
+   GrlConfig *config;
+   gint config_count;
++  GrlYoutubeSource *source;
+ 
+   GRL_LOG_DOMAIN_INIT (youtube_log_domain, "youtube");
+ 
+@@ -277,8 +278,7 @@ grl_youtube_plugin_init (GrlPluginRegistry *registry,
+     g_thread_init (NULL);
+   }
+ 
+-  GrlYoutubeSource *source =
+-    grl_youtube_source_new (api_key, YOUTUBE_CLIENT_ID);
++  source = grl_youtube_source_new (api_key, YOUTUBE_CLIENT_ID);
+ 
+   grl_plugin_registry_register_source (registry,
+                                        plugin,
+@@ -301,11 +301,11 @@ G_DEFINE_TYPE (GrlYoutubeSource, grl_youtube_source, GRL_TYPE_MEDIA_SOURCE);
+ static GrlYoutubeSource *
+ grl_youtube_source_new (const gchar *api_key, const gchar *client_id)
+ {
+-  GRL_DEBUG ("grl_youtube_source_new");
+-
+   GrlYoutubeSource *source;
+   GDataYouTubeService *service;
+ 
++  GRL_DEBUG ("grl_youtube_source_new");
++
+   service = gdata_youtube_service_new (api_key, client_id);
+   if (!service) {
+     GRL_WARNING ("Failed to initialize gdata service");
+@@ -426,9 +426,13 @@ release_operation_data (GrlMetadataSource *source,
+ static OperationSpec *
+ operation_spec_new ()
+ {
++  OperationSpec *os;
++
+   GRL_DEBUG ("Allocating new spec");
+-  OperationSpec *os =  g_slice_new0 (OperationSpec);
++
++  os =  g_slice_new0 (OperationSpec);
+   os->ref_count = 1;
++
+   return os;
+ }
+ 
+@@ -614,14 +618,14 @@ build_media_from_entry (GrlYoutubeSource *source,
+ static void
+ parse_categories (xmlDocPtr doc, xmlNodePtr node, OperationSpec *os)
+ {
+-  GRL_DEBUG ("parse_categories");
+-
+   guint total = 0;
+   GList *all = NULL, *iter;
+   CategoryInfo *cat_info;
+   gchar *id;
+   guint index = 0;
+ 
++  GRL_DEBUG ("parse_categories");
++
+   while (node) {
+     cat_info = g_slice_new (CategoryInfo);
+     id = (gchar *) xmlGetProp (node, (xmlChar *) "term");
+@@ -800,14 +804,14 @@ metadata_cb (GObject *object,
+ 	     GAsyncResult *result,
+ 	     gpointer user_data)
+ {
+-  GRL_DEBUG ("metadata_cb");
+-
+   GError *error = NULL;
+   GrlYoutubeSource *source;
+   GDataEntry *video;
+   GDataService *service;
+   GrlMediaSourceMetadataSpec *ms = (GrlMediaSourceMetadataSpec *) user_data;
+ 
++  GRL_DEBUG ("metadata_cb");
++
+   source = GRL_YOUTUBE_SOURCE (ms->source);
+   service = GDATA_SERVICE (source->priv->service);
+ 
+@@ -876,13 +880,13 @@ search_progress_cb (GDataEntry *entry,
+ static void
+ search_cb (GObject *object, GAsyncResult *result, OperationSpec *os)
+ {
+-  GRL_DEBUG ("search_cb");
+-
+   GDataFeed *feed;
+   GError *error = NULL;
+   gboolean need_extra_unref = FALSE;
+   GrlYoutubeSource *source = GRL_YOUTUBE_SOURCE (os->source);
+ 
++  GRL_DEBUG ("search_cb");
++
+   /* Check if operation was cancelled */
+   if (g_cancellable_is_cancelled (os->cancellable)) {
+     GRL_DEBUG ("Search operation has been cancelled");
+@@ -1045,10 +1049,10 @@ produce_container_from_directory (GDataService *service,
+ static void
+ produce_from_directory (CategoryInfo *dir, gint dir_size, OperationSpec *os)
+ {
+-  GRL_DEBUG ("produce_from_directory");
+-
+   guint index, remaining;
+ 
++  GRL_DEBUG ("produce_from_directory");
++
+   /* Youtube's first index is 1, but the directories start at 0 */
+   os->skip--;
+ 
+@@ -1479,11 +1483,11 @@ grl_youtube_source_metadata (GrlMediaSource *source,
+ static gboolean
+ grl_youtube_test_media_from_uri (GrlMediaSource *source, const gchar *uri)
+ {
+-  GRL_DEBUG ("grl_youtube_test_media_from_uri");
+-
+   gchar *video_id;
+   gboolean ok;
+ 
++  GRL_DEBUG ("grl_youtube_test_media_from_uri");
++
+   video_id = get_video_id_from_url (uri);
+   ok = (video_id != NULL);
+   g_free (video_id);
+@@ -1494,12 +1498,15 @@ static void
+ grl_youtube_get_media_from_uri (GrlMediaSource *source,
+ 				 GrlMediaSourceMediaFromUriSpec *mfus)
+ {
+-  GRL_DEBUG ("grl_youtube_get_media_from_uri");
+-
+   gchar *video_id;
+   GError *error;
+   GCancellable *cancellable;
+   GDataService *service;
++#ifdef GDATA_API_SUBJECT_TO_CHANGE
++  gchar *entry_id;
++#endif /* GDATA_API_SUBJECT_TO_CHANGE */
++
++  GRL_DEBUG ("grl_youtube_get_media_from_uri");
+ 
+   video_id = get_video_id_from_url (mfus->uri);
+   if (video_id == NULL) {
+@@ -1516,7 +1523,7 @@ grl_youtube_get_media_from_uri (GrlMediaSource *source,
+   cancellable = g_cancellable_new ();
+   grl_operation_set_data (mfus->media_from_uri_id, cancellable);
+ #ifdef GDATA_API_SUBJECT_TO_CHANGE
+-  gchar *entry_id = g_strconcat ("tag:youtube.com,2008:video:", video_id, NULL);
++  entry_id = g_strconcat ("tag:youtube.com,2008:video:", video_id, NULL);
+   gdata_service_query_single_entry_async (service,
+ 					  entry_id,
+ 					  NULL,
+@@ -1539,10 +1546,11 @@ static void
+ grl_youtube_source_cancel (GrlMetadataSource *source,
+                            guint operation_id)
+ {
++  GCancellable *cancellable;
++
+   GRL_DEBUG (__FUNCTION__);
+ 
+-  GCancellable *cancellable =
+-    (GCancellable *) grl_operation_get_data (operation_id);
++  cancellable = G_CANCELLABLE (grl_operation_get_data (operation_id));
+ 
+   if (cancellable) {
+     g_cancellable_cancel (cancellable);
+--
+cgit v0.9

diff --git a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-libgdata-0.9.patch b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-libgdata-0.9.patch
new file mode 100644
index 0000000..a7712e6
--- /dev/null
+++ b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-libgdata-0.9.patch
@@ -0,0 +1,178 @@
+From 1d7580183556d44dc9490b6ed7d72b512eeceab8 Mon Sep 17 00:00:00 2001
+From: Philip Withnall <philip@tecnocode.co.uk>
+Date: Mon, 04 Jul 2011 22:12:53 +0000
+Subject: youtube: Add support for compiling against libgdata ≥ 0.9.0
+
+This adds conditional support for compiling against libgdata ≥ 0.9.0, which
+broke various APIs from 0.8.x.
+---
+diff --git a/configure.ac b/configure.ac
+index 898ef51..7d90503 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -160,6 +160,10 @@ if test "x$HAVE_GDATA" = "xyes"; then
+    if test $gdata_version_major -eq 0 -a $gdata_version_minor -ge 7; then
+       GDATA_CFLAGS="$GDATA_CFLAGS -DGDATA_API_SUBJECT_TO_CHANGE"
+    fi
++
++   if `$PKG_CONFIG --atleast-version=0.9.1 libgdata`; then
++      AC_DEFINE(HAVE_LIBGDATA_0_9, 1, [libgdata is 0.9.1 or higher])
++   fi
+ fi
+ 
+ # ----------------------------------------------------------
+diff --git a/src/media/youtube/grl-youtube.c b/src/media/youtube/grl-youtube.c
+index 050a80d..7a08683 100644
+--- a/src/media/youtube/grl-youtube.c
++++ b/src/media/youtube/grl-youtube.c
+@@ -306,7 +306,11 @@ grl_youtube_source_new (const gchar *api_key, const gchar *client_id)
+ 
+   GRL_DEBUG ("grl_youtube_source_new");
+ 
++#ifdef HAVE_LIBGDATA_0_9
++  service = gdata_youtube_service_new (api_key, NULL);
++#else /* HAVE_LIBGDATA_0_9 */
+   service = gdata_youtube_service_new (api_key, client_id);
++#endif /* !HAVE_LIBGDATA_0_9 */
+   if (!service) {
+     GRL_WARNING ("Failed to initialize gdata service");
+     return NULL;
+@@ -1135,14 +1139,28 @@ produce_from_feed (OperationSpec *os)
+   service = GRL_YOUTUBE_SOURCE (os->source)->priv->service;
+   query = gdata_query_new_with_limits (NULL , os->skip, os->count);
+   os->category_info = &feeds_dir[feed_type];
++
++#ifdef HAVE_LIBGDATA_0_9
+   gdata_youtube_service_query_standard_feed_async (GDATA_YOUTUBE_SERVICE (service),
+                                                    feed_type,
+                                                    query,
+                                                    os->cancellable,
+                                                    search_progress_cb,
+                                                    os,
++                                                   NULL,
+                                                    (GAsyncReadyCallback) search_cb,
+                                                    os);
++#else /* HAVE_LIBGDATA_0_9 */
++  gdata_youtube_service_query_standard_feed_async (GDATA_YOUTUBE_SERVICE (service),
++                                                   feed_type,
++                                                   query,
++                                                   os->cancellable,
++                                                   search_progress_cb,
++                                                   os,
++                                                   (GAsyncReadyCallback) search_cb,
++                                                   os);
++#endif /* !HAVE_LIBGDATA_0_9 */
++
+   g_object_unref (query);
+ }
+ 
+@@ -1180,6 +1198,17 @@ produce_from_category (OperationSpec *os)
+   query = gdata_query_new_with_limits (NULL , os->skip, os->count);
+   os->category_info = &categories_dir[category_index];
+   gdata_query_set_categories (query, category_term);
++
++#ifdef HAVE_LIBGDATA_0_9
++  gdata_youtube_service_query_videos_async (GDATA_YOUTUBE_SERVICE (service),
++                                            query,
++                                            NULL,
++                                            search_progress_cb,
++                                            os,
++                                            NULL,
++                                            (GAsyncReadyCallback) search_cb,
++                                            os);
++#else /* HAVE_LIBGDATA_0_9 */
+   gdata_youtube_service_query_videos_async (GDATA_YOUTUBE_SERVICE (service),
+ 					    query,
+ 					    NULL,
+@@ -1187,6 +1216,8 @@ produce_from_category (OperationSpec *os)
+ 					    os,
+ 					    (GAsyncReadyCallback) search_cb,
+ 					    os);
++#endif /* !HAVE_LIBGDATA_0_9 */
++
+   g_object_unref (query);
+ }
+ 
+@@ -1329,6 +1360,17 @@ grl_youtube_source_search (GrlMediaSource *source,
+   grl_operation_set_data (ss->search_id, os->cancellable);
+ 
+   query = gdata_query_new_with_limits (ss->text, os->skip, os->count);
++
++#ifdef HAVE_LIBGDATA_0_9
++  gdata_youtube_service_query_videos_async (GDATA_YOUTUBE_SERVICE (GRL_YOUTUBE_SOURCE (source)->priv->service),
++                                            query,
++                                            os->cancellable,
++                                            search_progress_cb,
++                                            os,
++                                            NULL,
++                                            (GAsyncReadyCallback) search_cb,
++                                            os);
++#else /* HAVE_LIBGDATA_0_9 */
+   gdata_youtube_service_query_videos_async (GDATA_YOUTUBE_SERVICE (GRL_YOUTUBE_SOURCE (source)->priv->service),
+ 					    query,
+ 					    os->cancellable,
+@@ -1336,6 +1378,8 @@ grl_youtube_source_search (GrlMediaSource *source,
+ 					    os,
+ 					    (GAsyncReadyCallback) search_cb,
+ 					    os);
++#endif /* !HAVE_LIBGDATA_0_9 */
++
+   g_object_unref (query);
+ }
+ 
+@@ -1452,6 +1496,17 @@ grl_youtube_source_metadata (GrlMediaSource *source,
+ #ifdef GDATA_API_SUBJECT_TO_CHANGE
+     {
+       gchar *entryid = g_strconcat ("tag:youtube.com,2008:video:", id, NULL);
++
++#ifdef HAVE_LIBGDATA_0_9
++      gdata_service_query_single_entry_async (service,
++                                              NULL,
++                                              entryid,
++                                              NULL,
++                                              GDATA_TYPE_YOUTUBE_VIDEO,
++                                              cancellable,
++                                              metadata_cb,
++                                              ms);
++#else /* HAVE_LIBGDATA_0_9 */
+       gdata_service_query_single_entry_async (service,
+                                               entryid,
+                                               NULL,
+@@ -1459,6 +1514,8 @@ grl_youtube_source_metadata (GrlMediaSource *source,
+                                               cancellable,
+                                               metadata_cb,
+                                               ms);
++#endif /* !HAVE_LIBGDATA_0_9 */
++
+       g_free (entryid);
+     }
+ #else
+@@ -1524,6 +1581,17 @@ grl_youtube_get_media_from_uri (GrlMediaSource *source,
+   grl_operation_set_data (mfus->media_from_uri_id, cancellable);
+ #ifdef GDATA_API_SUBJECT_TO_CHANGE
+   entry_id = g_strconcat ("tag:youtube.com,2008:video:", video_id, NULL);
++
++#ifdef HAVE_LIBGDATA_0_9
++  gdata_service_query_single_entry_async (service,
++                                          NULL,
++                                          entry_id,
++                                          NULL,
++                                          GDATA_TYPE_YOUTUBE_VIDEO,
++                                          cancellable,
++                                          media_from_uri_cb,
++                                          mfus);
++#else /* HAVE_LIBGDATA_0_9 */
+   gdata_service_query_single_entry_async (service,
+ 					  entry_id,
+ 					  NULL,
+@@ -1531,6 +1599,8 @@ grl_youtube_get_media_from_uri (GrlMediaSource *source,
+ 					  cancellable,
+ 					  media_from_uri_cb,
+ 					  mfus);
++#endif /* !HAVE_LIBGDATA_0_9 */
++
+   g_free (entry_id);
+ #else
+   gdata_youtube_service_query_single_video_async (GDATA_YOUTUBE_SERVICE (service),
+--
+cgit v0.9

diff --git a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-missing-case.patch b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-missing-case.patch
new file mode 100644
index 0000000..a0329c0
--- /dev/null
+++ b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-missing-case.patch
@@ -0,0 +1,20 @@
+From 477ddd90c29aba07a9ab2319a6fe9e6b6acef5c1 Mon Sep 17 00:00:00 2001
+From: Philip Withnall <philip@tecnocode.co.uk>
+Date: Mon, 04 Jul 2011 22:15:56 +0000
+Subject: youtube: Add a missing case to a switch statement
+
+---
+diff --git a/src/media/youtube/grl-youtube.c b/src/media/youtube/grl-youtube.c
+index 7a08683..2bdaf01 100644
+--- a/src/media/youtube/grl-youtube.c
++++ b/src/media/youtube/grl-youtube.c
+@@ -1430,6 +1430,7 @@ grl_youtube_source_browse (GrlMediaSource *source,
+     case YOUTUBE_MEDIA_TYPE_CATEGORY:
+       produce_from_category (os);
+       break;
++    case YOUTUBE_MEDIA_TYPE_VIDEO:
+     default:
+       g_assert_not_reached ();
+       break;
+--
+cgit v0.9

diff --git a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-variable-shadowing.patch b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-variable-shadowing.patch
new file mode 100644
index 0000000..f1445a2
--- /dev/null
+++ b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-variable-shadowing.patch
@@ -0,0 +1,25 @@
+From e4c40d02fc1b6627b66682a28cdbb4cbd71aad7e Mon Sep 17 00:00:00 2001
+From: Philip Withnall <philip@tecnocode.co.uk>
+Date: Mon, 04 Jul 2011 21:56:05 +0000
+Subject: youtube: Fix variable shadowing a parameter
+
+---
+diff --git a/src/media/youtube/grl-youtube.c b/src/media/youtube/grl-youtube.c
+index 66609dd..050a80d 100644
+--- a/src/media/youtube/grl-youtube.c
++++ b/src/media/youtube/grl-youtube.c
+@@ -604,9 +604,9 @@ build_media_from_entry (GrlYoutubeSource *source,
+ 	gdata_youtube_video_look_up_content (video,
+ 					     "application/x-shockwave-flash");
+       if (youtube_content != NULL) {
+-	GDataMediaContent *content = GDATA_MEDIA_CONTENT (youtube_content);
+-	grl_media_set_external_player (media,
+-				       gdata_media_content_get_uri (content));
++        const gchar *uri =
++          gdata_media_content_get_uri (GDATA_MEDIA_CONTENT (youtube_content));
++	grl_media_set_external_player (media, uri);
+       }
+     }
+     iter = g_list_next (iter);
+--
+cgit v0.9

diff --git a/media-plugins/grilo-plugins/grilo-plugins-0.1.16.ebuild b/media-plugins/grilo-plugins/grilo-plugins-0.1.16.ebuild
new file mode 100644
index 0000000..2004a7e
--- /dev/null
+++ b/media-plugins/grilo-plugins/grilo-plugins-0.1.16.ebuild
@@ -0,0 +1,80 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-plugins/grilo-plugins/grilo-plugins-0.1.15.ebuild,v 1.2 2011/06/15 16:43:45 pacho Exp $
+
+EAPI="4"
+GNOME2_LA_PUNT="yes"
+
+inherit autotools eutils gnome2
+
+DESCRIPTION="A framework for easy media discovery and browsing"
+HOMEPAGE="https://live.gnome.org/Grilo"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="+youtube +vimeo upnp"
+
+RDEPEND="
+	>=dev-libs/glib-2.26:2
+	=media-libs/grilo-${PV}[network]
+
+	dev-libs/gmime:2.4
+	dev-libs/libxml2:2
+	dev-db/sqlite:3
+
+	youtube? ( >=dev-libs/libgdata-0.4.0
+		>=media-libs/quvi-0.2.15 )
+	upnp? ( >=net-libs/gupnp-0.13
+		>=net-libs/gupnp-av-0.5 )
+	vimeo? ( net-libs/libsoup:2.4
+		dev-libs/libgcrypt )"
+DEPEND="${RDEPEND}
+	>=dev-util/pkgconfig-0.9"
+
+# `make check` doesn't do anything, and ${S}/test/test fails without all plugins
+RESTRICT="test"
+
+pkg_setup() {
+	DOCS="AUTHORS NEWS README"
+	# --enable-debug only changes CFLAGS, useless for us
+	G2CONF="${G2CONF}
+		--disable-maintainer-mode
+		--disable-static
+		--disable-debug
+		--disable-uninstalled"
+
+	# Plugins
+	# TODO: Enable tracker support
+	G2CONF="${G2CONF}
+		--enable-filesystem
+		--enable-jamendo
+		--enable-lastfm-albumart
+		--enable-flickr
+		--enable-podcasts
+		--enable-bookmarks
+		--disable-shoutcast
+		--enable-apple-trailers
+		--enable-metadata-store
+		--enable-gravatar
+		--disable-tracker
+		--enable-localmetadata
+		$(use_enable upnp)
+		$(use_enable youtube)
+		$(use_enable vimeo)"
+}
+
+src_prepare() {
+	# important patches from upstream git master
+	epatch "${FILESDIR}/${P}-youtube-c90.patch"
+	epatch "${FILESDIR}/${P}-youtube-variable-shadowing.patch"
+	epatch "${FILESDIR}/${P}-youtube-missing-case.patch"
+	epatch "${FILESDIR}/${P}-youtube-libgdata-0.9.patch"
+	epatch "${FILESDIR}/${P}-local-metadata-leak.patch"
+
+	sed -i -e 's/^\(SUBDIRS .*\)test/\1/g' Makefile.*
+
+	eautoreconf
+
+	gnome2_src_prepare
+}



^ permalink raw reply related	[flat|nested] 2+ messages in thread
* [gentoo-commits] proj/gnome:gnome-next commit in: media-libs/grilo/, media-plugins/grilo-plugins/files/, ...
@ 2011-08-14 10:54 Nirbheek Chauhan
  0 siblings, 0 replies; 2+ messages in thread
From: Nirbheek Chauhan @ 2011-08-14 10:54 UTC (permalink / raw
  To: gentoo-commits

commit:     7da01d6febd401c839da0cedc1db8e478045f4ce
Author:     Nirbheek Chauhan <nirbheek <AT> gentoo <DOT> org>
AuthorDate: Sun Aug 14 09:54:22 2011 +0000
Commit:     Nirbheek Chauhan <nirbheek <AT> gentoo <DOT> org>
CommitDate: Sun Aug 14 09:54:22 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/gnome.git;a=commit;h=7da01d6f

grilo, grilo-plugins: moved to the tree, bug 377651

---
 media-libs/grilo/files/grilo-0.1.16-constants.py   |   50 ------
 .../grilo-0.1.16-media-source-infinite-loop.patch  |   48 ------
 media-libs/grilo/grilo-0.1.16.ebuild               |   63 -------
 .../grilo-plugins-0.1.16-local-metadata-leak.patch |   23 ---
 .../files/grilo-plugins-0.1.16-youtube-c90.patch   |  178 --------------------
 ...grilo-plugins-0.1.16-youtube-libgdata-0.9.patch |  178 --------------------
 ...grilo-plugins-0.1.16-youtube-missing-case.patch |   20 ---
 ...plugins-0.1.16-youtube-variable-shadowing.patch |   25 ---
 .../grilo-plugins/grilo-plugins-0.1.16.ebuild      |   80 ---------
 9 files changed, 0 insertions(+), 665 deletions(-)

diff --git a/media-libs/grilo/files/grilo-0.1.16-constants.py b/media-libs/grilo/files/grilo-0.1.16-constants.py
deleted file mode 100644
index e8e2690..0000000
--- a/media-libs/grilo/files/grilo-0.1.16-constants.py
+++ /dev/null
@@ -1,50 +0,0 @@
-KEY_NONEXISTING = 'nonexisting-key'
-KEY_ALBUM = 'album'
-KEY_ARTIST = 'artist'
-KEY_AUTHOR = 'author'
-KEY_BITRATE = 'bitrate'
-KEY_CERTIFICATE = 'certificate'
-KEY_CHILDCOUNT = 'childcount'
-KEY_DATE = 'date'
-KEY_DESCRIPTION = 'description'
-KEY_DURATION = 'duration'
-KEY_EXTERNAL_PLAYER = 'external-player'
-KEY_EXTERNAL_URL = 'external-url'
-KEY_FRAMERATE = 'framerate'
-KEY_GENRE = 'genre'
-KEY_HEIGHT = 'height'
-KEY_ID = 'id'
-KEY_LAST_PLAYED = 'last-played'
-KEY_LAST_POSITION = 'last-position'
-KEY_LICENSE = 'license'
-KEY_LYRICS = 'lyrics'
-KEY_MIME = 'mime'
-KEY_PLAY_COUNT = 'play-count'
-KEY_RATING = 'rating'
-KEY_SITE = 'site'
-KEY_SOURCE = 'source'
-KEY_STUDIO = 'studio'
-KEY_THUMBNAIL = 'thumbnail'
-KEY_TITLE = 'title'
-KEY_URL = 'url'
-KEY_WIDTH = 'width'
-
-REGISTERED_KEYS = [KEY_ALBUM, KEY_ARTIST, KEY_AUTHOR, KEY_BITRATE,
-                   KEY_CERTIFICATE, KEY_CHILDCOUNT, KEY_DATE,
-                   KEY_DESCRIPTION, KEY_DURATION, KEY_EXTERNAL_PLAYER,
-                   KEY_EXTERNAL_URL, KEY_FRAMERATE, KEY_GENRE, KEY_HEIGHT,
-                   KEY_ID, KEY_LAST_PLAYED, KEY_LAST_POSITION, KEY_LICENSE,
-                   KEY_LYRICS, KEY_MIME, KEY_PLAY_COUNT, KEY_RATING,
-                   KEY_SITE, KEY_SOURCE, KEY_STUDIO, KEY_THUMBNAIL,
-                   KEY_TITLE, KEY_URL, KEY_WIDTH]
-
-SUPPORTED_OPS = []
-try:
-    from gi.repository import Grl
-    SUPPORTED_OPS = [Grl.SupportedOps.NONE, Grl.SupportedOps.METADATA,
-                     Grl.SupportedOps.RESOLVE, Grl.SupportedOps.BROWSE,
-                     Grl.SupportedOps.SEARCH, Grl.SupportedOps.QUERY,
-                     Grl.SupportedOps.STORE, Grl.SupportedOps.STORE_PARENT,
-                     Grl.SupportedOps.REMOVE, Grl.SupportedOps.SET_METADATA]
-except:
-    pass

diff --git a/media-libs/grilo/files/grilo-0.1.16-media-source-infinite-loop.patch b/media-libs/grilo/files/grilo-0.1.16-media-source-infinite-loop.patch
deleted file mode 100644
index 755faac..0000000
--- a/media-libs/grilo/files/grilo-0.1.16-media-source-infinite-loop.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From df228459d4332f3cb675d28d1d4185ae22929b81 Mon Sep 17 00:00:00 2001
-From: Lionel Landwerlin <lionel.g.landwerlin@linux.intel.com>
-Date: Wed, 29 Jun 2011 13:13:38 +0000
-Subject: media-source: manage end of search/browse with splitted sources
-
-When running in splitted modes (usually when dealing with websites),
-if you get less results than what the user would like to get, we
-currently end up in an infinite loop with the core of grilo keeping
-asking for new items from a source which can't deliver anymore.
-
-To manage this specific case, we just check whether the plugin has
-returned a remaining results number equals to 0 as well as a null
-item.
-
-Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@linux.intel.com>
----
-diff --git a/src/grl-media-source.c b/src/grl-media-source.c
-index 459e29c..00494c3 100644
---- a/src/grl-media-source.c
-+++ b/src/grl-media-source.c
-@@ -643,8 +643,6 @@ browse_result_relay_cb (GrlMediaSource *source,
- 
-   brc = (struct BrowseRelayCb *) user_data;
- 
--  plugin_remaining = remaining;
--
-   /* --- operation cancel management --- */
- 
-   /* Check if operation is still valid , otherwise do not emit the result
-@@ -697,9 +695,13 @@ browse_result_relay_cb (GrlMediaSource *source,
-     as_info->count--;
-     as_info->chunk_consumed++;
- 
--    /* FIXME: If we received less than we requested we should
--       not do an extra query */
--    remaining = as_info->count;
-+    /* When auto split, if less results than what a chunk should give,
-+     * that means we've reached the end of the results. */
-+    if ((plugin_remaining == 0) &&
-+        (as_info->chunk_consumed < as_info->chunk_requested))
-+      remaining = 0;
-+    else
-+      remaining = as_info->count;
-   }
- 
-   /* --- relay operation  --- */
---
-cgit v0.9

diff --git a/media-libs/grilo/grilo-0.1.16.ebuild b/media-libs/grilo/grilo-0.1.16.ebuild
deleted file mode 100644
index c07ea5b..0000000
--- a/media-libs/grilo/grilo-0.1.16.ebuild
+++ /dev/null
@@ -1,63 +0,0 @@
-# Copyright 1999-2011 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/grilo/grilo-0.1.15.ebuild,v 1.2 2011/06/15 16:37:18 pacho Exp $
-
-EAPI="4"
-GNOME2_LA_PUNT="yes"
-#GNOME_TARBALL_SUFFIX="bz2"
-
-inherit autotools eutils gnome2
-
-DESCRIPTION="A framework for easy media discovery and browsing"
-HOMEPAGE="https://live.gnome.org/Grilo"
-
-LICENSE="LGPL-2.1"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-IUSE="doc +introspection +network test test-ui vala"
-
-RDEPEND="
-	>=dev-libs/glib-2.22:2
-	dev-libs/libxml2:2
-	network? ( >=net-libs/libsoup-2.33.4:2.4 )
-	test-ui? ( >=x11-libs/gtk+-3.0:3 )
-	introspection? ( >=dev-libs/gobject-introspection-0.9 )"
-DEPEND="${RDEPEND}
-	>=dev-util/pkgconfig-0.9
-	doc? ( >=dev-util/gtk-doc-1.10 )
-	vala? ( dev-lang/vala:0.12[vapigen] )
-	test? (
-		dev-python/pygobject:2[introspection?]
-		media-plugins/grilo-plugins )"
-
-pkg_setup() {
-	DOCS="AUTHORS NEWS README TODO"
-	# --enable-debug only changes CFLAGS, useless for us
-	G2CONF="${G2CONF}
-		--disable-maintainer-mode
-		--disable-static
-		--disable-debug
-		VALAC=$(type -P valac-0.12)
-		VALA_GEN_INTROSPECT=$(type -P vala-gen-introspect-0.12)
-		VAPIGEN=$(type -P vapigen-0.12)
-		$(use_enable introspection)
-		$(use_enable network grl-net)
-		$(use_enable test tests)
-		$(use_enable test-ui)
-		$(use_enable vala)"
-}
-
-src_prepare() {
-	# Various patches from upstream trunk
-	epatch "${FILESDIR}/${P}-media-source-infinite-loop.patch"
-	# Build system doesn't install this file with the tarball
-	cp "${FILESDIR}/${PN}-0.1.16-constants.py" "${S}/tests/python/constants.py"
-	eautoreconf
-
-	gnome2_src_prepare
-}
-
-src_test() {
-	cd tests/
-	emake check
-}

diff --git a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-local-metadata-leak.patch b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-local-metadata-leak.patch
deleted file mode 100644
index b674e07..0000000
--- a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-local-metadata-leak.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-From 9c1ccee8cadddeb6dd5d61e90ca65b3e951e326f Mon Sep 17 00:00:00 2001
-From: Lionel Landwerlin <lionel.g.landwerlin@linux.intel.com>
-Date: Sun, 03 Jul 2011 01:46:53 +0000
-Subject: local-metadata: fix memory leak on picture resolve
-
-A reference was still hold on a GFile object.
-
-Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@linux.intel.com>
----
-diff --git a/src/metadata/local-metadata/grl-local-metadata.c b/src/metadata/local-metadata/grl-local-metadata.c
-index 0ba1fcc..d1e3208 100644
---- a/src/metadata/local-metadata/grl-local-metadata.c
-+++ b/src/metadata/local-metadata/grl-local-metadata.c
-@@ -570,6 +570,7 @@ resolve_image (GrlMetadataSource *source,
-     g_file_query_info_async (file, G_FILE_ATTRIBUTE_THUMBNAIL_PATH,
-                              G_FILE_QUERY_INFO_NONE, G_PRIORITY_DEFAULT, cancellable,
-                              (GAsyncReadyCallback)got_file_info, rs);
-+    g_object_unref (file);
-   }
- }
- 
---
-cgit v0.9

diff --git a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-c90.patch b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-c90.patch
deleted file mode 100644
index d29ea3d..0000000
--- a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-c90.patch
+++ /dev/null
@@ -1,178 +0,0 @@
-From 0e425f129194593c3b7d3155aa8fc8f1a650cf06 Mon Sep 17 00:00:00 2001
-From: Philip Withnall <philip@tecnocode.co.uk>
-Date: Mon, 04 Jul 2011 21:53:18 +0000
-Subject: youtube: Fix ISO C90 warnings
-
-Can't mix declarations and code.
----
-diff --git a/src/media/youtube/grl-youtube.c b/src/media/youtube/grl-youtube.c
-index eadd506..2057ec5 100644
---- a/src/media/youtube/grl-youtube.c
-+++ b/src/media/youtube/grl-youtube.c
-@@ -250,6 +250,7 @@ grl_youtube_plugin_init (GrlPluginRegistry *registry,
-   gchar *api_key;
-   GrlConfig *config;
-   gint config_count;
-+  GrlYoutubeSource *source;
- 
-   GRL_LOG_DOMAIN_INIT (youtube_log_domain, "youtube");
- 
-@@ -277,8 +278,7 @@ grl_youtube_plugin_init (GrlPluginRegistry *registry,
-     g_thread_init (NULL);
-   }
- 
--  GrlYoutubeSource *source =
--    grl_youtube_source_new (api_key, YOUTUBE_CLIENT_ID);
-+  source = grl_youtube_source_new (api_key, YOUTUBE_CLIENT_ID);
- 
-   grl_plugin_registry_register_source (registry,
-                                        plugin,
-@@ -301,11 +301,11 @@ G_DEFINE_TYPE (GrlYoutubeSource, grl_youtube_source, GRL_TYPE_MEDIA_SOURCE);
- static GrlYoutubeSource *
- grl_youtube_source_new (const gchar *api_key, const gchar *client_id)
- {
--  GRL_DEBUG ("grl_youtube_source_new");
--
-   GrlYoutubeSource *source;
-   GDataYouTubeService *service;
- 
-+  GRL_DEBUG ("grl_youtube_source_new");
-+
-   service = gdata_youtube_service_new (api_key, client_id);
-   if (!service) {
-     GRL_WARNING ("Failed to initialize gdata service");
-@@ -426,9 +426,13 @@ release_operation_data (GrlMetadataSource *source,
- static OperationSpec *
- operation_spec_new ()
- {
-+  OperationSpec *os;
-+
-   GRL_DEBUG ("Allocating new spec");
--  OperationSpec *os =  g_slice_new0 (OperationSpec);
-+
-+  os =  g_slice_new0 (OperationSpec);
-   os->ref_count = 1;
-+
-   return os;
- }
- 
-@@ -614,14 +618,14 @@ build_media_from_entry (GrlYoutubeSource *source,
- static void
- parse_categories (xmlDocPtr doc, xmlNodePtr node, OperationSpec *os)
- {
--  GRL_DEBUG ("parse_categories");
--
-   guint total = 0;
-   GList *all = NULL, *iter;
-   CategoryInfo *cat_info;
-   gchar *id;
-   guint index = 0;
- 
-+  GRL_DEBUG ("parse_categories");
-+
-   while (node) {
-     cat_info = g_slice_new (CategoryInfo);
-     id = (gchar *) xmlGetProp (node, (xmlChar *) "term");
-@@ -800,14 +804,14 @@ metadata_cb (GObject *object,
- 	     GAsyncResult *result,
- 	     gpointer user_data)
- {
--  GRL_DEBUG ("metadata_cb");
--
-   GError *error = NULL;
-   GrlYoutubeSource *source;
-   GDataEntry *video;
-   GDataService *service;
-   GrlMediaSourceMetadataSpec *ms = (GrlMediaSourceMetadataSpec *) user_data;
- 
-+  GRL_DEBUG ("metadata_cb");
-+
-   source = GRL_YOUTUBE_SOURCE (ms->source);
-   service = GDATA_SERVICE (source->priv->service);
- 
-@@ -876,13 +880,13 @@ search_progress_cb (GDataEntry *entry,
- static void
- search_cb (GObject *object, GAsyncResult *result, OperationSpec *os)
- {
--  GRL_DEBUG ("search_cb");
--
-   GDataFeed *feed;
-   GError *error = NULL;
-   gboolean need_extra_unref = FALSE;
-   GrlYoutubeSource *source = GRL_YOUTUBE_SOURCE (os->source);
- 
-+  GRL_DEBUG ("search_cb");
-+
-   /* Check if operation was cancelled */
-   if (g_cancellable_is_cancelled (os->cancellable)) {
-     GRL_DEBUG ("Search operation has been cancelled");
-@@ -1045,10 +1049,10 @@ produce_container_from_directory (GDataService *service,
- static void
- produce_from_directory (CategoryInfo *dir, gint dir_size, OperationSpec *os)
- {
--  GRL_DEBUG ("produce_from_directory");
--
-   guint index, remaining;
- 
-+  GRL_DEBUG ("produce_from_directory");
-+
-   /* Youtube's first index is 1, but the directories start at 0 */
-   os->skip--;
- 
-@@ -1479,11 +1483,11 @@ grl_youtube_source_metadata (GrlMediaSource *source,
- static gboolean
- grl_youtube_test_media_from_uri (GrlMediaSource *source, const gchar *uri)
- {
--  GRL_DEBUG ("grl_youtube_test_media_from_uri");
--
-   gchar *video_id;
-   gboolean ok;
- 
-+  GRL_DEBUG ("grl_youtube_test_media_from_uri");
-+
-   video_id = get_video_id_from_url (uri);
-   ok = (video_id != NULL);
-   g_free (video_id);
-@@ -1494,12 +1498,15 @@ static void
- grl_youtube_get_media_from_uri (GrlMediaSource *source,
- 				 GrlMediaSourceMediaFromUriSpec *mfus)
- {
--  GRL_DEBUG ("grl_youtube_get_media_from_uri");
--
-   gchar *video_id;
-   GError *error;
-   GCancellable *cancellable;
-   GDataService *service;
-+#ifdef GDATA_API_SUBJECT_TO_CHANGE
-+  gchar *entry_id;
-+#endif /* GDATA_API_SUBJECT_TO_CHANGE */
-+
-+  GRL_DEBUG ("grl_youtube_get_media_from_uri");
- 
-   video_id = get_video_id_from_url (mfus->uri);
-   if (video_id == NULL) {
-@@ -1516,7 +1523,7 @@ grl_youtube_get_media_from_uri (GrlMediaSource *source,
-   cancellable = g_cancellable_new ();
-   grl_operation_set_data (mfus->media_from_uri_id, cancellable);
- #ifdef GDATA_API_SUBJECT_TO_CHANGE
--  gchar *entry_id = g_strconcat ("tag:youtube.com,2008:video:", video_id, NULL);
-+  entry_id = g_strconcat ("tag:youtube.com,2008:video:", video_id, NULL);
-   gdata_service_query_single_entry_async (service,
- 					  entry_id,
- 					  NULL,
-@@ -1539,10 +1546,11 @@ static void
- grl_youtube_source_cancel (GrlMetadataSource *source,
-                            guint operation_id)
- {
-+  GCancellable *cancellable;
-+
-   GRL_DEBUG (__FUNCTION__);
- 
--  GCancellable *cancellable =
--    (GCancellable *) grl_operation_get_data (operation_id);
-+  cancellable = G_CANCELLABLE (grl_operation_get_data (operation_id));
- 
-   if (cancellable) {
-     g_cancellable_cancel (cancellable);
---
-cgit v0.9

diff --git a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-libgdata-0.9.patch b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-libgdata-0.9.patch
deleted file mode 100644
index a7712e6..0000000
--- a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-libgdata-0.9.patch
+++ /dev/null
@@ -1,178 +0,0 @@
-From 1d7580183556d44dc9490b6ed7d72b512eeceab8 Mon Sep 17 00:00:00 2001
-From: Philip Withnall <philip@tecnocode.co.uk>
-Date: Mon, 04 Jul 2011 22:12:53 +0000
-Subject: youtube: Add support for compiling against libgdata ≥ 0.9.0
-
-This adds conditional support for compiling against libgdata ≥ 0.9.0, which
-broke various APIs from 0.8.x.
----
-diff --git a/configure.ac b/configure.ac
-index 898ef51..7d90503 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -160,6 +160,10 @@ if test "x$HAVE_GDATA" = "xyes"; then
-    if test $gdata_version_major -eq 0 -a $gdata_version_minor -ge 7; then
-       GDATA_CFLAGS="$GDATA_CFLAGS -DGDATA_API_SUBJECT_TO_CHANGE"
-    fi
-+
-+   if `$PKG_CONFIG --atleast-version=0.9.1 libgdata`; then
-+      AC_DEFINE(HAVE_LIBGDATA_0_9, 1, [libgdata is 0.9.1 or higher])
-+   fi
- fi
- 
- # ----------------------------------------------------------
-diff --git a/src/media/youtube/grl-youtube.c b/src/media/youtube/grl-youtube.c
-index 050a80d..7a08683 100644
---- a/src/media/youtube/grl-youtube.c
-+++ b/src/media/youtube/grl-youtube.c
-@@ -306,7 +306,11 @@ grl_youtube_source_new (const gchar *api_key, const gchar *client_id)
- 
-   GRL_DEBUG ("grl_youtube_source_new");
- 
-+#ifdef HAVE_LIBGDATA_0_9
-+  service = gdata_youtube_service_new (api_key, NULL);
-+#else /* HAVE_LIBGDATA_0_9 */
-   service = gdata_youtube_service_new (api_key, client_id);
-+#endif /* !HAVE_LIBGDATA_0_9 */
-   if (!service) {
-     GRL_WARNING ("Failed to initialize gdata service");
-     return NULL;
-@@ -1135,14 +1139,28 @@ produce_from_feed (OperationSpec *os)
-   service = GRL_YOUTUBE_SOURCE (os->source)->priv->service;
-   query = gdata_query_new_with_limits (NULL , os->skip, os->count);
-   os->category_info = &feeds_dir[feed_type];
-+
-+#ifdef HAVE_LIBGDATA_0_9
-   gdata_youtube_service_query_standard_feed_async (GDATA_YOUTUBE_SERVICE (service),
-                                                    feed_type,
-                                                    query,
-                                                    os->cancellable,
-                                                    search_progress_cb,
-                                                    os,
-+                                                   NULL,
-                                                    (GAsyncReadyCallback) search_cb,
-                                                    os);
-+#else /* HAVE_LIBGDATA_0_9 */
-+  gdata_youtube_service_query_standard_feed_async (GDATA_YOUTUBE_SERVICE (service),
-+                                                   feed_type,
-+                                                   query,
-+                                                   os->cancellable,
-+                                                   search_progress_cb,
-+                                                   os,
-+                                                   (GAsyncReadyCallback) search_cb,
-+                                                   os);
-+#endif /* !HAVE_LIBGDATA_0_9 */
-+
-   g_object_unref (query);
- }
- 
-@@ -1180,6 +1198,17 @@ produce_from_category (OperationSpec *os)
-   query = gdata_query_new_with_limits (NULL , os->skip, os->count);
-   os->category_info = &categories_dir[category_index];
-   gdata_query_set_categories (query, category_term);
-+
-+#ifdef HAVE_LIBGDATA_0_9
-+  gdata_youtube_service_query_videos_async (GDATA_YOUTUBE_SERVICE (service),
-+                                            query,
-+                                            NULL,
-+                                            search_progress_cb,
-+                                            os,
-+                                            NULL,
-+                                            (GAsyncReadyCallback) search_cb,
-+                                            os);
-+#else /* HAVE_LIBGDATA_0_9 */
-   gdata_youtube_service_query_videos_async (GDATA_YOUTUBE_SERVICE (service),
- 					    query,
- 					    NULL,
-@@ -1187,6 +1216,8 @@ produce_from_category (OperationSpec *os)
- 					    os,
- 					    (GAsyncReadyCallback) search_cb,
- 					    os);
-+#endif /* !HAVE_LIBGDATA_0_9 */
-+
-   g_object_unref (query);
- }
- 
-@@ -1329,6 +1360,17 @@ grl_youtube_source_search (GrlMediaSource *source,
-   grl_operation_set_data (ss->search_id, os->cancellable);
- 
-   query = gdata_query_new_with_limits (ss->text, os->skip, os->count);
-+
-+#ifdef HAVE_LIBGDATA_0_9
-+  gdata_youtube_service_query_videos_async (GDATA_YOUTUBE_SERVICE (GRL_YOUTUBE_SOURCE (source)->priv->service),
-+                                            query,
-+                                            os->cancellable,
-+                                            search_progress_cb,
-+                                            os,
-+                                            NULL,
-+                                            (GAsyncReadyCallback) search_cb,
-+                                            os);
-+#else /* HAVE_LIBGDATA_0_9 */
-   gdata_youtube_service_query_videos_async (GDATA_YOUTUBE_SERVICE (GRL_YOUTUBE_SOURCE (source)->priv->service),
- 					    query,
- 					    os->cancellable,
-@@ -1336,6 +1378,8 @@ grl_youtube_source_search (GrlMediaSource *source,
- 					    os,
- 					    (GAsyncReadyCallback) search_cb,
- 					    os);
-+#endif /* !HAVE_LIBGDATA_0_9 */
-+
-   g_object_unref (query);
- }
- 
-@@ -1452,6 +1496,17 @@ grl_youtube_source_metadata (GrlMediaSource *source,
- #ifdef GDATA_API_SUBJECT_TO_CHANGE
-     {
-       gchar *entryid = g_strconcat ("tag:youtube.com,2008:video:", id, NULL);
-+
-+#ifdef HAVE_LIBGDATA_0_9
-+      gdata_service_query_single_entry_async (service,
-+                                              NULL,
-+                                              entryid,
-+                                              NULL,
-+                                              GDATA_TYPE_YOUTUBE_VIDEO,
-+                                              cancellable,
-+                                              metadata_cb,
-+                                              ms);
-+#else /* HAVE_LIBGDATA_0_9 */
-       gdata_service_query_single_entry_async (service,
-                                               entryid,
-                                               NULL,
-@@ -1459,6 +1514,8 @@ grl_youtube_source_metadata (GrlMediaSource *source,
-                                               cancellable,
-                                               metadata_cb,
-                                               ms);
-+#endif /* !HAVE_LIBGDATA_0_9 */
-+
-       g_free (entryid);
-     }
- #else
-@@ -1524,6 +1581,17 @@ grl_youtube_get_media_from_uri (GrlMediaSource *source,
-   grl_operation_set_data (mfus->media_from_uri_id, cancellable);
- #ifdef GDATA_API_SUBJECT_TO_CHANGE
-   entry_id = g_strconcat ("tag:youtube.com,2008:video:", video_id, NULL);
-+
-+#ifdef HAVE_LIBGDATA_0_9
-+  gdata_service_query_single_entry_async (service,
-+                                          NULL,
-+                                          entry_id,
-+                                          NULL,
-+                                          GDATA_TYPE_YOUTUBE_VIDEO,
-+                                          cancellable,
-+                                          media_from_uri_cb,
-+                                          mfus);
-+#else /* HAVE_LIBGDATA_0_9 */
-   gdata_service_query_single_entry_async (service,
- 					  entry_id,
- 					  NULL,
-@@ -1531,6 +1599,8 @@ grl_youtube_get_media_from_uri (GrlMediaSource *source,
- 					  cancellable,
- 					  media_from_uri_cb,
- 					  mfus);
-+#endif /* !HAVE_LIBGDATA_0_9 */
-+
-   g_free (entry_id);
- #else
-   gdata_youtube_service_query_single_video_async (GDATA_YOUTUBE_SERVICE (service),
---
-cgit v0.9

diff --git a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-missing-case.patch b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-missing-case.patch
deleted file mode 100644
index a0329c0..0000000
--- a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-missing-case.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-From 477ddd90c29aba07a9ab2319a6fe9e6b6acef5c1 Mon Sep 17 00:00:00 2001
-From: Philip Withnall <philip@tecnocode.co.uk>
-Date: Mon, 04 Jul 2011 22:15:56 +0000
-Subject: youtube: Add a missing case to a switch statement
-
----
-diff --git a/src/media/youtube/grl-youtube.c b/src/media/youtube/grl-youtube.c
-index 7a08683..2bdaf01 100644
---- a/src/media/youtube/grl-youtube.c
-+++ b/src/media/youtube/grl-youtube.c
-@@ -1430,6 +1430,7 @@ grl_youtube_source_browse (GrlMediaSource *source,
-     case YOUTUBE_MEDIA_TYPE_CATEGORY:
-       produce_from_category (os);
-       break;
-+    case YOUTUBE_MEDIA_TYPE_VIDEO:
-     default:
-       g_assert_not_reached ();
-       break;
---
-cgit v0.9

diff --git a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-variable-shadowing.patch b/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-variable-shadowing.patch
deleted file mode 100644
index f1445a2..0000000
--- a/media-plugins/grilo-plugins/files/grilo-plugins-0.1.16-youtube-variable-shadowing.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From e4c40d02fc1b6627b66682a28cdbb4cbd71aad7e Mon Sep 17 00:00:00 2001
-From: Philip Withnall <philip@tecnocode.co.uk>
-Date: Mon, 04 Jul 2011 21:56:05 +0000
-Subject: youtube: Fix variable shadowing a parameter
-
----
-diff --git a/src/media/youtube/grl-youtube.c b/src/media/youtube/grl-youtube.c
-index 66609dd..050a80d 100644
---- a/src/media/youtube/grl-youtube.c
-+++ b/src/media/youtube/grl-youtube.c
-@@ -604,9 +604,9 @@ build_media_from_entry (GrlYoutubeSource *source,
- 	gdata_youtube_video_look_up_content (video,
- 					     "application/x-shockwave-flash");
-       if (youtube_content != NULL) {
--	GDataMediaContent *content = GDATA_MEDIA_CONTENT (youtube_content);
--	grl_media_set_external_player (media,
--				       gdata_media_content_get_uri (content));
-+        const gchar *uri =
-+          gdata_media_content_get_uri (GDATA_MEDIA_CONTENT (youtube_content));
-+	grl_media_set_external_player (media, uri);
-       }
-     }
-     iter = g_list_next (iter);
---
-cgit v0.9

diff --git a/media-plugins/grilo-plugins/grilo-plugins-0.1.16.ebuild b/media-plugins/grilo-plugins/grilo-plugins-0.1.16.ebuild
deleted file mode 100644
index 2004a7e..0000000
--- a/media-plugins/grilo-plugins/grilo-plugins-0.1.16.ebuild
+++ /dev/null
@@ -1,80 +0,0 @@
-# Copyright 1999-2011 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-plugins/grilo-plugins/grilo-plugins-0.1.15.ebuild,v 1.2 2011/06/15 16:43:45 pacho Exp $
-
-EAPI="4"
-GNOME2_LA_PUNT="yes"
-
-inherit autotools eutils gnome2
-
-DESCRIPTION="A framework for easy media discovery and browsing"
-HOMEPAGE="https://live.gnome.org/Grilo"
-
-LICENSE="LGPL-2.1"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-IUSE="+youtube +vimeo upnp"
-
-RDEPEND="
-	>=dev-libs/glib-2.26:2
-	=media-libs/grilo-${PV}[network]
-
-	dev-libs/gmime:2.4
-	dev-libs/libxml2:2
-	dev-db/sqlite:3
-
-	youtube? ( >=dev-libs/libgdata-0.4.0
-		>=media-libs/quvi-0.2.15 )
-	upnp? ( >=net-libs/gupnp-0.13
-		>=net-libs/gupnp-av-0.5 )
-	vimeo? ( net-libs/libsoup:2.4
-		dev-libs/libgcrypt )"
-DEPEND="${RDEPEND}
-	>=dev-util/pkgconfig-0.9"
-
-# `make check` doesn't do anything, and ${S}/test/test fails without all plugins
-RESTRICT="test"
-
-pkg_setup() {
-	DOCS="AUTHORS NEWS README"
-	# --enable-debug only changes CFLAGS, useless for us
-	G2CONF="${G2CONF}
-		--disable-maintainer-mode
-		--disable-static
-		--disable-debug
-		--disable-uninstalled"
-
-	# Plugins
-	# TODO: Enable tracker support
-	G2CONF="${G2CONF}
-		--enable-filesystem
-		--enable-jamendo
-		--enable-lastfm-albumart
-		--enable-flickr
-		--enable-podcasts
-		--enable-bookmarks
-		--disable-shoutcast
-		--enable-apple-trailers
-		--enable-metadata-store
-		--enable-gravatar
-		--disable-tracker
-		--enable-localmetadata
-		$(use_enable upnp)
-		$(use_enable youtube)
-		$(use_enable vimeo)"
-}
-
-src_prepare() {
-	# important patches from upstream git master
-	epatch "${FILESDIR}/${P}-youtube-c90.patch"
-	epatch "${FILESDIR}/${P}-youtube-variable-shadowing.patch"
-	epatch "${FILESDIR}/${P}-youtube-missing-case.patch"
-	epatch "${FILESDIR}/${P}-youtube-libgdata-0.9.patch"
-	epatch "${FILESDIR}/${P}-local-metadata-leak.patch"
-
-	sed -i -e 's/^\(SUBDIRS .*\)test/\1/g' Makefile.*
-
-	eautoreconf
-
-	gnome2_src_prepare
-}



^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-08-14 10:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-04  4:52 [gentoo-commits] proj/gnome:gnome-next commit in: media-libs/grilo/, media-plugins/grilo-plugins/files/, Alexandre Restovtsev
  -- strict thread matches above, loose matches on Subject: below --
2011-08-14 10:54 Nirbheek Chauhan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox