r2120 - in vdr/vdr-plugin-xine/branches/network/debian: . patches

Tobias Grimm tiber-guest at costa.debian.org
Sun Mar 26 00:02:09 UTC 2006


Author: tiber-guest
Date: 2006-03-26 00:02:08 +0000 (Sun, 26 Mar 2006)
New Revision: 2120

Added:
   vdr/vdr-plugin-xine/branches/network/debian/patches/01_upstream.dpatch
   vdr/vdr-plugin-xine/branches/network/debian/patches/02_constness.dpatch
   vdr/vdr-plugin-xine/branches/network/debian/patches/03_extra_keys.dpatch
Removed:
   vdr/vdr-plugin-xine/branches/network/debian/patches/02_grab.dpatch
   vdr/vdr-plugin-xine/branches/network/debian/patches/03_format_strings.dpatch
Modified:
   vdr/vdr-plugin-xine/branches/network/debian/changelog
   vdr/vdr-plugin-xine/branches/network/debian/control
   vdr/vdr-plugin-xine/branches/network/debian/patches/00list
   vdr/vdr-plugin-xine/branches/network/debian/patches/01_Makefile-fPIC-fix.dpatch
   vdr/vdr-plugin-xine/branches/network/debian/patches/01_debian.dpatch
   vdr/vdr-plugin-xine/branches/network/debian/patches/03_network.dpatch
   vdr/vdr-plugin-xine/branches/network/debian/vdr-plugin-xine.links
Log:
Synched with 0.7.8 and updated network patch


Modified: vdr/vdr-plugin-xine/branches/network/debian/changelog
===================================================================
--- vdr/vdr-plugin-xine/branches/network/debian/changelog	2006-03-25 23:58:13 UTC (rev 2119)
+++ vdr/vdr-plugin-xine/branches/network/debian/changelog	2006-03-26 00:02:08 UTC (rev 2120)
@@ -1,3 +1,25 @@
+vdr-plugin-xine (0.7.8-1net1) unstable; urgency=low
+
+  * Tobias Grimm <tg at e-tobi.net>
+    - Synced with 0.7.8-1
+
+ -- Debian VDR Team <pkg-vdr-dvb-devel at lists.alioth.debian.org>  Thu,  2 Feb 2006 15:28:25 +0100
+
+vdr-plugin-xine (0.7.8-1) unstable; urgency=low
+
+  * Thomas Schmidt <tschmidt at debian.org>
+    - Build-Depend on vdr-dev (>=1.3.41-1)
+  * Tobias Grimm <tg at e-tobi.net>
+    - New upstream release.
+    - Synced with Darren Salt's package 0.7.8-1.ds
+      + 02_constness.dpatch - sprinkled a little constness dust where appropriate
+      + Removed 02_grab.dpatch, 03_format_strings.dpatch (integrated in upstream)
+      + Updated 01_debian.dpatch
+    - Install no signal mpg's to /usr/share/vdr-plugin-xine/ and directly link them
+      into /var/lib/vdr/plugins/xine/ (don't link in /etc/vdr/plugins anymore)
+
+ -- Debian VDR Team <pkg-vdr-dvb-devel at lists.alioth.debian.org>  Thu,  2 Feb 2006 15:28:25 +0100
+
 vdr-plugin-xine (0.7.6-5net3) unstable; urgency=low
 
   * Tobias Grimm <tg at e-tobi.net>

Modified: vdr/vdr-plugin-xine/branches/network/debian/control
===================================================================
--- vdr/vdr-plugin-xine/branches/network/debian/control	2006-03-25 23:58:13 UTC (rev 2119)
+++ vdr/vdr-plugin-xine/branches/network/debian/control	2006-03-26 00:02:08 UTC (rev 2120)
@@ -3,7 +3,7 @@
 Priority: extra
 Maintainer: Debian VDR Team <pkg-vdr-dvb-devel at lists.alioth.debian.org>
 Uploaders: Darren Salt <linux at youmustbejoking.demon.co.uk>, Thomas Schmidt <tschmidt at debian.org>
-Build-Depends: debhelper (>= 4.0.0), dpatch, libxine-dev (>= 1.0.3a-0vdr2), vdr-dev (>=1.3.41-1)
+Build-Depends: debhelper (>= 4.0.0), dpatch, libxine-dev (>= 1.1.1-1vdr1), vdr-dev (>=1.3.41-1)
 Standards-Version: 3.6.2
 
 Package: vdr-plugin-xine

Modified: vdr/vdr-plugin-xine/branches/network/debian/patches/00list
===================================================================
--- vdr/vdr-plugin-xine/branches/network/debian/patches/00list	2006-03-25 23:58:13 UTC (rev 2119)
+++ vdr/vdr-plugin-xine/branches/network/debian/patches/00list	2006-03-26 00:02:08 UTC (rev 2120)
@@ -1,5 +1,6 @@
 01_debian
 01_Makefile-fPIC-fix
-02_grab
-03_format_strings
+#01_upstream
+02_constness
+#03_extra_keys
 03_network

Modified: vdr/vdr-plugin-xine/branches/network/debian/patches/01_Makefile-fPIC-fix.dpatch
===================================================================
--- vdr/vdr-plugin-xine/branches/network/debian/patches/01_Makefile-fPIC-fix.dpatch	2006-03-25 23:58:13 UTC (rev 2119)
+++ vdr/vdr-plugin-xine/branches/network/debian/patches/01_Makefile-fPIC-fix.dpatch	2006-03-26 00:02:08 UTC (rev 2120)
@@ -6,15 +6,15 @@
 ## DP: Adds -fPIC to Makefile 
 
 @DPATCH@
-diff -urNad vdr-plugin-xine-0.7.6/Makefile /tmp/dpep.xhL2DW/vdr-plugin-xine-0.7.6/Makefile
---- vdr-plugin-xine-0.7.6/Makefile	2005-09-11 21:30:06.000000000 +0200
-+++ /tmp/dpep.xhL2DW/vdr-plugin-xine-0.7.6/Makefile	2005-11-01 22:26:40.402979600 +0100
-@@ -16,7 +16,7 @@
- ### The C++ compiler and options:
+diff -urNad vdr-plugin-xine-0.7.8~/Makefile vdr-plugin-xine-0.7.8/Makefile
+--- vdr-plugin-xine-0.7.8~/Makefile	2006-03-26 00:06:04.000000000 +0100
++++ vdr-plugin-xine-0.7.8/Makefile	2006-03-26 00:06:27.000000000 +0100
+@@ -17,7 +17,7 @@
  
  CXX      ?= g++
+ #CXX       = /soft/gcc-4.1-20060113/bin/g++ -I/soft/include -L/soft/lib
 -CXXFLAGS ?= -O2 -g -Wall -Woverloaded-virtual
 +CXXFLAGS ?= -O2 -fPIC -g -Wall -Woverloaded-virtual
  #CXXFLAGS ?= -O0 -g3 -Wall -Woverloaded-virtual
+ #CXXFLAGS ?= -O0 -g3 -Wall -Woverloaded-virtual -Wformat=2 -Wextra
  
- ### The directory environment:

Modified: vdr/vdr-plugin-xine/branches/network/debian/patches/01_debian.dpatch
===================================================================
--- vdr/vdr-plugin-xine/branches/network/debian/patches/01_debian.dpatch	2006-03-25 23:58:13 UTC (rev 2119)
+++ vdr/vdr-plugin-xine/branches/network/debian/patches/01_debian.dpatch	2006-03-26 00:02:08 UTC (rev 2120)
@@ -6,20 +6,20 @@
 ## DP: Package-specific bits
 
 @DPATCH@
-diff -urNad vdr-plugin-xine-0.7.0/Make.config /tmp/dpep.bQLd5z/vdr-plugin-xine-0.7.0/Make.config
---- vdr-plugin-xine-0.7.0/Make.config	2005-01-30 00:24:29.000000000 +0000
-+++ /tmp/dpep.bQLd5z/vdr-plugin-xine-0.7.0/Make.config	2005-01-30 00:24:30.000000000 +0000
+diff -urNad vdr-plugin-xine-0.7.8~/Make.config vdr-plugin-xine-0.7.8/Make.config
+--- vdr-plugin-xine-0.7.8~/Make.config	2006-03-21 01:05:54.000000000 +0000
++++ vdr-plugin-xine-0.7.8/Make.config	2006-03-21 01:05:55.290710274 +0000
 @@ -0,0 +1,6 @@
 +INCLUDES+=-I/usr/include/freetype2
 +DVBDIR=.
 +VDRDIR=/usr/include/vdr
 +LIBDIR=$(DESTDIR)/usr/lib/vdr/plugins
 +VIDEODIR=/video
-+DATA_DIR=$(DESTDIR)/usr/share/vdr/vdr-xine
-diff -urNad vdr-plugin-xine-0.7.0/Makefile /tmp/dpep.bQLd5z/vdr-plugin-xine-0.7.0/Makefile
---- vdr-plugin-xine-0.7.0/Makefile	2005-01-30 00:24:29.000000000 +0000
-+++ /tmp/dpep.bQLd5z/vdr-plugin-xine-0.7.0/Makefile	2005-01-30 00:24:46.000000000 +0000
-@@ -28,7 +28,7 @@
++DATA_DIR=$(DESTDIR)/usr/share/vdr-plugin-xine
+diff -urNad vdr-plugin-xine-0.7.8~/Makefile vdr-plugin-xine-0.7.8/Makefile
+--- vdr-plugin-xine-0.7.8~/Makefile	2006-03-21 01:05:54.000000000 +0000
++++ vdr-plugin-xine-0.7.8/Makefile	2006-03-21 01:05:55.294710016 +0000
+@@ -30,7 +30,7 @@
  
  ### Allow user defined options to overwrite defaults:
  
@@ -28,7 +28,7 @@
  
  INCLUDES += `xine-config --cflags` 
  
-@@ -39,10 +39,10 @@
+@@ -41,10 +41,10 @@
  #VDR_XINE_SET_VIDEO_WINDOW = 1
  
  # where are these utilities for image grabbing? (default: anywhere on your PATH)
@@ -43,7 +43,7 @@
  
  ### The version number of VDR (taken from VDR's "config.h"):
  
-@@ -105,7 +105,16 @@
+@@ -107,7 +107,16 @@
  
  libvdr-$(PLUGIN).so: $(OBJS) Makefile
  	$(CXX) $(CXXFLAGS) -shared $(OBJS) -o $@

Copied: vdr/vdr-plugin-xine/branches/network/debian/patches/01_upstream.dpatch (from rev 2117, vdr/vdr-plugin-xine/trunk/debian/patches/01_upstream.dpatch)

Copied: vdr/vdr-plugin-xine/branches/network/debian/patches/02_constness.dpatch (from rev 2117, vdr/vdr-plugin-xine/trunk/debian/patches/02_constness.dpatch)

Deleted: vdr/vdr-plugin-xine/branches/network/debian/patches/02_grab.dpatch
===================================================================
--- vdr/vdr-plugin-xine/branches/network/debian/patches/02_grab.dpatch	2006-03-25 23:58:13 UTC (rev 2119)
+++ vdr/vdr-plugin-xine/branches/network/debian/patches/02_grab.dpatch	2006-03-26 00:02:08 UTC (rev 2120)
@@ -1,192 +0,0 @@
-#! /bin/sh /usr/share/dpatch/dpatch-run
-## 02_grab.dpatch by  <ds at flibble.youmustbejoking.demon.co.uk>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: No description.
-
- at DPATCH@
-diff -urNad vdr-plugin-xine-0.7.6~/xineDevice.c vdr-plugin-xine-0.7.6/xineDevice.c
---- vdr-plugin-xine-0.7.6~/xineDevice.c	2006-01-12 00:43:12.000000000 +0000
-+++ vdr-plugin-xine-0.7.6/xineDevice.c	2006-01-12 00:43:12.715161206 +0000
-@@ -2487,18 +2487,13 @@
-     return Length;
-   }
-   
--  bool cXineDevice::GrabImage(const char *FileName, bool Jpeg /* = true */, int Quality /* = -1 */, int SizeX /* = -1 */, int SizeY /* = -1 */)
-+  uchar *cXineDevice::GrabImage(int &Size, bool Jpeg /* = true */, int Quality /* = -1 */, int SizeX /* = -1 */, int SizeY /* = -1 */)
-   {
-     xfprintf(stderr, "GrabImage ...\n\n");
--    
--    if (m_xineLib.execFuncGrabImage(FileName, Jpeg, Quality, SizeX, SizeY))
--    {
--      xfprintf(stderr, "\nGrabImage succeeded.\n");
--      return true;
--    }
- 
--    xfprintf(stderr, "\nGrabImage failed.\n");    
--    return false;
-+    uchar *result = m_xineLib.execFuncGrabImage(Size, Jpeg, Quality, SizeX, SizeY);
-+    xfprintf(stderr, result ? "\nGrabImage succeeded.\n" : "\nGrabImage failed.\n");    
-+    return result;
-   }
- 
-   int64_t cXineDevice::GetSTC(void)
-diff -urNad vdr-plugin-xine-0.7.6~/xineDevice.h vdr-plugin-xine-0.7.6/xineDevice.h
---- vdr-plugin-xine-0.7.6~/xineDevice.h	2006-01-12 00:43:12.000000000 +0000
-+++ vdr-plugin-xine-0.7.6/xineDevice.h	2006-01-12 00:43:12.715161206 +0000
-@@ -66,7 +66,7 @@
-     int PlayCommon2(const uchar *Data, int Length);
-     int PlayCommon3(const uchar *Data, int Length);
-     
--    virtual bool GrabImage(const char *FileName, bool Jpeg = true, int Quality = -1, int SizeX = -1, int SizeY = -1);
-+    virtual uchar *GrabImage(int &Size, bool Jpeg = true, int Quality = -1, int SizeX = -1, int SizeY = -1);
-     virtual void SetVideoFormat(bool VideoFormat16_9);
-     virtual void SetVolumeDevice(int Volume);
-     
-diff -urNad vdr-plugin-xine-0.7.6~/xineLib.c vdr-plugin-xine-0.7.6/xineLib.c
---- vdr-plugin-xine-0.7.6~/xineLib.c	2006-01-12 00:43:12.000000000 +0000
-+++ vdr-plugin-xine-0.7.6/xineLib.c	2006-01-12 00:45:33.377856050 +0000
-@@ -3444,7 +3444,7 @@
- #define PNMTOJPEG "pnmtojpeg"
- #endif
-  
--  bool cXineLib::execFuncGrabImage(const char *FileName, bool Jpeg, int Quality, int SizeX, int SizeY)
-+  uchar *cXineLib::execFuncGrabImage(int &Size, bool Jpeg, int Quality, int SizeX, int SizeY)
-   {
-     if (!isConnected())
-       return false;
-@@ -3453,7 +3453,7 @@
-     cMutexLock ioLock(&m_ioMutex);
-     
-     if (!isConnected())
--      return false;
-+      return NULL;
-     
-     data_grab_image_t data;
-     data.header.func = func_grab_image;
-@@ -3465,32 +3465,32 @@
-    
-       off_t n = xread(fd_result, (char *)&resultUnion, sizeof (resultUnion.header));
-       if (n != sizeof (resultUnion.header))
--        return false;
-+        return NULL;
- 
-       if (data.header.func != resultUnion.header.func)
--        return false;
-+        return NULL;
-       
-       result_grab_image_t *result = &resultUnion.grab_image;
-         
-       n = xread(fd_result, (char *)result + sizeof (result->header), sizeof (*result) - sizeof (result->header));
-       if (n != sizeof (*result) - sizeof (result->header))
--        return false;
-+        return NULL;
- 
-       const size_t frameSize = result->header.len - sizeof (*result);
- 
- //      ::fprintf(stderr, "frameSize: %d\n", frameSize);
-       
-       if (frameSize <= 0)
--        return false;
-+        return NULL;
-       
-       uint8_t *img = (uint8_t *)::malloc(frameSize);
-       if (!img)
--        return false;
-+        return NULL;
-       
-       if (frameSize != (size_t)xread(fd_result, img, frameSize))
-       {
-         ::free(img);
--        return false;
-+        return NULL;
-       }
- 
-       if (XINE_IMGFMT_YUY2 == result->format)
-@@ -3499,7 +3499,7 @@
-         if (!img2)
-         {
-           ::free(img);
--          return false;
-+          return NULL;
-         }
- 
-         ::memset(img2, 0x80, frameSize);
-@@ -3531,11 +3531,10 @@
-       int videoH = -1;
-       execFuncVideoSize(videoX, videoY, videoW, videoH);
-       
--      bool success = false;
--        
--      int outfd = ::open(FileName, O_CREAT /* | O_EXCL */ | O_TRUNC | O_RDWR, 0644);
--      if (-1 != outfd)
-+      FILE *fd = ::tmpfile();
-+      if (fd)
-       {
-+        int outfd = fileno(fd);
-         int sizeX = SizeX;
-         int sizeY = SizeY;
-         
-@@ -3595,22 +3594,41 @@
-                     , result->width, result->height
-                     , 25, 1
-                     , ratioX, ratioY); 
--          
--          success = (frameSize == ::fwrite(img, 1, frameSize, f));
--          
--          ::pclose(f);
-+
-+          if (frameSize == ::fwrite(img, 1, frameSize, f))
-+          {
-+            ::pclose(f); // close the pipe here, grab the image in one go
-+            ::free(img);
-+            img = NULL;
-+
-+            Size = (int) lseek (outfd, 0, SEEK_END);
-+            lseek (outfd, 0, SEEK_SET);
-+
-+            if (Size != -1)
-+            {
-+              img = (uint8_t *)::malloc(Size);
-+              if (img && Size != ::read(outfd, img, Size))
-+              {
-+                ::free(img);
-+                img = NULL;
-+              }
-+            }
-+          }
-+          else
-+            ::pclose(f);
-         }
- 
-         ::free(cmd);
--        ::close(outfd);
-+
-+        ::fclose(fd);
-+
-+        return (uchar *)img;
-       }
--      
--      ::free(img);
- 
--      return success;
-+      ::free(img);
-     }
- 
--    return false;
-+    return NULL;
-   }
-   
-   bool cXineLib::execFuncGetPTS(int64_t &pts)
-diff -urNad vdr-plugin-xine-0.7.6~/xineLib.h vdr-plugin-xine-0.7.6/xineLib.h
---- vdr-plugin-xine-0.7.6~/xineLib.h	2006-01-12 00:43:12.000000000 +0000
-+++ vdr-plugin-xine-0.7.6/xineLib.h	2006-01-12 00:43:12.715161206 +0000
-@@ -254,7 +254,7 @@
-     bool execFuncMetronom(int64_t pts, uint32_t flags = 0);
-     bool execFuncNop();
-     bool execFuncSetPrebuffer(int frames);
--    bool execFuncGrabImage(const char *FileName, bool Jpeg, int Quality, int SizeX, int SizeY);
-+    uchar *execFuncGrabImage(int &Size, bool Jpeg, int Quality, int SizeX, int SizeY);
-     bool execFuncGetPTS(int64_t &pts);
-     bool execFuncVideoSize(int &videoLeft, int &videoTop, int &videoWidth, int &videoHeight);
- 

Copied: vdr/vdr-plugin-xine/branches/network/debian/patches/03_extra_keys.dpatch (from rev 2117, vdr/vdr-plugin-xine/trunk/debian/patches/03_extra_keys.dpatch)

Deleted: vdr/vdr-plugin-xine/branches/network/debian/patches/03_format_strings.dpatch
===================================================================
--- vdr/vdr-plugin-xine/branches/network/debian/patches/03_format_strings.dpatch	2006-03-25 23:58:13 UTC (rev 2119)
+++ vdr/vdr-plugin-xine/branches/network/debian/patches/03_format_strings.dpatch	2006-03-26 00:02:08 UTC (rev 2120)
@@ -1,111 +0,0 @@
-#!/bin/sh /usr/share/dpatch/dpatch-run
-
-## 03_format_strings.dpatch by Darren Salt
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Fix some missing-format-string bugs.
-
- at DPATCH@
-diff -urNad vdr-plugin-xine-0.7.6~/xineLib.c vdr-plugin-xine-0.7.6/xineLib.c
---- vdr-plugin-xine-0.7.6~/xineLib.c	2006-01-12 01:21:23.599614013 +0000
-+++ vdr-plugin-xine-0.7.6/xineLib.c	2006-01-12 01:21:47.774014821 +0000
-@@ -1912,8 +1912,8 @@
-     }
-     else
-     {
--      ::fprintf(stderr, ("vdr-xine: error: couldn't open '" + noSignalFileName + "'!\n").c_str());
--      esyslog(("vdr-xine: error: couldn't open '" + noSignalFileName + "'!\n").c_str());
-+      ::fprintf(stderr, "vdr-xine: error: couldn't open '%s'!\n", noSignalFileName.c_str());
-+      esyslog("vdr-xine: error: couldn't open '%s'!\n", noSignalFileName.c_str());
-     }
- 
-     assert(remote);
-@@ -1953,69 +1953,32 @@
- 
-     const mode_t origUmask = ::umask(0);
-     
--    if (::mkdir(m_fifoDir.c_str(), 0755) < 0)
--    {
--      perror(("vdr-xine: error: couldn't create directory '" + m_fifoDir + "'").c_str());
--      esyslog(("vdr-xine: error: couldn't create directory '" + m_fifoDir + "'").c_str());
--
--      ::umask(origUmask);
--      return false;
--    }
--    
--    if (::mknod(m_fifoNameExtControl.c_str(), 0666 | S_IFIFO, 0) < 0)
--    {
--      perror(("vdr-xine: error: couldn't create fifo '" + m_fifoNameExtControl + "'").c_str());
--      esyslog(("vdr-xine: error: couldn't create fifo '" + m_fifoNameExtControl + "'").c_str());
--
--      ::umask(origUmask);
--      return false;
--    }
--
--    if (::mknod(m_fifoNameExtResult.c_str(), 0644 | S_IFIFO, 0) < 0)
--    {
--      perror(("vdr-xine: error: couldn't create fifo '" + m_fifoNameExtResult + "'").c_str());
--      esyslog(("vdr-xine: error: couldn't create fifo '" + m_fifoNameExtResult + "'").c_str());
--
--      ::umask(origUmask);
--      return false;
--    }
--
--    if (::mknod(m_fifoNameControl.c_str(), 0644 | S_IFIFO, 0) < 0)
--    {
--      perror(("vdr-xine: error: couldn't create fifo '" + m_fifoNameControl + "'").c_str());
--      esyslog(("vdr-xine: error: couldn't create fifo '" + m_fifoNameControl + "'").c_str());
--
--      ::umask(origUmask);
--      return false;
--    }
--
--    if (::mknod(m_fifoNameResult.c_str(), 0666 | S_IFIFO, 0) < 0)
--    {
--      perror(("vdr-xine: error: couldn't create fifo '" + m_fifoNameResult + "'").c_str());
--      esyslog(("vdr-xine: error: couldn't create fifo '" + m_fifoNameResult + "'").c_str());
--
--      ::umask(origUmask);
--      return false;
--    }
-+#define MkFifo(String, Mask) \
-+	do { if (::mknod((String).c_str(), (Mask) | S_IFIFO, 0) < 0) \
-+	{ \
-+	  string msg = "vdr-xine: error: couldn't create fifo '" + (String) + "'"; \
-+	  perror(msg.c_str()); \
-+	  esyslog("%s", msg.c_str()); \
-+	  ::umask(origUmask); \
-+	  return false; \
-+	} } while (0)
- 
--    if (::mknod(m_fifoNameRemote.c_str(), 0666 | S_IFIFO, 0) < 0)
-+    if (::mkdir(m_fifoDir.c_str(), 0755) < 0)
-     {
--      perror(("vdr-xine: error: couldn't create fifo '" + m_fifoNameRemote + "'").c_str());
--      esyslog(("vdr-xine: error: couldn't create fifo '" + m_fifoNameRemote + "'").c_str());
--
-+      string msg = "vdr-xine: error: couldn't create directory '" + m_fifoDir + "'";
-+      perror(msg.c_str());
-+      esyslog("%s", msg.c_str());
-       ::umask(origUmask);
-       return false;
-     }
- 
--    if (::mknod(m_fifoNameStream.c_str(), 0644 | S_IFIFO, 0) < 0)
--    {
--      perror(("vdr-xine: error: couldn't create fifo '" + m_fifoNameStream + "'").c_str());
--      esyslog(("vdr-xine: error: couldn't create fifo '" + m_fifoNameStream + "'").c_str());
-+    MkFifo(m_fifoNameExtControl, 0666);
-+    MkFifo(m_fifoNameExtResult,  0644);
-+    MkFifo(m_fifoNameControl,    0644);
-+    MkFifo(m_fifoNameResult,     0666);
-+    MkFifo(m_fifoNameRemote,     0666);
-+    MkFifo(m_fifoNameStream,     0644);
- 
--      ::umask(origUmask);
--      return false;
--    }
--    
-     ::umask(origUmask);
-     
-     if (!Start())

Modified: vdr/vdr-plugin-xine/branches/network/debian/patches/03_network.dpatch
===================================================================
--- vdr/vdr-plugin-xine/branches/network/debian/patches/03_network.dpatch	2006-03-25 23:58:13 UTC (rev 2119)
+++ vdr/vdr-plugin-xine/branches/network/debian/patches/03_network.dpatch	2006-03-26 00:02:08 UTC (rev 2120)
@@ -4,54 +4,77 @@
 ## All lines beginning with `## DP:' are a description of the patch.
 ## DP: This patch allows to provide a vdr stream via a
 ## DP: sockets interface This patch is based on Peter Webers
-## DP: xine-0-7-4-network. 
+## DP: xine-0-7-7-network. 
 
 @DPATCH@
-diff -urNad vdr-plugin-xine-0.7.6~/xine.c vdr-plugin-xine-0.7.6/xine.c
---- vdr-plugin-xine-0.7.6~/xine.c	2006-01-15 15:56:06.000000000 +0100
-+++ vdr-plugin-xine-0.7.6/xine.c	2006-01-15 15:56:21.000000000 +0100
-@@ -17,8 +17,8 @@
- 
- 
- 
--static const char *VERSION        = "0.7.6";
--static const char *DESCRIPTION    = "Software based playback using xine";
-+static const char *VERSION        = "0.7.6-net";
-+static const char *DESCRIPTION    = "Software based playback using xine over network";
- //static const char *MAINMENUENTRY  = "xine - Toggle prebuffer setting";
- 
- 
-@@ -77,6 +77,7 @@
+diff -Nru xine-0.7.7.orig/xine.c xine-0.7.7/xine.c
+--- xine-0.7.7.orig/xine.c	2006-01-15 00:47:12.000000000 +0100
++++ xine-0.7.7/xine.c	2006-02-20 17:36:48.000000000 +0100
+@@ -33,7 +33,7 @@
+   
+ public:
+   PluginXine::cXineLib *m_xineLib;
+-  int m_instanceNo;
++  in_addr_t m_bindIp;
+   
+   cPluginXine(void);
+   virtual ~cPluginXine();
+@@ -56,7 +56,7 @@
+   , m_remote(0)
+   , m_remoteOn(false)
+   , m_xineLib(0)
+-  , m_instanceNo(-1)
++  , m_bindIp(0)
+ {
+   // Initialize any member variables here.
+   // DON'T DO ANYTHING ELSE THAT MAY HAVE SIDE EFFECTS, REQUIRE GLOBAL
+@@ -73,7 +73,7 @@
+   //Return a string that describes all known command line options.
+   //"  -         --             x                                                   \n"
+   return
+-    "  -i N                     instance number to append to FIFO directory\n"
++    "  -i ip                    ip address to bind to\n"
      "  -q                       turn off debug messages on console\n"
      "  -r                       turn on remote (pressing keys in xine controls VDR)\n"
      "  -s                       switch to curses skin, while xine is disconnected\n"
-+    "  -n                       use network interface\n"
-     ;
- }
- 
-@@ -85,7 +86,7 @@
-   ::optind = 0;
-   ::opterr = 0;
- 
--  for (int r = -1; (r = ::getopt(argc, argv, "i:qrs")) >= 0; )
-+  for (int r = -1; (r = ::getopt(argc, argv, "i:qrsn")) >= 0; )
-   {
-     switch (r)
+@@ -93,11 +93,9 @@
      {
-@@ -111,6 +112,10 @@
-       m_settings.SetBeQuiet(true);
+     case 'i':
+       {
+-        const int no = ::atoi(::optarg);
+-        if (no < 0)
++        m_bindIp = inet_addr(::optarg);
++        if (m_bindIp == INADDR_NONE)
+           return false;
+-        
+-        m_instanceNo = no;
+       }
        break;
        
-+    case 'n':
-+      m_settings.SetUseSocketInterface(true);
-+      break;
-+      
-     default:
-       return false;
-     }
-diff -urNad vdr-plugin-xine-0.7.6~/xineLib.c vdr-plugin-xine-0.7.6/xineLib.c
---- vdr-plugin-xine-0.7.6~/xineLib.c	2006-01-15 15:56:21.000000000 +0100
-+++ vdr-plugin-xine-0.7.6/xineLib.c	2006-01-15 16:00:11.000000000 +0100
+@@ -203,9 +201,9 @@
+ 
+ namespace PluginXine
+ {
+-  int GetInstanceNo(cPlugin *const plugin)
++  int GetBindIp(cPlugin *const plugin)
+   {
+-    return ((cPluginXine *)plugin)->m_instanceNo;
++    return ((cPluginXine *)plugin)->m_bindIp;
+   }
+ 
+   cXineLib *&GetXineLib(cPlugin *const plugin)
+diff -Nru xine-0.7.7.orig/xineLib.c xine-0.7.7/xineLib.c
+--- xine-0.7.7.orig/xineLib.c	2006-02-12 22:36:48.000000000 +0100
++++ xine-0.7.7/xineLib.c	2006-02-20 18:06:02.000000000 +0100
+@@ -1847,7 +1847,7 @@
+   
+ #endif
+ 
+-  extern int GetInstanceNo(cPlugin *const plugin);
++  extern int GetBindIp(cPlugin *const plugin);
+   extern cXineLib *&GetXineLib(cPlugin *const plugin);
+   
+   cXineLib::cXineLib(cPlugin *const plugin, const cXineSettings &settings, cMutex &osdMutex, cXineRemote *const remote)
 @@ -1855,6 +1855,10 @@
        , m_plugin(plugin)
        , m_settings(settings)
@@ -63,7 +86,25 @@
        , fd_fifo0(-1)
        , fd_result(-1)
        , fd_control(-1)
-@@ -1941,6 +1945,34 @@
+@@ -1873,14 +1877,9 @@
+   {
+     m_fifoDir = FIFO_DIR;
+ 
+-    if (GetInstanceNo(plugin) >= 0)
+-    {
+-      char s[ 20 ];
+-      ::sprintf(s, "%d", GetInstanceNo(plugin));
+-      
+-      m_fifoDir += s;
+-    }
+-
++    m_bindIp = GetBindIp(plugin);
++    m_fifoDir += itoa(m_bindIp);
++		
+     m_fifoNameControl    = m_fifoDir + "/stream.control";
+     m_fifoNameResult     = m_fifoDir + "/stream.result";
+     m_fifoNameRemote     = m_fifoDir + "/stream.event";
+@@ -1962,9 +1961,37 @@
      m_eventSink = eventSink;
    }
  
@@ -78,7 +119,7 @@
 +		return -1;
 +	}
 +
-+	sain.sin_addr.s_addr = 0;
++	sain.sin_addr.s_addr = m_bindIp;
 +	sain.sin_port = htons(port);
 +
 +	::setsockopt(fd,SOL_SOCKET,SO_REUSEADDR,&onoff, sizeof(int) );
@@ -97,24 +138,16 @@
 +  
    bool cXineLib::Open()
    {
-     ::unlink(m_fifoNameExtControl.c_str());
-@@ -1951,6 +1983,8 @@
-     ::unlink(m_fifoNameStream.c_str());
-     ::rmdir(m_fifoDir.c_str());
+-    ::unlink(m_fifoNameExtControl.c_str());
++/*    ::unlink(m_fifoNameExtControl.c_str());
+     ::unlink(m_fifoNameExtResult.c_str());
+     ::unlink(m_fifoNameControl.c_str());
+     ::unlink(m_fifoNameResult.c_str());
+@@ -2003,6 +2030,26 @@
+ #undef MkFifo
  
-+    if (! m_settings.ShallUseSocketInterface())
-+    {
-     const mode_t origUmask = ::umask(0);
-     
- #define MkFifo(String, Mask) \
-@@ -1980,6 +2014,30 @@
-     MkFifo(m_fifoNameStream,     0644);
- 
      ::umask(origUmask);
-+    }
-+    else
-+    {
-+  
++*/
 +/*
 +{ .path = FIFO_STREAM,           .mode = 0644, .port = 18701 },
 +{ .path = FIFO_STREAM_CONTROL,   .mode = 0644, .port = 18702 },
@@ -134,14 +167,22 @@
 +
 +	if ((fd_remote_serv = CreateServerSocket(18704)) == -1)
 +		return false;
-+    }
      
      if (!Start())
        return false;
-@@ -2012,6 +2070,11 @@
+@@ -2028,13 +2075,18 @@
+       disconnect();
+     }
+     
+-    ::unlink(m_fifoNameExtControl.c_str());
++/*    ::unlink(m_fifoNameExtControl.c_str());
+     ::unlink(m_fifoNameExtResult.c_str());
+     ::unlink(m_fifoNameControl.c_str());
+     ::unlink(m_fifoNameResult.c_str());
      ::unlink(m_fifoNameRemote.c_str());
      ::unlink(m_fifoNameStream.c_str());
-     ::rmdir(m_fifoDir.c_str());
+-    ::rmdir(m_fifoDir.c_str());
++    ::rmdir(m_fifoDir.c_str()); */
 +
 +	::close(fd_remote_serv);
 +	::close(fd_result_serv);
@@ -150,95 +191,50 @@
    }
  
    void cXineLib::internalPaused(const bool paused)
-@@ -2073,7 +2136,13 @@
-       int myErrno = errno;
-       
-       ::signal(SIGPIPE, sigPipeHandler);
--      
-+            if (r == 0)
-+      {
-+	  fprintf(stderr, "deadlock! (no more)\n");
-+	  disconnect();
-+	  return -1;
-+      }
-+
-       if (r <= 0)
-       {
-         if (EAGAIN == myErrno || EINTR == myErrno)
-@@ -2081,7 +2150,7 @@
- 
-         xfprintf(stderr, "read(%d) returned %d, error %d: ", n, r, myErrno);
-         errno = myErrno;
--        if (!m_settings.ShallBeQuiet())
-+        if (! m_settings.ShallBeQuiet())
-           perror("");
- 
-         disconnect();
-@@ -2263,27 +2332,74 @@
+@@ -2286,6 +2338,28 @@
  //    fprintf(stderr, "Action done\n");
    }
    
-+  int cXineLib::SocketAcceptHelper(int fd)
-+  {
-+	  // use cPoller for checking server socket for incoming requests
-+	  cPoller poller(fd,0); /* POLLIN */
-+	  struct sockaddr sain;
-+	  socklen_t len = sizeof(sain);
-+	  int client;
-+	  
-+	  //::fprintf(stderr,"vdr-xine: polling for connection on %d...\n",fd);
-+	  if (!poller.Poll(100))
-+		  return -1;
++int cXineLib::SocketAcceptHelper(int fd)
++{
++      // use cPoller for checking server socket for incoming requests
++      cPoller poller(fd,0); /* POLLIN */
++      struct sockaddr sain;
++      socklen_t len = sizeof(sain);
++      int client;
++      
++//      ::fprintf(stderr,"vdr-xine: polling for connection on %d...\n",fd);
++      if (!poller.Poll(100))
++              return -1;
 +
-+	  //::fprintf(stderr,"vdr-xine: incoming requests on %d\n",fd);
-+	  if ((client = ::accept(fd,(struct sockaddr *) &sain,&len)) == -1) {
-+		  ::fprintf(stderr,"vdr-xine: fifo0 failed to accept...\n");
-+		  return -1;
-+	  }
-+	  //::fprintf(stderr,"vdr-xine: successful request on %d (client: %d)\n",fd,client);
-+	  return client;
-+  }
++//      ::fprintf(stderr,"vdr-xine: incoming requests on %d\n",fd);
++      if ((client = ::accept(fd,(struct sockaddr *) &sain,&len)) == -1) {
++              ::fprintf(stderr,"vdr-xine: fifo0 failed to accept...\n");
++              return -1;
++      }
++//      ::fprintf(stderr,"vdr-xine: successful request on %d (client: %d)\n",fd,client);
++      return client;
++}
 +
-   bool cXineLib::checkConnect()
-   {
 +
-+	  /* files */
- //    bool reinit = false;
+   bool cXineLib::checkXineVersion()
+   {
+     int32_t version = 0;
+@@ -2306,7 +2380,8 @@
        
  //    if (-1 == fd_fifo0)
  //    {
 -      fd_fifo0 = ::open(m_fifoNameStream.c_str(), O_WRONLY | O_NONBLOCK);
--      if (-1 == fd_fifo0)
-+//
-+     if (! m_settings.ShallUseSocketInterface())
-+     {
-+
-+        fd_fifo0 = ::open(m_fifoNameStream.c_str(), O_WRONLY | O_NONBLOCK);
-+        if (-1 == fd_fifo0)
++/*
++			fd_fifo0 = ::open(m_fifoNameStream.c_str(), O_WRONLY | O_NONBLOCK);
+       if (-1 == fd_fifo0)
          return false;
  
--      xfprintf(stderr, "vdr-xine: Client connecting ...\n");
-+        xfprintf(stderr, "vdr-xine: Client connecting ...\n");
+@@ -2321,6 +2396,23 @@
  
--      char zero = 0;
--      xwrite(fd_fifo0, &zero, sizeof (zero));
-+        char zero = 0;
-+        xwrite(fd_fifo0, &zero, sizeof (zero));
- 
--      fd_remote = ::open(m_fifoNameRemote.c_str(), O_RDONLY | O_NONBLOCK);
--      fd_control = ::open(m_fifoNameControl.c_str(), O_WRONLY);
--      fd_result  = ::open(m_fifoNameResult.c_str() , O_RDONLY);
-+        fd_remote = ::open(m_fifoNameRemote.c_str(), O_RDONLY | O_NONBLOCK);
-+        fd_control = ::open(m_fifoNameControl.c_str(), O_WRONLY);
-+        fd_result  = ::open(m_fifoNameResult.c_str() , O_RDONLY);
- 
--      ::fcntl(fd_fifo0 , F_SETFL, ~O_NONBLOCK & ::fcntl(fd_fifo0 , F_GETFL, 0));
--      ::fcntl(fd_remote, F_SETFL, ~O_NONBLOCK & ::fcntl(fd_remote, F_GETFL, 0));
-+        ::fcntl(fd_fifo0 , F_SETFL, ~O_NONBLOCK & ::fcntl(fd_fifo0 , F_GETFL, 0));
-+        ::fcntl(fd_remote, F_SETFL, ~O_NONBLOCK & ::fcntl(fd_remote, F_GETFL, 0));
-+     }
-+     else
-+     {
+       ::fcntl(fd_fifo0 , F_SETFL, ~O_NONBLOCK & ::fcntl(fd_fifo0 , F_GETFL, 0));
+       ::fcntl(fd_remote, F_SETFL, ~O_NONBLOCK & ::fcntl(fd_remote, F_GETFL, 0));
++*/
 +	  /* sockets */
 +
 +	  if (fd_fifo0_serv == -1)
@@ -255,74 +251,31 @@
 +	  
 +	  if ((fd_remote = SocketAcceptHelper(fd_remote_serv)) == -1)
 +		  return false;
-+     }
        
        internalPaused(false);
        
-diff -urNad vdr-plugin-xine-0.7.6~/xineLib.h vdr-plugin-xine-0.7.6/xineLib.h
---- vdr-plugin-xine-0.7.6~/xineLib.h	2006-01-15 15:56:21.000000000 +0100
-+++ vdr-plugin-xine-0.7.6/xineLib.h	2006-01-15 15:56:21.000000000 +0100
-@@ -136,8 +136,15 @@
-       return fd_remote;
+diff -Nru xine-0.7.7.orig/xineLib.h xine-0.7.7/xineLib.h
+--- xine-0.7.7.orig/xineLib.h	2006-02-03 22:16:46.000000000 +0100
++++ xine-0.7.7/xineLib.h	2006-02-20 17:36:48.000000000 +0100
+@@ -88,6 +88,7 @@
+     string m_fifoNameStream;
+     string m_fifoNameExtControl;
+     string m_fifoNameExtResult;
++    in_addr_t m_bindIp;
+ 
+   private:
+     cPlugin *const m_plugin;
+@@ -137,7 +138,13 @@
      }
      
--  private:    
-+  private:
-+/* sockets */
-+	int CreateServerSocket(unsigned short port);
-+	int SocketAcceptHelper(int fd);
-+	int fd_fifo0_serv, fd_result_serv, fd_control_serv, fd_remote_serv;
-+
+   private:    
++ /* sockets */
++    int CreateServerSocket(unsigned short port);
++    int SocketAcceptHelper(int fd);
++    int fd_fifo0_serv, fd_result_serv, fd_control_serv, fd_remote_serv;
      int fd_fifo0, fd_result, fd_control, fd_remote;
 +
 +
      cMutex m_ioMutex, m_dataMutex, m_disconnectMutex;
      cMutex &m_osdMutex;
  
-diff -urNad vdr-plugin-xine-0.7.6~/xineSettings.c vdr-plugin-xine-0.7.6/xineSettings.c
---- vdr-plugin-xine-0.7.6~/xineSettings.c	2006-01-15 15:56:06.000000000 +0100
-+++ vdr-plugin-xine-0.7.6/xineSettings.c	2006-01-15 15:56:21.000000000 +0100
-@@ -57,6 +57,7 @@
-   cXineSettings::cXineSettings()
-     : m_switchSkin(false)
-     , m_beQuiet(false)
-+    , m_useSocketInterface(false)
-     , m_osdMode(osdBlendScaledAuto)
-     , m_usageMode(modeLiveTV)
- //    , m_usageModeDefault(modeLiveTV)
-@@ -479,4 +480,14 @@
-     return m_beQuiet;
-   }
-   
-+  void cXineSettings::SetUseSocketInterface(const bool useSocketInterface)
-+  {
-+    m_useSocketInterface = useSocketInterface;
-+  }
-+  
-+  bool cXineSettings::ShallUseSocketInterface() const
-+  {
-+    return m_useSocketInterface;
-+  }
-+  
- };
-diff -urNad vdr-plugin-xine-0.7.6~/xineSettings.h vdr-plugin-xine-0.7.6/xineSettings.h
---- vdr-plugin-xine-0.7.6~/xineSettings.h	2006-01-15 15:56:06.000000000 +0100
-+++ vdr-plugin-xine-0.7.6/xineSettings.h	2006-01-15 15:56:21.000000000 +0100
-@@ -74,6 +74,7 @@
-   private:
-     bool m_switchSkin;
-     bool m_beQuiet;
-+    bool m_useSocketInterface;
-     
-     eOsdMode m_osdMode;
-     eUsageMode m_usageMode /* , m_usageModeDefault */;
-@@ -148,6 +149,9 @@
- 
-     void SetBeQuiet(const bool beQuiet);
-     bool ShallBeQuiet() const;
-+
-+    void SetUseSocketInterface(const bool useSocketInterface);
-+    bool ShallUseSocketInterface() const;
-   };
- 
- };

Modified: vdr/vdr-plugin-xine/branches/network/debian/vdr-plugin-xine.links
===================================================================
--- vdr/vdr-plugin-xine/branches/network/debian/vdr-plugin-xine.links	2006-03-25 23:58:13 UTC (rev 2119)
+++ vdr/vdr-plugin-xine/branches/network/debian/vdr-plugin-xine.links	2006-03-26 00:02:08 UTC (rev 2120)
@@ -1,3 +1,2 @@
-/usr/share/vdr/vdr-xine/noSignal-completelyBlack.pes	/etc/vdr/plugins/xine/noSignal-completelyBlack.pes
-/usr/share/vdr/vdr-xine/noSignal.pes			/etc/vdr/plugins/xine/noSignal.pes
-/etc/vdr/plugins/xine					/var/lib/vdr/plugins/xine
+/usr/share/vdr-plugin-xine/noSignal-completelyBlack.mpg    /var/lib/vdr/plugins/xine/noSignal-completelyBlack.mpg
+/usr/share/vdr-plugin-xine/noSignal.mpg                    /var/lib/vdr/plugins/xine/noSignal.mpg




More information about the pkg-vdr-dvb-changes mailing list