[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
30/217: gnu: farstream: Enable tests.
From: |
guix-commits |
Subject: |
30/217: gnu: farstream: Enable tests. |
Date: |
Sun, 14 Nov 2021 19:20:31 -0500 (EST) |
vagrantc pushed a commit to branch core-updates-frozen-batched-changes
in repository guix.
commit a21f4b3da0379ec9421f1684b34055b40fee36e9
Author: Raghav Gururajan <rg@raghavgururajan.name>
AuthorDate: Wed Jun 16 21:56:14 2021 -0400
gnu: farstream: Enable tests.
This patch depends on gstreamer's update to 1.18.4.
* gnu/packages/patches/farstream-gupnp.patch: New file.
* gnu/local.mk (dist_patch_DATA): Add it.
* gnu/packages/freedesktop.scm (farstream)[patches]: Use it.
[arguments](tests?): Remove argument.
[phases](disable-timeout-tests): New phase.
---
gnu/local.mk | 1 +
gnu/packages/freedesktop.scm | 16 +++-
gnu/packages/patches/farstream-gupnp.patch | 140 +++++++++++++++++++++++++++++
3 files changed, 154 insertions(+), 3 deletions(-)
diff --git a/gnu/local.mk b/gnu/local.mk
index 0d064a4..a0914e9 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1053,6 +1053,7 @@ dist_patch_DATA =
\
%D%/packages/patches/exercism-disable-self-update.patch \
%D%/packages/patches/extempore-unbundle-external-dependencies.patch \
%D%/packages/patches/extundelete-e2fsprogs-1.44.patch \
+ %D%/packages/patches/farstream-gupnp.patch \
%D%/packages/patches/farstream-make.patch \
%D%/packages/patches/fastcap-mulGlobal.patch \
%D%/packages/patches/fastcap-mulSetup.patch \
diff --git a/gnu/packages/freedesktop.scm b/gnu/packages/freedesktop.scm
index af42a07..d0083a8 100644
--- a/gnu/packages/freedesktop.scm
+++ b/gnu/packages/freedesktop.scm
@@ -225,12 +225,13 @@ application-centers for distributions.")
(sha256
(base32 "1sd8syldyq6bphfdm129s3gq554vfv7vh1vcwzk48gjryf101awk"))
(patches
- (search-patches "farstream-make.patch"))))
+ (search-patches
+ "farstream-gupnp.patch" ;for test 'transmitter/rawudp'
+ "farstream-make.patch"))))
(build-system glib-or-gtk-build-system)
(outputs '("out" "doc"))
(arguments
- `(#:tests? #f ;
https://gitlab.freedesktop.org/farstream/farstream/-/issues/18
- #:configure-flags
+ `(#:configure-flags
(list
"--enable-gtk-doc"
"--enable-glib-asserts"
@@ -246,6 +247,15 @@ application-centers for distributions.")
(assoc-ref %build-inputs "common")
"common")
#t))
+ (add-after 'unpack 'disable-timeout-tests
+ (lambda _
+ (substitute* "tests/check/Makefile.am"
+ ;; This test timeouts despite changing
+ ;; the value of 'CK_DEFAULT_TIMEOUT' to 600,
+ ;; as per %common-gstreamer-phases.
+ ;; Reported to upstream:
+ ;;
https://gitlab.freedesktop.org/farstream/farstream/-/issues/20
+ (("[ \t]*transmitter/nice.*$") ""))))
(add-after 'unpack 'patch-docbook-xml
(lambda* (#:key inputs #:allow-other-keys)
(with-directory-excursion "docs"
diff --git a/gnu/packages/patches/farstream-gupnp.patch
b/gnu/packages/patches/farstream-gupnp.patch
new file mode 100644
index 0000000..f46170a
--- /dev/null
+++ b/gnu/packages/patches/farstream-gupnp.patch
@@ -0,0 +1,140 @@
+From e70dcd0a9f89efbdaa011c20737ad550635ea580 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Olivier=20Cr=C3=AAte?= <olivier.crete@collabora.com>
+Date: Tue, 20 Oct 2020 19:51:22 -0400
+Subject: [PATCH] rawudp-upnp test: Also build against new GUPnP 1.2 library if
+ present
+
+Update the configure test to match
+---
+ configure.ac | 17 +++++++++++++++++
+ tests/check/Makefile.am | 7 +++----
+ tests/check/transmitter/rawudp-upnp.c | 16 ++++++++++++++--
+ tests/check/transmitter/rawudp.c | 4 ++--
+ 4 files changed, 36 insertions(+), 8 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 03afc96b..1efed132 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -370,8 +370,25 @@ fi
+
+ if test "x$HAVE_GUPNP" = "xyes"; then
+ AC_DEFINE(HAVE_GUPNP,,[Have the GUPnP IGD library])
++
++ PKG_CHECK_MODULES(GUPNP_CORE, [ gupnp-1.2 ],
++ [ HAVE_GUPNP_CORE_12=yes ],
++ [ HAVE_GUPNP_CORE_12=no
++ PKG_CHECK_MODULES(GUPNP_CORE, [ gupnp-1.0 ],
++ [ HAVE_GUPNP_CORE_10=yes ],
++ [ HAVE_GUPNP_CORE_10=no ])
++ ])
++
++ if test "x$HAVE_GUPNP_CORE_10" = "xyes"; then
++ AC_DEFINE(HAVE_GUPNP_CORE_10,,[Have the GUPnP 1.0 library])
++ fi
++
++ if test "x$HAVE_GUPNP_CORE_12" = "xyes"; then
++ AC_DEFINE(HAVE_GUPNP_CORE_12,,[Have the GUPnP 1.2 library])
++ fi
+ fi
+
++
+ dnl build static plugins or not
+ AC_MSG_CHECKING([whether to build static plugins or not])
+ AC_ARG_ENABLE(
+diff --git a/tests/check/Makefile.am b/tests/check/Makefile.am
+index d50fc264..d21687d7 100644
+--- a/tests/check/Makefile.am
++++ b/tests/check/Makefile.am
+@@ -76,9 +76,9 @@ base_fscodec_SOURCES = \
+
+
+ transmitter_rawudp_CFLAGS = $(AM_CFLAGS) \
+- $(GUPNP_CFLAGS) $(GIO_CFLAGS) $(NICE_CFLAGS)
++ $(GUPNP_CORE_CFLAGS) $(GIO_CFLAGS) $(NICE_CFLAGS)
+ transmitter_rawudp_LDADD = $(LDADD) \
+- $(GUPNP_LIBS) \
++ $(GUPNP_CORE_LIBS) \
+ $(GIO_LIBS) \
+ $(NICE_LIBS)
+ transmitter_rawudp_SOURCES = \
+@@ -113,9 +113,8 @@ transmitter_nice_SOURCES = \
+ transmitter_nice_LDADD = $(LDADD) $(GST_BASE_LIBS)
+
+
+-transmitter_shm_CFLAGS = $(AM_CFLAGS) $(GUPNP_CFLAGS) $(NICE_CFLAGS)
++transmitter_shm_CFLAGS = $(AM_CFLAGS) $(NICE_CFLAGS)
+ transmitter_shm_LDADD = $(LDADD) \
+- $(GUPNP_LIBS) \
+ $(NICE_LIBS)
+ transmitter_shm_SOURCES = \
+ check-threadsafe.h \
+diff --git a/tests/check/transmitter/rawudp-upnp.c
b/tests/check/transmitter/rawudp-upnp.c
+index 4818cd28..9ccf85d8 100644
+--- a/tests/check/transmitter/rawudp-upnp.c
++++ b/tests/check/transmitter/rawudp-upnp.c
+@@ -37,7 +37,7 @@ get_vars (gboolean *out_got_address,
+ }
+
+
+-#ifdef HAVE_GUPNP
++#if defined(HAVE_GUPNP_CORE_10) || defined(HAVE_GUPNP_CORE_12)
+
+ #include <libgupnp/gupnp.h>
+
+@@ -126,8 +126,14 @@ start_upnp_server (void)
+ GUPnPDeviceInfo *subdev1;
+ GUPnPDeviceInfo *subdev2;
+ const gchar *upnp_xml_path;
++ GError *gerr = NULL;
+
+- context = gupnp_context_new (NULL, NULL, 0, NULL);
++#ifdef HAVE_GUPNP_CORE_12
++ context = gupnp_context_new (NULL, 0, &gerr);
++#else
++ context = gupnp_context_new (NULL, NULL, 0, &gerr);
++#endif
++ g_assert_no_error (gerr);
+ ts_fail_if (context == NULL, "Can't get gupnp context");
+
+ if (g_getenv ("UPNP_XML_PATH"))
+@@ -137,8 +143,14 @@ start_upnp_server (void)
+
+ gupnp_context_host_path (context, upnp_xml_path, "");
+
++#ifdef HAVE_GUPNP_CORE_12
++ dev = gupnp_root_device_new (context, "InternetGatewayDevice.xml",
++ upnp_xml_path, &gerr);
++ g_assert_no_error (gerr);
++#else
+ dev = gupnp_root_device_new (context, "InternetGatewayDevice.xml",
+ upnp_xml_path);
++#endif
+ ts_fail_if (dev == NULL, "could not get root dev");
+
+ subdev1 = gupnp_device_info_get_device (GUPNP_DEVICE_INFO (dev),
+diff --git a/tests/check/transmitter/rawudp.c
b/tests/check/transmitter/rawudp.c
+index e1936ac0..d803f347 100644
+--- a/tests/check/transmitter/rawudp.c
++++ b/tests/check/transmitter/rawudp.c
+@@ -637,7 +637,7 @@ GST_START_TEST (test_rawudptransmitter_stop_stream)
+ }
+ GST_END_TEST;
+
+-#ifdef HAVE_GUPNP
++#if defined(HAVE_GUPNP_CORE_10) || defined (HAVE_GUPNP_CORE_12)
+
+ GST_START_TEST (test_rawudptransmitter_run_upnp_discovery)
+ {
+@@ -967,7 +967,7 @@ rawudptransmitter_suite (void)
+ tcase_add_test (tc_chain, test_rawudptransmitter_stop_stream);
+ suite_add_tcase (s, tc_chain);
+
+-#ifdef HAVE_GUPNP
++#if defined(HAVE_GUPNP_CORE_10) || defined (HAVE_GUPNP_CORE_12)
+ if (g_getenv ("UPNP")) {
+ gchar *multicast_addr;
+
+--
+GitLab
+
- 10/217: gnu: gdk-pixbuf+svg: Fix typo in comment., (continued)
- 10/217: gnu: gdk-pixbuf+svg: Fix typo in comment., guix-commits, 2021/11/14
- 16/217: gnu: cogl: Propagate gdk-pixbuf+svg rather than gdk-pixbuf., guix-commits, 2021/11/14
- 17/217: gnu: mutter: Propagate gdk-pixbuf+svg rather than gdk-pixbuf., guix-commits, 2021/11/14
- 19/217: gnu: gstreamer: Update to 1.18.4., guix-commits, 2021/11/14
- 20/217: gnu: gst-plugins-base: Update to 1.18.4., guix-commits, 2021/11/14
- 21/217: gnu: gst-plugins-base: Enable more features., guix-commits, 2021/11/14
- 22/217: gnu: gst-plugins-good: Update to 1.18.4., guix-commits, 2021/11/14
- 25/217: gnu: gst-plugins-bad: Update to 1.18.4., guix-commits, 2021/11/14
- 26/217: gnu: gst-plugins-bad: Add missing inputs to enable more features., guix-commits, 2021/11/14
- 29/217: gnu: e2fsprogs: Update to 1.46.2., guix-commits, 2021/11/14
- 30/217: gnu: farstream: Enable tests.,
guix-commits <=
- 31/217: gnu: libevdev: Update to 1.11.0., guix-commits, 2021/11/14
- 33/217: gnu: bluez: Update to 5.59., guix-commits, 2021/11/14
- 35/217: gnu: gnupg: Update to 2.2.30., guix-commits, 2021/11/14
- 32/217: gnu: python-docutils: Update to 0.17.1., guix-commits, 2021/11/14
- 36/217: gnu: python-sphinxcontrib-htmlhelp: Update to 2.0.0., guix-commits, 2021/11/14
- 38/217: gnu: python-sphinx: Update to 4.2.0., guix-commits, 2021/11/14
- 40/217: gnu: gstreamer: Update to 1.19.2., guix-commits, 2021/11/14
- 42/217: gnu: gst-plugins-good: Update to 1.19.2., guix-commits, 2021/11/14
- 44/217: gnu: gst-plugins-bad: Update to 1.19.2., guix-commits, 2021/11/14
- 45/217: gnu: gst-plugins-ugly: Update to 1.19.2., guix-commits, 2021/11/14