sys-apps/kbd: Revbump to make "loadkeys -d" not stop on first error
authorLars Wendler <polynomial-c@gentoo.org>
Wed, 14 Aug 2019 06:19:50 +0000 (08:19 +0200)
committerLars Wendler <polynomial-c@gentoo.org>
Wed, 14 Aug 2019 06:21:05 +0000 (08:21 +0200)
Package-Manager: Portage-2.3.71, Repoman-2.3.17
Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
sys-apps/kbd/files/kbd-2.2.0-kbdfile-dont_stop_on_first_error.patch [new file with mode: 0644]
sys-apps/kbd/kbd-2.2.0-r2.ebuild [moved from sys-apps/kbd/kbd-2.2.0-r1.ebuild with 93% similarity]

diff --git a/sys-apps/kbd/files/kbd-2.2.0-kbdfile-dont_stop_on_first_error.patch b/sys-apps/kbd/files/kbd-2.2.0-kbdfile-dont_stop_on_first_error.patch
new file mode 100644 (file)
index 0000000..4b545f5
--- /dev/null
@@ -0,0 +1,31 @@
+From acf93e44f6d036303f95555069031f6fb12ce9d1 Mon Sep 17 00:00:00 2001
+From: Alexey Gladkov <gladkov.alexey@gmail.com>
+Date: Tue, 6 Aug 2019 13:59:34 +0200
+Subject: [PATCH] libkbdfile: Do not stop on the first error
+
+The kbdfile_find() gets a list of directories in which the filename. If
+we could not find the filename in the first directory, you do not need
+to return an error.
+
+Link: https://github.com/legionus/kbd/issues/31
+
+Signed-off-by: Alexey Gladkov <gladkov.alexey@gmail.com>
+---
+ src/libkbdfile/kbdfile.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/libkbdfile/kbdfile.c b/src/libkbdfile/kbdfile.c
+index 804f04a..fb8e035 100644
+--- a/src/libkbdfile/kbdfile.c
++++ b/src/libkbdfile/kbdfile.c
+@@ -433,8 +433,8 @@ kbdfile_find(char *fnam, char **dirpath, char **suffixes, struct kbdfile *fp)
+               rc = findfile_in_dir(fnam, dir, recdepth, suffixes, fp);
+               free(dir);
+-              if (rc <= 0)
+-                      return rc;
++              if (!rc)
++                      return 0;
+       }
+       return 1;
similarity index 93%
rename from sys-apps/kbd/kbd-2.2.0-r1.ebuild
rename to sys-apps/kbd/kbd-2.2.0-r2.ebuild
index 895a4995c52c8ceff513a5f2a6df026dd4517841..3675430c7a9d7eccab93b6edee8b3d82ed1048f5 100644 (file)
@@ -36,7 +36,8 @@ BDEPEND="
 "
 
 PATCHES=(
-       "${FILESDIR}/${PN}-2.2.0-cflags.patch" #691142
+       "${FILESDIR}/${P}-cflags.patch" #691142
+       "${FILESDIR}/${P}-kbdfile-dont_stop_on_first_error.patch"
 )
 
 src_unpack() {