[Pkg-xfce-commits] r5309 - in goodies/trunk/xfce4-radio-plugin/debian: . patches
Lionel Le Folgoc
mrpouit-guest at alioth.debian.org
Sun Apr 3 12:08:39 UTC 2011
Author: mrpouit-guest
Date: 2011-04-03 12:08:35 +0000 (Sun, 03 Apr 2011)
New Revision: 5309
Added:
goodies/trunk/xfce4-radio-plugin/debian/patches/
goodies/trunk/xfce4-radio-plugin/debian/patches/0001-Port-to-libv4l1.patch
goodies/trunk/xfce4-radio-plugin/debian/patches/series
Modified:
goodies/trunk/xfce4-radio-plugin/debian/changelog
goodies/trunk/xfce4-radio-plugin/debian/control
goodies/trunk/xfce4-radio-plugin/debian/rules
Log:
* Port to libv4l1 (fixes FTBFS with recent kernels):
- debian/control: b-dep on xfce4-dev-tools, autoconf, automake, libtool
and libv4l-dev.
- debian/patches/{0001-Port-to-libv4l1.patch,series}: added.
- debian/rules: run xdt-autogen at configure time.
Modified: goodies/trunk/xfce4-radio-plugin/debian/changelog
===================================================================
--- goodies/trunk/xfce4-radio-plugin/debian/changelog 2011-04-03 11:07:54 UTC (rev 5308)
+++ goodies/trunk/xfce4-radio-plugin/debian/changelog 2011-04-03 12:08:35 UTC (rev 5309)
@@ -10,6 +10,11 @@
- add myself to Uploaders.
- remove Simon and Emanuele from uploaders, thanks to them.
- bump xfce4-panel-dev b-dep to (>= 4.8.0).
+ * Port to libv4l1 (fixes FTBFS with recent kernels):
+ - debian/control: b-dep on xfce4-dev-tools, autoconf, automake, libtool
+ and libv4l-dev.
+ - debian/patches/{0001-Port-to-libv4l1.patch,series}: added.
+ - debian/rules: run xdt-autogen at configure time.
-- Lionel Le Folgoc <mrpouit at gmail.com> Sun, 03 Apr 2011 00:32:39 +0200
Modified: goodies/trunk/xfce4-radio-plugin/debian/control
===================================================================
--- goodies/trunk/xfce4-radio-plugin/debian/control 2011-04-03 11:07:54 UTC (rev 5308)
+++ goodies/trunk/xfce4-radio-plugin/debian/control 2011-04-03 12:08:35 UTC (rev 5309)
@@ -5,7 +5,8 @@
Uploaders: Stefan Ott <stefan at ott.net>, Yves-Alexis Perez <corsac at debian.org>,
Lionel Le Folgoc <mrpouit at gmail.com>
Build-Depends: cdbs, debhelper (>= 7), xfce4-panel-dev (>= 4.8.0),
- libxml2-dev, libxml-parser-perl, intltool, libxfcegui4-dev, hardening-includes
+ libxml2-dev, libxml-parser-perl, intltool, libxfcegui4-dev, hardening-includes,
+ libv4l-dev, xfce4-dev-tools, autoconf, automake, libtool
Standards-Version: 3.9.1
Homepage: http://goodies.xfce.org/
Vcs-Svn: svn://svn.debian.org/pkg-xfce/goodies/trunk/xfce4-radio-plugin/
Added: goodies/trunk/xfce4-radio-plugin/debian/patches/0001-Port-to-libv4l1.patch
===================================================================
--- goodies/trunk/xfce4-radio-plugin/debian/patches/0001-Port-to-libv4l1.patch (rev 0)
+++ goodies/trunk/xfce4-radio-plugin/debian/patches/0001-Port-to-libv4l1.patch 2011-04-03 12:08:35 UTC (rev 5309)
@@ -0,0 +1,174 @@
+From b5a4e77348ad5302884a717f65a04ff59a2bdd87 Mon Sep 17 00:00:00 2001
+From: Lionel Le Folgoc <lionel at lefolgoc.net>
+Date: Sun, 3 Apr 2011 13:34:44 +0200
+Subject: Port to libv4l1
+
+In linux >= 2.6.38, <linux/videodev.h> has been dropped, so port the plugin to
+use the libv4l compatibility layer.
+---
+ configure.in | 1 +
+ panel-plugin/Makefile.am | 4 +++-
+ panel-plugin/v4l1.c | 24 +++++++++++-------------
+ panel-plugin/xfce4-radio.h | 3 ---
+ 4 files changed, 15 insertions(+), 17 deletions(-)
+
+Patch backported to apply cleanly against the debian package
+(configure.in.in -> configure.in).
+
+Bug: https://bugzilla.xfce.org/show_bug.cgi?id=7464
+Origin: backport, https://bugzilla.xfce.org/attachment.cgi?id=3596
+
+diff --git a/configure.in b/configure.in
+index b00b903..79b18ff 100644
+--- a/configure.in
++++ b/configure.in
+@@ -37,6 +37,7 @@ AC_HEADER_STDC
+ dnl configure the panel plugin
+ XDT_CHECK_PACKAGE([LIBXFCE4PANEL], [libxfce4panel-1.0], [4.3.22])
+ XDT_CHECK_PACKAGE([LIBXFCEGUI4], [libxfcegui4-1.0], [4.3.22])
++XDT_CHECK_PACKAGE([LIBV4L1], [libv4l1], [0.2])
+
+ dnl check for i18n support
+ XDT_I18N([ar ast ca cs da de el en_GB es eu fr gl hu id it ja lv nl pl pt_BR pt ru sq sv tr ug uk ur_PK ur zh_CN zh_TW ])
+diff --git a/panel-plugin/Makefile.am b/panel-plugin/Makefile.am
+index 32f81d3..dc09401 100644
+--- a/panel-plugin/Makefile.am
++++ b/panel-plugin/Makefile.am
+@@ -11,11 +11,13 @@ xfce4_radio_plugin_CFLAGS = \
+ -DPACKAGE_LOCALE_DIR=\"$(localedir)\" \
+ @LIBXFCE4PANEL_CFLAGS@ \
+ @LIBXFCEGUI4_CFLAGS@ \
++ @LIBV4L1_CFLAGS@ \
+ -std=c99
+
+ xfce4_radio_plugin_LDADD = \
+ @LIBXFCE4PANEL_LIBS@ \
+- @LIBXFCEGUI4_LIBS@
++ @LIBXFCEGUI4_LIBS@ \
++ @LIBV4L1_LIBS@
+
+ # .desktop file
+ #
+diff --git a/panel-plugin/v4l1.c b/panel-plugin/v4l1.c
+index 6bfc316..5ad6eaa 100644
+--- a/panel-plugin/v4l1.c
++++ b/panel-plugin/v4l1.c
+@@ -15,14 +15,12 @@
+
+ #include <stdio.h>
+ #include <stdlib.h>
+-#include <unistd.h>
+ #include <string.h>
+ #include <math.h>
+ #include <fcntl.h>
+-#include <sys/ioctl.h>
+ #include <assert.h>
+
+-#include <linux/videodev.h>
++#include <libv4l1.h>
+ #include "radio.h"
+
+ typedef struct _V4L1RadioDev V4L1RadioDev;
+@@ -40,11 +38,11 @@ v4l1_radio_init(RadioDev *radio_dev, char *device)
+ V4L1RadioDev *dev = (V4L1RadioDev*)radio_dev;
+ struct video_tuner tuner;
+
+- if ((dev->fd = open(device, O_RDONLY)) < 0)
++ if ((dev->fd = v4l1_open(device, O_RDONLY)) < 0)
+ return 0;
+
+ tuner.tuner = 0;
+- if (ioctl (dev->fd, VIDIOCGTUNER, &tuner) < 0)
++ if (v4l1_ioctl (dev->fd, VIDIOCGTUNER, &tuner) < 0)
+ dev->freq_fact = 16;
+ else
+ {
+@@ -85,7 +83,7 @@ v4l1_radio_set_freq(RadioDev *radio_dev, float freq)
+
+ assert ((freq <= 108) && (freq > 65));
+
+- if (ioctl(dev->fd, VIDIOCSFREQ, &ifreq) < 0)
++ if (v4l1_ioctl(dev->fd, VIDIOCSFREQ, &ifreq) < 0)
+ perror ("VIDIOCSFREQ");
+ }
+
+@@ -98,7 +96,7 @@ v4l1_radio_mute(RadioDev *radio_dev, int mute)
+ if (dev->fd<0)
+ return;
+
+- if (ioctl(dev->fd, VIDIOCGAUDIO, &vid_aud)) {
++ if (v4l1_ioctl(dev->fd, VIDIOCGAUDIO, &vid_aud)) {
+ perror("VIDIOCGAUDIO");
+ memset (&vid_aud, 0, sizeof (struct video_audio));
+ }
+@@ -109,7 +107,7 @@ v4l1_radio_mute(RadioDev *radio_dev, int mute)
+ vid_aud.flags &= ~VIDEO_AUDIO_MUTE;
+ vid_aud.mode = VIDEO_SOUND_STEREO;
+ }
+- if (ioctl(dev->fd, VIDIOCSAUDIO, &vid_aud))
++ if (v4l1_ioctl(dev->fd, VIDIOCSAUDIO, &vid_aud))
+ perror("VIDIOCSAUDIO");
+ }
+
+@@ -123,7 +121,7 @@ v4l1_radio_get_stereo(RadioDev *radio_dev)
+ if (dev->fd<0)
+ return -1;
+
+- if (ioctl (dev->fd, VIDIOCGAUDIO, &va) < 0)
++ if (v4l1_ioctl (dev->fd, VIDIOCGAUDIO, &va) < 0)
+ return -1;
+ if (va.mode == VIDEO_SOUND_STEREO)
+ return 1;
+@@ -142,7 +140,7 @@ v4l1_radio_get_signal(RadioDev *radio_dev)
+ return -1;
+
+ memset(&vt,0,sizeof(vt));
+- ioctl (dev->fd, VIDIOCGTUNER, &vt);
++ v4l1_ioctl (dev->fd, VIDIOCGTUNER, &vt);
+ signal=vt.signal>>13;
+
+ return signal;
+@@ -157,7 +155,7 @@ v4l1_radio_get_freq(RadioDev *radio_dev)
+ if (dev->fd<0)
+ return -1;
+
+- if (ioctl (dev->fd, VIDIOCGFREQ, &freq))
++ if (v4l1_ioctl (dev->fd, VIDIOCGFREQ, &freq))
+ {
+ perror ("VIDIOCGFREQ");
+ return -1;
+@@ -174,7 +172,7 @@ v4l1_radio_is_muted(RadioDev *radio_dev)
+ if (dev->fd<0)
+ return -1;
+
+- if (ioctl (dev->fd, VIDIOCGAUDIO, &vid_aud)) {
++ if (v4l1_ioctl (dev->fd, VIDIOCGAUDIO, &vid_aud)) {
+ perror ("VIDIOCGAUDIO");
+ return -1;
+ }
+@@ -188,7 +186,7 @@ v4l1_radio_finalize(RadioDev *radio_dev)
+ V4L1RadioDev *dev = (V4L1RadioDev*)radio_dev;
+
+ if (dev->fd >= 0)
+- close(dev->fd);
++ v4l1_close(dev->fd);
+ free (dev);
+ }
+
+diff --git a/panel-plugin/xfce4-radio.h b/panel-plugin/xfce4-radio.h
+index a8ad6fc..f2b8115 100644
+--- a/panel-plugin/xfce4-radio.h
++++ b/panel-plugin/xfce4-radio.h
+@@ -24,9 +24,6 @@
+ #include <glib.h>
+ #include <fcntl.h>
+
+-#include <sys/ioctl.h>
+-#include <linux/videodev.h>
+-
+ #include <libxfce4panel/xfce-panel-plugin.h>
+
+ #define FREQ_MIN 8750
+--
+1.7.4.1
+
Added: goodies/trunk/xfce4-radio-plugin/debian/patches/series
===================================================================
--- goodies/trunk/xfce4-radio-plugin/debian/patches/series (rev 0)
+++ goodies/trunk/xfce4-radio-plugin/debian/patches/series 2011-04-03 12:08:35 UTC (rev 5309)
@@ -0,0 +1 @@
+0001-Port-to-libv4l1.patch
Modified: goodies/trunk/xfce4-radio-plugin/debian/rules
===================================================================
--- goodies/trunk/xfce4-radio-plugin/debian/rules 2011-04-03 11:07:54 UTC (rev 5308)
+++ goodies/trunk/xfce4-radio-plugin/debian/rules 2011-04-03 12:08:35 UTC (rev 5309)
@@ -10,6 +10,13 @@
export CFLAGS LDFLAGS
+post-patches::
+ NOCONFIGURE=1 xdt-autogen
+
+clean::
+ rm -f $$(find -name 'Makefile.in*')
+ rm -f aclocal.m4 configure
+
binary-post-install/xfce4-radio-plugin::
-rm -rf debian/`dh_listpackages`/usr/lib/xfce4/panel-plugins/*.a
-rm -rf debian/`dh_listpackages`/usr/lib/xfce4/panel-plugins/*.la
More information about the Pkg-xfce-commits
mailing list