rpms/xine-lib/F-9 xine-lib-1.1.15-avsync_hack.patch, NONE, 1.1 xine-lib-safe-audio-pause.patch, NONE, 1.1 .cvsignore, 1.18, 1.19 sources, 1.19, 1.20 xine-lib-mk-autotools-patch.sh, 1.3, 1.4 xine-lib.spec, 1.49, 1.50

Rex Dieter rdieter at fedoraproject.org
Tue Feb 10 23:17:30 UTC 2009


Author: rdieter

Update of /cvs/pkgs/rpms/xine-lib/F-9
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv2632

Modified Files:
	.cvsignore sources xine-lib-mk-autotools-patch.sh 
	xine-lib.spec 
Added Files:
	xine-lib-1.1.15-avsync_hack.patch 
	xine-lib-safe-audio-pause.patch 
Log Message:
* Tue Feb 10 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.16.2-1
- xine-lib-1.1.16.2


xine-lib-1.1.15-avsync_hack.patch:

--- NEW FILE xine-lib-1.1.15-avsync_hack.patch ---
diff -uNr xine-lib-1.1.15.orig/src/xine-engine/audio_out.c xine-lib-1.1.15/src/xine-engine/audio_out.c
--- xine-lib-1.1.15.orig/src/xine-engine/audio_out.c	2008-07-10 18:19:10.000000000 +0200
+++ xine-lib-1.1.15/src/xine-engine/audio_out.c	2009-01-10 21:57:20.000000000 +0100
@@ -1151,8 +1151,17 @@
   
     /*
      * calculate gap:
+     *
+     * HACK (rwa): If we have no video stream we do not need an AV sync and so
+     *             we assume a gap of 0. This seems to avoid the skips in the
+     *             first seconds when playing audio-only via the "glitch-free"
+     *             pulseaudio server.
      */
-    gap = in_buf->vpts - hw_vpts;
+    if (in_buf && in_buf->stream && in_buf->stream->video_decoder_plugin) {
+	gap = in_buf->vpts - hw_vpts;
+    } else {
+	gap = 0;
+    }
     lprintf ("hw_vpts : %" PRId64 " buffer_vpts : %" PRId64 " gap : %" PRId64 "\n",
              hw_vpts, in_buf->vpts, gap);
 

xine-lib-safe-audio-pause.patch:

--- NEW FILE xine-lib-safe-audio-pause.patch ---
diff -r ce4b1533a0af src/xine-engine/audio_out.c
--- a/src/xine-engine/audio_out.c	Sun Jan 11 22:24:42 2009 +0000
+++ b/src/xine-engine/audio_out.c	Sat Feb 07 15:09:24 2009 -0200
@@ -243,6 +243,7 @@
   audio_fifo_t   *free_fifo;
   audio_fifo_t   *out_fifo;
   int64_t         last_audio_vpts;
+  pthread_mutex_t current_speed_lock;
   uint32_t        current_speed;        /* the current playback speed */
   /* FIXME: replace all this->clock->speed with this->current_speed. we should make
    * sure nobody will change speed without going through xine.c:set_speed_internal */
@@ -1040,6 +1041,7 @@
      * we must process/free buffers otherwise the entire engine will stop.
      */
     
+    pthread_mutex_lock(&this->current_speed_lock);
     if ( this->audio_loop_running && 
          (this->clock->speed == XINE_SPEED_PAUSE || 
           (this->clock->speed != XINE_FINE_SPEED_NORMAL && 
@@ -1055,6 +1057,7 @@
 	    _x_refcounter_dec(in_buf->stream->refcounter);
 	  fifo_append (this->free_fifo, in_buf);
 	  in_buf = NULL;
+	  pthread_mutex_unlock(&this->current_speed_lock);
 	  continue;
 	}
 
@@ -1065,6 +1068,7 @@
       }
 
       lprintf ("loop:pause: I feel sleepy (%d buffers).\n", this->out_fifo->num_buffers);
+      pthread_mutex_unlock(&this->current_speed_lock);
       xine_usec_sleep (10000);
       lprintf ("loop:pause: I wake up.\n");
       continue;
@@ -1274,6 +1278,7 @@
       fifo_append (this->free_fifo, in_buf);
       in_buf = NULL;
     }
+    pthread_mutex_unlock(&this->current_speed_lock);
 
     /* Give other threads a chance to use functions which require this->driver_lock to
      * be available. This is needed when using NPTL on Linux (and probably PThreads
@@ -1684,6 +1689,7 @@
   free (this->frame_buf[1]);
   free (this->zero_space);
   
+  pthread_mutex_destroy(&this->current_speed_lock);
   pthread_mutex_destroy(&this->flush_audio_driver_lock);
   pthread_cond_destroy(&this->flush_audio_driver_reached);
 
@@ -1910,11 +1916,15 @@
     if (value != XINE_FINE_SPEED_NORMAL && value != XINE_SPEED_PAUSE && !this->slow_fast_audio )
       this->ao.control(&this->ao, AO_CTRL_FLUSH_BUFFERS, NULL);
 
+    /* current_speed_lock is here to make sure the ao_loop will pause in a safe place.
+     * that is, we cannot pause writing to device, filling gaps etc. */
+    pthread_mutex_lock(&this->current_speed_lock);
     this->ao.control(&this->ao,
       	             (value == XINE_SPEED_PAUSE) ? AO_CTRL_PLAY_PAUSE : AO_CTRL_PLAY_RESUME, NULL);
     this->current_speed = value;
     if( this->slow_fast_audio )
       ao_update_resample_factor(this);
+    pthread_mutex_unlock(&this->current_speed_lock);
     break;
     
   default:
@@ -2056,6 +2066,7 @@
   this->driver                = driver;
   this->xine                  = xine;
   this->clock                 = xine->clock;
+  this->current_speed         = xine->clock->speed;
   this->streams               = xine_list_new();
     
   /* warning: driver_lock is a recursive mutex. it must NOT be
@@ -2087,6 +2098,7 @@
   this->discard_buffers        = 0;
   this->zero_space             = calloc (1, ZERO_BUF_SIZE * 4 * 6); /* MAX as 32bit, 6 channels. */
   
+  pthread_mutex_init( &this->current_speed_lock, NULL );
   pthread_mutex_init( &this->flush_audio_driver_lock, NULL );
   pthread_cond_init( &this->flush_audio_driver_reached, NULL );
 
diff -r ce4b1533a0af src/xine-engine/xine.c
--- a/src/xine-engine/xine.c	Sun Jan 11 22:24:42 2009 +0000
+++ b/src/xine-engine/xine.c	Sat Feb 07 15:09:25 2009 -0200
@@ -330,17 +330,20 @@
 
 static void set_speed_internal (xine_stream_t *stream, int speed) {
   xine_t *xine = stream->xine;
+  int old_speed = xine->clock->speed;
 
-  if (xine->clock->speed != XINE_SPEED_PAUSE && speed == XINE_SPEED_PAUSE)
+  if (old_speed != XINE_SPEED_PAUSE && speed == XINE_SPEED_PAUSE)
     /* get all decoder and post threads in a state where they agree to be blocked */
     xine->port_ticket->revoke(xine->port_ticket, 0);
   
-  if (xine->clock->speed == XINE_SPEED_PAUSE && speed != XINE_SPEED_PAUSE)
+  if (old_speed == XINE_SPEED_PAUSE && speed != XINE_SPEED_PAUSE)
     /* all decoder and post threads may continue now */
     xine->port_ticket->issue(xine->port_ticket, 0);
   
-  stream->xine->clock->set_fine_speed (stream->xine->clock, speed);
-
+  if (old_speed != XINE_SPEED_PAUSE && speed == XINE_SPEED_PAUSE)
+    /* set master clock so audio_out loop can pause in a safe place */
+    stream->xine->clock->set_fine_speed (stream->xine->clock, speed);
+  
   /* see coment on audio_out loop about audio_paused */
   if( stream->audio_out ) {
     xine->port_ticket->acquire(xine->port_ticket, 1);
@@ -350,6 +353,10 @@
     
     xine->port_ticket->release(xine->port_ticket, 1);
   }
+  
+  if (old_speed == XINE_SPEED_PAUSE && speed != XINE_SPEED_PAUSE)
+    /* master clock is set after resuming the audio device (audio_out loop may continue) */
+    stream->xine->clock->set_fine_speed (stream->xine->clock, speed);
 }
 
 


Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/xine-lib/F-9/.cvsignore,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- .cvsignore	7 Jan 2009 20:32:58 -0000	1.18
+++ .cvsignore	10 Feb 2009 23:16:59 -0000	1.19
@@ -1,2 +1,2 @@
-xine-lib-1.1.16-autotools.patch.bz2
-xine-lib-1.1.16-pruned.tar.bz2
+xine-lib-1.1.16.2-pruned.tar.bz2
+xine-lib-1.1.16.2-autotools.patch.bz2


Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/xine-lib/F-9/sources,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -r1.19 -r1.20
--- sources	7 Jan 2009 20:32:58 -0000	1.19
+++ sources	10 Feb 2009 23:16:59 -0000	1.20
@@ -1,2 +1,2 @@
-fe8148f2a0ec7b2e75ad509e8086e33f  xine-lib-1.1.16-autotools.patch.bz2
-512f31d8414ef4654ca366c0dce37301  xine-lib-1.1.16-pruned.tar.bz2
+e2c3a178be02f5c32957b2716123aa28  xine-lib-1.1.16.2-pruned.tar.bz2
+07bf186d51b8315026453a2f21b33703  xine-lib-1.1.16.2-autotools.patch.bz2


Index: xine-lib-mk-autotools-patch.sh
===================================================================
RCS file: /cvs/pkgs/rpms/xine-lib/F-9/xine-lib-mk-autotools-patch.sh,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- xine-lib-mk-autotools-patch.sh	18 Apr 2007 17:57:19 -0000	1.3
+++ xine-lib-mk-autotools-patch.sh	10 Feb 2009 23:17:00 -0000	1.4
@@ -22,10 +22,12 @@
 tar jxf xine-lib-$version-pruned.tar.bz2
 cp -a xine-lib-$version xine-lib-$version-pruned
 
-cd xine-lib-$version
+pushd xine-lib-$version
+# extra work for to omit old libtool-related crud
+rm -f configure ltmain.sh libtool m4/libtool.m4 m4/ltoptions.m4 m4/ltversion.m4
 ./autogen.sh noconfig
 rm -rf autom4te.cache *~
-cd ..
+popd
 
 diff -Nru xine-lib-$version-pruned xine-lib-$version \
 | bzip2 --best > xine-lib-$version-autotools.patch.bz2


Index: xine-lib.spec
===================================================================
RCS file: /cvs/pkgs/rpms/xine-lib/F-9/xine-lib.spec,v
retrieving revision 1.49
retrieving revision 1.50
diff -u -r1.49 -r1.50
--- xine-lib.spec	18 Jan 2009 21:43:01 -0000	1.49
+++ xine-lib.spec	10 Feb 2009 23:17:00 -0000	1.50
@@ -19,12 +19,10 @@
 
 %if 0%{?fedora}
     %define     with_aalib  %{?_without_aalib:0}%{!?_without_aalib:1}
-    %define     with_caca   %{?_without_caca:0}%{!?_without_caca:1}
     %define     with_pa     %{?_without_pulseaudio:0}%{!?_without_pulseaudio:1}
     %define     with_xcb    %{?_without_xcb:0}%{!?_without_xcb:1}
 %else
     %define     with_aalib  %{?_with_aalib:1}%{!?_with_aalib:0}
-    %define     with_caca   %{?_with_caca:1}%{!?_with_caca:0}
     %define     with_pa     %{?_with_pulseaudio:1}%{!?_with_pulseaudio:0}
     %define     with_xcb    %{?_with_xcb:1}%{!?_with_xcb:0}
 %endif # Fedora
@@ -33,10 +31,10 @@
 %define _without_arts --without-arts
 %endif
 
-Summary:        Xine library
+Summary:        A multimedia engine 
 Name:           xine-lib
-Version:        1.1.16
-Release:        2%{?dist}
+Version:        1.1.16.2
+Release:        1%{?dist}
 License:        GPLv2+
 Group:          System Environment/Libraries
 URL:            http://xinehq.de/
@@ -52,10 +50,17 @@
 
 Patch1:         %{name}-1.1.4-optflags.patch
 Patch6:         %{name}-1.1.1-deepbind-939.patch
+# FIXME for 1.1.16.1 ?
 Patch7:         %{name}-1.1.16-old-caca.patch
+# http://bugzilla.redhat.com/470568
+Patch8:         xine-lib-1.1.15-avsync_hack.patch
 ## upstream patches
+Patch100:	xine-lib-safe-audio-pause.patch
 
 Provides:       xine-lib(plugin-abi) = %{abiver}
+%if "%{?_isa}" != "%{nil}"
+Provides:       xine-lib(plugin-abi)%{?_isa} = %{abiver}
+%endif
 # X11
 BuildRequires:  libX11-devel
 BuildRequires:  libXv-devel
@@ -72,13 +77,11 @@
 %if %{with_aalib}
 BuildRequires:  aalib-devel >= 1.4
 %endif # aalib
-%if %{with_caca}
 %if 0%{?old_caca}
 BuildRequires:  libcaca-devel >= 0.99
 %else
-BuildRequires:  libcaca-devel >= 0.99-0.5.beta16
+BuildRequires:  libcaca-devel >= 0.99-0.5.beta14
 %endif
-%endif # caca
 %if 0%{!?_without_directfb:1}
 BuildRequires:  directfb-devel
 %endif # directfb
@@ -120,13 +123,10 @@
 BuildRequires:  libdvdnav-devel
 
 %description
-This package contains the Xine library. Xine is a free multimedia player.
-It can play back various media. It also decodes multimedia files from local
-disk drives, and displays multimedia streamed over the Internet. It
-interprets many of the most common multimedia formats available - and some
-of the most uncommon formats, too.  --with/--without rpmbuild options
-(some default values depend on target distribution): aalib, caca, directfb,
-imagemagick, freetype, antialiasing (with freetype), pulseaudio, xcb.
+This package contains the Xine library.  It can be used to play back
+various media, decode multimedia files from local disk drives, and display
+multimedia streamed over the Internet. It interprets many of the most
+common multimedia formats available - and some uncommon formats, too. 
 
 %package        devel
 Summary:        Xine library development files
@@ -136,10 +136,10 @@
 Requires:       zlib-devel
 
 %description    devel
-This package contains development files for xine-lib.
+This package contains development files for %{name}.
 
 %package        arts
-Summary:        aRts plugin for xine-lib
+Summary:        aRts plugin for %{name} 
 Group:          System Environment/Libraries
 Requires:       %{name} = %{version}-%{release}
 #Requires:      xine-lib(plugin-abi) = %{abiver}
@@ -147,27 +147,27 @@
 Obsoletes:      xine-lib-extras < 1.1.7-3
 
 %description    arts
-This package contains the aRts extra plugin for xine-lib.
+This package contains the aRts plugin for %{name}.
 
 %package        pulseaudio
-Summary:        Pulseaudio plugin for xine-lib
+Summary:        Pulseaudio plugin for %{name} 
 Group:          System Environment/Libraries
 Requires:       %{name} = %{version}-%{release}
 # -pulseaudio was split off -extras at 1.1.11.1-2
 #Obsoletes:     xine-lib-extras < 1.1.11.1-2
 
 %description    pulseaudio
-This package contains the pulseaudio plugin for xine-lib.
+This package contains the pulseaudio plugin for %{name}.
 
 
 %package        extras
-Summary:        Additional plugins for xine-lib
+Summary:        Additional plugins for %{name} 
 Group:          System Environment/Libraries
 Requires:       %{name} = %{version}-%{release}
 #Requires:      xine-lib(plugin-abi) = %{abiver}
 
 %description    extras
-This package contains extra plugins for xine-lib:
+This package contains extra plugins for %{name}:
   - EsounD
   - JACK
   - GDK-Pixbuf
@@ -177,9 +177,7 @@
 %if %{with_aalib}
   - AA-lib
 %endif # aalib
-%if %{with_caca}
   - Libcaca
-%endif # caca
 %if 0%{!?_without_imagemagick:1}
   - Image decoding
 %endif # imagemagick
@@ -198,10 +196,15 @@
 # needed at least when compiling with external ffmpeg and internal faad livna bug#939.
 # see also http://bugzilla.redhat.com/480504 for side-effects
 #patch6 -p1 -b .deepbind
+
 %if 0%{?old_caca}
 %patch7 -p0 -b .old-caca
 %endif
 
+%patch8 -p1 -b .avsync_hack
+
+%patch100 -p1 -b .safe_audio_pause
+
 # Avoid standard rpaths on lib64 archs: (autotools patch should handle this, no? -- Rex )
 #sed -i -e 's|"/lib /usr/lib\b|"/%{_lib} %{_libdir}|' configure
 
@@ -226,6 +229,7 @@
 %if 0%{?_with_freetype:1}
 %if 0%{?_with_antialiasing:1}
     --enable-antialiasing \
+    --with-caca \
 %endif # antialiasing
     --with-freetype \
     --with-fontconfig \
@@ -233,7 +237,6 @@
     --with-external-ffmpeg \
     --with-xv-path=%{_libdir} \
     --with-libflac \
-    --with-external-libdvdnav \
     --with-external-libmpcdec \
 %if 0%{?_without_imagemagick:1}
     --without-imagemagick \
@@ -411,9 +414,7 @@
 %if %{with_aalib}
 %{_libdir}/xine/plugins/%{abiver}/xineplug_vo_out_aa.so
 %endif # aalib
-%if %{with_caca}
 %{_libdir}/xine/plugins/%{abiver}/xineplug_vo_out_caca.so
-%endif # caca
 %if 0%{!?_without_directfb:1}
 %{_libdir}/xine/plugins/%{abiver}/xineplug_vo_out_directfb.so
 %{_libdir}/xine/plugins/%{abiver}/xineplug_vo_out_xdirectfb.so
@@ -435,8 +436,26 @@
 
 
 %changelog
+* Tue Feb 10 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.16.2-1
+- xine-lib-1.1.16.2
+
+* Mon Feb 09 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.16.1-4
+- gapless-race-fix patch (kdebug#180339)
+
+* Sat Feb 07 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.16.1-3
+- safe-audio-pause patch (kdebug#180339)
+
+* Mon Jan 26 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.16.1-2
+- Provides: xine-lib(plugin-abi)%%{?_isa} = %%{abiver}
+- touchup Summary/Description
+
+* Fri Jan 23 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.16.1-1
+- xine-lib-1.1.16.1
+- include avsync patch (#470568)
+
 * Sun Jan 18 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.16-2
 - drop deepbind patch (#480504)
+- caca support (EPEL)
 
 * Wed Jan 07 2009 Kevin Kofler <Kevin at tigcc.ticalc.org> - 1.1.16-1.1
 - patch for old libcaca in F9-




More information about the scm-commits mailing list