diff options
-rw-r--r-- | configure.ac | 32 | ||||
-rw-r--r-- | meson.build | 4 | ||||
-rw-r--r-- | src/librygel-core/rygel-core-2.6.deps | 2 | ||||
-rw-r--r-- | src/librygel-core/rygel-description-file.vala | 24 | ||||
-rw-r--r-- | src/librygel-core/rygel-root-device.vala | 11 | ||||
-rw-r--r-- | src/librygel-ruih/rygel-ruih-2.0.deps | 2 | ||||
-rw-r--r-- | src/librygel-server/rygel-server-2.6.deps | 2 | ||||
-rw-r--r-- | src/plugins/media-export/meson.build | 2 | ||||
-rw-r--r-- | src/plugins/media-export/rygel-media-export-dvd-container.vala | 4 | ||||
-rw-r--r-- | tests/meson.build | 2 |
10 files changed, 44 insertions, 41 deletions
diff --git a/configure.ac b/configure.ac index 95caac6c..2581024b 100644 --- a/configure.ac +++ b/configure.ac @@ -37,8 +37,8 @@ GLIB_REQUIRED=2.40.0 LIBXML_REQUIRED=2.7 VALA_REQUIRED=0.40.0 VALADOC_REQUIRED=0.2 -GSSDP_REQUIRED=0.14.15 -GUPNP_REQUIRED=0.20.14 +GSSDP_REQUIRED=1.1.0 +GUPNP_REQUIRED=1.1.0 GUPNP_AV_REQUIRED=0.12.8 GUPNP_DLNA_REQUIRED=0.9.4 GSTREAMER_REQUIRED=1.12 @@ -66,20 +66,20 @@ VALAFLAGS="--enable-deprecated --target-glib=2.40 $VALAFLAGS" ######################################################## ## Base ######################################################## -RYGEL_BASE_MODULES="gupnp-1.0 >= $GUPNP_REQUIRED gee-0.8 >= $GEE_REQUIRED" +RYGEL_BASE_MODULES="gupnp-1.2 >= $GUPNP_REQUIRED gee-0.8 >= $GEE_REQUIRED" PKG_CHECK_MODULES([LIBRYGEL_CORE_DEPS], [$RYGEL_BASE_MODULES - gssdp-1.0 >= $GSSDP_REQUIRED + gssdp-1.2 >= $GSSDP_REQUIRED gio-2.0 >= $GIO_REQUIRED gmodule-2.0 libxml-2.0 >= $LIBXML_REQUIRED]) -RYGEL_BASE_MODULES_VALAFLAGS='--pkg gupnp-1.0 --pkg gee-0.8' +RYGEL_BASE_MODULES_VALAFLAGS='--pkg gupnp-1.2 --pkg gee-0.8' ######################################################## ## Core ######################################################## -LIBRYGEL_CORE_DEPS_VALAFLAGS="$RYGEL_BASE_MODULES_VALAFLAGS --pkg gssdp-1.0 --pkg gio-2.0 --pkg gmodule-2.0 --pkg posix" +LIBRYGEL_CORE_DEPS_VALAFLAGS="$RYGEL_BASE_MODULES_VALAFLAGS --pkg gssdp-1.2 --pkg gio-2.0 --pkg gmodule-2.0 --pkg posix" AC_SUBST([LIBRYGEL_CORE_DEPS_VALAFLAGS]) ######################################################## @@ -114,13 +114,13 @@ AC_SUBST([LIBRYGEL_DB_DEPS_VALAFLAGS]) ######################################################## PKG_CHECK_MODULES([LIBRYGEL_SERVER_DEPS], [$RYGEL_COMMON_MODULES - gssdp-1.0 >= $GSSDP_REQUIRED + gssdp-1.2 >= $GSSDP_REQUIRED gio-2.0 >= $GIO_REQUIRED gmodule-2.0 libxml-2.0 >= $LIBXML_REQUIRED libsoup-2.4 >= $LIBSOUP_REQUIRED libmediaart-2.0 >= $MEDIAART_REQUIRED]) -LIBRYGEL_SERVER_DEPS_VALAFLAGS="$RYGEL_COMMON_MODULES_VALAFLAGS --pkg gssdp-1.0 --pkg gio-2.0 --pkg libsoup-2.4 --pkg gmodule-2.0 --pkg libmediaart-2.0" +LIBRYGEL_SERVER_DEPS_VALAFLAGS="$RYGEL_COMMON_MODULES_VALAFLAGS --pkg gssdp-1.2 --pkg gio-2.0 --pkg libsoup-2.4 --pkg gmodule-2.0 --pkg libmediaart-2.0" AC_SUBST([LIBRYGEL_SERVER_DEPS_VALAFLAGS]) ######################################################## @@ -147,7 +147,7 @@ AC_SUBST([LIBRYGEL_RUIH_DEPS_VALAFLAGS]) PKG_CHECK_MODULES([RYGEL_DEPS], [$RYGEL_COMMON_MODULES gio-2.0 >= $GIO_REQUIRED - gssdp-1.0 >= $GSSDP_REQUIRED]) + gssdp-1.2 >= $GSSDP_REQUIRED]) # Not all tests use all of these dependencies, @@ -159,10 +159,10 @@ PKG_CHECK_MODULES([RYGEL_DEPS], PKG_CHECK_MODULES([TEST_DEPS], [$RYGEL_COMMON_MODULES gio-2.0 >= $GIO_REQUIRED - gssdp-1.0 >= $GSSDP_REQUIRED + gssdp-1.2 >= $GSSDP_REQUIRED libsoup-2.4 >= $LIBSOUP_REQUIRED libxml-2.0 >= $LIBXML_REQUIRED]) -TEST_DEPS_VALAFLAGS="$RYGEL_COMMON_MODULES_VALAFLAGS --pkg gio-2.0 --pkg gssdp-1.0 --pkg libsoup-2.4 --pkg libxml-2.0 --pkg gmodule-2.0" +TEST_DEPS_VALAFLAGS="$RYGEL_COMMON_MODULES_VALAFLAGS --pkg gio-2.0 --pkg gssdp-1.2 --pkg libsoup-2.4 --pkg libxml-2.0 --pkg gmodule-2.0" AC_SUBST([TEST_DEPS_VALAFLAGS]) ######################################################## @@ -171,7 +171,7 @@ AC_SUBST([TEST_DEPS_VALAFLAGS]) PKG_CHECK_MODULES([EXAMPLE_DEPS], [$RYGEL_COMMON_MODULES gio-2.0 >= $GIO_REQUIRED - gssdp-1.0 >= $GSSDP_REQUIRED]) + gssdp-1.2 >= $GSSDP_REQUIRED]) dnl Media engine to use BUILT_ENGINES="librygel-media-engine-simple" @@ -349,15 +349,15 @@ AC_ARG_WITH( ui, HAVE_GTK=no if test x$try_ui = xyes ; then dnl check for gtk - PKG_CHECK_MODULES([RYGEL_UI_DEPS], [$RYGEL_BASE_MODULES gtk+-3.0 >= $GTK_REQUIRED gssdp-1.0 >= $GSSDP_REQUIRED gee-0.8 >= $GEE_REQUIRED], + PKG_CHECK_MODULES([RYGEL_UI_DEPS], [$RYGEL_BASE_MODULES gtk+-3.0 >= $GTK_REQUIRED gssdp-1.2 >= $GSSDP_REQUIRED gee-0.8 >= $GEE_REQUIRED], [ RYGEL_CHECK_PACKAGES([gtk+-3.0], [HAVE_GTK=yes]) - RYGEL_UI_DEPS_VALAFLAGS="$RYGEL_BASE_MODULES_VALAFLAGS --pkg gtk+-3.0 --pkg gssdp-1.0 --pkg gee-0.8" + RYGEL_UI_DEPS_VALAFLAGS="$RYGEL_BASE_MODULES_VALAFLAGS --pkg gtk+-3.0 --pkg gssdp-1.2 --pkg gee-0.8" AC_SUBST([RYGEL_UI_DEPS_VALAFLAGS]) PKG_CHECK_MODULES([EXAMPLE_UI_DEPS], [$RYGEL_COMMON_MODULES gio-2.0 >= $GIO_REQUIRED - gssdp-1.0 >= $GSSDP_REQUIRED + gssdp-1.2 >= $GSSDP_REQUIRED gstreamer-video-1.0 >= $GSTREAMER_REQUIRED gtk+-3.0 >= $GTK_REQUIRED],, [ @@ -447,7 +447,7 @@ AS_IF([test "x$enable_tracker_plugin" = "xyes"], # This should be called only after all RYGEL_CHECK_VALA() and RYGEL_ADD_PLUGIN() calls: RYGEL_CHECK_VALA([$VALA_REQUIRED], - [gupnp-1.0 + [gupnp-1.2 gupnp-av-1.0 gio-2.0 gee-0.8 diff --git a/meson.build b/meson.build index cab6efd6..9ea273a7 100644 --- a/meson.build +++ b/meson.build @@ -68,9 +68,9 @@ add_global_arguments(['-include','config.h'], language : 'c') valadoc = find_program('valadoc', required : false) gtkdoc = dependency('gtk-doc', required : false) -gupnp = dependency('gupnp-1.0', version : '>= 1.0') +gupnp = dependency('gupnp-1.2', version : '>= 1.1') gee = dependency('gee-0.8', version: '>= 0.8.0') -gssdp = dependency('gssdp-1.0', version : '>= 1.0') +gssdp = dependency('gssdp-1.2', version : '>= 1.1') glib = dependency('glib-2.0', version : '>= 2.26') gio = dependency('gio-2.0', version : '>= 2.26') gio_unix = dependency('gio-unix-2.0', version : '>= 2.26') diff --git a/src/librygel-core/rygel-core-2.6.deps b/src/librygel-core/rygel-core-2.6.deps index c65d41bb..e30cec7a 100644 --- a/src/librygel-core/rygel-core-2.6.deps +++ b/src/librygel-core/rygel-core-2.6.deps @@ -1,4 +1,4 @@ gee-0.8 gio-2.0 libxml-2.0 -gupnp-1.0 +gupnp-1.2 diff --git a/src/librygel-core/rygel-description-file.vala b/src/librygel-core/rygel-description-file.vala index 8649dafe..e08e47d8 100644 --- a/src/librygel-core/rygel-description-file.vala +++ b/src/librygel-core/rygel-description-file.vala @@ -162,7 +162,7 @@ public class Rygel.DescriptionFile : Object { * @return The currenly set friendly name. */ public string get_friendly_name () { - var element = Rygel.XMLUtils.get_element ((Xml.Node *) this.doc.doc, + var element = Rygel.XMLUtils.get_element ((Xml.Node *) this.doc.get_doc (), "root", "device", "friendlyName"); @@ -188,7 +188,7 @@ public class Rygel.DescriptionFile : Object { * @return The currenly set UDN. */ public string? get_udn () { - var element = Rygel.XMLUtils.get_element ((Xml.Node *) this.doc.doc, + var element = Rygel.XMLUtils.get_element ((Xml.Node *) this.doc.get_doc (), "root", "device", "UDN"); @@ -376,13 +376,13 @@ public class Rygel.DescriptionFile : Object { private Xml.Node* get_device_element () { return Rygel.XMLUtils.get_element - ((Xml.Node *) this.doc.doc, + ((Xml.Node *) this.doc.get_doc (), "root", "device"); } private bool apply_xpath (string xpath, out Xml.XPath.Object *xpo) { - var context = new XPath.Context (this.doc.doc); + var context = new XPath.Context (this.doc.get_doc ()); var result = context.eval_expression (xpath); var retval = result != null && @@ -400,7 +400,7 @@ public class Rygel.DescriptionFile : Object { public void add_service (string device_name, ResourceInfo resource_info) { var list = Rygel.XMLUtils.get_element - ((Xml.Node *) this.doc.doc, + ((Xml.Node *) this.doc.get_doc (), "root", "device", "serviceList"); @@ -432,7 +432,7 @@ public class Rygel.DescriptionFile : Object { IconInfo icon_info, string url) { var list = Rygel.XMLUtils.get_element - ((Xml.Node *) this.doc.doc, + ((Xml.Node *) this.doc.get_doc (), "root", "device", "iconList"); @@ -488,7 +488,7 @@ public class Rygel.DescriptionFile : Object { public void save (string path) throws GLib.Error { string mem = null; int len = -1; - doc.doc.dump_memory_enc (out mem, out len, "UTF-8"); + doc.get_doc ().dump_memory_enc (out mem, out len, "UTF-8"); if (unlikely (len <= 0)) { var message = _("Failed to write modified description to %s"); @@ -521,7 +521,7 @@ public class Rygel.DescriptionFile : Object { string? new_value, string? ns = null) { var xml_element = Rygel.XMLUtils.get_element - ((Xml.Node *) this.doc.doc, + ((Xml.Node *) this.doc.get_doc (), "root", "device", element); @@ -532,13 +532,13 @@ public class Rygel.DescriptionFile : Object { // Element not found: create it var device_element = Rygel.XMLUtils.get_element - ((Xml.Node *) this.doc.doc, + ((Xml.Node *) this.doc.get_doc (), "root", "device"); Xml.Ns *xml_ns = null; if (ns != null) { - xml_ns = this.doc.doc.search_ns(device_element, ns); + xml_ns = this.doc.get_doc ().search_ns(device_element, ns); } xml_element = device_element->new_child (xml_ns, element, new_value); @@ -550,7 +550,7 @@ public class Rygel.DescriptionFile : Object { Xml.Node* sibling = null; for (index--; index > 0; index--) { sibling = Rygel.XMLUtils.get_element - ((Xml.Node *) this.doc.doc, + ((Xml.Node *) this.doc.get_doc (), "root", "device", device_elements[index]); @@ -580,7 +580,7 @@ public class Rygel.DescriptionFile : Object { */ private void remove_device_element (string element) { var xml_element = Rygel.XMLUtils.get_element - ((Xml.Node *) this.doc.doc, + ((Xml.Node *) this.doc.get_doc (), "root", "device", element); diff --git a/src/librygel-core/rygel-root-device.vala b/src/librygel-core/rygel-root-device.vala index 4d212d51..b14bf8c0 100644 --- a/src/librygel-core/rygel-root-device.vala +++ b/src/librygel-core/rygel-root-device.vala @@ -37,23 +37,24 @@ using Gee; * having first instantiated the #RygelRootDeviceFactory * for a #GUPnPContext. */ -public class Rygel.RootDevice: GUPnP.RootDevice { +public class Rygel.RootDevice: GUPnP.RootDevice, GLib.Initable { public ArrayList<ServiceInfo> services { get; internal set; } /* Services we implement */ public RootDevice (GUPnP.Context context, Plugin plugin, XMLDoc description_doc, string description_path, - string description_dir) { + string description_dir) throws Error { Object (context : context, resource_factory : plugin, description_doc : description_doc, description_path: description_path, description_dir: description_dir); + init (null); } - public override void constructed () { - base.constructed (); + public bool init (Cancellable? cancellable) throws Error { + base.init (cancellable); this.services = new ArrayList<ServiceInfo> (); var plugin = this.resource_factory as Plugin; @@ -67,5 +68,7 @@ public class Rygel.RootDevice: GUPnP.RootDevice { this.services.add (service); } } + + return true; } } diff --git a/src/librygel-ruih/rygel-ruih-2.0.deps b/src/librygel-ruih/rygel-ruih-2.0.deps index 55a17667..490da8a3 100644 --- a/src/librygel-ruih/rygel-ruih-2.0.deps +++ b/src/librygel-ruih/rygel-ruih-2.0.deps @@ -1,5 +1,5 @@ gee-0.8 -gupnp-1.0 +gupnp-1.2 gio-2.0 rygel-core-2.6 gupnp-av-1.0 diff --git a/src/librygel-server/rygel-server-2.6.deps b/src/librygel-server/rygel-server-2.6.deps index 55a17667..490da8a3 100644 --- a/src/librygel-server/rygel-server-2.6.deps +++ b/src/librygel-server/rygel-server-2.6.deps @@ -1,5 +1,5 @@ gee-0.8 -gupnp-1.0 +gupnp-1.2 gio-2.0 rygel-core-2.6 gupnp-av-1.0 diff --git a/src/plugins/media-export/meson.build b/src/plugins/media-export/meson.build index f036e490..46f9918c 100644 --- a/src/plugins/media-export/meson.build +++ b/src/plugins/media-export/meson.build @@ -19,7 +19,7 @@ mx_extract_sources = [ mx_extract = executable('mx-extract', mx_extract_sources, - dependencies : mx_export_deps, + dependencies : [mx_export_deps, gssdp], c_args : ['-DG_LOG_DOMAIN="MxExtract"'], link_with: constants, install: true, diff --git a/src/plugins/media-export/rygel-media-export-dvd-container.vala b/src/plugins/media-export/rygel-media-export-dvd-container.vala index 028ff6b6..44f64900 100644 --- a/src/plugins/media-export/rygel-media-export-dvd-container.vala +++ b/src/plugins/media-export/rygel-media-export-dvd-container.vala @@ -58,7 +58,7 @@ internal class Rygel.MediaExport.DVDContainer : SimpleContainer, UpdatableObject Xml.ParserOption.NONET); this.doc = new GUPnP.XMLDoc (doc); - var context = new Xml.XPath.Context (this.doc.doc); + var context = new Xml.XPath.Context (this.doc.get_doc ()); var xpo = context.eval ("/lsdvd/track"); if (xpo->type != Xml.XPath.ObjectType.NODESET) { warning ("No tracks found in DVD"); @@ -82,7 +82,7 @@ internal class Rygel.MediaExport.DVDContainer : SimpleContainer, UpdatableObject var parts = id.split (":"); var track = int.parse (parts[2]); - var context = new Xml.XPath.Context (this.doc.doc); + var context = new Xml.XPath.Context (this.doc.get_doc ()); var xpo = context.eval ("/lsdvd/track"); if (!(xpo->type == Xml.XPath.ObjectType.NODESET && xpo->nodesetval->length () >= track)) { diff --git a/tests/meson.build b/tests/meson.build index a1e3a71a..480f9d1d 100644 --- a/tests/meson.build +++ b/tests/meson.build @@ -4,7 +4,7 @@ searchable_container_test = executable( 'rygel-searchable-container-test', files('searchable-container/rygel-searchable-container.vala', 'searchable-container/test.vala'), - dependencies : [test_deps, gupnp_av, gio] + dependencies : [test_deps, gupnp_av, gio, gssdp] ) object_creator_test = executable( |