[arch-commits] Commit in xf86-input-magictouch/repos (9 files)
Eric Bélanger
eric at archlinux.org
Sun Apr 26 22:54:37 UTC 2009
Date: Sunday, April 26, 2009 @ 18:54:36
Author: eric
Revision: 36681
Merged revisions 36680 via svnmerge from
svn+ssh://svn.archlinux.org/srv/svn-packages/xf86-input-magictouch/trunk
........
r36680 | eric | 2009-04-26 18:54:21 -0400 (Sun, 26 Apr 2009) | 2 lines
upgpkg: xf86-input-magictouch 1.0.0.5-6
Added license, Added xorg-util-macros makedepends, Added latest git patches to fix miscellaneous build/run time issues
........
Added:
xf86-input-magictouch/repos/extra-x86_64/LICENSE
(from rev 36680, xf86-input-magictouch/trunk/LICENSE)
xf86-input-magictouch/repos/extra-x86_64/git-0ab3a572.patch
(from rev 36680, xf86-input-magictouch/trunk/git-0ab3a572.patch)
xf86-input-magictouch/repos/extra-x86_64/git-2a6abb40.patch
(from rev 36680, xf86-input-magictouch/trunk/git-2a6abb40.patch)
xf86-input-magictouch/repos/extra-x86_64/git-6dca5f57.patch
(from rev 36680, xf86-input-magictouch/trunk/git-6dca5f57.patch)
xf86-input-magictouch/repos/extra-x86_64/git-7f90f6a6.patch
(from rev 36680, xf86-input-magictouch/trunk/git-7f90f6a6.patch)
xf86-input-magictouch/repos/extra-x86_64/git-bbd27423.patch
(from rev 36680, xf86-input-magictouch/trunk/git-bbd27423.patch)
xf86-input-magictouch/repos/extra-x86_64/git-c616070c.patch
(from rev 36680, xf86-input-magictouch/trunk/git-c616070c.patch)
Modified:
xf86-input-magictouch/repos/extra-x86_64/ (properties)
xf86-input-magictouch/repos/extra-x86_64/PKGBUILD
--------------------+
LICENSE | 26 ++
PKGBUILD | 25 +-
git-0ab3a572.patch | 38 +++
git-2a6abb40.patch | 578 +++++++++++++++++++++++++++++++++++++++++++++++++++
git-6dca5f57.patch | 26 ++
git-7f90f6a6.patch | 25 ++
git-bbd27423.patch | 24 ++
git-c616070c.patch | 97 ++++++++
8 files changed, 835 insertions(+), 4 deletions(-)
Property changes on: xf86-input-magictouch/repos/extra-x86_64
___________________________________________________________________
Modified: svnmerge-integrated
- /xf86-input-magictouch/trunk:1-20562
+ /xf86-input-magictouch/trunk:1-36680
Copied: xf86-input-magictouch/repos/extra-x86_64/LICENSE (from rev 36680, xf86-input-magictouch/trunk/LICENSE)
===================================================================
--- extra-x86_64/LICENSE (rev 0)
+++ extra-x86_64/LICENSE 2009-04-26 22:54:36 UTC (rev 36681)
@@ -0,0 +1,26 @@
+This package was downloaded from
+http://xorg.freedesktop.org/releases/individual/driver/
+
+Copyright (C) 1994-2003 The XFree86 Project, Inc. All Rights Reserved.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is fur-
+nished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FIT-
+NESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+XFREE86 PROJECT BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CON-
+NECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+Except as contained in this notice, the name of the XFree86 Project shall not
+be used in advertising or otherwise to promote the sale, use or other deal-
+ings in this Software without prior written authorization from the XFree86
+Project.
Modified: extra-x86_64/PKGBUILD
===================================================================
--- extra-x86_64/PKGBUILD 2009-04-26 22:54:21 UTC (rev 36680)
+++ extra-x86_64/PKGBUILD 2009-04-26 22:54:36 UTC (rev 36681)
@@ -3,20 +3,37 @@
pkgname=xf86-input-magictouch
pkgver=1.0.0.5
-pkgrel=5
+pkgrel=6
pkgdesc="X.org magictouch input driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
+license=('custom')
depends=('glibc')
-makedepends=('pkgconfig' 'xorg-server>=1.1.1')
+makedepends=('pkgconfig' 'xorg-server>=1.1.1' 'xorg-util-macros')
groups=('xorg-input-drivers')
options=('!libtool')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-md5sums=('d23f2791cd634ef85b7cc5e9da8f8407')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2 \
+ git-7f90f6a6.patch git-6dca5f57.patch git-c616070c.patch \
+ git-2a6abb40.patch git-bbd27423.patch git-0ab3a572.patch LICENSE)
+md5sums=('d23f2791cd634ef85b7cc5e9da8f8407' 'fcdf04ff2bea4f5dba4f1d2be77872ef'\
+ '927c19be07b2de21efdb896074a6996d' 'af1f19626b18994b5b9bbb98b1029eb3'\
+ '5c3b5e20dbb6b201e58b4c38c09e4885' '6d1553a3febd5238b60ce322cadc2230'\
+ 'f97a8f43d9975bdc6afb7b339600dcad' '6db298bec5113f63f5619567bcda9b56')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i "${srcdir}/git-0ab3a572.patch" || return 1
+ patch -Np1 -i "${srcdir}/git-6dca5f57.patch" || return 1
+ patch -Np1 -i "${srcdir}/git-bbd27423.patch" || return 1
+ patch -Np1 -i "${srcdir}/git-c616070c.patch" || return 1
+ patch -Np1 -i "${srcdir}/git-7f90f6a6.patch" || return 1
+ patch -Np1 -i "${srcdir}/git-2a6abb40.patch" || return 1
+ libtoolize --force || return 1
+ aclocal || return 1
+ autoconf || return 1
+ automake || return 1
./configure --prefix=/usr || return 1
make || return 1
make DESTDIR="${pkgdir}" install || return 1
+ install -D -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
Copied: xf86-input-magictouch/repos/extra-x86_64/git-0ab3a572.patch (from rev 36680, xf86-input-magictouch/trunk/git-0ab3a572.patch)
===================================================================
--- extra-x86_64/git-0ab3a572.patch (rev 0)
+++ extra-x86_64/git-0ab3a572.patch 2009-04-26 22:54:36 UTC (rev 36681)
@@ -0,0 +1,38 @@
+From 0ab3a5722f1fe4d34bcba29bffb0813f0966fc54 Mon Sep 17 00:00:00 2001
+From: Alan Coopersmith <Alan.Coopersmith at sun.com>
+Date: Fri, 03 Feb 2006 23:27:57 +0000
+Subject: Driver name is "magictouch", not "void"
+
+---
+diff --git a/ChangeLog b/ChangeLog
+index e6c8681..40cb99b 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,8 @@
++2006-02-03 Alan Coopersmith <alan.coopersmith at sun.com>
++
++ * man/magictouch.man:
++ Driver name is "magictouch", not "void"
++
+ 2005-12-20 Kevin E. Martin <kem-at-freedesktop-dot-org>
+
+ * configure.ac:
+diff --git a/man/magictouch.man b/man/magictouch.man
+index 663d115..c9e974d 100644
+--- a/man/magictouch.man
++++ b/man/magictouch.man
+@@ -1,9 +1,9 @@
+-.\" $XFree86$
++.\" $XdotOrg: $
+ .\" shorthand for double quote that works everywhere.
+ .ds q \N'34'
+-.TH VOID __drivermansuffix__ __vendorversion__
++.TH MAGICTOUCH __drivermansuffix__ __vendorversion__
+ .SH NAME
+-void \- null input driver
++magictouch \- MagicTouch input driver
+ .SH SYNOPSIS
+ .nf
+ .B "Section \*qInputDevice\*q"
+--
+cgit v0.8.2
Copied: xf86-input-magictouch/repos/extra-x86_64/git-2a6abb40.patch (from rev 36680, xf86-input-magictouch/trunk/git-2a6abb40.patch)
===================================================================
--- extra-x86_64/git-2a6abb40.patch (rev 0)
+++ extra-x86_64/git-2a6abb40.patch 2009-04-26 22:54:36 UTC (rev 36681)
@@ -0,0 +1,578 @@
+From 2a6abb40d484dcfe9833ece6a42bb47af97da894 Mon Sep 17 00:00:00 2001
+From: Peter Hutterer <peter.hutterer at redhat.com>
+Date: Thu, 14 Aug 2008 06:13:04 +0000
+Subject: Remove pre-XFREE86_V4 cruft.
+
+---
+diff --git a/src/xf86MagicTouch.c b/src/xf86MagicTouch.c
+index 9541318..3056426 100644
+--- a/src/xf86MagicTouch.c
++++ b/src/xf86MagicTouch.c
+@@ -6,12 +6,8 @@
+ #include "config.h"
+ #endif
+
+-#include <xf86Version.h>
+-#if XF86_VERSION_CURRENT >= XF86_VERSION_NUMERIC(3,9,0,0,0)
+-#define XFREE86_V4
+-#endif
++#include <xorgVersion.h>
+
+-#ifdef XFREE86_V4
+ #include <errno.h>
+ #include <string.h>
+ #include <unistd.h>
+@@ -26,129 +22,8 @@
+ #include <xf86Module.h>
+ #endif
+
+-#else /* XFREE86_V4 */
+-
+-#include <X11/Xos.h>
+-#include <signal.h>
+-#include <stdio.h>
+-#define NEED_EVENTS
+-#include <X11/X.h>
+-#include <X11/Xproto.h>
+-#include "inputstr.h"
+-#include "scrnintstr.h"
+-
+-#include <X11/extensions/XI.h>
+-#include <X11/extensions/XIproto.h>
+-
+-#if defined(sun) && !defined(i386)
+-#include <errno.h>
+-#include <termio.h>
+-#include <fcntl.h>
+-#include <ctype.h>
+-
+-#include "extio.h"
+-#else /* defined(sun) && !defined(i386) */
+-#include "compiler.h"
+-
+-#include "xf86.h"
+-#include "xf86Procs.h"
+-#include "xf86_OSlib.h"
+-#include "xf86_Config.h"
+-#include "xf86Xinput.h"
+-#include "xf86Version.h"
+-#endif /* defined(sun) && !defined(i386) */
+-
+-#if !defined(sun) || defined(i386)
+-#include "os.h"
+-#include "osdep.h"
+-#include "exevents.h"
+-
+-#include "extnsionst.h"
+-#include "extinit.h"
+-#endif /* !defined(sun) || defined(i386) */
+-
+-#endif /* XFREE86_V4 */
+-
+-
+-#ifndef XFREE86_V4
+-#if !defined(sun) || defined(i386)
+-/*
+- ***************************************************************************
+- *
+- * Configuration descriptor.
+- *
+- ***************************************************************************
+- */
+-
+-#define PORT 1
+-#define MAGIC_DEVICE_NAME 2
+-#define SCREEN_NO 3
+-#define MAXX 4
+-#define MAXY 5
+-#define MINX 6
+-#define MINY 7
+-#define DEBUG_LEVEL 8
+-#define HISTORY_SIZE 9
+-#define LINK_SPEED 10
+-#define ALWAYS_CORE 11
+-#define SWAP_AXES 12
+-#define N_SAMPLE_X 13
+-#define N_SAMPLE_Y 14
+-
+-static SymTabRec MagicTab[] = {
+- { ENDSUBSECTION, "endsubsection" },
+- { PORT, "port" },
+- { MAGIC_DEVICE_NAME, "devicename" },
+- { SCREEN_NO, "screenno" },
+- { MAXX, "maximumxposition" },
+- { MAXY, "maximumyposition" },
+- { MINX, "minimumxposition" },
+- { MINY, "minimumyposition" },
+- { DEBUG_LEVEL, "debuglevel" },
+- { HISTORY_SIZE, "historysize" },
+- { LINK_SPEED, "linkspeed" },
+- { ALWAYS_CORE, "alwayscore" },
+- { SWAP_AXES, "swapxy" },
+- { N_SAMPLE_X, "numsamplex" },
+- { N_SAMPLE_Y, "numsampley" },
+- { -1, "" },
+-};
+
+
+-#define LS1200 1
+-#define LS2400 2
+-#define LS4800 3
+-#define LS9600 4
+-
+-static SymTabRec LinkSpeedTab[] = {
+- { LS1200, "b1200" },
+- { LS2400, "b2400" },
+- { LS4800, "b4800" },
+- { LS9600, "b9600" }
+-};
+-#endif /* !defined(sun) || defined(i386) */
+-
+-/*
+- * This struct connects a line speed with
+- * a compatible motion packet delay. The
+- * driver will attempt to enforce a correct
+- * delay (according to this table) in order to
+- * avoid losing data in the touchscreen controller.
+- * LinkSpeedValues should be kept in sync with
+- * LinkSpeedTab.
+- */
+-typedef struct {
+- int speed;
+- int delay;
+-} LinkParameterStruct;
+-
+-static LinkParameterStruct LinkSpeedValues[] = {
+- { B1200, 8 },
+- { B2400, 4 },
+- { B4800, 2 },
+- { B9600, 1 }
+-};
+-#endif /* XFREE86_V4 */
+
+
+ /*
+@@ -200,7 +75,6 @@ static int debug_level = 0;
+ #endif
+
+
+-#ifdef XFREE86_V4
+ #undef SYSCALL
+ #undef read
+ #undef write
+@@ -210,7 +84,6 @@ static int debug_level = 0;
+ #define read(fd, ptr, num) xf86ReadSerial(fd, ptr, num)
+ #define write(fd, ptr, num) xf86WriteSerial(fd, ptr, num)
+ #define close(fd) xf86CloseSerial(fd)
+-#endif
+
+
+
+@@ -230,9 +103,6 @@ typedef struct _MagicPrivateRec {
+ int max_x; /* Maximum x */
+ int min_y; /* Minimum y reported by calibration */
+ int max_y; /* Maximum y */
+-#ifndef XFREE86_V4
+- int link_speed; /* Speed of the RS232 link connecting the ts. */
+-#endif
+ int screen_no; /* Screen associated with the device */
+ int screen_width; /* Width of the associated X screen */
+ int screen_height; /* Height of the screen */
+@@ -248,219 +118,6 @@ typedef struct _MagicPrivateRec {
+ } MagicPrivateRec, *MagicPrivatePtr;
+
+
+-#ifndef XFREE86_V4
+-#if !defined(sun) || defined(i386)
+-/*
+- ****************************************************************************
+- * xf86MagicConfig --
+- * Configure the device driver from configuration data
+- ****************************************************************************
+- */
+-static Bool
+-xf86MagicConfig(LocalDevicePtr *array,
+- int inx,
+- int max,
+- LexPtr val)
+-{
+- LocalDevicePtr local = array[inx];
+- MagicPrivatePtr priv = (MagicPrivatePtr)(local->private);
+- int token;
+-
+- while ((token = xf86GetToken(MagicTab)) != ENDSUBSECTION) {
+- switch(token) {
+-
+- case PORT:
+- if (xf86GetToken(NULL) != STRING) {
+- xf86ConfigError("MagicTouch input port expected");
+- }
+- priv->input_dev = strdup(val->str);
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch input port: %s\n",
+- XCONFIG_GIVEN, priv->input_dev);
+- }
+- break;
+-
+- case MAGIC_DEVICE_NAME:
+- if (xf86GetToken(NULL) != STRING) {
+- xf86ConfigError("Magictouch device name expected");
+- }
+- local->name = strdup(val->str);
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch X device name: %s\n",
+- XCONFIG_GIVEN, local->name);
+- }
+- break;
+-
+- case SCREEN_NO:
+- if (xf86GetToken(NULL) != NUMBER) {
+- xf86ConfigError("MagicTouch screen number expected");
+- }
+- priv->screen_no = val->num;
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch associated screen: %d\n",
+- XCONFIG_GIVEN, priv->screen_no);
+- }
+- break;
+-
+- case LINK_SPEED:
+- {
+- int ltoken = xf86GetToken(LinkSpeedTab);
+- if (ltoken == EOF ||
+- ltoken == STRING ||
+- ltoken == NUMBER) {
+- xf86ConfigError("MagicTouch link speed expected");
+- }
+- priv->link_speed = LinkSpeedValues[ltoken-1].speed;
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch link speed: %s bps\n",
+- XCONFIG_GIVEN, (LinkSpeedTab[ltoken-1].name)+1);
+- }
+- }
+- break;
+-
+- case MAXX:
+- if (xf86GetToken(NULL) != NUMBER) {
+- xf86ConfigError("MagicTouch maximum x position expected");
+- }
+- priv->max_x = val->num;
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch maximum x position: %d\n",
+- XCONFIG_GIVEN, priv->max_x);
+- }
+- break;
+-
+- case MAXY:
+- if (xf86GetToken(NULL) != NUMBER) {
+- xf86ConfigError("MagicTouch maximum y position expected");
+- }
+- priv->max_y = val->num;
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch maximum y position: %d\n",
+- XCONFIG_GIVEN, priv->max_y);
+- }
+- break;
+-
+- case MINX:
+- if (xf86GetToken(NULL) != NUMBER) {
+- xf86ConfigError("MagicTouch minimum x position expected");
+- }
+- priv->min_x = val->num;
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch minimum x position: %d\n",
+- XCONFIG_GIVEN, priv->min_x);
+- }
+- break;
+-
+- case MINY:
+- if (xf86GetToken(NULL) != NUMBER) {
+- xf86ConfigError("MagicTouch minimum y position expected");
+- }
+- priv->min_y = val->num;
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch minimum y position: %d\n",
+- XCONFIG_GIVEN, priv->min_y);
+- }
+- break;
+-
+- case DEBUG_LEVEL:
+- if (xf86GetToken(NULL) != NUMBER) {
+- xf86ConfigError("MagicTouch driver debug level expected");
+- }
+- debug_level = val->num;
+- if (xf86Verbose) {
+-#if DEBUG
+- ErrorF("%s MagicTouch debug level sets to %d\n", XCONFIG_GIVEN,
+- debug_level);
+-#else
+- ErrorF("%s MagicTouch debug not available\n",
+- XCONFIG_GIVEN, debug_level);
+-#endif
+- }
+- break;
+-
+- case HISTORY_SIZE:
+- if (xf86GetToken(NULL) != NUMBER) {
+- xf86ConfigError("MagicTouch motion history size expected");
+- }
+- local->history_size = val->num;
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch motion history size is %d\n", XCONFIG_GIVEN,
+- local->history_size);
+- }
+- break;
+-
+- case ALWAYS_CORE:
+- xf86AlwaysCore(local, TRUE);
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch device will always stays core pointer\n",
+- XCONFIG_GIVEN);
+- }
+- break;
+-
+- case SWAP_AXES:
+- priv->swap_axes = 1;
+- if (xf86Verbose) {
+- ErrorF("%s MagicTouch device will work with X and Y axes swapped\n",
+- XCONFIG_GIVEN);
+- }
+- break;
+-
+- case N_SAMPLE_X:
+- if (xf86GetToken(NULL) != NUMBER) {
+- xf86ConfigError("MagicTouch driver NumSamplesX expected");
+- }
+- priv->num_medie_x = val->num;
+-
+-
+- if (priv->num_medie_x>MEDIE_X)
+- priv->num_medie_x=MEDIE_X;
+-
+- DBG(4,
+- ErrorF("NumSampleX = %d\n", priv->num_medie_x)
+- );
+-
+- break;
+-
+- case N_SAMPLE_Y:
+- if (xf86GetToken(NULL) != NUMBER) {
+- xf86ConfigError("MagicTouch driver NumSamplesY expected");
+- }
+- priv->num_medie_y = val->num;
+-
+- if (priv->num_medie_y>MEDIE_Y)
+- priv->num_medie_y=MEDIE_Y;
+-
+- DBG(4,
+- ErrorF("NumSampleY = %d\n", priv->num_medie_y)
+- );
+- break;
+-
+- case EOF:
+- FatalError("Unexpected EOF (missing EndSubSection)");
+- break;
+-
+- default:
+- xf86ConfigError("MagicTouch subsection keyword expected");
+- break;
+- }
+- }
+-
+- if (priv->max_x - priv->min_x <= 0) {
+- ErrorF("%s MagicTouch: reverse x mode (minimum x position >= maximum x position)\n",
+- XCONFIG_GIVEN);
+- }
+- if (priv->max_y - priv->min_y <= 0) {
+- ErrorF("%s MagicTouch: reverse y mode (minimum y position >= maximum y position)\n",
+- XCONFIG_GIVEN);
+- }
+-
+- DBG(2, ErrorF("xf86MagicConfig port name=%s\n", priv->input_dev))
+-
+- return Success;
+-}
+-
+-#endif /* !defined(sun) || defined(i386) */
+-#endif /* XFREE86_V4 */
+
+ /****************************************************************************
+ *
+@@ -604,9 +261,6 @@ xf86MagicControl(DeviceIntPtr dev,
+ */
+ xf86MotionHistoryAllocate(local);
+
+-#ifndef XFREE86_V4
+- AssignTypeAndName(dev, local->atom, local->name);
+-#endif /* XFREE86_V4 */
+
+ DBG(2, ErrorF("MagicTouch INIT OK\n") );
+
+@@ -615,66 +269,14 @@ xf86MagicControl(DeviceIntPtr dev,
+ case DEVICE_ON:
+ DBG(2, ErrorF("MagicTouch ON\n") );
+ if (local->fd<0) {
+-#ifndef XFREE86_V4
+- struct termios termios_tty;
+- int i,result;
+-#endif
+
+ DBG(2, ErrorF("Opening device...\n") );
+
+-#ifdef XFREE86_V4
+ local->fd = xf86OpenSerial(local->options);
+ if (local->fd<0) {
+ ErrorF("Impossibile aprire MagicTouch\n");
+ return !Success;
+ }
+-#else
+- SYSCALL( local->fd = open(priv->input_dev, O_RDWR | O_NDELAY, 0) );
+- if (local->fd<0) {
+- Error("Impossibile aprire MagicTouch\n");
+- return !Success;
+- }
+-
+- DBG(3, ErrorF("Provo a configurare il MagicTouch\n") );
+-
+-
+- memset(&termios_tty, 0, sizeof(termios_tty) );
+- termios_tty.c_iflag = 0;
+- termios_tty.c_cflag = priv->link_speed | CS8 | CREAD | CLOCAL;
+- termios_tty.c_oflag = 0;
+- termios_tty.c_lflag = 0;
+- termios_tty.c_cc[VTIME]=0;
+- termios_tty.c_cc[VMIN]=1;
+-
+- /*
+- * Attivo l'RTS per abilitare il touch controller
+- */
+-#if 0
+- SYSCALL( result = ioctl(local->fd, TIOCMGET, &status_line) );
+- if (result<0)
+- {
+- Error("Impossibile leggere stato linee seriale\n");
+- close(local->fd);
+- return !Success;
+- }
+- status_line |= TIOCM_RTS;
+- SYSCALL( result = ioctl(local->fd, TIOCMSET, &status_line) );
+- if (result<0)
+- {
+- Error("Impossibile settare stato linee seriale\n");
+- close(local->fd);
+- return !Success;
+- }
+-#endif
+-
+- SYSCALL( result = tcsetattr(local->fd, TCSANOW, &termios_tty) );
+- if (result<0)
+- {
+- Error("Impossibile configurare MagicTouch\n");
+- close(local->fd);
+- return !Success;
+- }
+-#endif
+
+
+ /* Controlla se e' presente il touch controller.*/
+@@ -958,14 +560,12 @@ xf86MagicConvert(LocalDevicePtr local,
+ *x = (priv->screen_width * (input_x - priv->min_x)) / width;
+ *y = (priv->screen_height - (priv->screen_height * (input_y - priv->min_y)) / height);
+
+-#ifdef XFREE86_V4
+ /*
+ * Need to check if still on the correct screen.
+ * This call is here so that this work can be done after
+ * calib and before posting the event.
+ */
+ xf86XInputSetScreen(local, priv->screen_no, *x, *y);
+-#endif
+
+ DBG(3, ErrorF("MagicConvert: x(%d), y(%d)\n", *x, *y));
+
+@@ -981,17 +581,9 @@ xf86MagicConvert(LocalDevicePtr local,
+ ************************************************************************
+ */
+ static LocalDevicePtr
+-#ifndef XFREE86_V4
+-xf86MagicAllocate(void)
+-#else
+ xf86MagicAllocate(InputDriverPtr drv)
+-#endif
+ {
+-#ifndef XFREE86_V4
+- LocalDevicePtr local = (LocalDevicePtr) xalloc( sizeof(LocalDeviceRec) );
+-#else
+ LocalDevicePtr local = xf86AllocateInput(drv, 0);
+-#endif
+
+ MagicPrivatePtr priv = (MagicPrivatePtr) xalloc( sizeof(MagicPrivateRec) );
+
+@@ -1011,12 +603,7 @@ xf86MagicAllocate(InputDriverPtr drv)
+ }
+
+ /* I buffers sono allocati correttamente */
+-#ifdef XFREE86_V4
+ priv->input_dev = strdup(MAGIC_PORT);
+-#else
+- priv->input_dev = MAGIC_PORT;
+- priv->link_speed = MAGIC_LINK_SPEED;
+-#endif
+
+ priv->min_x = 60;
+ priv->max_x = 960;
+@@ -1042,11 +629,6 @@ xf86MagicAllocate(InputDriverPtr drv)
+ local->name = XI_TOUCHSCREEN;
+ local->flags = 0;
+
+-#ifndef XFREE86_V4
+-#if !defined(sun) || defined(i386)
+- local->device_config = xf86MagicConfig;
+-#endif /* !defined(sun) || defined(i386) */
+-#endif /* XFREE86_V4*/
+
+ local->device_control = xf86MagicControl;
+ local->read_input = xf86MagicReadInput;
+@@ -1068,40 +650,7 @@ xf86MagicAllocate(InputDriverPtr drv)
+ #endif
+
+
+-#ifndef XFREE86_V4
+-
+-/*
+- * Sezione relativa a X < 4.0.0
+- */
+-
+-DeviceAssocRec magictouch_assoc = {
+- "magictouch",
+- xf86MagicAllocate
+-};
+-
+-#ifdef DYNAMIC_MODULE
+-
+-#ifndef DLSYM_BUG
+-int init_module(unsigned long server_version)
+-#else
+-int init_xf86Magic(unsigned long server_version)
+-#endif
+-{
+- /* Aggiunge l'assiocazione per il touchscreen */
+- xf86AddDeviceAssoc(&magictouch_assoc);
+-
+- /* Controlla la versione */
+- if (server_version != XF86_VERSION_CURRENT) {
+- ErrorF("Warining: MagicTouch module compiled for version %s\n", XF86_VERSION);
+- return 0;
+- }
+- return 1;
+-}
+-#endif /* DYNAMIC_MODULE */
+-
+-#else
+ /*
+ * Sezione relativa a X >= 4.0.0
+ */
+
+-#endif /* XFREE86_V4 */
+--
+cgit v0.8.2
Copied: xf86-input-magictouch/repos/extra-x86_64/git-6dca5f57.patch (from rev 36680, xf86-input-magictouch/trunk/git-6dca5f57.patch)
===================================================================
--- extra-x86_64/git-6dca5f57.patch (rev 0)
+++ extra-x86_64/git-6dca5f57.patch 2009-04-26 22:54:36 UTC (rev 36681)
@@ -0,0 +1,26 @@
+From 6dca5f57e066e1fc911da9e51a5019a2ef69401b Mon Sep 17 00:00:00 2001
+From: Benjamin Close <Benjamin.Close at clearchain.com>
+Date: Wed, 09 Jan 2008 03:40:10 +0000
+Subject: Remove reliance on xf86_ansic.h
+
+The file was removed in 1faba797cbfe1a4804b7ea6b47e1ca9d4e4324e4
+and prevents compilation.
+
+Found by: Tinderbox
+---
+diff --git a/src/xf86MagicTouch.c b/src/xf86MagicTouch.c
+index d23d89c..12992e6 100644
+--- a/src/xf86MagicTouch.c
++++ b/src/xf86MagicTouch.c
+@@ -21,9 +21,6 @@
+
+ #include <misc.h>
+ #include <xf86.h>
+-#if !defined(DGUX)
+-#include <xf86_ansic.h>
+-#endif
+ #include <xf86_OSproc.h>
+ #include <xf86Xinput.h>
+ #include <exevents.h>
+--
+cgit v0.8.2
Copied: xf86-input-magictouch/repos/extra-x86_64/git-7f90f6a6.patch (from rev 36680, xf86-input-magictouch/trunk/git-7f90f6a6.patch)
===================================================================
--- extra-x86_64/git-7f90f6a6.patch (rev 0)
+++ extra-x86_64/git-7f90f6a6.patch 2009-04-26 22:54:36 UTC (rev 36681)
@@ -0,0 +1,25 @@
+From 7f90f6a6266b896da41be0f9b04621556c2e083d Mon Sep 17 00:00:00 2001
+From: Peter Hutterer <peter at cs.unisa.edu.au>
+Date: Mon, 26 May 2008 12:41:25 +0000
+Subject: Check for XINPUT ABI 3.
+
+---
+diff --git a/src/xf86MagicTouch.c b/src/xf86MagicTouch.c
+index 1a784ff..9541318 100644
+--- a/src/xf86MagicTouch.c
++++ b/src/xf86MagicTouch.c
+@@ -574,7 +574,11 @@ xf86MagicControl(DeviceIntPtr dev,
+ /*
+ * Il movimento viene eseguito su due assi in coordinate assolute.
+ */
+- if (InitValuatorClassDeviceStruct(dev, 2, xf86GetMotionEvents, local->history_size, Absolute) == FALSE )
++ if (InitValuatorClassDeviceStruct(dev, 2,
++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) < 3
++ xf86GetMotionEvents,
++#endif
++ local->history_size, Absolute) == FALSE )
+ {
+ ErrorF("MagicTouch ValuatorClassDeviceStruct: ERRORE\n");
+ return !Success;
+--
+cgit v0.8.2
Copied: xf86-input-magictouch/repos/extra-x86_64/git-bbd27423.patch (from rev 36680, xf86-input-magictouch/trunk/git-bbd27423.patch)
===================================================================
--- extra-x86_64/git-bbd27423.patch (rev 0)
+++ extra-x86_64/git-bbd27423.patch 2009-04-26 22:54:36 UTC (rev 36681)
@@ -0,0 +1,24 @@
+From bbd274235f80cc8858f27d232f4218de2792250e Mon Sep 17 00:00:00 2001
+From: Paulo Cesar Pereira de Andrade <pcpa at mandriva.com>
+Date: Thu, 31 Jan 2008 00:58:21 +0000
+Subject: Fix typo emoveEnabledDevice -> RemoveEnabledDevice.
+
+Typo detected when searching for missing symbols.
+
+Signed-off-by: Peter Hutterer <peter at cs.unisa.edu.au>
+---
+diff --git a/src/xf86MagicTouch.c b/src/xf86MagicTouch.c
+index 12992e6..4de6559 100644
+--- a/src/xf86MagicTouch.c
++++ b/src/xf86MagicTouch.c
+@@ -695,7 +695,7 @@ xf86MagicControl(DeviceIntPtr dev,
+ DBG(2, ErrorF("MagicTouch OFF\n") );
+ dev->public.on = FALSE;
+ if (local->fd>=0)
+- emoveEnabledDevice(local->fd);
++ RemoveEnabledDevice(local->fd);
+
+ SYSCALL( close(local->fd) );
+ local->fd = -1;
+--
+cgit v0.8.2
Copied: xf86-input-magictouch/repos/extra-x86_64/git-c616070c.patch (from rev 36680, xf86-input-magictouch/trunk/git-c616070c.patch)
===================================================================
--- extra-x86_64/git-c616070c.patch (rev 0)
+++ extra-x86_64/git-c616070c.patch 2009-04-26 22:54:36 UTC (rev 36681)
@@ -0,0 +1,97 @@
+From c616070ccdafd1dede1eb263bb480c7cf6cf6145 Mon Sep 17 00:00:00 2001
+From: Paulo Cesar Pereira de Andrade <pcpa at mandriva.com.br>
+Date: Sun, 16 Mar 2008 05:44:35 +0000
+Subject: Don't call non existing function and compile warning fixes.
+
+Signed-off-by: Peter Hutterer <peter at cs.unisa.edu.au>
+---
+diff --git a/src/xf86MagicTouch.c b/src/xf86MagicTouch.c
+index 4de6559..1a784ff 100644
+--- a/src/xf86MagicTouch.c
++++ b/src/xf86MagicTouch.c
+@@ -12,12 +12,9 @@
+ #endif
+
+ #ifdef XFREE86_V4
+-
+-#ifndef XFree86LOADER
+ #include <errno.h>
+ #include <string.h>
+ #include <unistd.h>
+-#endif
+
+ #include <misc.h>
+ #include <xf86.h>
+@@ -213,7 +210,6 @@ static int debug_level = 0;
+ #define read(fd, ptr, num) xf86ReadSerial(fd, ptr, num)
+ #define write(fd, ptr, num) xf86WriteSerial(fd, ptr, num)
+ #define close(fd) xf86CloseSerial(fd)
+-#define strdup(str) xf86strdup(str)
+ #endif
+
+
+@@ -549,8 +545,10 @@ xf86MagicControl(DeviceIntPtr dev,
+ LocalDevicePtr local = (LocalDevicePtr) dev->public.devicePrivate;
+ MagicPrivatePtr priv = (MagicPrivatePtr)(local->private);
+ unsigned char map[] = { 0, 1 };
+- unsigned char req[MAGIC_PACKET_SIZE], replay[MAGIC_PACKET_SIZE];
++ unsigned char req[MAGIC_PACKET_SIZE];
++#if 0
+ int status_line;
++#endif
+
+ switch (mode) {
+ case DEVICE_INIT:
+@@ -725,7 +723,6 @@ GetPacket(LocalDevicePtr local, unsigned char *buffer, int *n_rx, int fd)
+ int num_bytes;
+ int i;
+ Bool ok;
+- MagicPrivatePtr priv=(MagicPrivatePtr) local->private;
+
+ DBG(6, ErrorF("Entering GetPacket with packet_pos == %d\n", *n_rx) );
+
+@@ -851,11 +848,10 @@ xf86MagicReadInput(LocalDevicePtr local)
+ MagicPrivatePtr priv = (MagicPrivatePtr)(local->private);
+ int cur_x, cur_y;
+ Bool touch_now;
+- static int n_coms = 0;
+
+ if (!priv->e_presente) {
+ DBG(4,
+- ErrorF("<<%s[%d]>> ReadInput: Touch Controller non inizializzato\n")
++ ErrorF("xf86MagicReadInput: Touch Controller non inizializzato\n")
+ );
+ return;
+ }
+@@ -874,8 +870,8 @@ xf86MagicReadInput(LocalDevicePtr local)
+ cur_y = priv->packet_buf[3];
+ cur_y <<= 6;
+ cur_y |= priv->packet_buf[4];
+-
+- touch_now = priv->packet_buf[0] & MGCT_TOUCH == MGCT_TOUCH;
++
++ touch_now = (priv->packet_buf[0] & MGCT_TOUCH) == MGCT_TOUCH;
+
+ /* Se c'e' pressione sul touch inizio a calcolare la posizione
+ e a spostare il cursore grafico */
+@@ -972,8 +968,7 @@ xf86MagicConvert(LocalDevicePtr local,
+ return TRUE;
+ }
+
+-
+-
++#ifndef XFree86LOADER
+ /*
+ ************************************************************************
+ *
+@@ -1066,7 +1061,7 @@ xf86MagicAllocate(InputDriverPtr drv)
+ return local;
+
+ } /* xf86MagicAllocae */
+-
++#endif
+
+
+ #ifndef XFREE86_V4
+--
+cgit v0.8.2
More information about the arch-commits
mailing list