Hello community, here is the log from the commit of package linuxconsoletools for openSUSE:Factory checked in at 2016-02-17 10:33:07 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/linuxconsoletools (Old) and /work/SRC/openSUSE:Factory/.linuxconsoletools.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "linuxconsoletools" Changes: -------- --- /work/SRC/openSUSE:Factory/linuxconsoletools/linuxconsoletools.changes 2015-02-22 17:21:15.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.linuxconsoletools.new/linuxconsoletools.changes 2016-02-17 12:15:14.000000000 +0100 @@ -1,0 +2,11 @@ +Thu Feb 11 19:18:59 UTC 2016 - [email protected] + +- Update to 1.4.9 + * inputattach supports a new mouseman4 mode for 4-button Logitech + mice + * inputattach supports EETI eGalaxTouch touchscreens + * inputattach can provide a "ready" notification to systemd + * js-set-enum-leds no longer uses hotplug.functions. +- Spec file cleanups and dependency updates + +------------------------------------------------------------------- Old: ---- linuxconsoletools-1.4.8.tar.bz2 New: ---- linuxconsoletools-1.4.9.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ linuxconsoletools.spec ++++++ --- /var/tmp/diff_new_pack.CH0LJq/_old 2016-02-17 12:15:15.000000000 +0100 +++ /var/tmp/diff_new_pack.CH0LJq/_new 2016-02-17 12:15:15.000000000 +0100 @@ -1,7 +1,7 @@ # # spec file for package linuxconsoletools # -# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,7 +17,7 @@ Name: linuxconsoletools -Version: 1.4.8 +Version: 1.4.9 Release: 0 Summary: A set of utilities for joysticks License: GPL-2.0+ @@ -26,8 +26,9 @@ Source0: http://sourceforge.net/projects/linuxconsole/files/%{name}-%{version}.tar.bz2 BuildRequires: libSDL-devel BuildRequires: linux-kernel-headers +BuildRequires: pkg-config +BuildRequires: systemd-devel BuildRequires: udev - # moved in 13.2 Provides: input-utils = 2007.06.22 Obsoletes: input-utils <= 2007.06.22 @@ -46,15 +47,14 @@ settings as configured using jscal * jstest - test joystick devices - %prep %setup -q %build -make %{?_smp_mflags} CFLAGS="%{optflags}" +make %{?_smp_mflags} CFLAGS="%{optflags}" SYSTEMD_SUPPORT=1 %install -%make_install PREFIX=%{_prefix} +make %{?_smp_mflags} DESTDIR=%{buildroot} PREFIX=%{_prefix} install chmod 644 %{buildroot}%{_mandir}/man1/* # Fix udev dir mkdir -p %{buildroot}%{_libexecdir}/udev @@ -63,9 +63,25 @@ %files %defattr(-,root,root) %doc COPYING NEWS README -%{_bindir}/* +%{_bindir}/ffcfstress +%{_bindir}/ffmvforce +%{_bindir}/ffset +%{_bindir}/fftest +%{_bindir}/inputattach +%{_bindir}/jscal +%{_bindir}/jscal-restore +%{_bindir}/jscal-store +%{_bindir}/jstest +%{_mandir}/man1/ffcfstress.1%{ext_man} +%{_mandir}/man1/ffmvforce.1%{ext_man} +%{_mandir}/man1/ffset.1%{ext_man} +%{_mandir}/man1/fftest.1%{ext_man} +%{_mandir}/man1/inputattach.1%{ext_man} +%{_mandir}/man1/jscal-restore.1%{ext_man} +%{_mandir}/man1/jscal-store.1%{ext_man} +%{_mandir}/man1/jscal.1%{ext_man} +%{_mandir}/man1/jstest.1%{ext_man} %{_datadir}/joystick/ -%{_mandir}/man1/* %{_libexecdir}/udev/js-set-enum-leds %changelog ++++++ linuxconsoletools-1.4.8.tar.bz2 -> linuxconsoletools-1.4.9.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/linuxconsoletools-1.4.8/Makefile new/linuxconsoletools-1.4.9/Makefile --- old/linuxconsoletools-1.4.8/Makefile 2015-01-18 15:20:37.000000000 +0100 +++ new/linuxconsoletools-1.4.9/Makefile 2016-01-09 16:31:52.000000000 +0100 @@ -2,7 +2,7 @@ # # Makefile for Linux input utilities # -# © 2011-2015 Stephen Kitt <[email protected]> +# © 2011-2016 Stephen Kitt <[email protected]> # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -19,7 +19,7 @@ # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301 USA. -VERSION := 1.4.8 +VERSION := 1.4.9 PACKAGE := linuxconsoletools-$(VERSION) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/linuxconsoletools-1.4.8/NEWS new/linuxconsoletools-1.4.9/NEWS --- old/linuxconsoletools-1.4.8/NEWS 2015-01-18 15:47:25.000000000 +0100 +++ new/linuxconsoletools-1.4.9/NEWS 2016-01-07 20:38:13.000000000 +0100 @@ -1,3 +1,17 @@ +Version 1.4.9 +------------- + +* inputattach supports a new mouseman4 mode for 4-button Logitech mice + (thanks to Jamie Lentin <[email protected]>). + +* inputattach supports EETI eGalaxTouch touchscreens (thanks to + Böszörményi Zoltán <[email protected]>). + +* inputattach can provide a "ready" notification to systemd (thanks to + Böszörményi Zoltán <[email protected]>). + +* js-set-enum-leds no longer uses hotplug.functions. + Version 1.4.8 ------------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/linuxconsoletools-1.4.8/README new/linuxconsoletools-1.4.9/README --- old/linuxconsoletools-1.4.8/README 2015-01-18 15:43:58.000000000 +0100 +++ new/linuxconsoletools-1.4.9/README 2016-01-07 20:42:32.000000000 +0100 @@ -1,5 +1,5 @@ linuxconsole tools - Release 1.4.8 + Release 1.4.9 http://sf.net/projects/linuxconsole/ @@ -45,6 +45,8 @@ To install the utilities and their manpages, run make +or + make SYSTEMD_SUPPORT=1 and then as root make install from the distribution's top directory. This will install everything @@ -118,6 +120,54 @@ matched by "WACf") no longer contains the matching identifier. The appropriate X.org driver when using inputattach in this way is evdev. +A udev rule, especially shipped in a custom OS package is not +always applicable because it cannot handle the conflict presented +by the fact that not all computers are built the same and on one +computer, e.g ttyS1 can be attached to a specific touchscreen, +in another computer it can be attached to a different kind of +touchscreen or a different device or connected at all. +For this case, a wrapper script started from sysvinit, upstart, or +systemd is better suited. systemd needs special treatment inside +inputattach: a notification must be sent to it when inputattach +becomes "ready". To achieve this, the previously mentioned +"make SYSTEMD_SUPPORT=1" must be used to include this support. +Then a systemd unit file and the wrapper script can be added, similar +to the following: + +----8<---- inputattach-wrapper.sh ----8<---- +#!/bin/sh + +SYSTEM=`detect_computer_type` +case $SYSTEM in +type1) + inputattach --daemon -pm9k /dev/ttyS2 + ;; +type2) + inputattach --daemon -mtouch /dev/ttyS2 + ;; +# and so on +*) + # do nothing for other computers + ;; +esac + +# Exit without errors, so systemd won't try to +# restart our script for the "do nothing" case. +exit 0 +----8<- end of inputattach-wrapper.sh-8<---- + +----8<---- inputattach.service ----8<---- +[Unit] +Description=inputattach helper service + +[Service] +Type=forking +NotifyAccess=all +ExecStart=/usr/sbin/inputattach-wrapper.sh + +[Install] +WantedBy=multi-user.target +----8<- end of inputattach.service----8<---- Configuring PS3 controller LEDs ------------------------------- @@ -163,6 +213,9 @@ * Andrew Basterfield: fix for Spaceball 4000FLX support. * bri: PS3 controller LED configuration * Julian Squires: Wacom IV support. +* Jamie Lentin: mouseman4 mode. +* Böszörményi Zoltán: eGalaxTouch support, Hampshire support, systemd + notification. License @@ -173,7 +226,7 @@ Copyright © 2001 Oliver Hamann Copyright © 2001-2002 Johann Deneux Copyright © 2001 Arndt Schoenewald - Copyright © 2008-2015 Stephen Kitt + Copyright © 2008-2016 Stephen Kitt This program is free software; you can redistribute it and/or modify diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/linuxconsoletools-1.4.8/docs/Makefile new/linuxconsoletools-1.4.9/docs/Makefile --- old/linuxconsoletools-1.4.8/docs/Makefile 2011-12-15 16:49:01.000000000 +0100 +++ new/linuxconsoletools-1.4.9/docs/Makefile 2016-01-09 16:31:28.000000000 +0100 @@ -27,6 +27,6 @@ install: install -d $(DESTDIR)$(PREFIX)/share/man/man1 - install $(MANPAGES) $(DESTDIR)$(PREFIX)/share/man/man1 + install -m644 $(MANPAGES) $(DESTDIR)$(PREFIX)/share/man/man1 .PHONY: install diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/linuxconsoletools-1.4.8/docs/inputattach.1 new/linuxconsoletools-1.4.9/docs/inputattach.1 --- old/linuxconsoletools-1.4.8/docs/inputattach.1 2015-01-18 15:43:41.000000000 +0100 +++ new/linuxconsoletools-1.4.9/docs/inputattach.1 2016-01-09 16:29:35.000000000 +0100 @@ -1,4 +1,4 @@ -.TH inputattach 1 "August 9, 2011" inputattach +.TH inputattach 1 "January 9, 2016" inputattach .SH NAME inputattach \- attach a serial line to an input-layer device .SH SYNOPSIS @@ -28,7 +28,13 @@ .SS Modes .TP .BR \-dump ", " \-\-dump -Just enable device . +Just enable device. +.TP +.BR \-eeti ", " \-\-eetiegalax +EETI eGalaxTouch. +.TP +.BR \-ep ", " \-\-easypen +Genius EasyPen 3x4 tablet. .TP .BR \-elo3b ", " \-\-elo261-280 ELO Touchscreen, 3-byte mode. @@ -48,6 +54,9 @@ .BR \-ipaq ", " \-\-h3600ts Ipaq h3600 touchscreen. .TP +.BR \-ham ", " \-\-hampshire +Hampshire touchscreen. +.TP .BR \-ifor ", " \-\-iforce I-Force joystick or wheel. .TP @@ -66,6 +75,9 @@ .BR \-mmw ", " \-\-mmwheel Logitech mouse with 4-5 buttons or a wheel. .TP +.BR \-mman4 ", " \-\-mouseman4 +4-button Logitech / Genius mouse. +.TP .BR \-mman ", " \-\-mouseman 3-button Logitech / Genius mouse. .TP @@ -82,16 +94,19 @@ Newton keyboard. .TP .BR \-pm3k ", " \-\-penmount3000 -Penmount 3000 touchscreen. +PenMount 3000 touchscreen. .TP .BR \-pm6k ", " \-\-penmount6000 -Penmount 6000 touchscreen. +PenMount 6000 touchscreen. .TP .BR \-pmm1 ", " \-\-penmount6250 -Penmount 6250 touchscreen. +PenMount 6250 touchscreen. .TP .BR \-pm9k ", " \-\-penmount9000 -Penmount 9000 touchscreen. +PenMount 9000 touchscreen. +.TP +.BR \-ps2m ", " \-\-ps2mult +PS/2 serial multiplexer. .TP .BR \-ps2ser ", " \-\-ps2serkbd PS/2 via serial keyboard. @@ -117,9 +132,6 @@ .BR \-taos ", " \-\-taos\-evm TAOS evaluation module. .TP -.BR \-tsc ", " \-\-tsc -TSC-10/25/40 touch screen. -.TP .BR \-t213 ", " \-\-touchit213 Sahara Touch-iT213 Tablet PC. .TP @@ -129,6 +141,9 @@ .BR \-tw ", " \-\-touchwin Touchwindow serial touchscreen. .TP +.BR \-tsc ", " \-\-tsc +TSC-10/25/40 serial touchscreen. +.TP .BR \-twidjoy ", " \-\-twiddler-joy Handykey Twiddler used as a joystick. .TP @@ -144,7 +159,7 @@ "\fB\-\-baud 19200\fP" must be specified. .TP .BR \-wacom_iv ", " \-\-wacom_iv -Wacom protocol IV tablets. +Wacom protocol IV tablet. .TP .BR \-war ", " \-\-warrior WingMan Warrior. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/linuxconsoletools-1.4.8/docs/list-inputattach-modes new/linuxconsoletools-1.4.9/docs/list-inputattach-modes --- old/linuxconsoletools-1.4.8/docs/list-inputattach-modes 2011-12-15 16:49:01.000000000 +0100 +++ new/linuxconsoletools-1.4.9/docs/list-inputattach-modes 2016-01-09 16:18:34.000000000 +0100 @@ -5,8 +5,8 @@ print ".BR \\-" substr($2, 2) " \", \" " "\\-\\-" substr($1, 3); # print "\\fB\\-" substr($2, 2) "\\fR, \\fB\\-\\-" substr($1, 3) "\\fR"; remainder = ""; - for (i = 3; i <= NF; i++) + for (i = 3; i < NF; i++) remainder = remainder $i " "; - print remainder; + print remainder $NF "."; } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/linuxconsoletools-1.4.8/utils/Makefile new/linuxconsoletools-1.4.9/utils/Makefile --- old/linuxconsoletools-1.4.8/utils/Makefile 2015-01-18 15:22:53.000000000 +0100 +++ new/linuxconsoletools-1.4.9/utils/Makefile 2015-12-17 08:51:26.000000000 +0100 @@ -38,6 +38,13 @@ clean: $(RM) *.o *.swp $(PROGRAMS) *.orig *.rej map *~ +ifeq ($(SYSTEMD_SUPPORT),1) +SYSTEMDFLAGS = -DSYSTEMD_SUPPORT=1 $(shell pkg-config --cflags --libs libsystemd) +endif + +inputattach: inputattach.c + $(CC) $(CFLAGS) $(CPPFLAGS) -funsigned-char $^ $(LDFLAGS) $(SYSTEMDFLAGS) -lm -o $@ + ffcfstress: ffcfstress.c $(CC) $(CFLAGS) $(CPPFLAGS) -funsigned-char $^ $(LDFLAGS) -lm -o $@ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/linuxconsoletools-1.4.8/utils/inputattach.c new/linuxconsoletools-1.4.9/utils/inputattach.c --- old/linuxconsoletools-1.4.8/utils/inputattach.c 2015-01-18 15:43:41.000000000 +0100 +++ new/linuxconsoletools-1.4.9/utils/inputattach.c 2016-01-09 16:27:02.000000000 +0100 @@ -43,6 +43,9 @@ #include <sys/ioctl.h> #include <termios.h> #include <unistd.h> +#ifdef SYSTEMD_SUPPORT +#include <systemd/sd-daemon.h> +#endif static int readchar(int fd, unsigned char *c, int timeout) { @@ -622,6 +625,82 @@ return 0; } +#ifdef SERIO_EGALAX + +static int check_egalax_response(int fd, unsigned char *command, int sz, unsigned char *response) { + int pos = 0; + int error = 0; + int rest_length; + + if (write(fd, command, sz) != sz) + return -1; + + for (pos = 0; pos < 3; pos++) { + if (readchar(fd, &response[pos], 100)) { + error = 1; + break; + } + } + + if (error) + return -1; + + rest_length = response[1] - 1; + + for (; rest_length; rest_length--, pos++) { + if (readchar(fd, &response[pos], 100)) { + error = 1; + break; + } + } + + if (error) + return -1; + + if (response[1] >= command[1] && + response[0] == command[0] && + response[2] == command[2]) + return 0; + + return -1; +} + +static int egalax_init(int fd, unsigned long *id, unsigned long *extra) { + unsigned char packet_alive_query[3] = { 0x0a, 0x01, 'A' }; + unsigned char packet_fw_ver[3] = { 0x0a, 0x01, 'D' }; + unsigned char packet_ctrl_type[3] = { 0x0a, 0x01, 'E' }; + unsigned char response[128]; + + if (check_egalax_response(fd, packet_alive_query, sizeof(packet_alive_query), response)) + return -1; + + if (check_egalax_response(fd, packet_fw_ver, sizeof(packet_fw_ver), response)) + return -1; + +#if 0 + /* Log the firmware version */ + response[(unsigned char)response[1] + 2] = '\0'; + printf("EETI eGalaxTouch firmware: %s\n", &response[3]); +#endif + + if (check_egalax_response(fd, packet_ctrl_type, sizeof(packet_ctrl_type), response)) + return -1; + +#if 0 + /* + * Log the controller type. Maybe it will be useful + * later to detect the multitouch controllers and + * handle it in the kernel driver. + */ + response[(unsigned char)response[1] + 2] = '\0'; + printf("EETI eGalaxTouch controller type: %s\n", &response[3]); +#endif + + return 0; +} + +# endif /* SERIO_EGALAX */ + struct input_types { const char *name; const char *name2; @@ -676,6 +755,9 @@ { "--mouseman", "-mman", "3-button Logitech / Genius mouse", B1200, CS7, SERIO_MP, 0x00, 0x01, 1, NULL }, +{ "--mouseman4", "-mman4", "4-button Logitech / Genius mouse", + B1200, CS7, + SERIO_MP, 0x00, 0x03, 1, NULL }, { "--intellimouse", "-ms3", "Microsoft IntelliMouse", B1200, CS7, SERIO_MZ, 0x00, 0x11, 1, NULL }, @@ -704,6 +786,11 @@ { "--twiddler-joy", "-twidjoy", "Handykey Twiddler used as a joystick", B2400, CS8, SERIO_TWIDJOY, 0x00, 0x00, 0, twiddler_init }, +#ifdef SERIO_EGALAX +{ "--eetiegalax", "-eeti", "EETI eGalaxTouch", + B9600, CS8, + SERIO_EGALAX, 0x00, 0x00, 0, egalax_init }, +#endif { "--elotouch", "-elo", "ELO touchscreen, 10-byte mode", B9600, CS8, SERIO_ELO, 0x00, 0x00, 0, NULL }, @@ -716,6 +803,9 @@ { "--elo261-280", "-elo3b", "ELO Touchscreen, 3-byte mode", B9600, CS8 | CRTSCTS, SERIO_ELO, 0x03, 0x00, 0, NULL }, +{ "--hampshire", "-ham", "Hampshire touchscreen", + B9600, CS8, + SERIO_HAMPSHIRE, 0x00, 0x00, 0, NULL }, { "--mtouch", "-mtouch", "MicroTouch (3M) touchscreen", B9600, CS8 | CRTSCTS, SERIO_MICROTOUCH, 0x00, 0x00, 0, NULL }, @@ -768,7 +858,7 @@ { "--w8001", "-w8001", "Wacom W8001", B38400, CS8, SERIO_W8001, 0x00, 0x00, 0, NULL }, -{ "--wacom_iv", "-wacom_iv", "Wacom protocol 4 tablet", +{ "--wacom_iv", "-wacom_iv", "Wacom protocol IV tablet", B9600, CS8 | CRTSCTS, SERIO_WACOM_IV, 0x00, 0x00, 0, wacom_iv_init }, { NULL, NULL, NULL, 0, 0, 0, 0, 0, 0, NULL } @@ -924,6 +1014,10 @@ retval = EXIT_FAILURE; } +#ifdef SYSTEMD_SUPPORT + sd_notifyf(0, "READY=1\nSTATUS=Processing...\nMAINPID=%lu", (unsigned long) getpid()); +#endif + errno = 0; do { i = read(fd, NULL, 0); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/linuxconsoletools-1.4.8/utils/js-set-enum-leds new/linuxconsoletools-1.4.9/utils/js-set-enum-leds --- old/linuxconsoletools-1.4.8/utils/js-set-enum-leds 2015-01-18 15:16:12.000000000 +0100 +++ new/linuxconsoletools-1.4.9/utils/js-set-enum-leds 2016-01-07 20:36:14.000000000 +0100 @@ -23,8 +23,6 @@ # even before the gamepad is connected. In these cases please match what # bluez will do (or may already have done if it is already running.) -. /lib/udev/hotplug.functions - # If the set_gamepad_leds function provided for convenience is to be used # for a particular type of gamepad, the udev rule should provide the following # postional parameters. See /lib/udev/rules.d/60-joystick for examples. @@ -42,7 +40,7 @@ echo $1 > $led/brightness shift 1 else - mesg "set_gamepad_leds: wrong number of leds or values" + echo "set_gamepad_leds: wrong number of leds or values" 1>&2 exit -1 fi done @@ -72,5 +70,5 @@ ;; esac ;; - *) mesg "called with no matching model" + *) echo "called with no matching model" 1>&2 esac
