Hello community, here is the log from the commit of package grilo-plugins for openSUSE:Factory checked in at Thu Aug 11 15:39:32 CEST 2011. -------- New Changes file: --- /dev/null 2010-08-26 16:28:41.000000000 +0200 +++ /mounts/work_src_done/STABLE/grilo-plugins/grilo-plugins.changes 2011-08-04 15:42:09.000000000 +0200 @@ -0,0 +1,18 @@ +------------------------------------------------------------------- +Wed Aug 3 18:59:32 UTC 2011 - dimstar@opensuse.org + +- Spec file cleanup for inclusion into Factory. +- Add grilo-plugins-gdata0.9.patch: Fix build with gdata 0.9, taken + from git. + +------------------------------------------------------------------- +Fri Jul 8 13:51:01 UTC 2011 - cbosdonnat@novell.com + +- Added tracker-sparql-0.11 and libquvi dependencies for build on + Factory. + +------------------------------------------------------------------- +Thu Jul 7 15:59:54 UTC 2011 - cbosdonnat@novell.com + +- Initial package for grilo plugins + calling whatdependson for head-i586 New: ---- grilo-plugins-0.1.16.tar.bz2 grilo-plugins-gdata0.9.patch grilo-plugins.changes grilo-plugins.spec tracker-sparql-version.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ grilo-plugins.spec ++++++ # # spec file for package grilo-plugins # # Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: grilo-plugins Version: 0.1.16 Release: 1 # FIXME: The various plugins probably need to be split out in smaller packages. (see bnc#710364) License: LGPL-2.1+ Summary: Media discovering and browsing framework -- Media and Metadata Plugins Url: https://live.gnome.org/Grilo Group: Productivity/Multimedia/Other Source: http://ftp.gnome.org/pub/GNOME/sources/grilo/0.1/%{name}-%{version}.tar.bz2 # PATCH-FIX-UPSTREAM tracker-sparql-version.patch bgo#654248 cbosdonnat@suse.com -- Check for tracker-sparql-0.11 to build on Factory Patch0: tracker-sparql-version.patch # PATCH-FIX-UPSTREAM grilo-plugins-gdata0.9.patch dimstar@opensuse.org -- Fix build with libgdata 0.9. Taken from git, commits 4e36c - 37ee6 Patch1: grilo-plugins-gdata0.9.patch # Needed for Patch1 BuildRequires: gnome-common BuildRequires: pkgconfig(gio-2.0) BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(gmime-2.4) BuildRequires: pkgconfig(gmodule-2.0) BuildRequires: pkgconfig(gobject-2.0) BuildRequires: pkgconfig(grilo-0.1) = 0.1.16 BuildRequires: pkgconfig(gthread-2.0) BuildRequires: pkgconfig(gupnp-1.0) BuildRequires: pkgconfig(gupnp-av-1.0) BuildRequires: pkgconfig(libgdata) BuildRequires: pkgconfig(libsoup-2.4) BuildRequires: pkgconfig(libxml-2.0) BuildRequires: pkgconfig(sqlite3) %if 0%{?suse_version} > 1140 BuildRequires: pkgconfig(libquvi) >= 0.2.15 BuildRequires: pkgconfig(tracker-sparql-0.11) %else BuildRequires: pkgconfig(tracker-sparql-0.10) %endif BuildRoot: %{_tmppath}/%{name}-%{version}-build %description Grilo is a framework for browsing and searching media content from various sources using a single API. This package provides plugins for accessing content from various media providers, including podcasts, UPnP/DLNA, Apple trailers, Flickr, Jamendo, Vimeo, YouTube. %prep %setup -q %patch0 -p1 %patch1 -p1 %build # reconfiguration needed for patch1 NOCONFIGURE=1 gnome-autogen.sh %configure --disable-static make %{?_smp_mflags} %install %make_install find %{buildroot} -type f -name "*.la" -delete -print %check make check %clean %{?buildroot:rm -rf %{buildroot}} %files %defattr(-,root,root) %doc AUTHORS ChangeLog COPYING NEWS README # Explicitly list plugins %{_libdir}/grilo-0.1/libgrlappletrailers.so %{_datadir}/grilo-0.1/plugins/grl-apple-trailers.xml %{_libdir}/grilo-0.1/libgrlbookmarks.so %{_datadir}/grilo-0.1/plugins/grl-bookmarks.xml %{_libdir}/grilo-0.1/libgrlfilesystem.so %{_datadir}/grilo-0.1/plugins/grl-filesystem.xml %{_libdir}/grilo-0.1/libgrlflickr.so %{_datadir}/grilo-0.1/plugins/grl-flickr.xml %{_libdir}/grilo-0.1/libgrlgravatar.so %{_datadir}/grilo-0.1/plugins/grl-gravatar.xml %{_libdir}/grilo-0.1/libgrljamendo.so %{_datadir}/grilo-0.1/plugins/grl-jamendo.xml %{_libdir}/grilo-0.1/libgrllastfm-albumart.so %{_datadir}/grilo-0.1/plugins/grl-lastfm-albumart.xml %{_libdir}/grilo-0.1/libgrllocalmetadata.so %{_datadir}/grilo-0.1/plugins/grl-local-metadata.xml %{_libdir}/grilo-0.1/libgrlmetadatastore.so %{_datadir}/grilo-0.1/plugins/grl-metadata-store.xml %{_libdir}/grilo-0.1/libgrlpodcasts.so %{_datadir}/grilo-0.1/plugins/grl-podcasts.xml %{_libdir}/grilo-0.1/libgrltracker.so %{_datadir}/grilo-0.1/plugins/grl-tracker.xml %{_libdir}/grilo-0.1/libgrlupnp.so %{_datadir}/grilo-0.1/plugins/grl-upnp.xml %{_libdir}/grilo-0.1/libgrlvimeo.so %{_datadir}/grilo-0.1/plugins/grl-vimeo.xml %{_libdir}/grilo-0.1/libgrlyoutube.so %{_datadir}/grilo-0.1/plugins/grl-youtube.xml %changelog ++++++ grilo-plugins-gdata0.9.patch ++++++ Index: grilo-plugins-0.1.16/configure.ac =================================================================== --- grilo-plugins-0.1.16.orig/configure.ac +++ grilo-plugins-0.1.16/configure.ac @@ -118,7 +118,7 @@ PKG_CHECK_MODULES(GUPNPAV, gupnp-av-1.0 PKG_CHECK_MODULES(SQLITE, sqlite3, HAVE_SQLITE=yes, HAVE_SQLITE=no) -PKG_CHECK_MODULES(GDATA, libgdata >= 0.4.0, HAVE_GDATA=yes, HAVE_GDATA=no) +PKG_CHECK_MODULES(GDATA, libgdata >= 0.7.0, HAVE_GDATA=yes, HAVE_GDATA=no) PKG_CHECK_MODULES(QUVI, libquvi >= 0.2.15, HAVE_QUVI=yes, HAVE_QUVI=no) @@ -156,11 +156,8 @@ PKG_CHECK_MODULES(GLIB_2_26, glib-2.0 >= # ---------------------------------------------------------- if test "x$HAVE_GDATA" = "xyes"; then - gdata_version=`${PKG_CONFIG} --modversion libgdata` - gdata_version_major=`echo $gdata_version | awk -F. '{ print $1 }'` - gdata_version_minor=`echo $gdata_version | awk -F. '{ print $2 }'` - if test $gdata_version_major -eq 0 -a $gdata_version_minor -ge 7; then - GDATA_CFLAGS="$GDATA_CFLAGS -DGDATA_API_SUBJECT_TO_CHANGE" + 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 Index: grilo-plugins-0.1.16/src/media/youtube/grl-youtube.c =================================================================== --- grilo-plugins-0.1.16.orig/src/media/youtube/grl-youtube.c +++ grilo-plugins-0.1.16/src/media/youtube/grl-youtube.c @@ -250,6 +250,7 @@ grl_youtube_plugin_init (GrlPluginRegist 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 (GrlPluginRegist 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,12 +301,16 @@ G_DEFINE_TYPE (GrlYoutubeSource, grl_you 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"); + +#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; @@ -424,11 +428,15 @@ release_operation_data (GrlMetadataSourc } static OperationSpec * -operation_spec_new () +operation_spec_new (void) { + OperationSpec *os; + GRL_DEBUG ("Allocating new spec"); - OperationSpec *os = g_slice_new0 (OperationSpec); + + os = g_slice_new0 (OperationSpec); os->ref_count = 1; + return os; } @@ -453,7 +461,7 @@ operation_spec_ref (OperationSpec *os) } inline static GrlNetWc * -get_wc () +get_wc (void) { if (ytsrc && !ytsrc->priv->wc) ytsrc->priv->wc = grl_net_wc_new (); @@ -558,13 +566,9 @@ build_media_from_entry (GrlYoutubeSource } else if (iter->data == GRL_METADATA_KEY_DATE) { GTimeVal date; gchar *date_str; -#ifdef GDATA_API_SUBJECT_TO_CHANGE gint64 published = gdata_entry_get_published (entry); date.tv_sec = (glong) published; date.tv_usec = 0; -#else - gdata_entry_get_published (entry, &date); -#endif if (date.tv_sec != 0 || date.tv_usec != 0) { date_str = g_time_val_to_iso8601 (&date); grl_media_set_date (media, date_str); @@ -600,9 +604,9 @@ build_media_from_entry (GrlYoutubeSource 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); @@ -614,14 +618,14 @@ build_media_from_entry (GrlYoutubeSource 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,24 +804,19 @@ 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); -#ifdef GDATA_API_SUBJECT_TO_CHANGE video = gdata_service_query_single_entry_finish (service, result, &error); -#else - video = - GDATA_ENTRY (gdata_youtube_service_query_single_video_finish - (GDATA_YOUTUBE_SERVICE (service), result, &error)); -#endif + if (error) { release_operation_data (GRL_METADATA_SOURCE (ms->source), ms->metadata_id); error->code = GRL_CORE_ERROR_METADATA_FAILED; @@ -876,13 +875,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 +1044,10 @@ produce_container_from_directory (GDataS 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--; @@ -1131,6 +1130,18 @@ 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, @@ -1139,6 +1150,8 @@ produce_from_feed (OperationSpec *os) os, (GAsyncReadyCallback) search_cb, os); +#endif /* !HAVE_LIBGDATA_0_9 */ + g_object_unref (query); } @@ -1176,6 +1189,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, @@ -1183,6 +1207,8 @@ produce_from_category (OperationSpec *os os, (GAsyncReadyCallback) search_cb, os); +#endif /* !HAVE_LIBGDATA_0_9 */ + g_object_unref (query); } @@ -1235,13 +1261,7 @@ media_from_uri_cb (GObject *object, GAsy source = GRL_YOUTUBE_SOURCE (mfus->source); service = GDATA_SERVICE (source->priv->service); -#ifdef GDATA_API_SUBJECT_TO_CHANGE video = gdata_service_query_single_entry_finish (service, result, &error); -#else - video = - GDATA_ENTRY (gdata_youtube_service_query_single_video_finish - (GDATA_YOUTUBE_SERVICE (service), result, &error)); -#endif if (error) { error->code = GRL_CORE_ERROR_MEDIA_FROM_URI_FAILED; @@ -1325,6 +1345,17 @@ grl_youtube_source_search (GrlMediaSourc 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, @@ -1332,6 +1363,8 @@ grl_youtube_source_search (GrlMediaSourc os, (GAsyncReadyCallback) search_cb, os); +#endif /* !HAVE_LIBGDATA_0_9 */ + g_object_unref (query); } @@ -1382,6 +1415,7 @@ grl_youtube_source_browse (GrlMediaSourc case YOUTUBE_MEDIA_TYPE_CATEGORY: produce_from_category (os); break; + case YOUTUBE_MEDIA_TYPE_VIDEO: default: g_assert_not_reached (); break; @@ -1445,9 +1479,18 @@ grl_youtube_source_metadata (GrlMediaSou default: cancellable = g_cancellable_new (); grl_operation_set_data (ms->metadata_id, cancellable); -#ifdef GDATA_API_SUBJECT_TO_CHANGE - { - gchar *entryid = g_strconcat ("tag:youtube.com,2008:video:", id, NULL); + 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, @@ -1455,17 +1498,10 @@ grl_youtube_source_metadata (GrlMediaSou cancellable, metadata_cb, ms); +#endif /* !HAVE_LIBGDATA_0_9 */ + g_free (entryid); - } -#else - gdata_youtube_service_query_single_video_async (GDATA_YOUTUBE_SERVICE (service), - NULL, - id, - cancellable, - metadata_cb, - ms); -#endif - break; + break; } if (error) { @@ -1479,11 +1515,11 @@ grl_youtube_source_metadata (GrlMediaSou 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 +1530,13 @@ 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; + gchar *entry_id; + + GRL_DEBUG ("grl_youtube_get_media_from_uri"); video_id = get_video_id_from_url (mfus->uri); if (video_id == NULL) { @@ -1515,8 +1552,18 @@ grl_youtube_get_media_from_uri (GrlMedia 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); + +#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, @@ -1524,25 +1571,20 @@ grl_youtube_get_media_from_uri (GrlMedia 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), - NULL, - video_id, - cancellable, - media_from_uri_cb, - mfus); -#endif } 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); ++++++ tracker-sparql-version.patch ++++++ Index: grilo-plugins-0.1.16/configure.ac =================================================================== --- grilo-plugins-0.1.16.orig/configure.ac +++ grilo-plugins-0.1.16/configure.ac @@ -130,11 +130,13 @@ PKG_CHECK_MODULES(GTHREAD, gthread-2.0, PKG_CHECK_MODULES(GMIME, gmime-2.4, HAVE_GMIME=yes, HAVE_GMIME=no) -PKG_CHECK_MODULES(TRACKER_SPARQL, tracker-sparql-0.10, +PKG_CHECK_MODULES(TRACKER_SPARQL, tracker-sparql-0.11, HAVE_TRACKER_SPARQL=yes, - [PKG_CHECK_MODULES(TRACKER_SPARQL, tracker-sparql-0.9, + [PKG_CHECK_MODULES(TRACKER_SPARQL, tracker-sparql-0.10, HAVE_TRACKER_SPARQL=yes, - HAVE_TRACKER_SPARQL=no)]) + [PKG_CHECK_MODULES(TRACKER_SPARQL, tracker-sparql-0.9, + HAVE_TRACKER_SPARQL=yes, + HAVE_TRACKER_SPARQL=no)])]) PKG_CHECK_MODULES(TRACKER_0_10_5, tracker-sparql-0.10 >= 0.10.5, ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... -- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org