[Pkg-voip-commits] r10716 - in /portaudio19/trunk/debian: README.Debian changelog control patches/0001-pa_linux_alsa-fix-hang-in-callback-caused-by-abort.patch patches/series rules
bdrung at alioth.debian.org
bdrung at alioth.debian.org
Sun Dec 25 18:13:47 UTC 2016
Author: bdrung
Date: Sun Dec 25 18:13:43 2016
New Revision: 10716
URL: http://svn.debian.org/wsvn/pkg-voip/?sc=1&rev=10716
Log:
Import portaudio19 19+svn20140130-1.1
Added:
portaudio19/trunk/debian/README.Debian
portaudio19/trunk/debian/patches/0001-pa_linux_alsa-fix-hang-in-callback-caused-by-abort.patch
Modified:
portaudio19/trunk/debian/changelog
portaudio19/trunk/debian/control
portaudio19/trunk/debian/patches/series
portaudio19/trunk/debian/rules
Added: portaudio19/trunk/debian/README.Debian
URL: http://svn.debian.org/wsvn/pkg-voip/portaudio19/trunk/debian/README.Debian?rev=10716&op=file
==============================================================================
--- portaudio19/trunk/debian/README.Debian (added)
+++ portaudio19/trunk/debian/README.Debian Sun Dec 25 18:13:43 2016
@@ -0,0 +1,8 @@
+This package ships static libraries and they are compiled with -fPIC
+to let reverse dependencies use the static libraries as part of shared
+libraries and PIE binaries.
+
+The exception is discussed in this thread:
+ https://lists.debian.org/debian-devel/2016/09/msg00277.html
+
+ -- Balint Reczey <balint at balintreczey.hu>, Thu, 29 Sep 2016 13:47:13 +0200
Modified: portaudio19/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-voip/portaudio19/trunk/debian/changelog?rev=10716&op=diff
==============================================================================
--- portaudio19/trunk/debian/changelog (original)
+++ portaudio19/trunk/debian/changelog Sun Dec 25 18:13:43 2016
@@ -1,3 +1,13 @@
+portaudio19 (19+svn20140130-1.1) unstable; urgency=medium
+
+ * Non-maintainer upload.
+ * Fix lockups in portaudio after upgrading to alsa-lib 1.1.2
+ (Closes: #833950)
+ * Build only PIC objects (Closes: #837424)
+ * Move portaudio19-dev to section libdevel (Closes: #813990)
+
+ -- Balint Reczey <balint at balintreczey.hu> Thu, 29 Sep 2016 14:34:58 +0200
+
portaudio19 (19+svn20140130-1) unstable; urgency=medium
* New upstream release.
Modified: portaudio19/trunk/debian/control
URL: http://svn.debian.org/wsvn/pkg-voip/portaudio19/trunk/debian/control?rev=10716&op=diff
==============================================================================
--- portaudio19/trunk/debian/control (original)
+++ portaudio19/trunk/debian/control Sun Dec 25 18:13:43 2016
@@ -49,7 +49,7 @@
This package contains the shared library of the C++ bindings.
Package: portaudio19-dev
-Section: devel
+Section: libdevel
Architecture: any
Depends: libasound2-dev [linux-any],
libjack-dev,
Added: portaudio19/trunk/debian/patches/0001-pa_linux_alsa-fix-hang-in-callback-caused-by-abort.patch
URL: http://svn.debian.org/wsvn/pkg-voip/portaudio19/trunk/debian/patches/0001-pa_linux_alsa-fix-hang-in-callback-caused-by-abort.patch?rev=10716&op=file
==============================================================================
--- portaudio19/trunk/debian/patches/0001-pa_linux_alsa-fix-hang-in-callback-caused-by-abort.patch (added)
+++ portaudio19/trunk/debian/patches/0001-pa_linux_alsa-fix-hang-in-callback-caused-by-abort.patch Sun Dec 25 18:13:43 2016
@@ -0,0 +1,93 @@
+From f17d549093a9653285f81ff5a14f4a41d395fbce Mon Sep 17 00:00:00 2001
+From: Phil Burk <philburk at mobileer.com>
+Date: Wed, 14 Sep 2016 08:50:33 -0700
+Subject: [PATCH] pa_linux_alsa: fix hang in callback caused by abort
+
+The author of this patch is Alan Horstmann.
+
+Fixes ticket #251
+---
+ src/hostapi/alsa/pa_linux_alsa.c | 35 ++++++++++++++++++++++++++---------
+ 1 file changed, 26 insertions(+), 9 deletions(-)
+
+--- a/src/hostapi/alsa/pa_linux_alsa.c
++++ b/src/hostapi/alsa/pa_linux_alsa.c
+@@ -3810,8 +3810,23 @@
+ totalFds += self->playback.nfds;
+ }
+
++#ifdef PTHREAD_CANCELED
++ if( self->callbackMode )
++ {
++ /* To allow 'Abort' to terminate the callback thread, enable cancelability just for poll() (& disable after) */
++ pthread_setcancelstate( PTHREAD_CANCEL_ENABLE, NULL );
++ }
++#endif
++
+ pollResults = poll( self->pfds, totalFds, pollTimeout );
+
++#ifdef PTHREAD_CANCELED
++ if( self->callbackMode )
++ {
++ pthread_setcancelstate( PTHREAD_CANCEL_DISABLE, NULL );
++ }
++#endif
++
+ if( pollResults < 0 )
+ {
+ /* XXX: Depend on preprocessor condition? */
+@@ -4180,12 +4195,18 @@
+ int streamStarted = 0;
+
+ assert( stream );
++ /* Not implemented */
++ assert( !stream->primeBuffers );
+
+ /* Execute OnExit when exiting */
+ pthread_cleanup_push( &OnExit, stream );
+-
+- /* Not implemented */
+- assert( !stream->primeBuffers );
++#ifdef PTHREAD_CANCELED
++ /* 'Abort' will use thread cancellation to terminate the callback thread, but the Alsa-lib functions
++ * are NOT cancel-safe, (and can end up in an inconsistent state). So, disable cancelability for
++ * the thread here, and just re-enable it for the poll() in PaAlsaStream_WaitForFrames(). */
++ pthread_testcancel();
++ pthread_setcancelstate( PTHREAD_CANCEL_DISABLE, NULL );
++#endif
+
+ /* @concern StreamStart If the output is being primed the output pcm needs to be prepared, otherwise the
+ * stream is started immediately. The latter involves signaling the waiting main thread.
+@@ -4270,10 +4291,6 @@
+ {
+ xrun = 0;
+
+-#ifdef PTHREAD_CANCELED
+- pthread_testcancel();
+-#endif
+-
+ /** @concern Xruns Under/overflows are to be reported to the callback */
+ if( stream->underrun > 0.0 )
+ {
+@@ -4304,11 +4321,12 @@
+ #if 0
+ CallbackUpdate( &stream->threading );
+ #endif
++
+ CalculateTimeInfo( stream, &timeInfo );
+ PaUtil_BeginBufferProcessing( &stream->bufferProcessor, &timeInfo, cbFlags );
+ cbFlags = 0;
+
+- /* CPU load measurement should include processing activivity external to the stream callback */
++ /* CPU load measurement should include processing activity external to the stream callback */
+ PaUtil_BeginCpuLoadMeasurement( &stream->cpuLoadMeasurer );
+
+ framesGot = framesAvail;
+@@ -4339,7 +4357,6 @@
+ {
+ /* Go back to polling for more frames */
+ break;
+-
+ }
+
+ if( paContinue != callbackResult )
Modified: portaudio19/trunk/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-voip/portaudio19/trunk/debian/patches/series?rev=10716&op=diff
==============================================================================
--- portaudio19/trunk/debian/patches/series (original)
+++ portaudio19/trunk/debian/patches/series Sun Dec 25 18:13:43 2016
@@ -1 +1,2 @@
audacity-portmixer.patch
+0001-pa_linux_alsa-fix-hang-in-callback-caused-by-abort.patch
Modified: portaudio19/trunk/debian/rules
URL: http://svn.debian.org/wsvn/pkg-voip/portaudio19/trunk/debian/rules?rev=10716&op=diff
==============================================================================
--- portaudio19/trunk/debian/rules (original)
+++ portaudio19/trunk/debian/rules Sun Dec 25 18:13:43 2016
@@ -9,7 +9,7 @@
rm -f bindings/cpp/doc/Makefile doc/html/*
override_dh_auto_configure:
- dh_auto_configure -- --enable-cxx
+ dh_auto_configure -- --enable-cxx -with-pic=yes
override_dh_auto_build:
dh_auto_build
More information about the Pkg-voip-commits
mailing list