Update to kbd-2.2.0
This commit is contained in:
parent
eff44b086d
commit
70af662a75
14
.gitignore
vendored
14
.gitignore
vendored
@ -1,4 +1,3 @@
|
||||
kbd-1.12.tar.bz2
|
||||
kbd-latsun-fonts.tar.bz2
|
||||
sun12x22-fixed.psfu
|
||||
kbd-sun12x22-fixed.tar.bz2
|
||||
@ -7,18 +6,7 @@ ro.tar.bz2
|
||||
kbd-latarcyrheb-16-fixed.tar.bz2
|
||||
ro_maps.tar.bz2
|
||||
terminus.tar.bz2
|
||||
kbd-1.13wip.tar.gz
|
||||
kbd-1.15.tar.gz
|
||||
/kbd-1.15.2.tar.bz2
|
||||
/kbd-1.15.2.tar.bz2.sign
|
||||
/fr-dvorak.tar.bz2
|
||||
/kbd-1.15.3.tar.bz2
|
||||
/kbd-1.15.3.tar.bz2.sign
|
||||
/kbd-latarcyrheb-32.tar.bz2
|
||||
/kbd-1.15.3.tar.gz
|
||||
/kbd-1.15.5.tar.gz
|
||||
/kbd-2.0.1.tar.gz
|
||||
/kbdinfo.1
|
||||
/kbd-2.0.2.tar.xz
|
||||
/kbd-2.0.3.tar.xz
|
||||
/kbd-2.0.4.tar.xz
|
||||
/kbd-2.2.0.tar.xz
|
||||
|
@ -1,7 +1,7 @@
|
||||
diff -up kbd-2.0.4/docs/man/man8/kbdrate.8.orig kbd-2.0.4/docs/man/man8/kbdrate.8
|
||||
--- kbd-2.0.4/docs/man/man8/kbdrate.8.orig 2017-01-11 11:04:50.114831348 +0100
|
||||
+++ kbd-2.0.4/docs/man/man8/kbdrate.8 2017-01-11 11:05:35.619851252 +0100
|
||||
@@ -22,7 +22,7 @@ Using
|
||||
diff -up kbd-2.1.0/docs/man/man8/kbdrate.8.orig kbd-2.1.0/docs/man/man8/kbdrate.8
|
||||
--- kbd-2.1.0/docs/man/man8/kbdrate.8.orig 2019-06-21 10:08:17.000000000 +0200
|
||||
+++ kbd-2.1.0/docs/man/man8/kbdrate.8 2019-07-17 10:36:19.876499648 +0200
|
||||
@@ -19,7 +19,7 @@ Using
|
||||
without any options will reset the repeat rate to 10.9 characters per second (cps)
|
||||
and the delay to 250 milliseconds (ms) for Intel- and M68K-based systems.
|
||||
These are the IBM defaults. On SPARC-based systems it will reset the repeat rate
|
||||
@ -10,10 +10,10 @@ diff -up kbd-2.0.4/docs/man/man8/kbdrate.8.orig kbd-2.0.4/docs/man/man8/kbdrate.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
diff -up kbd-2.0.4/src/kbdrate.c.orig kbd-2.0.4/src/kbdrate.c
|
||||
--- kbd-2.0.4/src/kbdrate.c.orig 2017-01-11 11:05:10.226840148 +0100
|
||||
+++ kbd-2.0.4/src/kbdrate.c 2017-01-11 11:05:56.832860537 +0100
|
||||
@@ -111,9 +111,12 @@ static int valid_delays[] = { 250, 500,
|
||||
diff -up kbd-2.1.0/src/kbdrate.c.orig kbd-2.1.0/src/kbdrate.c
|
||||
--- kbd-2.1.0/src/kbdrate.c.orig 2019-07-02 17:44:57.000000000 +0200
|
||||
+++ kbd-2.1.0/src/kbdrate.c 2019-07-17 11:07:04.732486323 +0200
|
||||
@@ -114,9 +114,12 @@ static int print_only = 0;
|
||||
static int
|
||||
KDKBDREP_ioctl_ok(double rate, int delay, int silent)
|
||||
{
|
||||
@ -26,8 +26,8 @@ diff -up kbd-2.0.4/src/kbdrate.c.orig kbd-2.0.4/src/kbdrate.c
|
||||
* Since 2.4.9 also on i386.
|
||||
*/
|
||||
struct my_kbd_repeat kbdrep_s;
|
||||
@@ -176,6 +179,9 @@ KDKBDREP_ioctl_ok(double rate, int delay
|
||||
rate, kbdrep_s.delay);
|
||||
@@ -181,6 +184,9 @@ KDKBDREP_ioctl_ok(double rate, int delay
|
||||
}
|
||||
|
||||
return 1; /* success! */
|
||||
+#else /* no KDKBDREP or __sparc__ */
|
||||
@ -35,31 +35,28 @@ diff -up kbd-2.0.4/src/kbdrate.c.orig kbd-2.0.4/src/kbdrate.c
|
||||
+#endif /* KDKBDREP */
|
||||
}
|
||||
|
||||
#ifndef KIOCSRATE
|
||||
@@ -226,7 +232,7 @@ sigalrmhandler(int sig __attribute__((un
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
#ifdef __sparc__
|
||||
- double rate = 5.0; /* Default rate */
|
||||
+ double rate = 20.0; /* Default rate */
|
||||
int delay = 200; /* Default delay */
|
||||
#else
|
||||
double rate = 10.9; /* Default rate */
|
||||
@@ -275,8 +281,9 @@ int main(int argc, char **argv)
|
||||
if (KIOCSRATE_ioctl_ok(rate, delay, silent)) /* sparc? */
|
||||
return 0;
|
||||
#ifdef KIOCSRATE
|
||||
@@ -251,6 +257,9 @@ ioport_set(double rate, int delay, int s
|
||||
|
||||
/* https://wiki.osdev.org/PS/2_Keyboard */
|
||||
|
||||
- /* The ioport way */
|
||||
+ /* The ioport way - will crash on sparc */
|
||||
|
||||
+
|
||||
+#ifndef __sparc__
|
||||
for (i = 0; i < RATE_COUNT; i++)
|
||||
for (i = 0; i < (int) RATE_COUNT; i++)
|
||||
if (rate * 10 >= valid_rates[i]) {
|
||||
value &= 0x60;
|
||||
@@ -333,5 +340,6 @@ int main(int argc, char **argv)
|
||||
@@ -304,11 +313,12 @@ ioport_set(double rate, int delay, int s
|
||||
valid_rates[value & 0x1f] / 10.0,
|
||||
valid_delays[(value & 0x60) >> 5]);
|
||||
|
||||
+#endif
|
||||
return EXIT_SUCCESS;
|
||||
return 1;
|
||||
}
|
||||
|
||||
#ifdef __sparc__
|
||||
-double rate = 5.0; /* Default rate */
|
||||
+double rate = 20.0; /* Default rate */
|
||||
int delay = 200; /* Default delay */
|
||||
#else
|
||||
double rate = 10.9; /* Default rate */
|
||||
|
@ -1,18 +1,18 @@
|
||||
diff -up kbd-2.0.4/src/loadkeys.c.orig kbd-2.0.4/src/loadkeys.c
|
||||
--- kbd-2.0.4/src/loadkeys.c.orig 2017-01-11 11:14:48.308093019 +0100
|
||||
+++ kbd-2.0.4/src/loadkeys.c 2017-01-11 11:15:18.018106020 +0100
|
||||
@@ -27,7 +27,7 @@
|
||||
diff -up kbd-2.1.0/src/loadkeys.c.orig kbd-2.1.0/src/loadkeys.c
|
||||
--- kbd-2.1.0/src/loadkeys.c.orig 2019-07-15 10:57:18.000000000 +0200
|
||||
+++ kbd-2.1.0/src/loadkeys.c 2019-07-17 14:34:51.224525616 +0200
|
||||
@@ -24,7 +24,7 @@
|
||||
#include "paths.h"
|
||||
#include "keymap.h"
|
||||
|
||||
static const char *progname = NULL;
|
||||
-static const char *const dirpath1[] = { "", DATADIR "/" KEYMAPDIR "/**", KERNDIR "/", 0 };
|
||||
+static const char *const dirpath1[] = { "", DATADIR "/" KEYMAPDIR "/**", DATADIR "/" XKBKEYMAPDIR "/", DATADIR "/" LEGACYKEYMAPDIR "/**", KERNDIR "/", 0 };
|
||||
static const char *const suffixes[] = { "", ".kmap", ".map", 0 };
|
||||
|
||||
static void __attribute__((noreturn))
|
||||
diff -up kbd-2.0.4/src/paths.h.orig kbd-2.0.4/src/paths.h
|
||||
--- kbd-2.0.4/src/paths.h.orig 2017-01-11 11:15:40.404115812 +0100
|
||||
+++ kbd-2.0.4/src/paths.h 2017-01-11 11:15:59.730124274 +0100
|
||||
diff -up kbd-2.1.0/src/paths.h.orig kbd-2.1.0/src/paths.h
|
||||
--- kbd-2.1.0/src/paths.h.orig 2019-05-07 11:21:10.000000000 +0200
|
||||
+++ kbd-2.1.0/src/paths.h 2019-07-17 14:35:13.870574558 +0200
|
||||
@@ -5,6 +5,8 @@
|
||||
* The following five subdirectories are defined:
|
||||
*/
|
||||
|
@ -1,7 +1,7 @@
|
||||
diff -up kbd-2.0.4/src/kdmapop.c.orig kbd-2.0.4/src/kdmapop.c
|
||||
--- kbd-2.0.4/src/kdmapop.c.orig 2018-11-05 10:06:05.208744333 +0100
|
||||
+++ kbd-2.0.4/src/kdmapop.c 2018-11-05 10:14:16.149215908 +0100
|
||||
@@ -154,6 +154,7 @@ int getunimap(int fd, struct unimapdesc
|
||||
diff -up kbd-2.1.0/src/kdmapop.c.orig kbd-2.1.0/src/kdmapop.c
|
||||
--- kbd-2.1.0/src/kdmapop.c.orig 2019-05-07 11:21:10.000000000 +0200
|
||||
+++ kbd-2.1.0/src/kdmapop.c 2019-07-17 14:38:15.799967669 +0200
|
||||
@@ -155,6 +155,7 @@ int getunimap(int fd, struct unimapdesc
|
||||
}
|
||||
if (ioctl(fd, GIO_UNIMAP, &ud)) {
|
||||
perror("GIO_UNIMAP");
|
||||
@ -9,22 +9,10 @@ diff -up kbd-2.0.4/src/kdmapop.c.orig kbd-2.0.4/src/kdmapop.c
|
||||
return -1;
|
||||
}
|
||||
if (ct != ud.entry_ct)
|
||||
diff -up kbd-2.0.4/src/libkeymap/common.c.orig kbd-2.0.4/src/libkeymap/common.c
|
||||
--- kbd-2.0.4/src/libkeymap/common.c.orig 2016-12-19 16:01:51.000000000 +0100
|
||||
+++ kbd-2.0.4/src/libkeymap/common.c 2018-11-05 10:05:50.207730393 +0100
|
||||
@@ -246,5 +246,8 @@ int lk_free(struct lk_ctx *ctx)
|
||||
ctx->key_line = NULL;
|
||||
}
|
||||
|
||||
+ free(ctx);
|
||||
+ ctx = NULL;
|
||||
+
|
||||
return 0;
|
||||
}
|
||||
diff -up kbd-2.0.4/src/setfont.c.orig kbd-2.0.4/src/setfont.c
|
||||
--- kbd-2.0.4/src/setfont.c.orig 2018-11-05 10:28:01.994027734 +0100
|
||||
+++ kbd-2.0.4/src/setfont.c 2018-11-05 10:35:54.933477039 +0100
|
||||
@@ -327,6 +327,8 @@ do_loadfont(int fd, char *inbuf, int wid
|
||||
diff -up kbd-2.1.0/src/setfont.c.orig kbd-2.1.0/src/setfont.c
|
||||
--- kbd-2.1.0/src/setfont.c.orig 2019-06-25 18:14:32.000000000 +0200
|
||||
+++ kbd-2.1.0/src/setfont.c 2019-07-17 14:39:57.928188355 +0200
|
||||
@@ -323,6 +323,8 @@ do_loadfont(int fd, char *inbuf, int wid
|
||||
|
||||
if (putfont(fd, buf, fontsize, width, hwunit))
|
||||
exit(EX_OSERR);
|
||||
|
16
kbd-2.2.0-fix-flags.patch
Normal file
16
kbd-2.2.0-fix-flags.patch
Normal file
@ -0,0 +1,16 @@
|
||||
diff -up kbd-2.2.0/configure.ac.orig kbd-2.2.0/configure.ac
|
||||
--- kbd-2.2.0/configure.ac.orig 2019-08-28 11:07:00.787173606 +0200
|
||||
+++ kbd-2.2.0/configure.ac 2019-08-28 11:08:07.217317151 +0200
|
||||
@@ -72,9 +72,9 @@ if test "$enable_code_coverage" = yes; t
|
||||
fi
|
||||
|
||||
case "$GCC,$ac_cv_prog_cc_g" in
|
||||
- yes,yes) CFLAGS="-g $CC_O_LEVEL $FORTIFY_SOURCE" ;;
|
||||
- yes,) CFLAGS="$CC_O_LEVEL $FORTIFY_SOURCE" ;;
|
||||
- ,yes) CFLAGS="-g" ;;
|
||||
+ yes,yes) CFLAGS="$CC_O_LEVEL $FORTIFY_SOURCE $CFLAGS" ;;
|
||||
+ yes,) CFLAGS="$CC_O_LEVEL $FORTIFY_SOURCE $CFLAGS" ;;
|
||||
+ ,yes) CFLAGS="$CFLAGS" ;;
|
||||
esac
|
||||
|
||||
CC_CHECK_CFLAGS_APPEND([\
|
14
kbd-2.2.0-format-security.patch
Normal file
14
kbd-2.2.0-format-security.patch
Normal file
@ -0,0 +1,14 @@
|
||||
diff -up kbd-2.2.0/src/libkeymap/analyze.l.orig kbd-2.2.0/src/libkeymap/analyze.l
|
||||
--- kbd-2.2.0/src/libkeymap/analyze.l.orig 2019-06-25 11:41:55.000000000 +0200
|
||||
+++ kbd-2.2.0/src/libkeymap/analyze.l 2019-10-17 08:39:01.924605478 +0200
|
||||
@@ -463,7 +463,10 @@ To to|To|TO
|
||||
|
||||
strerror_r(errno, buf, sizeof(buf));
|
||||
|
||||
+ /* workaround -Werror=format-security error
|
||||
ERR(yyextra, buf);
|
||||
+ */
|
||||
+ ERR(yyextra, _("unknown error"));
|
||||
return(ERROR);
|
||||
}
|
||||
|
20
kbd.spec
20
kbd.spec
@ -1,6 +1,6 @@
|
||||
Name: kbd
|
||||
Version: 2.0.4
|
||||
Release: 15%{?dist}
|
||||
Version: 2.2.0
|
||||
Release: 1%{?dist}
|
||||
Summary: Tools for configuring the console (keyboard, virtual terminals, etc.)
|
||||
License: GPLv2+
|
||||
URL: http://www.kbd-project.org/
|
||||
@ -29,8 +29,12 @@ Patch5: kbd-1.15.5-loadkeys-search-path.patch
|
||||
Patch6: kbd-2.0.2-unicode-start-font.patch
|
||||
# Patch7: fixes issues found by static analysis
|
||||
Patch7: kbd-2.0.4-covscan-fixes.patch
|
||||
# Patch8: fix flags
|
||||
Patch8: kbd-2.2.0-fix-flags.patch
|
||||
# Patch9: workaround -Werror=format-security build error
|
||||
Patch9: kbd-2.2.0-format-security.patch
|
||||
|
||||
BuildRequires: gcc, bison, flex, gettext, pam-devel, check-devel
|
||||
BuildRequires: gcc, bison, flex, gettext, pam-devel, check-devel, automake
|
||||
BuildRequires: console-setup, xkeyboard-config
|
||||
Requires: %{name}-misc = %{version}-%{release}
|
||||
# Temporarily require -legacy
|
||||
@ -72,6 +76,9 @@ cp -fp %{SOURCE6} .
|
||||
%patch5 -p1 -b .loadkeys-search-path
|
||||
%patch6 -p1 -b .unicode-start-font
|
||||
%patch7 -p1 -b .covscan-fixes
|
||||
%patch8 -p1 -b .fix-flags
|
||||
%patch9 -p1 -b .format-security
|
||||
autoconf
|
||||
|
||||
# 7-bit maps are obsolete; so are non-euro maps
|
||||
pushd data/keymaps/i386
|
||||
@ -84,7 +91,6 @@ cp azerty/fr-latin9.map azerty/fr.map
|
||||
cp azerty/fr-latin9.map azerty/fr-latin0.map # legacy alias
|
||||
|
||||
# Rename conflicting keymaps
|
||||
mv dvorak/no.map dvorak/no-dvorak.map
|
||||
mv fgGIod/trf.map fgGIod/trf-fgGIod.map
|
||||
mv olpc/es.map olpc/es-olpc.map
|
||||
mv olpc/pt.map olpc/pt-olpc.map
|
||||
@ -102,7 +108,7 @@ mv "ChangeLog_" "ChangeLog"
|
||||
|
||||
%build
|
||||
%configure --prefix=%{_prefix} --datadir=/lib/kbd --mandir=%{_mandir} --localedir=%{_datadir}/locale --enable-nls
|
||||
make %{?_smp_mflags}
|
||||
make %{?_smp_mflags} V=1
|
||||
|
||||
%install
|
||||
make install DESTDIR=$RPM_BUILD_ROOT
|
||||
@ -189,6 +195,10 @@ gzip $RPM_BUILD_ROOT/lib/kbd/keymaps/xkb/cz.map
|
||||
/lib/kbd/keymaps/legacy
|
||||
|
||||
%changelog
|
||||
* Mon Feb 10 2020 Vitezslav Crhonek <vcrhonek@redhat.com> - 2.2.0-1
|
||||
- Update to kbd-2.2.0
|
||||
Resolves: #1742036
|
||||
|
||||
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.4-15
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||
|
||||
|
2
sources
2
sources
@ -1,4 +1,4 @@
|
||||
SHA512 (kbd-latsun-fonts.tar.bz2) = b98da5df85017ef1bd297eb2255046d54dd805c84356db7533f24e49fb78c8e3999901a45a49cdf6a74c0002bba2e0aa8327469d78dd38b6e747103972c30584
|
||||
SHA512 (kbd-latarcyrheb-32.tar.bz2) = 1870a708e16cf16f8343f02f7e97940e8404655078f92709a0b8a334be772faa99b4dbaca37e8d8c5b16d0d4d811fe6b102e4f76ae821148eb33075613dc95b8
|
||||
SHA512 (kbdinfo.1) = 8696d55f6c15f0ee2c2936eca6180b18100a87b11f0efe809a9531bb1228c67cd096cbc8fa25d9ee496daab28892ee5f320cc4bc9c9d816ff666bb4f80271c99
|
||||
SHA512 (kbd-2.0.4.tar.xz) = 5e264b3695b0af0bc85e0a4fa2c43e13648d8ea82102f3b051c28da2abfc52977577c470bce48f30cec9b0d215297e48c9b05e00561c990e3770fb68f6544e0f
|
||||
SHA512 (kbd-2.2.0.tar.xz) = 73885d98e81a630065e0b1b380af87f12fe983c8e148e97f0b884ec2ec724ed5295ad170e9734c03c37ca3ac80db6366c5ca73aadaa6ccdd2cb5bc80f394e909
|
||||
|
Loading…
Reference in New Issue
Block a user