From cfbb761258e86cdb12f3bed465d21a5684b9b125b40bf2b15679107ea53d61f1 Mon Sep 17 00:00:00 2001 From: Stefan Dirsch Date: Thu, 5 Sep 2013 14:08:05 +0000 Subject: [PATCH] =?UTF-8?q?-=20update=20to=20release=201.1.4;=20changes=20?= =?UTF-8?q?since=201.1.0:=20=20=20*=20mtdev=5Fclose=20should=20ignore=20NU?= =?UTF-8?q?LL=20devices.=20=20=20*=20Return=20EINVAL=20for=20invalid=20par?= =?UTF-8?q?ameters=20on=20mtdev=5Finit.=20=20=20*=20Add=20the=20missing=20?= =?UTF-8?q?distance=20event=20to=20the=20internal=20slot=20=20=20=20=20rep?= =?UTF-8?q?resentation=20=20=20*=20Add=20support=20for=20kernel=20MT=20slo?= =?UTF-8?q?t=20state=20retrieval=20=20=20*=20Fix=20pc=20file=20to=20allow?= =?UTF-8?q?=20compiling=20with=20mtdev=20installed=20in=20non-std=20=20=20?= =?UTF-8?q?=20=20path.=20=20=20*=20Drop=20maintainer=20mode=20-=20enable?= =?UTF-8?q?=20by=20default=20=20=20*=20Rename=20INCLUDES=20to=20AM=5FCPPFL?= =?UTF-8?q?AGS=20=20=20*=20Merge=20build=20fixes=20from=20Peter=20Hutterer?= =?UTF-8?q?.=20=20=20*=20Replace=20hardcoded=2011=20with=20a=20define=20?= =?UTF-8?q?=20=20*=20Fix=20compiler=20warning=20-=20implicit=20declaration?= =?UTF-8?q?=20of=20function=20'abs'=20=20=20*=20test:=20silence=20compiler?= =?UTF-8?q?=20warning=20-=20implicit=20declaration=20of=20function=20=20?= =?UTF-8?q?=20=20=20=E2=80=98atoi=E2=80=99=20=20=20*=20Enable=20silent=20r?= =?UTF-8?q?ules=20by=20default=20=20=20*=20Merge=20more=20build=20fixes=20?= =?UTF-8?q?from=20Peter=20Hutterer,=20along=20with=20a=20more=20=20=20=20?= =?UTF-8?q?=20explicit=20declaration=20of=20the=20backwards=20compatibilit?= =?UTF-8?q?y=20constraints=20=20=20=20=20on=20the=20API.=20-=20removed=20o?= =?UTF-8?q?bsolete=20patches:=20=20=20*=20U=5FReturn-EINVAL-for-invalid-pa?= =?UTF-8?q?rameters-on-mtdev=5Finit.patch=20=20=20*=20U=5Fmtdev=5Fclose-sh?= =?UTF-8?q?ould-ignore-NULL-devices.patch=20=20=20*=20mtdev-implicit.diff?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit OBS-URL: https://build.opensuse.org/package/show/X11:XOrg/mtdev?expand=0&rev=9 --- ...for-invalid-parameters-on-mtdev_init.patch | 31 ------------ ...dev_close-should-ignore-NULL-devices.patch | 48 ------------------- mtdev-1.1.0.tar.bz2 | 3 -- mtdev-1.1.4.tar.bz2 | 3 ++ mtdev-implicit.diff | 45 ----------------- mtdev.changes | 27 +++++++++++ mtdev.spec | 14 ++---- 7 files changed, 34 insertions(+), 137 deletions(-) delete mode 100644 U_Return-EINVAL-for-invalid-parameters-on-mtdev_init.patch delete mode 100644 U_mtdev_close-should-ignore-NULL-devices.patch delete mode 100644 mtdev-1.1.0.tar.bz2 create mode 100644 mtdev-1.1.4.tar.bz2 delete mode 100644 mtdev-implicit.diff diff --git a/U_Return-EINVAL-for-invalid-parameters-on-mtdev_init.patch b/U_Return-EINVAL-for-invalid-parameters-on-mtdev_init.patch deleted file mode 100644 index 27899fb..0000000 --- a/U_Return-EINVAL-for-invalid-parameters-on-mtdev_init.patch +++ /dev/null @@ -1,31 +0,0 @@ -From 3aa3de4c19b80caaf93812fafff20acd5f5a4d12 Mon Sep 17 00:00:00 2001 -From: Peter Hutterer -Date: Tue, 19 Apr 2011 11:45:45 +0200 -Subject: [PATCH 2/2] Return EINVAL for invalid parameters on mtdev_init. - -[rydberg@euromail.se: minor cleanup] -Signed-off-by: Peter Hutterer -Signed-off-by: Henrik Rydberg ---- - src/core.c | 5 ++++- - 1 files changed, 4 insertions(+), 1 deletions(-) - -diff --git a/src/core.c b/src/core.c -index 07bc828..87ef420 100644 ---- a/src/core.c -+++ b/src/core.c -@@ -359,7 +359,10 @@ int mtdev_init(struct mtdev *dev) - - int mtdev_open(struct mtdev *dev, int fd) - { -- int ret; -+ int ret = -EINVAL; -+ -+ if (!dev || fd < 0) -+ goto error; - ret = mtdev_init(dev); - if (ret) - goto error; --- -1.7.6 - diff --git a/U_mtdev_close-should-ignore-NULL-devices.patch b/U_mtdev_close-should-ignore-NULL-devices.patch deleted file mode 100644 index 32209d4..0000000 --- a/U_mtdev_close-should-ignore-NULL-devices.patch +++ /dev/null @@ -1,48 +0,0 @@ -From 61684cf0466200631b6a44af1c662eb760ad3f5d Mon Sep 17 00:00:00 2001 -From: Peter Hutterer -Date: Tue, 19 Apr 2011 11:41:04 +0200 -Subject: [PATCH 1/2] mtdev_close should ignore NULL devices. - -Saves us one goto label in mtdev_init. - -Signed-off-by: Peter Hutterer -Signed-off-by: Henrik Rydberg ---- - src/core.c | 12 +++++++----- - 1 files changed, 7 insertions(+), 5 deletions(-) - -diff --git a/src/core.c b/src/core.c -index 1f7c1fe..07bc828 100644 ---- a/src/core.c -+++ b/src/core.c -@@ -365,11 +365,11 @@ int mtdev_open(struct mtdev *dev, int fd) - goto error; - ret = mtdev_configure(dev, fd); - if (ret) -- goto mtdev; -+ goto error; - return 0; -- mtdev: -- mtdev_close(dev); -+ - error: -+ mtdev_close(dev); - return ret; - } - -@@ -411,8 +411,10 @@ void mtdev_close_delete(struct mtdev *dev) - - void mtdev_close(struct mtdev *dev) - { -- free(dev->state); -- memset(dev, 0, sizeof(struct mtdev)); -+ if (dev) { -+ free(dev->state); -+ memset(dev, 0, sizeof(struct mtdev)); -+ } - } - - void mtdev_delete(struct mtdev *dev) --- -1.7.6 - diff --git a/mtdev-1.1.0.tar.bz2 b/mtdev-1.1.0.tar.bz2 deleted file mode 100644 index 425055d..0000000 --- a/mtdev-1.1.0.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:4cdd9f72ea04536788ddf2ddef7279abb44b7b4a466e6bd01bdd975cf236aa50 -size 246508 diff --git a/mtdev-1.1.4.tar.bz2 b/mtdev-1.1.4.tar.bz2 new file mode 100644 index 0000000..870f117 --- /dev/null +++ b/mtdev-1.1.4.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6b59b055ff22f2b91d4284187c2515826c338b81f6f33bd90f6bedc7c1fb9a38 +size 273780 diff --git a/mtdev-implicit.diff b/mtdev-implicit.diff deleted file mode 100644 index 88c8b8e..0000000 --- a/mtdev-implicit.diff +++ /dev/null @@ -1,45 +0,0 @@ -From: Jan Engelhardt -Date: 2012-02-12 19:46:35.478843702 +0100 - -build: resolve compiler warnings due to use of impl.-decl. fns - -match_four.c: In function 'set_dist': -match_four.c:79:4: warning: implicit declaration of function 'abs' [-Wimplicit-function-declaration] -mtdev-kernel.c: In function 'main': -mtdev-kernel.c:130:2: warning: implicit declaration of function 'atoi' [-Wimplicit-function-declaration] - ---- - src/match_four.c | 1 + - test/mtdev-kernel.c | 3 ++- - 2 files changed, 3 insertions(+), 1 deletion(-) - -Index: mtdev-1.1.0/src/match_four.c -=================================================================== ---- mtdev-1.1.0.orig/src/match_four.c -+++ mtdev-1.1.0/src/match_four.c -@@ -1,3 +1,4 @@ -+#include - #include "match.h" - #include - -Index: mtdev-1.1.0/test/mtdev-kernel.c -=================================================================== ---- mtdev-1.1.0.orig/test/mtdev-kernel.c -+++ mtdev-1.1.0/test/mtdev-kernel.c -@@ -26,6 +26,7 @@ - * - ****************************************************************************/ - -+#include - #include <../src/common.h> - #include - #include -@@ -127,7 +128,7 @@ int main(int argc, char *argv[]) - return 1; - } - -- eslot = atoi(argv[1]) + 1; -+ eslot = strtol(argv[1], NULL, 0) + 1; - if (eslot > SLOT_CNT) { - fprintf(stderr, "allowed slot range: 2 - %d\n", SLOT_MAX); - return 1; diff --git a/mtdev.changes b/mtdev.changes index c506810..cddf61b 100644 --- a/mtdev.changes +++ b/mtdev.changes @@ -1,3 +1,30 @@ +------------------------------------------------------------------- +Thu Sep 5 13:53:53 UTC 2013 - sndirsch@suse.com + +- update to release 1.1.4; changes since 1.1.0: + * mtdev_close should ignore NULL devices. + * Return EINVAL for invalid parameters on mtdev_init. + * Add the missing distance event to the internal slot + representation + * Add support for kernel MT slot state retrieval + * Fix pc file to allow compiling with mtdev installed in non-std + path. + * Drop maintainer mode - enable by default + * Rename INCLUDES to AM_CPPFLAGS + * Merge build fixes from Peter Hutterer. + * Replace hardcoded 11 with a define + * Fix compiler warning - implicit declaration of function 'abs' + * test: silence compiler warning - implicit declaration of function + ‘atoi’ + * Enable silent rules by default + * Merge more build fixes from Peter Hutterer, along with a more + explicit declaration of the backwards compatibility constraints + on the API. +- removed obsolete patches: + * U_Return-EINVAL-for-invalid-parameters-on-mtdev_init.patch + * U_mtdev_close-should-ignore-NULL-devices.patch + * mtdev-implicit.diff + ------------------------------------------------------------------- Sun Feb 12 18:48:05 UTC 2012 - jengelh@medozas.de diff --git a/mtdev.spec b/mtdev.spec index da4c2d1..66630c3 100644 --- a/mtdev.spec +++ b/mtdev.spec @@ -1,7 +1,7 @@ # # spec file for package mtdev # -# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,18 +16,14 @@ # - Name: mtdev BuildRequires: pkgconfig Summary: Multitouch Protocol Translation Library License: MIT Group: System/Libraries -Version: 1.1.0 +Version: 1.1.4 Release: 0 Source: http://bitmath.org/code/mtdev/mtdev-%{version}.tar.bz2 -Patch1: U_mtdev_close-should-ignore-NULL-devices.patch -Patch2: U_Return-EINVAL-for-invalid-parameters-on-mtdev_init.patch -Patch3: mtdev-implicit.diff Url: http://bitmath.org/code/mtdev/ BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -44,16 +40,14 @@ The mtdev is a stand-alone library which transforms all variants of kernel MT ev %package devel Summary: Development package for mtdev library Group: Development/Libraries/C and C++ -Requires: libmtdev1 = %{version} glibc-devel +Requires: glibc-devel +Requires: libmtdev1 = %{version} %description devel This package contains the files needed to compile programs that use mtdev library. %prep %setup -q -%patch1 -p1 -%patch2 -p1 -%patch -P 3 -p1 %build %configure --disable-static