public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/xine-lib] epel9-next: * Mon Feb 09 2009 Rex Dieter <rdieter@fedoraproject.org> - 1.1.16.1-4
@ 2026-07-20 20:00 Rex Dieter
  0 siblings, 0 replies; only message in thread
From: Rex Dieter @ 2026-07-20 20:00 UTC (permalink / raw)
  To: git-commits

            A new commit has been pushed.

            Repo   : rpms/xine-lib
            Branch : epel9-next
            Commit : 36c65a75b1d7d2345971b27c0d3b13872ce77f6d
            Author : Rex Dieter <rdieter@fedoraproject.org>
            Date   : 2009-02-09T13:38:55+00:00
            Stats  : +152/-4 in 2 file(s)
            URL    : https://src.fedoraproject.org/rpms/xine-lib/c/36c65a75b1d7d2345971b27c0d3b13872ce77f6d?branch=epel9-next

            Log:
            * Mon Feb 09 2009 Rex Dieter <rdieter@fedoraproject.org> - 1.1.16.1-4
- gapless-race-fix patch (kdebug#180339)

---
diff --git a/xine-lib-1.1.16.1-gapless_race_fix.patch b/xine-lib-1.1.16.1-gapless_race_fix.patch
new file mode 100644
index 0000000..ec46cbf
--- /dev/null
+++ b/xine-lib-1.1.16.1-gapless_race_fix.patch
@@ -0,0 +1,144 @@
+diff -up xine-lib-1.1.16.1/src/xine-engine/audio_out.c.gapless_rate_fix xine-lib-1.1.16.1/src/xine-engine/audio_out.c
+--- xine-lib-1.1.16.1/src/xine-engine/audio_out.c.gapless_rate_fix	2009-02-09 07:30:08.000000000 -0600
++++ xine-lib-1.1.16.1/src/xine-engine/audio_out.c	2009-02-09 07:30:08.000000000 -0600
+@@ -1623,7 +1623,7 @@ static void ao_close(xine_audio_port_t *
+   pthread_mutex_unlock(&this->streams_lock);
+ 
+   /* close driver if no streams left */
+-  if (!ite && !this->grab_only && !stream->gapless_switch) {
++  if (!ite && !this->grab_only && !stream->keep_ao_driver_open) {
+     xprintf (this->xine, XINE_VERBOSITY_DEBUG, "audio_out: no streams left, closing driver\n");
+ 
+     if (this->audio_loop_running) {
+diff -up xine-lib-1.1.16.1/src/xine-engine/video_decoder.c.gapless_rate_fix xine-lib-1.1.16.1/src/xine-engine/video_decoder.c
+--- xine-lib-1.1.16.1/src/xine-engine/video_decoder.c.gapless_rate_fix	2008-04-28 08:30:56.000000000 -0500
++++ xine-lib-1.1.16.1/src/xine-engine/video_decoder.c	2009-02-09 07:31:36.000000000 -0600
+@@ -160,7 +160,7 @@ static void *video_decoder_loop (void *s
+       
+       running_ticket->release(running_ticket, 0);
+       
+-      if( !stream->gapless_switch )
++      if( !(buf->decoder_flags & BUF_FLAG_GAPLESS_SW) )
+         stream->metronom->handle_video_discontinuity (stream->metronom, 
+ 						      DISC_STREAMSTART, 0);
+       
+diff -up xine-lib-1.1.16.1/src/xine-engine/xine.c.gapless_rate_fix xine-lib-1.1.16.1/src/xine-engine/xine.c
+--- xine-lib-1.1.16.1/src/xine-engine/xine.c.gapless_rate_fix	2009-02-09 07:30:08.000000000 -0600
++++ xine-lib-1.1.16.1/src/xine-engine/xine.c	2009-02-09 07:30:08.000000000 -0600
+@@ -426,6 +426,7 @@ void xine_stop (xine_stream_t *stream) {
+ static void close_internal (xine_stream_t *stream) {
+ 
+   int i ;
++  int gapless_switch = stream->gapless_switch;
+ 
+   if( stream->slave ) {
+     xine_close( stream->slave );
+@@ -436,7 +437,7 @@ static void close_internal (xine_stream_
+     }
+   }
+ 
+-  if( !stream->gapless_switch ) {
++  if( !gapless_switch ) {
+     /* make sure that other threads cannot change the speed, especially pauseing the stream */
+     pthread_mutex_lock(&stream->speed_change_lock);
+     stream->ignore_speed_change = 1;
+@@ -452,7 +453,7 @@ static void close_internal (xine_stream_
+   
+   stop_internal( stream );
+   
+-  if( !stream->gapless_switch ) {
++  if( !gapless_switch ) {
+     if (stream->video_out)
+       stream->video_out->set_property(stream->video_out, VO_PROP_DISCARD_FRAMES, 0);  
+     if (stream->audio_out)
+@@ -603,6 +604,7 @@ xine_stream_t *xine_stream_new (xine_t *
+   stream->early_finish_event     = 0;
+   stream->delay_finish_event     = 0;
+   stream->gapless_switch         = 0;
++  stream->keep_ao_driver_open    = 0;
+ 
+   stream->video_out              = vo;
+   if (vo)
+diff -up xine-lib-1.1.16.1/src/xine-engine/buffer.h.gapless_rate_fix xine-lib-1.1.16.1/src/xine-engine/buffer.h
+--- xine-lib-1.1.16.1/src/xine-engine/buffer.h.gapless_rate_fix	2009-01-10 19:25:34.000000000 -0600
++++ xine-lib-1.1.16.1/src/xine-engine/buffer.h	2009-02-09 07:30:08.000000000 -0600
+@@ -378,6 +378,9 @@ struct buf_element_s {
+  * decoder_info[2] carries denominator for display aspect ratio       */
+ #define BUF_FLAG_ASPECT      0x0800
+ 
++/* represent the state of gapless_switch at the time buf was enqueued */
++#define BUF_FLAG_GAPLESS_SW  0x1000
++
+ 
+ /* Special buffer types:
+  * Sometimes there is a need to relay special information from a demuxer
+diff -up xine-lib-1.1.16.1/src/xine-engine/demux.c.gapless_rate_fix xine-lib-1.1.16.1/src/xine-engine/demux.c
+--- xine-lib-1.1.16.1/src/xine-engine/demux.c.gapless_rate_fix	2009-01-10 19:25:34.000000000 -0600
++++ xine-lib-1.1.16.1/src/xine-engine/demux.c	2009-02-09 07:30:08.000000000 -0600
+@@ -228,15 +228,18 @@ void _x_demux_control_headers_done (xine
+ void _x_demux_control_start( xine_stream_t *stream ) {
+ 
+   buf_element_t *buf;
++  uint32_t flags = (stream->gapless_switch) ? BUF_FLAG_GAPLESS_SW : 0;
+ 
+   pthread_mutex_lock(&stream->demux_mutex);  
+ 
+   buf = stream->video_fifo->buffer_pool_alloc (stream->video_fifo);
+   buf->type = BUF_CONTROL_START;
++  buf->decoder_flags = flags;
+   stream->video_fifo->put (stream->video_fifo, buf);
+ 
+   buf = stream->audio_fifo->buffer_pool_alloc (stream->audio_fifo);
+   buf->type = BUF_CONTROL_START;
++  buf->decoder_flags = flags;
+   stream->audio_fifo->put (stream->audio_fifo, buf);
+ 
+   pthread_mutex_unlock(&stream->demux_mutex);  
+diff -up xine-lib-1.1.16.1/src/xine-engine/audio_decoder.c.gapless_rate_fix xine-lib-1.1.16.1/src/xine-engine/audio_decoder.c
+--- xine-lib-1.1.16.1/src/xine-engine/audio_decoder.c.gapless_rate_fix	2008-04-28 08:30:56.000000000 -0500
++++ xine-lib-1.1.16.1/src/xine-engine/audio_decoder.c	2009-02-09 07:30:08.000000000 -0600
+@@ -89,16 +89,18 @@ static void *audio_decoder_loop (void *s
+       if (stream->audio_decoder_plugin) {
+ 
+ 	lprintf ("close old decoder\n");
+-
++      
++	stream->keep_ao_driver_open = !!(buf->decoder_flags & BUF_FLAG_GAPLESS_SW);
+ 	_x_free_audio_decoder (stream, stream->audio_decoder_plugin);
+ 	stream->audio_decoder_plugin = NULL;
+ 	stream->audio_track_map_entries = 0;
+ 	stream->audio_type = 0;
++	stream->keep_ao_driver_open = 0;
+       }
+       
+       running_ticket->release(running_ticket, 0);
+       
+-      if( !stream->gapless_switch )
++      if( !(buf->decoder_flags & BUF_FLAG_GAPLESS_SW) )
+         stream->metronom->handle_audio_discontinuity (stream->metronom, DISC_STREAMSTART, 0);
+       
+       buftype_unknown = 0;
+diff -up xine-lib-1.1.16.1/src/xine-engine/xine_interface.c.gapless_rate_fix xine-lib-1.1.16.1/src/xine-engine/xine_interface.c
+--- xine-lib-1.1.16.1/src/xine-engine/xine_interface.c.gapless_rate_fix	2008-07-12 17:52:01.000000000 -0500
++++ xine-lib-1.1.16.1/src/xine-engine/xine_interface.c	2009-02-09 07:30:08.000000000 -0600
+@@ -527,6 +527,9 @@ void xine_set_param (xine_stream_t *stre
+   
+   case XINE_PARAM_GAPLESS_SWITCH:
+     stream->gapless_switch = !!value;
++    if( stream->gapless_switch && !stream->early_finish_event ) {
++      xprintf (stream->xine, XINE_VERBOSITY_DEBUG, "frontend possibly buggy: gapless_switch without early_finish_event\n");
++    }
+     break;
+     
+   default:
+diff -up xine-lib-1.1.16.1/src/xine-engine/xine_internal.h.gapless_rate_fix xine-lib-1.1.16.1/src/xine-engine/xine_internal.h
+--- xine-lib-1.1.16.1/src/xine-engine/xine_internal.h.gapless_rate_fix	2008-08-24 16:51:15.000000000 -0500
++++ xine-lib-1.1.16.1/src/xine-engine/xine_internal.h	2009-02-09 07:30:08.000000000 -0600
+@@ -361,6 +361,7 @@ struct xine_stream_s {
+   int                        early_finish_event; /* do not wait fifos get empty before sending event */
+   int                        gapless_switch;     /* next stream switch will be gapless */
+   int                        delay_finish_event; /* delay event in 1/10 sec units. 0=>no delay, -1=>forever */
++  int                        keep_ao_driver_open;
+ #endif
+ };
+ 

diff --git a/xine-lib.spec b/xine-lib.spec
index 5e94b77..2a29d59 100644
--- a/xine-lib.spec
+++ b/xine-lib.spec
@@ -34,7 +34,7 @@
 Summary:        A multimedia engine 
 Name:           xine-lib
 Version:        1.1.16.1
-Release:        3%{?dist}
+Release:        4%{?dist}
 License:        GPLv2+
 Group:          System Environment/Libraries
 URL:            http://xinehq.de/
@@ -56,6 +56,7 @@ Patch7:         %{name}-1.1.16-old-caca.patch
 Patch8:         xine-lib-1.1.15-avsync_hack.patch
 ## upstream patches
 Patch100:	xine-lib-safe-audio-pause.patch
+Patch101: 	xine-lib-1.1.16.1-gapless_race_fix.patch
 
 Provides:       xine-lib(plugin-abi) = %{abiver}
 %if "%{?_isa}" != "%{nil}"
@@ -89,7 +90,7 @@ BuildRequires:  directfb-devel
 BuildRequires:  ImageMagick-devel >= 6.2.4.6-1
 %endif # imagemagick
 %if 0%{?_with_freetype:1}
-BuildRequires:  fontconfig-devel
+BuildRequires:  fontcotnfig-devel
 %endif # freetype
 # Audio
 BuildRequires:  alsa-lib-devel >= 0.9.0
@@ -204,6 +205,7 @@ touch -r m4/optimizations.m4.stamp m4/optimizations.m4
 %patch8 -p1 -b .avsync_hack
 
 %patch100 -p1 -b .safe_audio_pause
+%patch101 -p1 -b .gapless_race_fix
 
 # Avoid standard rpaths on lib64 archs: (autotools patch should handle this, no? -- Rex )
 #sed -i -e 's|"/lib /usr/lib\b|"/%{_lib} %{_libdir}|' configure
@@ -237,7 +239,6 @@ export SDL_CFLAGS="$(sdl-config --cflags)" SDL_LIBS="$(sdl-config --libs)"
     --with-external-ffmpeg \
     --with-xv-path=%{_libdir} \
     --with-libflac \
-    --with-external-libdvdnav \
     --with-external-libmpcdec \
 %if 0%{?_without_imagemagick:1}
     --without-imagemagick \
@@ -437,8 +438,11 @@ rm -rf $RPM_BUILD_ROOT
 
 
 %changelog
+* Mon Feb 09 2009 Rex Dieter <rdieter@fedoraproject.org> - 1.1.16.1-4
+- gapless-race-fix patch (kdebug#180339)
+
 * Sat Feb 07 2009 Rex Dieter <rdieter@fedoraproject.org> - 1.1.16.1-3
-- safe-audio-pause patch
+- safe-audio-pause patch (kdebug#180339)
 
 * Mon Jan 26 2009 Rex Dieter <rdieter@fedoraproject.org> - 1.1.16.1-2
 - Provides: xine-lib(plugin-abi)%%{?_isa} = %%{abiver}

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2026-07-20 20:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-07-20 20:00 [rpms/xine-lib] epel9-next: * Mon Feb 09 2009 Rex Dieter <rdieter@fedoraproject.org> - 1.1.16.1-4 Rex Dieter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox