diff options
author | jbeich <jbeich@FreeBSD.org> | 2017-01-14 01:59:03 +0800 |
---|---|---|
committer | jbeich <jbeich@FreeBSD.org> | 2017-01-14 01:59:03 +0800 |
commit | fca5d710542893b1ce9d1d26fe7e065fd870b62c (patch) | |
tree | 6ec14c5ac81f03af1b5d5d253498c32206221be4 /www | |
parent | 216fb579305df6fdaef8fb986d30ef343976d3d6 (diff) | |
download | freebsd-ports-gnome-fca5d710542893b1ce9d1d26fe7e065fd870b62c.tar.gz freebsd-ports-gnome-fca5d710542893b1ce9d1d26fe7e065fd870b62c.tar.zst freebsd-ports-gnome-fca5d710542893b1ce9d1d26fe7e065fd870b62c.zip |
www/firefox-esr: improve A/V sync with SNDIO=on
PR: 215867
Reported by: Sergey <kpect@protonmail.com>
Submitted by: Tobias Kortkamp <t@tobik.me>
Obtained from: upstream
MFH: 2017Q1
Diffstat (limited to 'www')
-rw-r--r-- | www/firefox-esr/Makefile | 2 | ||||
-rw-r--r-- | www/firefox-esr/files/patch-bug1153151 | 13 | ||||
-rw-r--r-- | www/firefox-esr/files/patch-bug1153179 | 40 | ||||
-rw-r--r-- | www/libxul/Makefile | 2 | ||||
-rw-r--r-- | www/libxul/files/patch-bug1153151 | 13 | ||||
-rw-r--r-- | www/libxul/files/patch-bug1153179 | 40 |
6 files changed, 108 insertions, 2 deletions
diff --git a/www/firefox-esr/Makefile b/www/firefox-esr/Makefile index 741139e80508..60512c75f183 100644 --- a/www/firefox-esr/Makefile +++ b/www/firefox-esr/Makefile @@ -4,7 +4,7 @@ PORTNAME= firefox DISTVERSION= 45.6.0 DISTVERSIONSUFFIX=esr.source -PORTREVISION= 4 +PORTREVISION= 5 PORTEPOCH= 1 CATEGORIES= www ipv6 MASTER_SITES= MOZILLA/${PORTNAME}/releases/${DISTVERSION}esr/source \ diff --git a/www/firefox-esr/files/patch-bug1153151 b/www/firefox-esr/files/patch-bug1153151 new file mode 100644 index 000000000000..855cdab89472 --- /dev/null +++ b/www/firefox-esr/files/patch-bug1153151 @@ -0,0 +1,13 @@ +Bug 1153151 - make libcubeb sndio use non-blocking i/o + +--- media/libcubeb/src/cubeb_sndio.c.orig 2017-01-12 17:53:15 UTC ++++ media/libcubeb/src/cubeb_sndio.c +@@ -187,7 +187,7 @@ sndio_stream_init(cubeb *context, + if (s == NULL) + return CUBEB_ERROR; + s->context = context; +- s->hdl = sio_open(NULL, SIO_PLAY, 0); ++ s->hdl = sio_open(NULL, SIO_PLAY, 1); + if (s->hdl == NULL) { + free(s); + DPR("sndio_stream_init(), sio_open() failed\n"); diff --git a/www/firefox-esr/files/patch-bug1153179 b/www/firefox-esr/files/patch-bug1153179 new file mode 100644 index 000000000000..f39c9bbdcd82 --- /dev/null +++ b/www/firefox-esr/files/patch-bug1153179 @@ -0,0 +1,40 @@ +Bug 1153179 - fix latency reporting in libcubeb sndio + +--- media/libcubeb/src/cubeb_sndio.c.orig 2017-01-12 17:53:15 UTC ++++ media/libcubeb/src/cubeb_sndio.c +@@ -67,7 +67,7 @@ sndio_onmove(void *arg, int delta) + { + cubeb_stream *s = (cubeb_stream *)arg; + +- s->rdpos += delta; ++ s->rdpos += delta * s->bpf; + } + + static void * +@@ -135,7 +135,7 @@ sndio_mainloop(void *arg) + state = CUBEB_STATE_ERROR; + break; + } +- s->wrpos = 0; ++ s->wrpos += n; + start += n; + } + } +@@ -326,7 +336,7 @@ sndio_stream_get_position(cubeb_stream * + { + pthread_mutex_lock(&s->mtx); + DPR("sndio_stream_get_position() %lld\n", s->rdpos); +- *p = s->rdpos; ++ *p = s->rdpos / s->bpf; + pthread_mutex_unlock(&s->mtx); + return CUBEB_OK; + } +@@ -346,7 +356,7 @@ sndio_stream_get_latency(cubeb_stream * + { + // http://www.openbsd.org/cgi-bin/man.cgi?query=sio_open + // in the "Measuring the latency and buffers usage" paragraph. +- *latency = stm->wrpos - stm->rdpos; ++ *latency = (stm->wrpos - stm->rdpos) / stm->bpf; + return CUBEB_OK; + } + diff --git a/www/libxul/Makefile b/www/libxul/Makefile index b353282a69c5..175513256946 100644 --- a/www/libxul/Makefile +++ b/www/libxul/Makefile @@ -3,7 +3,7 @@ PORTNAME= libxul DISTVERSION= 45.6.0 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES?= www devel MASTER_SITES= MOZILLA/firefox/releases/${DISTVERSION}esr/source \ MOZILLA/firefox/candidates/${DISTVERSION}esr-candidates/build1/source diff --git a/www/libxul/files/patch-bug1153151 b/www/libxul/files/patch-bug1153151 new file mode 100644 index 000000000000..855cdab89472 --- /dev/null +++ b/www/libxul/files/patch-bug1153151 @@ -0,0 +1,13 @@ +Bug 1153151 - make libcubeb sndio use non-blocking i/o + +--- media/libcubeb/src/cubeb_sndio.c.orig 2017-01-12 17:53:15 UTC ++++ media/libcubeb/src/cubeb_sndio.c +@@ -187,7 +187,7 @@ sndio_stream_init(cubeb *context, + if (s == NULL) + return CUBEB_ERROR; + s->context = context; +- s->hdl = sio_open(NULL, SIO_PLAY, 0); ++ s->hdl = sio_open(NULL, SIO_PLAY, 1); + if (s->hdl == NULL) { + free(s); + DPR("sndio_stream_init(), sio_open() failed\n"); diff --git a/www/libxul/files/patch-bug1153179 b/www/libxul/files/patch-bug1153179 new file mode 100644 index 000000000000..f39c9bbdcd82 --- /dev/null +++ b/www/libxul/files/patch-bug1153179 @@ -0,0 +1,40 @@ +Bug 1153179 - fix latency reporting in libcubeb sndio + +--- media/libcubeb/src/cubeb_sndio.c.orig 2017-01-12 17:53:15 UTC ++++ media/libcubeb/src/cubeb_sndio.c +@@ -67,7 +67,7 @@ sndio_onmove(void *arg, int delta) + { + cubeb_stream *s = (cubeb_stream *)arg; + +- s->rdpos += delta; ++ s->rdpos += delta * s->bpf; + } + + static void * +@@ -135,7 +135,7 @@ sndio_mainloop(void *arg) + state = CUBEB_STATE_ERROR; + break; + } +- s->wrpos = 0; ++ s->wrpos += n; + start += n; + } + } +@@ -326,7 +336,7 @@ sndio_stream_get_position(cubeb_stream * + { + pthread_mutex_lock(&s->mtx); + DPR("sndio_stream_get_position() %lld\n", s->rdpos); +- *p = s->rdpos; ++ *p = s->rdpos / s->bpf; + pthread_mutex_unlock(&s->mtx); + return CUBEB_OK; + } +@@ -346,7 +356,7 @@ sndio_stream_get_latency(cubeb_stream * + { + // http://www.openbsd.org/cgi-bin/man.cgi?query=sio_open + // in the "Measuring the latency and buffers usage" paragraph. +- *latency = stm->wrpos - stm->rdpos; ++ *latency = (stm->wrpos - stm->rdpos) / stm->bpf; + return CUBEB_OK; + } + |