Compare commits

..

10 Commits

Author SHA1 Message Date
LeRoyce Pearson d6a9539e0c add build.zig 2024-02-21 12:09:51 -07:00
Pierre Le Marre e325e65eb8 Add test_unit to all tests
Currently it only ensure we do not buffer `stdout`.
2024-02-21 06:26:36 +01:00
Peter Hutterer e7570bcb78 test: disable stdout output buffering for our tests
Hook this into test_create_context() so all the test immediately use it.
2024-02-20 11:27:13 +10:00
Peter Hutterer 5270a55324 test: print the keyboard state as part of test_key_seq_va
Makes it easier to debug modifier bugs.
2024-02-20 11:27:13 +10:00
Peter Hutterer be1c2f27ce test: improve debugging output for test_key_seq
Print the op too to make it easier to find which part in a long test_key_seq
triggered an assertion and add some whitespace for nicer debugging output.
2024-02-20 11:27:13 +10:00
Peter Hutterer 883bac60d8 tools: constify the prefix in tools_print_keycode_state 2024-02-20 11:27:13 +10:00
Peter Hutterer 51e084728a Fix a typo 2024-02-20 11:27:13 +10:00
Mikhail Gusarov d21645be08 xkbcomp: Require newline after !include line in rules files
Rules file parser allows constructs like

!include "foo" !include "bar" !layout = symbols

This is most likely an oversight in original code.

Closes #452
2024-02-20 11:27:02 +10:00
Peter Hutterer 89ceb3515b tools: add --verbose to interactive-evdev 2024-02-15 10:44:09 +01:00
Pierre Le Marre ed2dc978b1 keysyms: Update using latest xorgproto
This fixes a typo and improves comments.

xorgproto commit: cd33097fc779f280925c6d6bbfbd5150f93ca5bc
Relevant MR: https://gitlab.freedesktop.org/xorg/proto/xorgproto/-/merge_requests/84
2024-02-08 14:24:28 +01:00
35 changed files with 4055 additions and 333 deletions

83
build.zig Normal file
View File

@ -0,0 +1,83 @@
const std = @import("std");
const VERSION = std.SemanticVersion{ .major = 1, .minor = 6, .patch = 0 };
pub fn build(b: *std.Build) void {
const target = b.standardTargetOptions(.{});
const optimize = b.standardOptimizeOption(.{});
// const enable_x11 = b.option(bool, "enable-x11", "Whether to enable x11 compatibility");
const xkb_config_root = b.option([]const u8, "xkb-config-root", "Root directory for xkb config") orelse "/usr/share/X11/xkb";
const x_locale_root = b.option([]const u8, "x-locale-root", "x locale root") orelse "/usr/share/X11/locale";
const config_header = b.addConfigHeader(.{}, .{
.EXIT_INVALID_USAGE = @as(i64, 2),
.LIBXKBCOMMON_VERSION = b.fmt("\"{}\"", .{VERSION}),
.DFLT_XKB_CONFIG_ROOT = xkb_config_root,
.DFLT_XKB_CONFIG_EXTRA_PATH = b.fmt("\"{s}\"", .{"/usr/share/xkb"}),
.XLOCALEDIR = b.fmt("\"{s}\"", .{x_locale_root}),
.DEFAULT_XKB_RULES = "\"evdev\"",
.DEFAULT_XKB_MODEL = "\"pc105\"",
.DEFAULT_XKB_LAYOUT = "\"us\"",
.DEFAULT_XKB_VARIANT = "NULL",
.DEFAULT_XKB_OPTIONS = "NULL",
.HAVE_STRNDUP = @as(i64, 1),
.HAVE_MMAP = @as(i64, 1),
});
// _ = b.run(&.{ "bison", "--defines=src/xkbcomp/parser.h", "-o", "src/xkbcomp/parser.c", "-p", "_xkbcommon_", "src/xkbcomp/parser.y" });
const lib = b.addStaticLibrary(.{
.name = "xkbcommon",
.target = target,
.optimize = optimize,
});
lib.root_module.c_std = .C11;
lib.addConfigHeader(config_header);
lib.addCSourceFiles(.{
.files = &.{
"src/compose/parser.c",
"src/compose/paths.c",
"src/compose/state.c",
"src/compose/table.c",
"src/xkbcomp/action.c",
"src/xkbcomp/ast-build.c",
"src/xkbcomp/compat.c",
"src/xkbcomp/expr.c",
"src/xkbcomp/include.c",
"src/xkbcomp/keycodes.c",
"src/xkbcomp/keymap.c",
"src/xkbcomp/keymap-dump.c",
"src/xkbcomp/keywords.c",
"src/xkbcomp/parser.c",
"src/xkbcomp/rules.c",
"src/xkbcomp/scanner.c",
"src/xkbcomp/symbols.c",
"src/xkbcomp/types.c",
"src/xkbcomp/vmod.c",
"src/xkbcomp/xkbcomp.c",
"src/atom.c",
"src/context.c",
"src/context-priv.c",
"src/keysym.c",
"src/keysym-utf.c",
"src/keymap.c",
"src/keymap-priv.c",
"src/state.c",
"src/text.c",
"src/utf8.c",
"src/utils.c",
},
});
lib.installHeadersDirectoryOptions(.{
.source_dir = .{ .path = "include/xkbcommon" },
.install_dir = .header,
.install_subdir = "xkbcommon",
});
lib.addIncludePath(.{ .path = "src" });
lib.addIncludePath(.{ .path = "include/" });
lib.linkLibC();
b.installArtifact(lib);
}

60
build.zig.zon Normal file
View File

@ -0,0 +1,60 @@
.{
.name = "libxkbcommon",
.version = "1.6.0",
// This field is optional.
// This is currently advisory only; Zig does not yet do anything
// with this value.
//.minimum_zig_version = "0.11.0",
// This field is optional.
// Each dependency must either provide a `url` and `hash`, or a `path`.
// `zig build --fetch` can be used to fetch all dependencies of a package, recursively.
// Once all dependencies are fetched, `zig build` no longer requires
// internet connectivity.
.dependencies = .{
// See `zig fetch --save <url>` for a command-line interface for adding dependencies.
//.example = .{
// // When updating this field to a new URL, be sure to delete the corresponding
// // `hash`, otherwise you are communicating that you expect to find the old hash at
// // the new URL.
// .url = "https://example.com/foo.tar.gz",
//
// // This is computed from the file contents of the directory of files that is
// // obtained after fetching `url` and applying the inclusion rules given by
// // `paths`.
// //
// // This field is the source of truth; packages do not come from a `url`; they
// // come from a `hash`. `url` is just one of many possible mirrors for how to
// // obtain a package matching this `hash`.
// //
// // Uses the [multihash](https://multiformats.io/multihash/) format.
// .hash = "...",
//
// // When this is provided, the package is found in a directory relative to the
// // build root. In this case the package's hash is irrelevant and therefore not
// // computed. This field and `url` are mutually exclusive.
// .path = "foo",
//},
},
// Specifies the set of files and directories that are included in this package.
// Only files and directories listed here are included in the `hash` that
// is computed for this package.
// Paths are relative to the build root. Use the empty string (`""`) to refer to
// the build root itself.
// A directory listed here means that all files within, recursively, are included.
.paths = .{
// This makes *all* files, recursively, included in this package. It is generally
// better to explicitly list the files and directories instead, to insure that
// fetching from tarballs, file system paths, and version control all result
// in the same contents hash.
"",
// For example...
//"build.zig",
//"build.zig.zon",
//"src",
//"LICENSE",
//"README.md",
},
}

View File

@ -102,14 +102,52 @@ SOFTWARE.
* existing legacy keysym values in the range 0x0100 to 0x20ff. * existing legacy keysym values in the range 0x0100 to 0x20ff.
* *
* Where several mnemonic names are defined for the same keysym in this * Where several mnemonic names are defined for the same keysym in this
* file, all but the first one listed should be considered deprecated, * file, the first one listed is considered the "canonical" name. This
* unless the comment explicitly states the alias, e.g.: * is the name that should be used when retrieving a keysym name from
* its code. The next names are considered "aliases" to the canonical
* name.
*
* Aliases are made explicit by writing in their comment "alias for",
* followed by the corresponding canonical name. Example:
* *
* #define XKB_KEY_dead_tilde 0xfe53 * #define XKB_KEY_dead_tilde 0xfe53
* #define XKB_KEY_dead_perispomeni 0xfe53 // alias for dead_tilde * #define XKB_KEY_dead_perispomeni 0xfe53 // alias for dead_tilde
* *
* Additionally, a keysym can be explicitly deprecated by starting the * The rules to consider a keysym mnemonic name deprecated are:
* comment with "deprecated". *
* 1. A legacy keysym with its Unicode mapping in parentheses is
* deprecated (see above).
*
* 2. A keysym name is *explicitly* deprecated by starting its comment
* with "deprecated". Examples:
*
* #define XKB_KEY_L1 0xffc8 // deprecated alias for F11
* #define XKB_KEY_quoteleft 0x0060 // deprecated
*
* 3. A keysym name is *explicitly* *not* deprecated by starting its
* comment with "non-deprecated alias". Examples:
*
* #define XKB_KEY_dead_tilde 0xfe53
* #define XKB_KEY_dead_perispomeni 0xfe53 // non-deprecated alias for dead_tilde
*
* 4. If none of the previous rules apply, an alias is *implicitly*
* deprecated if there is at least one previous name for the
* corresponding keysym that is *not* explicitly deprecated.
*
* Examples:
*
* // SingleCandidate is the canonical name
* #define XKB_KEY_SingleCandidate 0xff3c
* // Hangul_SingleCandidate is deprecated because it is an alias
* // and it does not start with "non-deprecated alias"
* #define XKB_KEY_Hangul_SingleCandidate 0xff3c // Single candidate
*
* // guillemotleft is the canonical name, but it is deprecated
* #define XKB_KEY_guillemotleft 0x00ab // deprecated alias for guillemetleft (misspelling)
* // guillemetleft is not deprecated, because the keysym has no endorsed name before it.
* #define XKB_KEY_guillemetleft 0x00ab // U+00AB LEFT-POINTING DOUBLE ANGLE QUOTATION MARK
* // The following hypothetical name is deprecated because guillemetleft come before.
* #define XKB_KEY_guillemetleft2 0x00ab
* *
* Mnemonic names for keysyms are defined in this file with lines * Mnemonic names for keysyms are defined in this file with lines
* that match one of these Perl regular expressions: * that match one of these Perl regular expressions:
@ -156,7 +194,10 @@ SOFTWARE.
* e.g. keysyms removals. * e.g. keysyms removals.
* *
* Therefore, it is advised to proceed to no removal and to make a new * Therefore, it is advised to proceed to no removal and to make a new
* name canonical only 10 years after its introduction. * name canonical only 10 years after its introduction. This means that
* some keysyms may have their first listed name deprecated during the
* period of transition. Once this period is over, the deprecated name
* should be moved after the new canonical name.
*/ */
#define XKB_KEY_VoidSymbol 0xffffff /* Void symbol */ #define XKB_KEY_VoidSymbol 0xffffff /* Void symbol */
@ -193,7 +234,7 @@ SOFTWARE.
#define XKB_KEY_Kanji 0xff21 /* Kanji, Kanji convert */ #define XKB_KEY_Kanji 0xff21 /* Kanji, Kanji convert */
#define XKB_KEY_Muhenkan 0xff22 /* Cancel Conversion */ #define XKB_KEY_Muhenkan 0xff22 /* Cancel Conversion */
#define XKB_KEY_Henkan_Mode 0xff23 /* Start/Stop Conversion */ #define XKB_KEY_Henkan_Mode 0xff23 /* Start/Stop Conversion */
#define XKB_KEY_Henkan 0xff23 /* Alias for Henkan_Mode */ #define XKB_KEY_Henkan 0xff23 /* non-deprecated alias for Henkan_Mode */
#define XKB_KEY_Romaji 0xff24 /* to Romaji */ #define XKB_KEY_Romaji 0xff24 /* to Romaji */
#define XKB_KEY_Hiragana 0xff25 /* to Hiragana */ #define XKB_KEY_Hiragana 0xff25 /* to Hiragana */
#define XKB_KEY_Katakana 0xff26 /* to Katakana */ #define XKB_KEY_Katakana 0xff26 /* to Katakana */
@ -242,7 +283,7 @@ SOFTWARE.
#define XKB_KEY_Help 0xff6a /* Help */ #define XKB_KEY_Help 0xff6a /* Help */
#define XKB_KEY_Break 0xff6b #define XKB_KEY_Break 0xff6b
#define XKB_KEY_Mode_switch 0xff7e /* Character set switch */ #define XKB_KEY_Mode_switch 0xff7e /* Character set switch */
#define XKB_KEY_script_switch 0xff7e /* Alias for Mode_switch */ #define XKB_KEY_script_switch 0xff7e /* non-deprecated alias for Mode_switch */
#define XKB_KEY_Num_Lock 0xff7f #define XKB_KEY_Num_Lock 0xff7f
/* Keypad functions, keypad numbers cleverly chosen to map to ASCII */ /* Keypad functions, keypad numbers cleverly chosen to map to ASCII */
@ -388,7 +429,7 @@ SOFTWARE.
#define XKB_KEY_ISO_Level5_Shift 0xfe11 #define XKB_KEY_ISO_Level5_Shift 0xfe11
#define XKB_KEY_ISO_Level5_Latch 0xfe12 #define XKB_KEY_ISO_Level5_Latch 0xfe12
#define XKB_KEY_ISO_Level5_Lock 0xfe13 #define XKB_KEY_ISO_Level5_Lock 0xfe13
#define XKB_KEY_ISO_Group_Shift 0xff7e /* Alias for Mode_switch */ #define XKB_KEY_ISO_Group_Shift 0xff7e /* non-deprecated alias for Mode_switch */
#define XKB_KEY_ISO_Group_Latch 0xfe06 #define XKB_KEY_ISO_Group_Latch 0xfe06
#define XKB_KEY_ISO_Group_Lock 0xfe07 #define XKB_KEY_ISO_Group_Lock 0xfe07
#define XKB_KEY_ISO_Next_Group 0xfe08 #define XKB_KEY_ISO_Next_Group 0xfe08
@ -426,7 +467,7 @@ SOFTWARE.
#define XKB_KEY_dead_acute 0xfe51 #define XKB_KEY_dead_acute 0xfe51
#define XKB_KEY_dead_circumflex 0xfe52 #define XKB_KEY_dead_circumflex 0xfe52
#define XKB_KEY_dead_tilde 0xfe53 #define XKB_KEY_dead_tilde 0xfe53
#define XKB_KEY_dead_perispomeni 0xfe53 /* alias for dead_tilde */ #define XKB_KEY_dead_perispomeni 0xfe53 /* non-deprecated alias for dead_tilde */
#define XKB_KEY_dead_macron 0xfe54 #define XKB_KEY_dead_macron 0xfe54
#define XKB_KEY_dead_breve 0xfe55 #define XKB_KEY_dead_breve 0xfe55
#define XKB_KEY_dead_abovedot 0xfe56 #define XKB_KEY_dead_abovedot 0xfe56
@ -444,9 +485,9 @@ SOFTWARE.
#define XKB_KEY_dead_horn 0xfe62 #define XKB_KEY_dead_horn 0xfe62
#define XKB_KEY_dead_stroke 0xfe63 #define XKB_KEY_dead_stroke 0xfe63
#define XKB_KEY_dead_abovecomma 0xfe64 #define XKB_KEY_dead_abovecomma 0xfe64
#define XKB_KEY_dead_psili 0xfe64 /* alias for dead_abovecomma */ #define XKB_KEY_dead_psili 0xfe64 /* non-deprecated alias for dead_abovecomma */
#define XKB_KEY_dead_abovereversedcomma 0xfe65 #define XKB_KEY_dead_abovereversedcomma 0xfe65
#define XKB_KEY_dead_dasia 0xfe65 /* alias for dead_abovereversedcomma */ #define XKB_KEY_dead_dasia 0xfe65 /* non-deprecated alias for dead_abovereversedcomma */
#define XKB_KEY_dead_doublegrave 0xfe66 #define XKB_KEY_dead_doublegrave 0xfe66
#define XKB_KEY_dead_belowring 0xfe67 #define XKB_KEY_dead_belowring 0xfe67
#define XKB_KEY_dead_belowmacron 0xfe68 #define XKB_KEY_dead_belowmacron 0xfe68
@ -475,9 +516,9 @@ SOFTWARE.
#define XKB_KEY_dead_O 0xfe87 #define XKB_KEY_dead_O 0xfe87
#define XKB_KEY_dead_u 0xfe88 #define XKB_KEY_dead_u 0xfe88
#define XKB_KEY_dead_U 0xfe89 #define XKB_KEY_dead_U 0xfe89
#define XKB_KEY_dead_small_schwa 0xfe8a /* deprecated, use dead_schwa instead */ #define XKB_KEY_dead_small_schwa 0xfe8a /* deprecated alias for dead_schwa */
#define XKB_KEY_dead_capital_schwa 0xfe8b /* deprecated, use dead_SCHWA instead */
#define XKB_KEY_dead_schwa 0xfe8a #define XKB_KEY_dead_schwa 0xfe8a
#define XKB_KEY_dead_capital_schwa 0xfe8b /* deprecated alias for dead_SCHWA */
#define XKB_KEY_dead_SCHWA 0xfe8b #define XKB_KEY_dead_SCHWA 0xfe8b
#define XKB_KEY_dead_greek 0xfe8c #define XKB_KEY_dead_greek 0xfe8c
@ -693,7 +734,7 @@ SOFTWARE.
#define XKB_KEY_diaeresis 0x00a8 /* U+00A8 DIAERESIS */ #define XKB_KEY_diaeresis 0x00a8 /* U+00A8 DIAERESIS */
#define XKB_KEY_copyright 0x00a9 /* U+00A9 COPYRIGHT SIGN */ #define XKB_KEY_copyright 0x00a9 /* U+00A9 COPYRIGHT SIGN */
#define XKB_KEY_ordfeminine 0x00aa /* U+00AA FEMININE ORDINAL INDICATOR */ #define XKB_KEY_ordfeminine 0x00aa /* U+00AA FEMININE ORDINAL INDICATOR */
#define XKB_KEY_guillemotleft 0x00ab /* deprecated misspelling. Use guillemetleft instead. */ #define XKB_KEY_guillemotleft 0x00ab /* deprecated alias for guillemetleft (misspelling) */
#define XKB_KEY_guillemetleft 0x00ab /* U+00AB LEFT-POINTING DOUBLE ANGLE QUOTATION MARK */ #define XKB_KEY_guillemetleft 0x00ab /* U+00AB LEFT-POINTING DOUBLE ANGLE QUOTATION MARK */
#define XKB_KEY_notsign 0x00ac /* U+00AC NOT SIGN */ #define XKB_KEY_notsign 0x00ac /* U+00AC NOT SIGN */
#define XKB_KEY_hyphen 0x00ad /* U+00AD SOFT HYPHEN */ #define XKB_KEY_hyphen 0x00ad /* U+00AD SOFT HYPHEN */
@ -709,9 +750,9 @@ SOFTWARE.
#define XKB_KEY_periodcentered 0x00b7 /* U+00B7 MIDDLE DOT */ #define XKB_KEY_periodcentered 0x00b7 /* U+00B7 MIDDLE DOT */
#define XKB_KEY_cedilla 0x00b8 /* U+00B8 CEDILLA */ #define XKB_KEY_cedilla 0x00b8 /* U+00B8 CEDILLA */
#define XKB_KEY_onesuperior 0x00b9 /* U+00B9 SUPERSCRIPT ONE */ #define XKB_KEY_onesuperior 0x00b9 /* U+00B9 SUPERSCRIPT ONE */
#define XKB_KEY_masculine 0x00ba /* deprecated inconsistent name (see ordfeminine), use ordmasculine instead */ #define XKB_KEY_masculine 0x00ba /* deprecated alias for ordmasculine (inconsistent name) */
#define XKB_KEY_ordmasculine 0x00ba /* U+00BA MASCULINE ORDINAL INDICATOR */ #define XKB_KEY_ordmasculine 0x00ba /* U+00BA MASCULINE ORDINAL INDICATOR */
#define XKB_KEY_guillemotright 0x00bb /* deprecated misspelling. Use guillemotright instead. */ #define XKB_KEY_guillemotright 0x00bb /* deprecated alias for guillemetright (misspelling) */
#define XKB_KEY_guillemetright 0x00bb /* U+00BB RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK */ #define XKB_KEY_guillemetright 0x00bb /* U+00BB RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK */
#define XKB_KEY_onequarter 0x00bc /* U+00BC VULGAR FRACTION ONE QUARTER */ #define XKB_KEY_onequarter 0x00bc /* U+00BC VULGAR FRACTION ONE QUARTER */
#define XKB_KEY_onehalf 0x00bd /* U+00BD VULGAR FRACTION ONE HALF */ #define XKB_KEY_onehalf 0x00bd /* U+00BD VULGAR FRACTION ONE HALF */
@ -1033,7 +1074,7 @@ SOFTWARE.
#define XKB_KEY_kana_N 0x04dd /* U+30F3 KATAKANA LETTER N */ #define XKB_KEY_kana_N 0x04dd /* U+30F3 KATAKANA LETTER N */
#define XKB_KEY_voicedsound 0x04de /* U+309B KATAKANA-HIRAGANA VOICED SOUND MARK */ #define XKB_KEY_voicedsound 0x04de /* U+309B KATAKANA-HIRAGANA VOICED SOUND MARK */
#define XKB_KEY_semivoicedsound 0x04df /* U+309C KATAKANA-HIRAGANA SEMI-VOICED SOUND MARK */ #define XKB_KEY_semivoicedsound 0x04df /* U+309C KATAKANA-HIRAGANA SEMI-VOICED SOUND MARK */
#define XKB_KEY_kana_switch 0xff7e /* Alias for Mode_switch */ #define XKB_KEY_kana_switch 0xff7e /* non-deprecated alias for Mode_switch */
/* /*
* Arabic * Arabic
@ -1130,7 +1171,7 @@ SOFTWARE.
#define XKB_KEY_Arabic_farsi_yeh 0x10006cc /* deprecated alias for Farsi_yeh */ #define XKB_KEY_Arabic_farsi_yeh 0x10006cc /* deprecated alias for Farsi_yeh */
#define XKB_KEY_Arabic_yeh_baree 0x10006d2 /* U+06D2 ARABIC LETTER YEH BARREE */ #define XKB_KEY_Arabic_yeh_baree 0x10006d2 /* U+06D2 ARABIC LETTER YEH BARREE */
#define XKB_KEY_Arabic_heh_goal 0x10006c1 /* U+06C1 ARABIC LETTER HEH GOAL */ #define XKB_KEY_Arabic_heh_goal 0x10006c1 /* U+06C1 ARABIC LETTER HEH GOAL */
#define XKB_KEY_Arabic_switch 0xff7e /* Alias for Mode_switch */ #define XKB_KEY_Arabic_switch 0xff7e /* non-deprecated alias for Mode_switch */
/* /*
* Cyrillic * Cyrillic
@ -1318,7 +1359,7 @@ SOFTWARE.
#define XKB_KEY_Greek_IOTA 0x07c9 /* U+0399 GREEK CAPITAL LETTER IOTA */ #define XKB_KEY_Greek_IOTA 0x07c9 /* U+0399 GREEK CAPITAL LETTER IOTA */
#define XKB_KEY_Greek_KAPPA 0x07ca /* U+039A GREEK CAPITAL LETTER KAPPA */ #define XKB_KEY_Greek_KAPPA 0x07ca /* U+039A GREEK CAPITAL LETTER KAPPA */
#define XKB_KEY_Greek_LAMDA 0x07cb /* U+039B GREEK CAPITAL LETTER LAMDA */ #define XKB_KEY_Greek_LAMDA 0x07cb /* U+039B GREEK CAPITAL LETTER LAMDA */
#define XKB_KEY_Greek_LAMBDA 0x07cb /* alias for Greek_LAMDA */ #define XKB_KEY_Greek_LAMBDA 0x07cb /* non-deprecated alias for Greek_LAMDA */
#define XKB_KEY_Greek_MU 0x07cc /* U+039C GREEK CAPITAL LETTER MU */ #define XKB_KEY_Greek_MU 0x07cc /* U+039C GREEK CAPITAL LETTER MU */
#define XKB_KEY_Greek_NU 0x07cd /* U+039D GREEK CAPITAL LETTER NU */ #define XKB_KEY_Greek_NU 0x07cd /* U+039D GREEK CAPITAL LETTER NU */
#define XKB_KEY_Greek_XI 0x07ce /* U+039E GREEK CAPITAL LETTER XI */ #define XKB_KEY_Greek_XI 0x07ce /* U+039E GREEK CAPITAL LETTER XI */
@ -1343,7 +1384,7 @@ SOFTWARE.
#define XKB_KEY_Greek_iota 0x07e9 /* U+03B9 GREEK SMALL LETTER IOTA */ #define XKB_KEY_Greek_iota 0x07e9 /* U+03B9 GREEK SMALL LETTER IOTA */
#define XKB_KEY_Greek_kappa 0x07ea /* U+03BA GREEK SMALL LETTER KAPPA */ #define XKB_KEY_Greek_kappa 0x07ea /* U+03BA GREEK SMALL LETTER KAPPA */
#define XKB_KEY_Greek_lamda 0x07eb /* U+03BB GREEK SMALL LETTER LAMDA */ #define XKB_KEY_Greek_lamda 0x07eb /* U+03BB GREEK SMALL LETTER LAMDA */
#define XKB_KEY_Greek_lambda 0x07eb /* alias for Greek_lamda */ #define XKB_KEY_Greek_lambda 0x07eb /* non-deprecated alias for Greek_lamda */
#define XKB_KEY_Greek_mu 0x07ec /* U+03BC GREEK SMALL LETTER MU */ #define XKB_KEY_Greek_mu 0x07ec /* U+03BC GREEK SMALL LETTER MU */
#define XKB_KEY_Greek_nu 0x07ed /* U+03BD GREEK SMALL LETTER NU */ #define XKB_KEY_Greek_nu 0x07ed /* U+03BD GREEK SMALL LETTER NU */
#define XKB_KEY_Greek_xi 0x07ee /* U+03BE GREEK SMALL LETTER XI */ #define XKB_KEY_Greek_xi 0x07ee /* U+03BE GREEK SMALL LETTER XI */
@ -1358,7 +1399,7 @@ SOFTWARE.
#define XKB_KEY_Greek_chi 0x07f7 /* U+03C7 GREEK SMALL LETTER CHI */ #define XKB_KEY_Greek_chi 0x07f7 /* U+03C7 GREEK SMALL LETTER CHI */
#define XKB_KEY_Greek_psi 0x07f8 /* U+03C8 GREEK SMALL LETTER PSI */ #define XKB_KEY_Greek_psi 0x07f8 /* U+03C8 GREEK SMALL LETTER PSI */
#define XKB_KEY_Greek_omega 0x07f9 /* U+03C9 GREEK SMALL LETTER OMEGA */ #define XKB_KEY_Greek_omega 0x07f9 /* U+03C9 GREEK SMALL LETTER OMEGA */
#define XKB_KEY_Greek_switch 0xff7e /* Alias for Mode_switch */ #define XKB_KEY_Greek_switch 0xff7e /* non-deprecated alias for Mode_switch */
/* /*
* Technical * Technical
@ -1608,7 +1649,7 @@ SOFTWARE.
#define XKB_KEY_hebrew_shin 0x0cf9 /* U+05E9 HEBREW LETTER SHIN */ #define XKB_KEY_hebrew_shin 0x0cf9 /* U+05E9 HEBREW LETTER SHIN */
#define XKB_KEY_hebrew_taw 0x0cfa /* U+05EA HEBREW LETTER TAV */ #define XKB_KEY_hebrew_taw 0x0cfa /* U+05EA HEBREW LETTER TAV */
#define XKB_KEY_hebrew_taf 0x0cfa /* deprecated */ #define XKB_KEY_hebrew_taf 0x0cfa /* deprecated */
#define XKB_KEY_Hebrew_switch 0xff7e /* Alias for Mode_switch */ #define XKB_KEY_Hebrew_switch 0xff7e /* non-deprecated alias for Mode_switch */
/* /*
* Thai * Thai
@ -1721,7 +1762,7 @@ SOFTWARE.
#define XKB_KEY_Hangul_MultipleCandidate 0xff3d /* Multiple candidate */ #define XKB_KEY_Hangul_MultipleCandidate 0xff3d /* Multiple candidate */
#define XKB_KEY_Hangul_PreviousCandidate 0xff3e /* Previous candidate */ #define XKB_KEY_Hangul_PreviousCandidate 0xff3e /* Previous candidate */
#define XKB_KEY_Hangul_Special 0xff3f /* Special symbols */ #define XKB_KEY_Hangul_Special 0xff3f /* Special symbols */
#define XKB_KEY_Hangul_switch 0xff7e /* Alias for Mode_switch */ #define XKB_KEY_Hangul_switch 0xff7e /* non-deprecated alias for Mode_switch */
/* Hangul Consonant Characters */ /* Hangul Consonant Characters */
#define XKB_KEY_Hangul_Kiyeog 0x0ea1 /* U+3131 HANGUL LETTER KIYEOK */ #define XKB_KEY_Hangul_Kiyeog 0x0ea1 /* U+3131 HANGUL LETTER KIYEOK */

View File

@ -434,6 +434,7 @@ if build_tools
link_with: libxkbcommon_tools_internal, link_with: libxkbcommon_tools_internal,
dependencies: dep_libxkbcommon, dependencies: dep_libxkbcommon,
) )
configh_data.set10('HAVE_TOOLS', true)
# Tool: xkbcli # Tool: xkbcli
executable('xkbcli', 'tools/xkbcli.c', executable('xkbcli', 'tools/xkbcli.c',
@ -586,6 +587,8 @@ You can disable the Wayland xkbcli programs with -Denable-wayland=false.''')
dependencies: [tools_dep], dependencies: [tools_dep],
include_directories: [include_directories('src', 'include', 'tools')], include_directories: [include_directories('src', 'include', 'tools')],
install: false) install: false)
else
tools_dep = declare_dependency()
endif endif
@ -628,6 +631,7 @@ libxkbcommon_test_internal = static_library(
test_dep = declare_dependency( test_dep = declare_dependency(
include_directories: include_directories('src', 'include'), include_directories: include_directories('src', 'include'),
link_with: libxkbcommon_test_internal, link_with: libxkbcommon_test_internal,
dependencies: [tools_dep],
) )
if get_option('enable-x11') if get_option('enable-x11')
libxkbcommon_x11_test_internal = static_library( libxkbcommon_x11_test_internal = static_library(

View File

@ -2592,303 +2592,295 @@ static const char *keysym_names =
#endif #endif
static const uint16_t keysym_name_G[] = { static const uint16_t keysym_name_G[] = {
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 868, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1675, 0, 2816, 0,
0, 0, 0, 0, 0, 0, 0, 0, 1086, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1042, 0, 490, 0, 2754, 0, 0, 0, 0, 91, 0, 0, 0, 2536, 0, 0, 0, 226, 0,
4049, 1115, 0, 0, 0, 917, 0, 0, 1753, 0, 3420, 1735, 1457, 0, 0, 2914, 0, 1419, 0, 0, 0, 0, 0, 650, 1573, 0, 0, 0, 0, 0, 0, 0, 0, 0, 554,
0, 2762, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 563, 0, 0, 2123, 1353, 0, 3981, 0, 0, 0, 3013, 0, 0, 3374, 0, 0, 0, 0, 0, 0, 2399, 3823, 2705, 0,
0, 0, 0, 3316, 0, 0, 734, 0, 0, 0, 2403, 0, 0, 0, 0, 0, 0, 2668, 0, 154, 0, 0, 1234, 0, 2378, 3563, 0, 373, 0, 0, 0, 316, 1528, 0, 2949, 0,
4061, 0, 0, 0, 0, 0, 0, 0, 0, 4175, 0, 2599, 0, 0, 0, 0, 4350, 0, 1610, 1003, 0, 1390, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4341, 0, 0, 0, 0, 0, 0,
407, 0, 2488, 0, 0, 0, 2530, 0, 0, 0, 0, 3229, 0, 4237, 3889, 0, 0, 22, 0, 3953, 0, 0, 1760, 4147, 0, 0, 966, 0, 0, 2684, 0, 0, 0, 0, 784, 0,
0, 0, 0, 0, 2873, 0, 3501, 3373, 0, 638, 0, 0, 0, 0, 0, 0, 0, 0, 3322, 2851, 655, 0, 0, 0, 0, 4316, 0, 3996, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3837,
0, 0, 0, 0, 0, 0, 3068, 0, 0, 831, 0, 3287, 2687, 0, 0, 0, 0, 2958, 0, 0, 1350, 1469, 2150, 0, 0, 0, 0, 3125, 0, 0, 0, 0, 2453, 1892, 0, 484,
0, 0, 0, 0, 0, 0, 0, 0, 0, 695, 780, 0, 0, 0, 0, 0, 0, 136, 2149, 1446, 0, 0, 0, 0, 0, 0, 0, 0, 0, 462, 2363, 0, 0, 0, 3486, 2373, 0, 1560,
0, 4092, 0, 2547, 1473, 4566, 2147, 0, 656, 3737, 0, 0, 0, 0, 0, 0, 863, 3024, 2755, 0, 0, 248, 0, 3229, 0, 681, 0, 0, 3048, 4176, 0, 0,
1569, 1334, 200, 0, 0, 0, 0, 1947, 0, 0, 0, 0, 0, 0, 4460, 0, 4024, 0, 3451, 2837, 2929, 0, 0, 3725, 0, 0, 2628, 3124, 789, 2858, 0, 0, 0, 0,
0, 69, 0, 0, 0, 0, 4387, 0, 0, 0, 0, 0, 1780, 0, 1443, 0, 0, 0, 4152, 3686, 0, 0, 748, 0, 0, 3977, 3988, 0, 1610, 0, 443, 0, 0, 0, 0, 0,
1580, 0, 284, 0, 3505, 0, 3872, 0, 0, 0, 0, 2795, 4462, 0, 0, 0, 0, 0, 2724, 0, 791, 2168, 0, 0, 726, 0, 0, 0, 1496, 0, 100, 0, 0, 0, 0, 302,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1292, 0, 0, 4362, 0, 2454, 0, 0, 3059, 0, 4388, 0, 1916, 0, 0, 0, 0, 1863, 0, 3863, 0, 2321, 3300, 1445,
1868, 0, 0, 0, 0, 2160, 0, 0, 0, 32, 727, 0, 0, 2818, 0, 1071, 0, 2922, 2365, 0, 0, 0, 0, 3555, 3282, 1679, 0, 1743, 1935, 0, 0, 0, 1995, 0,
0, 0, 0, 0, 1367, 0, 0, 0, 0, 1483, 0, 0, 2308, 0, 0, 0, 0, 1421, 0, 0, 2491, 0, 0, 3503, 2364, 1771, 0, 0, 0, 4092, 447, 463, 0, 0, 4168, 0,
2253, 0, 0, 0, 0, 0, 0, 0, 0, 4373, 0, 0, 0, 4330, 4323, 0, 0, 0, 0, 0, 3865, 0, 1244, 0, 1509, 4164, 3233, 248, 1777, 0, 0, 1655, 0, 3718, 0,
0, 0, 0, 0, 0, 561, 0, 0, 0, 1678, 0, 0, 1324, 0, 0, 0, 1690, 2186, 0, 138, 0, 0, 0, 0, 1776, 30, 0, 0, 0, 2396, 0, 0, 3541, 0, 484, 1383,
4186, 0, 0, 0, 4171, 0, 1954, 0, 781, 0, 0, 0, 0, 0, 291, 0, 3992, 0, 899, 0, 0, 848, 3119, 0, 1457, 0, 0, 1139, 0, 0, 0, 3910, 1027, 0, 708,
0, 0, 0, 0, 0, 0, 0, 0, 1702, 1523, 0, 2906, 1503, 1876, 0, 0, 0, 0, 0, 3584, 0, 2415, 0, 0, 0, 0, 764, 1645, 0, 0, 1784, 772, 4369, 0, 4253,
4173, 3993, 0, 0, 0, 0, 0, 0, 0, 353, 0, 0, 0, 3254, 0, 0, 0, 844, 0, 1854, 0, 0, 3735, 2048, 0, 1356, 0, 3612, 0, 0, 0, 0, 4237, 2260, 1160,
1181, 2781, 0, 0, 2291, 796, 4448, 1416, 0, 0, 0, 0, 0, 1670, 0, 0, 0, 205, 3082, 0, 1806, 98, 0, 0, 0, 0, 0, 1105, 3665, 87, 0, 2494, 0,
0, 0, 0, 0, 0, 0, 1957, 0, 0, 0, 2774, 0, 664, 0, 0, 2095, 3593, 4621, 2462, 0, 896, 1820, 0, 419, 3994, 2127, 0, 38, 0, 2441, 0, 3266, 1844,
0, 2629, 0, 0, 2619, 177, 4201, 0, 1878, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1785, 4391, 2745, 0, 0, 3195, 0, 0, 3848, 0, 0, 1567, 2881, 0, 2368, 0,
0, 889, 773, 0, 0, 0, 261, 1096, 0, 2802, 0, 0, 0, 0, 0, 0, 0, 1117, 644, 3143, 2442, 2132, 0, 2781, 0, 0, 3932, 0, 0, 0, 0, 0, 773, 0,
1434, 0, 0, 1891, 0, 0, 2671, 0, 2398, 0, 0, 0, 0, 0, 2894, 0, 0, 1605, 1991, 0, 3910, 4059, 0, 2309, 0, 0, 849, 555, 823, 0, 533, 0, 0, 0,
0, 0, 0, 0, 0, 1553, 0, 0, 0, 441, 0, 0, 3314, 3499, 1764, 4475, 3264, 2410, 0, 3420, 79, 1786, 0, 1050, 0, 0, 3631, 0, 0, 0, 0, 0, 472, 0,
0, 230, 2907, 3545, 1881, 0, 2007, 0, 0, 0, 276, 0, 0, 1970, 0, 0, 0, 1381, 0, 0, 1991, 4390, 0, 2881, 2689, 1389, 1739, 0, 3384, 0, 2558,
2243, 2300, 3639, 50, 0, 0, 662, 2071, 2431, 794, 0, 0, 76, 4334, 0, 0, 3451, 867, 0, 0, 0, 750, 0, 0, 0, 0, 3175, 1114, 0, 0, 3710, 0, 0, 0,
0, 0, 4523, 0, 524, 2519, 2765, 45, 31, 0, 4144, 3415, 0, 0, 0, 0, 0, 1088, 78, 0, 3195, 0, 0, 460, 1787, 0, 1023, 17, 1863, 0, 1004, 0, 0,
0, 0, 1339, 0, 0, 0, 2348, 0, 0, 0, 0, 0, 0, 1354, 2271, 3167, 0, 2659, 0, 787, 2741, 0, 2092, 0, 1532, 0, 0, 0, 3276, 0, 0, 583, 0, 2967,
0, 110, 0, 1626, 4201, 1468, 0, 2168, 0, 3251, 0, 1279, 0, 1414, 192, 2292, 0, 0, 3308, 1941, 3372, 4322, 0, 0, 1698, 2896, 0, 0, 929, 3573,
0, 2303, 917, 0, 2249, 0, 0, 0, 0, 204, 0, 2280, 3765, 0, 3456, 0, 0, 3193, 0, 0, 2181, 2117, 0, 288, 0, 0, 0, 685, 0, 90, 3771, 2039, 1046,
0, 0, 383, 0, 0, 0, 0, 4374, 0, 338, 2996, 2546, 0, 1232, 3643, 0, 0, 0, 2216, 0, 2655, 0, 0, 26, 0, 1016, 2084, 0, 591, 0, 1942, 0, 1158,
1303, 0, 0, 3545, 2166, 826, 0, 0, 0, 0, 0, 0, 0, 0, 0, 960, 0, 0, 0, 0, 4213, 1853, 0, 4121, 2735, 0, 0, 1711, 1434, 0, 0, 0, 1247, 3608,
4398, 1692, 1861, 4364, 0, 1152, 0, 0, 1081, 0, 3493, 1715, 2219, 3771, 943, 0, 0, 3957, 0, 0, 2564, 482, 0, 0, 2238, 0, 0, 0, 3456, 1659,
1970, 4012, 2439, 2562, 0, 0, 0, 4332, 2287, 0, 4265, 216, 4257, 661, 3793, 3222, 2039, 0, 0, 0, 1321, 2398, 4383, 0, 0, 0, 167, 0, 492,
4004, 2422, 0, 3870, 0, 0, 0, 0, 0, 2564, 225, 1185, 1372, 3667, 2089, 3132, 2470, 0, 0, 0, 1239, 938, 0, 1738, 4394, 3035, 3266, 0, 0, 189,
1839, 0, 0, 0, 2319, 0, 0, 703, 0, 0, 0, 130, 1094, 0, 0, 0, 0, 0, 0, 2232, 3138, 0, 0, 3749, 1137, 2535, 2735, 0, 0, 2897, 2711, 15, 1027,
0, 4594, 4405, 2496, 1812, 0, 0, 2487, 0, 0, 1797, 1628, 0, 0, 4602, 0, 0, 306, 2229, 2016, 3174, 0, 0, 0, 0, 173, 1012, 2039, 1965, 1644,
0, 4368, 0, 0, 0, 1006, 335, 387, 0, 0, 0, 0, 0, 0, 0, 0, 4017, 2048, 3328, 1325, 0, 0, 87, 0, 0, 0, 118, 2968, 3659, 3285, 0, 519, 1660,
333, 0, 385, 0, 3563, 0, 3853, 0, 0, 0, 2050, 2629, 1442, 0, 0, 0, 382, 2099, 0, 0, 1659, 686, 0, 0, 0, 0, 47, 134, 1790, 0, 3904, 2750, 1045,
0, 2581, 2986, 839, 2913, 0, 0, 3467, 0, 4030, 2322, 0, 1288, 0, 0, 0, 0, 0, 3535, 0, 3449, 0, 2955, 1258, 0, 3072, 2173, 528, 1662, 0, 0,
0, 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, 2357, 0, 3542, 0, 0, 0, 616, 0, 4124, 0, 647, 3650, 410, 0, 0, 1838, 2677, 0, 485, 0, 0, 3078, 4399, 0,
4145, 0, 0, 0, 0, 1905, 0, 0, 2069, 0, 0, 0, 3431, 0, 848, 0, 0, 0, 0, 3700, 0, 0, 2252, 752, 0, 0, 0, 1132, 1597, 0, 0, 1573, 3215, 0, 0,
2440, 0, 0, 0, 64, 0, 3540, 0, 2001, 2881, 0, 1032, 676, 0, 2913, 2240, 2351, 310, 0, 0, 3778, 755, 1959, 4151, 816, 0, 1986, 0, 0, 0, 0, 2346,
1248, 0, 0, 0, 0, 1048, 0, 0, 3676, 1976, 0, 1207, 0, 1196, 0, 1139, 0, 3290, 1550, 0, 0, 0, 0, 0, 2069, 0, 0, 0, 2921, 241, 4339, 0, 2796,
3142, 0, 2805, 0, 0, 0, 0, 0, 582, 0, 0, 0, 0, 596, 1997, 0, 2350, 0, 0, 2315, 0, 4261, 2035, 1399, 1268, 3305, 0, 0, 3158, 0, 1448, 0, 678,
4534, 0, 782, 0, 1958, 0, 1406, 0, 0, 0, 3922, 0, 1382, 3788, 3584, 0, 0, 0, 840, 1236, 2448, 3140, 0, 0, 0, 0, 0, 4327, 0, 587, 0, 3776, 0,
0, 3440, 0, 0, 596, 0, 0, 0, 254, 0, 330, 0, 0, 0, 0, 0, 149, 975, 0, 3701, 0, 0, 0, 2655, 0, 0, 0, 1978, 0, 0, 0, 0, 0, 358, 1498, 3445,
0, 187, 0, 0, 0, 644, 0, 4437, 0, 483, 3373, 692, 0, 0, 0, 0, 543, 0, 886, 0, 0, 0, 0, 0, 3980, 2738, 0, 0, 835, 0, 2298, 0, 1370, 0, 0,
0, 0, 0, 2913, 236, 232, 0, 0, 1897, 3276, 1556, 0, 3760, 3365, 0, 0, 1756, 2312, 1848, 1648, 1723, 0, 0, 0, 1574, 0, 0, 0, 0, 1492, 743, 0,
0, 0, 0, 2009, 1325, 0, 707, 0, 2517, 3342, 0, 2753, 1940, 0, 410, 0, 0, 2416, 0, 0, 0, 0, 0, 2717, 0, 2373, 0, 0, 1914, 1000, 4102, 0,
4608, 0, 0, 1235, 3703, 2267, 0, 742, 1860, 0, 0, 0, 4032, 0, 1112, 1088, 0, 0, 2101, 521, 2163, 186, 979, 1511, 0, 0, 2220, 3396, 0, 2675,
3793, 0, 0, 1336, 1604, 1708, 0, 664, 0, 4046, 0, 0, 0, 176, 940, 0, 0, 0, 0, 1627, 521, 3053, 3385, 0, 2901, 0, 280, 0, 2779, 0, 4282, 0, 0,
1421, 0, 0, 844, 3043, 2047, 0, 0, 0, 542, 0, 0, 931, 1836, 1659, 1500, 0, 0, 260, 3536, 3705, 416, 2032, 0, 1075, 2368, 0, 3396, 0, 1605, 0,
0, 0, 2486, 0, 1335, 3432, 0, 1730, 1729, 0, 4483, 4316, 0, 0, 0, 2157, 0, 4384, 0, 4101, 1881, 0, 0, 1130, 0, 0, 0, 996, 315, 0, 0, 0, 2362,
654, 0, 1004, 0, 0, 0, 4381, 0, 0, 0, 0, 793, 1302, 855, 2245, 0, 0, 0, 148, 0, 4230, 0, 0, 944, 0, 1181, 1047, 778, 1788, 0, 1066, 0, 3247,
2603, 0, 0, 855, 0, 1485, 0, 0, 4492, 3042, 2389, 1003, 671, 1965, 0, 784, 0, 786, 0, 0, 0, 0, 1372, 0, 0, 1876, 0, 153, 438, 1676, 4157, 0,
4456, 0, 3016, 0, 4245, 0, 0, 829, 0, 2608, 0, 284, 1692, 0, 0, 0, 0, 0, 3419, 4140, 388, 0, 0, 0, 742, 1220, 0, 328, 0, 3753, 3079, 0, 4356,
0, 2471, 0, 0, 1152, 0, 3120, 0, 0, 1212, 0, 0, 0, 1579, 0, 3225, 3499, 3581, 1002, 0, 1706, 1227, 3629, 0, 3543, 0, 3340, 0, 1282, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1683, 3507, 0, 0, 911, 0, 0, 0, 0, 3428, 0, 0, 75, 1918, 911, 1209, 156, 1316, 0, 0, 1331, 3506, 0, 2254,
1653, 0, 1444, 1510, 731, 2001, 2671, 988, 0, 0, 0, 3331, 607, 0, 1033, 0, 4103, 754, 2059, 0, 2445, 2536, 0, 0, 0, 0, 1720, 1060, 2281, 3400,
58, 1723, 923, 0, 0, 0, 0, 239, 0, 2347, 0, 0, 745, 0, 0, 0, 0, 0, 0, 3095, 0, 0, 0, 2195, 1294, 0, 3097, 1352, 3303, 0, 1382, 1695, 1892, 0,
0, 1512, 0, 0, 0, 1272, 0, 0, 1055, 395, 0, 973, 0, 1409, 0, 2396, 0, 0, 1012, 0, 2774, 3024, 3998, 0, 0, 0, 0, 877, 1381, 1526, 0, 996,
0, 4011, 2341, 367, 0, 0, 0, 1871, 0, 3680, 0, 53, 0, 0, 0, 0, 0, 0, 0, 1978, 681, 4235, 0, 2551, 4269, 0, 838, 2181, 3767, 0, 0, 0, 4044, 0,
2655, 1884, 2532, 0, 0, 2168, 1645, 0, 2637, 1686, 0, 0, 733, 3786, 0, 160, 0, 0, 0, 0, 240, 0, 0, 3569, 311, 0, 2662, 2157, 0, 0, 282, 0,
1116, 4493, 1142, 0, 3437, 3420, 0, 0, 0, 1609, 1869, 0, 4478, 0, 0, 0, 0, 3966, 3004, 4362, 458, 2934, 0, 0, 0, 215, 3121, 0, 3340, 4107,
0, 2391, 912, 0, 4377, 0, 0, 3622, 3440, 0, 1400, 4276, 1153, 2275, 0, 2477, 0, 3874, 1786, 0, 1223, 1717, 0, 0, 0, 0, 0, 544, 0, 0, 3617, 0,
0, 4037, 1252, 0, 0, 3562, 1262, 527, 0, 0, 0, 3293, 505, 0, 1404, 0, 3198, 0, 0, 0, 0, 0, 0, 0, 0, 2772, 0, 3854, 376, 4203, 2224, 3734,
1355, 0, 1594, 0, 0, 1223, 0, 4526, 0, 0, 0, 1335, 0, 3394, 571, 0, 0, 0, 1793, 4160, 611, 0, 0, 2284, 1949, 0, 3861, 2017, 1683, 542, 544,
2775, 547, 0, 0, 3328, 1256, 0, 0, 2841, 1532, 0, 0, 0, 2232, 3731, 2, 605, 0, 0, 4037, 890, 0, 0, 3840, 2316, 0, 0, 1830, 0, 0, 1959, 2092,
0, 1733, 1306, 0, 0, 2519, 3304, 0, 0, 4158, 0, 0, 0, 4286, 4016, 2071, 0, 3987, 0, 0, 0, 2238, 248, 893, 1869, 0, 0, 1779, 0, 0, 3736, 330, 0,
0, 4023, 3512, 783, 4325, 3994, 0, 0, 4361, 0, 1964, 0, 0, 0, 85, 0, 0, 0, 3710, 0, 83, 0, 2128, 0, 1827, 0, 0, 0, 323, 0, 0, 0, 701, 708,
1325, 2001, 2306, 0, 0, 0, 0, 0, 0, 4040, 0, 835, 1337, 60, 0, 0, 1197, 863, 2613, 469, 0, 0, 626, 0, 0, 0, 0, 1410, 4066, 1027, 3660, 887,
2258, 4029, 0, 0, 1865, 0, 2290, 0, 0, 2926, 3237, 3018, 0, 0, 1436, 0, 847, 631, 0, 0, 0, 0, 0, 715, 2708, 761, 3030, 0, 0, 939, 2992, 0, 0,
0, 4527, 0, 1131, 0, 192, 580, 4314, 0, 1457, 679, 2538, 1248, 431, 3137, 0, 2858, 0, 2748, 184, 1400, 3862, 4129, 0, 0, 1906, 1263, 1257,
3921, 0, 0, 0, 0, 0, 429, 0, 735, 0, 1716, 0, 0, 0, 0, 378, 3984, 0, 3311, 3630, 0, 0, 0, 1980, 0, 2273, 577, 3748, 0, 0, 2035, 1194, 2869,
825, 0, 0, 0, 2233, 0, 1249, 1123, 3647, 0, 0, 491, 1440, 0, 709, 75, 858, 3791, 2693, 1954, 3623, 0, 1030, 0, 0, 0, 2479, 0, 0, 0, 1897,
2302, 0, 485, 0, 1569, 0, 0, 0, 610, 2498, 0, 0, 3297, 0, 2597, 1282, 331, 3528, 2478, 0, 1881, 0, 3921, 1390, 3894, 2423, 1642, 3661, 0, 0,
708, 0, 519, 195, 0, 0, 0, 2156, 424, 1717, 0, 0, 1774, 0, 0, 2976, 0, 4097, 0, 3678, 1028, 294, 993, 2040, 0, 0, 10, 2729, 0, 258, 188,
1148, 0, 0, 0, 1516, 4227, 1455, 1721, 2062, 0, 0, 0, 1693, 1867, 0, 318, 2892, 2411, 3278, 411, 0, 0, 0, 1258, 2477, 0, 1002, 1626, 0, 0,
73, 0, 0, 4425, 433, 0, 1867, 0, 0, 4437, 0, 0, 3027, 0, 0, 4579, 816, 1295, 0, 368, 0, 0, 0, 0, 0, 4216, 0, 1747, 0, 1625, 0, 1953, 3095,
2127, 0, 0, 4597, 0, 0, 3384, 2351, 3508, 0, 495, 656, 0, 0, 2956, 2640, 0, 1393, 415, 0, 0, 1854, 0, 2498, 1453, 1704, 0, 0, 1347, 0,
4402, 0, 493, 3129, 821, 260, 0, 2189, 4321, 0, 0, 0, 789, 1807, 0, 3892, 1006, 0, 1832, 0, 700, 3704, 1246, 0, 593, 654, 0, 0, 0, 0, 4013,
3014, 3928, 254, 0, 3410, 3129, 2376, 0, 0, 1903, 1823, 0, 827, 1584, 0, 1758, 0, 1425, 0, 2393, 455, 2965, 4184, 0, 0, 0, 0, 2186, 347,
4318, 0, 0, 517, 0, 0, 1483, 0, 4364, 0, 4602, 1955, 3915, 3132, 0, 0, 3477, 0, 0, 1881, 0, 0, 318, 4300, 666, 0, 0, 0, 2525, 0, 0, 0, 0, 0,
4389, 0, 0, 535, 1936, 2357, 3477, 4291, 0, 4207, 1240, 1476, 4597, 1319, 1191, 892, 0, 2041, 91, 662, 0, 0, 2121, 0, 854, 0, 904, 3064, 0,
132, 0, 0, 0, 0, 4533, 0, 3522, 0, 11, 3069, 4539, 1464, 2112, 721, 2934, 0, 647, 0, 4028, 3957, 0, 1447, 1434, 0, 0, 626, 0, 0, 2137,
3111, 305, 1270, 873, 2200, 0, 2893, 1150, 1614, 0, 0, 2014, 3754, 181, 3551, 0, 900, 3517, 0, 2186, 2176, 0, 5, 1729, 2574, 1299, 4005, 719,
4470, 1303, 3373, 4052, 0, 0, 0, 391, 2158, 4004, 0, 0, 0, 0, 2745, 0, 0, 832, 0, 0, 0, 0, 1870, 0, 379, 0, 0, 246, 61, 1066, 3914, 1499,
1054, 527, 1776, 715, 0, 4411, 0, 4118, 525, 1447, 2190, 0, 991, 4407, 1669, 971, 0, 0, 0, 2228, 0, 0, 941, 3621, 0, 0, 0, 0, 2332, 0, 0,
3614, 0, 950, 962, 3908, 603, 0, 2820, 4276, 0, 2519, 1426, 0, 4539, 2624, 0, 0, 1956, 1154, 0, 1072, 0, 0, 3239, 3053, 0, 915, 884, 3519,
3155, 989, 0, 2366, 2378, 3584, 2616, 0, 0, 429, 2509, 0, 0, 82, 3899, 2407, 3329, 3206, 603, 0, 0, 631, 4328, 767, 0, 1912, 833, 0, 3759,
2517, 2995, 227, 180, 27, 0, 0, 1742, 938, 0, 510, 1933, 1948, 3960, 2330, 1644, 182, 2661, 2231, 0, 673, 0, 0, 3909, 1861, 0, 691, 2450,
499, 1255, 0, 0, 1124, 0, 421, 969, 0, 4352, 0, 0, 3295, 0, 0, 2945, 1697, 781, 0, 3074, 0, 788, 0, 0, 0, 0, 77, 0, 0, 1574, 3096, 0, 0,
4480, 3368, 2958, 0, 1407, 0, 785, 0, 780, 1022, 0, 1804, 1799, 0, 4033, 0, 0, 3905, 1750, 3123, 1653, 1876, 0, 0, 1405, 47, 1935, 2794,
3827, 0, 0, 2100, 0, 0, 3404, 0, 0, 2076, 2346, 1478, 344, 3854, 3439, 0, 3609, 3588, 0, 797, 0, 1708, 3070, 2605, 0, 754, 293, 1847, 80, 0,
0, 3893, 4110, 705, 2845, 0, 0, 1448, 543, 2986, 2360, 0, 270, 3570, 0, 0, 611, 443, 0, 4137, 276, 1899, 0, 0, 0, 0, 2834, 0, 340, 3070, 1569,
3473, 4368, 0, 1995, 1011, 0, 4321, 0, 0, 0, 791, 3572, 0, 1000, 0, 0, 3466, 2160, 0, 688, 0, 1260, 2923, 0, 355, 0, 291, 0, 0, 373, 0, 0,
396, 3217, 0, 0, 0, 2191, 0, 1125, 3519, 0, 1900, 214, 0, 0, 0, 0, 0, 1954, 2150, 3259, 2097, 2653, 1624, 0, 3779, 0, 0, 1063, 382, 0, 2241,
82, 948, 2347, 0, 0, 0, 0, 0, 0, 2439, 1973, 786, 3512, 0, 66, 0, 531, 3943, 1998, 0, 0, 587, 0, 1347, 0, 924, 0, 0, 0, 2670, 1902, 2769, 0,
2308, 960, 0, 0, 0, 0, 0, 0, 3424, 849, 1444, 376, 2338, 1231, 1849, 0, 1242, 0, 0, 0, 3048, 1310, 0, 3543, 0, 0, 2355, 0, 0, 1603, 4317,
4356, 4354, 318, 1377, 0, 1805, 0, 1622, 4335, 799, 0, 4441, 0, 0, 966, 1965, 0, 0, 2511, 918, 0, 3150, 0, 3781, 2227, 1481, 0, 1069, 0, 1878,
2015, 236, 4607, 4326, 0, 3190, 352, 2588, 2467, 1730, 396, 0, 0, 0, 0, 482, 1653, 4038, 0, 153, 0, 1273, 3671, 2825, 4115, 0, 229, 0, 0, 0, 0,
3974, 0, 4313, 0, 0, 0, 1306, 551, 3465, 340, 629, 345, 638, 4471, 654, 426, 663, 1153, 2344, 0, 0, 0, 0, 3881, 2320, 0, 3919, 1095, 0,
1952, 4002, 0, 0, 0, 0, 3950, 0, 1922, 2926, 0, 2971, 4092, 0, 985, 0, 2033, 0, 0, 3681, 2413, 0, 767, 697, 1867, 321, 0, 601, 1852, 1013,
0, 2236, 1614, 1612, 851, 3388, 0, 3039, 3211, 0, 0, 4214, 3317, 0, 0, 2427, 0, 985, 2484, 0, 3245, 0, 728, 1299, 0, 0, 0, 2721, 0, 0, 0,
1943, 796, 2341, 2602, 0, 0, 3007, 3020, 2175, 1418, 1599, 0, 4445, 2192, 309, 0, 0, 2062, 0, 0, 2631, 2363, 874, 910, 1910, 0, 0, 2481,
1539, 1600, 2348, 3508, 1366, 547, 2777, 1114, 1986, 0, 4038, 2046, 3685, 4188, 1185, 1731, 3307, 0, 2485, 1089, 1580, 0, 0, 2716, 0, 0, 0,
480, 0, 0, 383, 0, 4535, 0, 360, 0, 0, 2373, 0, 2242, 0, 0, 0, 0, 1581, 2348, 2168, 0, 0, 1151, 0, 0, 242, 0, 162, 564, 0, 0, 739, 0, 0, 0, 0,
0, 517, 1983, 4334, 1117, 2656, 2531, 3446, 2758, 0, 1674, 69, 0, 2909, 1758, 1620, 0, 1252, 1881, 3114, 0, 0, 1924, 3206, 0, 903, 859, 1850,
741, 0, 447, 0, 0, 2594, 3921, 0, 0, 3942, 1506, 342, 3200, 458, 0, 0, 911, 0, 278, 0, 0, 0, 0, 1262, 0, 1568, 1628, 0, 2607, 0, 0, 1969,
1122, 0, 0, 557, 95, 3652, 2902, 79, 1319, 0, 4599, 628, 1566, 0, 0, 0, 710, 2199, 2488, 1577, 0, 3738, 0, 0, 2335, 0, 2428, 1591, 3357, 768,
4561, 2021, 2678, 4081, 1783, 1749, 1194, 0, 419, 981, 0, 2282, 44, 264, 0, 0, 2153, 0, 4172, 1571, 0, 0, 4274, 0, 1374, 757, 1560, 0,
467, 4318, 0, 0, 652, 1026, 4610, 3874, 1881, 0, 4335, 0, 0, 0, 308, 3770, 0, 0, 0, 2721, 131, 0, 0, 912, 4168, 0, 1348, 2513, 574, 2967, 0,
1663, 2119, 965, 0, 4216, 1737, 464, 0, 0, 4429, 1471, 813, 0, 388, 0, 3301, 3096, 1677, 2232, 0, 1727, 0, 0, 164, 1636, 0, 0, 3125, 0,
1374, 0, 0, 0, 17, 0, 4608, 0, 0, 2213, 0, 717, 0, 0, 0, 3842, 0, 2577, 1719, 592, 0, 0, 1945, 2961, 0, 0, 0, 3669, 0, 316, 3002, 2285, 302,
0, 0, 1737, 0, 0, 0, 283, 0, 0, 0, 2011, 0, 0, 0, 743, 834, 3155, 0, 0, 1108, 3652, 0, 4252, 1308, 0, 33, 994, 0, 2300, 0, 4396, 345, 0, 0, 0,
0, 499, 0, 2591, 1336, 2035, 3365, 0, 1189, 3837, 4549, 649, 0, 2420, 0, 2146, 0, 0, 3022, 254, 0, 2900, 0, 1599, 3203, 2013, 0, 0, 0, 3116,
523, 0, 3055, 0, 2450, 0, 1452, 0, 2596, 451, 4386, 2232, 0, 1215, 0, 3124, 675, 0, 3752, 2157, 148, 2489, 669, 0, 921, 2506, 3165, 749,
3509, 608, 0, 923, 0, 1376, 4256, 4600, 2094, 0, 0, 0, 0, 47, 1088, 0, 2591, 2763, 0, 1521, 0, 2308, 2086, 3618, 4178, 0, 0, 0, 2473, 3796,
2403, 1083, 0, 0, 4217, 4525, 370, 1257, 294, 3192, 456, 761, 1861, 0, 969, 1554, 1707, 0, 0, 0, 0, 1925, 3081, 763, 0, 0, 1931, 0, 1355,
723, 0, 0, 4257, 0, 0, 0, 2483, 4151, 0, 1883, 0, 0, 2552, 0, 192, 0, 0, 2314, 2089, 4214, 0, 1682, 0, 71, 976, 0, 2982, 3904, 4068, 591,
2612, 0, 0, 530, 0, 2039, 0, 0, 4000, 1744, 0, 0, 0, 0, 0, 0, 0, 0, 83, 1209, 0, 0, 0, 1641, 0, 965, 947, 2471, 1932, 0, 0, 1714, 0, 3995, 0,
0, 141, 2521, 0, 2114, 528, 868, 0, 0, 91, 4059, 0, 1046, 0, 0, 1384, 0, 337, 0, 3798, 1966, 2456, 0, 1278, 1938, 0, 0, 173, 0, 0, 0, 496,
3301, 4619, 194, 527, 2222, 78, 1388, 4482, 0, 2437, 0, 1739, 3875, 266, 0, 0, 0, 1553, 3815, 877, 0, 349, 0, 1313, 2103, 0, 4203, 0, 0, 0,
211, 4592, 688, 2178, 2450, 0, 412, 0, 0, 0, 2979, 624, 0, 3968, 4334, 1771, 2377, 1203, 397, 0, 309, 0, 2770, 1403, 0, 0, 0, 0, 0, 3609,
0, 3487, 2267, 4607, 0, 3256, 0, 4009, 591, 0, 986, 3408, 3823, 0, 0, 3517, 0, 0, 844, 0, 0, 0, 0, 907, 1176, 558, 1815, 0, 66, 555, 0, 1214,
0, 1112, 0, 0, 2114, 2482, 4367, 0, 4389, 0, 0, 3062, 2740, 1183, 0, 0, 1261, 0, 0, 0, 0, 3631, 0, 0, 2388, 0, 0, 2216, 123, 0, 0, 521, 116,
2064, 0, 0, 1842, 1484, 1637, 0, 0, 119, 2256, 0, 1297, 0, 2983, 41, 0, 0, 0, 0, 851, 0, 3759, 0, 1554, 0, 0, 2670, 2647, 0, 1334, 916, 0, 0,
0, 3261, 4008, 2127, 2456, 0, 0, 0, 1470, 0, 0, 0, 118, 3064, 2109, 0, 0, 3869, 927, 0, 2094, 2679, 3430, 0, 523, 369, 2303, 1666, 0, 0, 0,
3424, 0, 3880, 0, 2573, 4316, 3161, 0, 0, 2386, 2223, 0, 183, 1361, 0, 3793, 0, 0, 3034, 0, 2006, 0, 4141, 3285, 0, 1165, 2159, 3097, 0, 0,
1184, 1714, 1003, 0, 181, 397, 4398, 2136, 0, 3059, 4471, 4574, 1275, 1280, 0, 1467, 1889, 0, 2402, 0, 0, 3351, 0, 2927, 0, 1274, 162, 1156,
4420, 0, 0, 0, 3105, 668, 0, 1657, 0, 4333, 1205, 0, 402, 0, 0, 504, 1767, 0, 69, 1552, 189, 38, 680, 0, 3915, 2020, 4023, 0, 0, 4142, 3772,
3715, 976, 2085, 2999, 0, 2498, 0, 2150, 272, 0, 1007, 1864, 1541, 0, 0, 0, 1828, 2118, 0, 229, 0, 2184, 0, 338, 952, 2205, 0, 3061, 1941,
2509, 4215, 1482, 0, 3932, 462, 0, 2226, 1392, 847, 923, 0, 0, 0, 0, 353, 0, 0, 2472, 3304, 940, 0, 3521, 0, 0, 0, 4170, 0, 0, 1185, 0, 0,
3703, 0, 60, 0, 3197, 689, 0, 0, 0, 0, 1244, 56, 4249, 0, 0, 602, 0, 2517, 2695, 2345, 773, 706, 0, 0, 0, 702, 3498, 341, 0, 0, 254, 1467,
1362, 1970, 0, 1189, 720, 3966, 0, 3939, 4503, 1474, 3782, 309, 0, 0, 3786, 0, 1915, 0, 3631, 2861, 4101, 0, 1007, 2851, 0, 0, 0, 0, 0, 303,
2640, 2210, 904, 3072, 426, 2990, 1770, 3059, 0, 0, 1512, 0, 3422, 971, 0, 1107, 1814, 0, 0, 2886, 1686, 284, 1118, 0, 3666, 0, 3689,
3859, 0, 4489, 1401, 2273, 570, 390, 2514, 4180, 1561, 2196, 596, 4617, 3842, 3320, 2162, 91, 2412, 83, 1067, 0, 1066, 0, 3606, 2965, 0, 2965,
1209, 0, 947, 0, 3707, 0, 933, 3833, 0, 842, 1334, 0, 4471, 9, 2411, 0, 2418, 1799, 0, 2851, 0, 0, 3412, 3347, 574, 0, 1163, 0, 3307, 0,
2815, 0, 112, 2077, 121, 0, 0, 0, 3574, 0, 0, 788, 0, 0, 4216, 0, 1485, 3913, 39, 979, 0, 766, 3716, 1182, 581, 3419, 0, 0, 1468, 1026, 0, 0,
0, 1919, 4046, 0, 623, 3930, 0, 0, 2995, 0, 0, 1963, 0, 0, 4290, 0, 0, 0, 1226, 393, 0, 0, 0, 0, 0, 1028, 0, 707, 0, 3005, 871, 0, 0, 3903,
991, 1504, 2540, 0, 0, 0, 199, 684, 2268, 0, 0, 770, 4152, 60, 2828, 0, 3015, 656, 831, 0, 3171, 0, 3622, 0, 0, 357, 0, 3440, 508, 1931, 0,
1986, 0, 579, 2454, 0, 0, 1607, 1213, 3993, 2532, 1121, 0, 3839, 0, 2331, 0, 0, 107, 3239, 2886, 1909, 1582, 0, 29, 0, 1398, 2847, 2222, 0,
945, 3334, 0, 1413, 1731, 250, 0, 0, 0, 1153, 1104, 1927, 1075, 4521, 2104, 0, 1460, 447, 2399, 4185, 0, 1780, 0, 218, 2016, 2889, 717, 0, 0,
0, 1730, 1328, 1406, 0, 1162, 1121, 3845, 1796, 0, 2376, 663, 3584, 0, 0, 3509, 1953, 0, 1469, 0, 0, 889, 0, 533, 3229, 409, 305, 60, 0, 0,
278, 0, 1547, 3394, 0, 0, 0, 0, 0, 1636, 0, 2167, 3923, 0, 705, 1932, 656, 0, 3656, 1439, 1957, 0, 0, 0, 208, 428, 3857, 3803, 4075, 565,
0, 852, 0, 4433, 0, 0, 0, 0, 0, 1524, 3195, 0, 0, 3246, 0, 2552, 1345, 2751, 0, 0, 0, 0, 509, 1601, 2340, 0, 1082, 1401, 2155, 2461, 1267, 0,
849, 545, 3616, 4318, 3112, 2026, 1202, 2266, 810, 0, 1020, 1811, 1058, 2974, 0, 1049, 0, 179, 0, 539, 2407, 1009, 2116, 2080, 1489, 0, 1412,
1831, 2019, 4216, 0, 0, 3666, 758, 0, 0, 1295, 1732, 0, 0, 0, 3428, 0, 0, 3158, 3157, 1114, 0, 0, 0, 0, 365, 4332, 3509, 0, 2927, 2733,
300, 0, 3389, 3947, 1294, 113, 0, 0, 0, 0, 490, 0, 1250, 0, 4246, 520, 789, 0, 1346, 1140, 1984, 229, 950, 0, 2111, 3575, 0, 0, 0, 2450, 0,
0, 484, 452, 648, 887, 0, 915, 0, 56, 1096, 4306, 0, 771, 0, 0, 0, 2373, 0, 1299, 0, 2806, 0, 0, 1381, 0, 0, 0, 1405, 1661, 0, 0, 0, 1141,
2625, 0, 0, 890, 1282, 3838, 0, 1252, 2545, 3318, 4104, 0, 2615, 0, 1155, 0, 0, 0, 3624, 0, 0, 0, 0, 0, 0, 2638, 385, 0, 0, 2226, 0, 0, 0,
870, 4124, 2127, 0, 2203, 0, 0, 0, 89, 3076, 189, 0, 0, 4170, 4480, 0, 0, 0, 3544, 0, 0, 3902, 3857, 0, 0, 2454, 2820, 0, 0, 2393, 622, 659,
2348, 163, 0, 1810, 2940, 0, 0, 0, 124, 2435, 835, 2902, 1733, 245, 0, 4364, 0, 0, 171, 349, 307, 0, 427, 1741, 0, 453, 4333, 0, 0, 636, 0,
0, 870, 0, 0, 2477, 3345, 666, 0, 0, 0, 0, 4290, 2922, 3986, 0, 0, 596, 2442, 69, 3056, 4389, 0, 0, 939, 0, 3974, 0, 0, 4281, 0, 3102, 356,
2946, 1297, 492, 0, 3212, 0, 0, 0, 2321, 0, 598, 960, 0, 1220, 0, 0, 0, 1673, 369, 3073, 4048, 0, 238, 2466, 342, 0, 2137, 2169, 2937, 0, 553,
3399, 0, 1197, 0, 0, 0, 2455, 0, 522, 0, 0, 576, 2183, 536, 2275, 4092, 0, 2670, 1038, 2862, 2559, 0, 4068, 4107, 2048, 2887, 1077, 0, 0, 3951,
682, 2355, 3159, 0, 0, 0, 4226, 3309, 2011, 1859, 1998, 0, 1443, 1463, 0, 0, 1768, 0, 0, 3367, 1032, 0, 2858, 3370, 0, 0, 413, 2952, 2887,
0, 0, 0, 1984, 0, 1052, 0, 473, 649, 0, 0, 0, 1734, 0, 599, 793, 4428, 2970, 2811, 0, 726, 3224, 4, 867, 461, 2538, 153, 563, 1560, 0, 884,
0, 3363, 0, 0, 2564, 2452, 1357, 0, 4134, 4285, 0, 0, 2334, 98, 2617, 4200, 762, 4301, 1847, 0, 0, 2520, 201, 0, 0, 624, 2425, 364, 2351,
4142, 2926, 1238, 4505, 987, 145, 0, 1263, 0, 328, 0, 3859, 0, 2777, 0, 638, 0, 3421, 3881, 213, 75, 1909, 0, 2930, 3931, 744, 0, 3441, 461,
3083, 0, 810, 0, 0, 4184, 0, 0, 3922, 0, 1013, 1401, 0, 0, 943, 4466, 1354, 0, 448, 1901, 2555, 0, 0, 2115, 492, 0, 849, 653, 0, 0, 0, 0,
86, 1985, 303, 1235, 0, 1970, 868, 2987, 0, 0, 0, 1753, 0, 0, 0, 0, 3486, 0, 392, 0, 0, 0, 4097, 0, 0, 0, 3824, 0, 0, 1424, 2546, 0, 624,
2231, 0, 3921, 0, 1373, 0, 0, 1161, 2774, 0, 2075, 1737, 4387, 0, 1891, 0, 1977, 0, 0, 2200, 0, 4285, 4231, 0, 1413, 0, 1678, 1798, 4204, 0,
0, 0, 1129, 989, 555, 2216, 2115, 0, 3300, 2515, 33, 0, 2168, 0, 1884, 3676, 1044, 2267, 3640, 0, 3397, 368, 0, 0, 2250, 3343, 0, 4277, 1346,
1118, 0, 3228, 0, 1422, 1616, 2332, 1971, 0, 0, 1892, 3461, 0, 2595, 0, 3977, 2684, 0, 0, 0, 2429, 723, 1092, 2414, 101, 456, 3977, 0, 2265, 0,
874, 0, 2511, 0, 782, 32, 2498, 0, 1496, 1602, 3338, 4039, 0, 1051, 0, 0, 0, 2686, 0, 0, 0, 0, 0, 1811, 0, 1771, 2954, 0, 144, 0, 2204,
3298, 0, 0, 0, 574, 4246, 0, 2042, 0, 0, 0, 1695, 0, 0, 760, 4252, 1066, 0, 3188, 36, 0, 42, 270, 868, 2341, 0, 1863, 3192, 3542, 0, 1865,
3750, 0, 792, 4414, 222, 4211, 0, 3149, 264, 0, 1240, 2035, 0, 0, 888, 659, 1217, 3277, 0, 0, 0, 0, 206, 2189, 0, 2789, 3442, 1106, 2940,
1568, 1366, 2215, 0, 3392, 1305, 1430, 3140, 3038, 0, 0, 4165, 0, 4132, 2614, 0, 4047, 0, 0, 2825, 2149, 408, 0, 3633, 0, 2497, 2299, 0, 0,
3841, 2173, 0, 1277, 735, 0, 36, 0, 304, 1671, 18, 2120, 0, 4004, 0, 0, 375, 0, 0, 2522, 0, 0, 0, 0, 2820, 2686, 0, 0, 460, 0, 1749, 0, 0, 0,
1606, 1243, 0, 0, 2759, 2857, 2031, 1657, 0, 0, 0, 0, 89, 3257, 4614, 0, 1040, 454, 1004, 0, 0, 0, 0, 1275, 0, 3419, 2195, 3925, 4078, 720,
2372, 512, 0, 2288, 0, 0, 4237, 1250, 0, 0, 689, 0, 0, 4441, 2221, 3191, 3555, 0, 3023, 4122, 2270, 0, 0, 0, 122, 1332, 1994, 3557, 3975,
2162, 678, 3839, 2115, 0, 3729, 0, 610, 2634, 909, 4448, 448, 2356, 405, 0, 509, 1605, 0, 0, 0, 4057, 0, 0, 0, 0, 77, 0, 3066, 416, 0, 864,
4348, 2928, 3759, 0, 2015, 2153, 1348, 0, 0, 0, 1832, 3026, 1187, 0, 0, 1503, 2680, 4297, 0, 646, 892, 3882, 1614, 0, 1060, 3489, 0, 671,
29, 1031, 1049, 583, 0, 1757, 1469, 854, 318, 0, 3032, 2044, 0, 0, 0, 512, 3427, 3838, 807, 0, 1012, 0, 133, 0, 2493, 158, 1983, 954, 0, 0,
1251, 0, 4002, 0, 0, 3156, 0, 886, 0, 0, 1560, 1605, 0, 0, 0, 0, 4587, 0, 0, 2428, 3341, 2857, 0, 504, 0, 2197, 0, 0, 0, 413, 2666, 210, 62,
2403, 0, 1121, 0, 0, 0, 4358, 1265, 0, 360, 0, 409, 0, 0, 0, 4464, 0, 3633, 0, 1792, 231, 1331, 1163, 0, 3500, 1584, 0, 0, 2058, 55, 0, 2133,
2893, 3954, 0, 0, 927, 1330, 0, 0, 0, 4415, 1667, 2039, 302, 752, 3191, 904, 2149, 0, 3078, 0, 76, 751, 532, 2355, 0, 1364, 1224, 0, 3883,
944, 0, 0, 1640, 4315, 3232, 3095, 81, 0, 2565, 289, 2217, 708, 0, 0, 1371, 824, 0, 0, 1522, 0, 0, 0, 705, 3656, 2701, 0, 0, 0, 112, 1167, 0,
611, 688, 0, 2958, 3230, 0, 782, 0, 0, 2717, 803, 91, 0, 0, 436, 0, 0, 946, 868, 1315, 0, 2776, 57, 0, 0, 3891, 0, 0, 0, 4003, 0, 4186, 0,
78, 0, 0, 0, 0, 3877, 987, 594, 0, 68, 0, 3149, 0, 1435, 823, 4380, 1542, 0, 1867, 0, 3783, 0, 508, 0, 2306, 0, 159, 1867, 1097, 1567,
2978, 4574, 834, 0, 3266, 0, 0, 872, 0, 3074, 1032, 1663, 0, 3500, 0, 3509, 2664, 0, 1063, 1713, 0, 0, 2521, 463, 1439, 3901, 0, 0, 0, 2750,
0, 3780, 0, 0, 4020, 1414, 2473, 0, 4262, 0, 0, 1477, 0, 2404, 1387, 0, 0, 4130, 0, 2867, 0, 1463, 0, 3553, 0, 1264, 2212, 0, 3490, 3876, 3238,
1425, 2955, 602, 593, 2485, 2043, 589, 0, 0, 734, 0, 0, 674, 0, 1680, 0, 1130, 3431, 1016, 0, 3208, 0, 1611, 0, 0, 521, 0, 279, 3567, 4378,
1833, 0, 3470, 2726, 0, 0, 1719, 2945, 2813, 0, 202, 1174, 0, 0, 3310, 620, 1261, 948, 0, 406, 1640, 0, 2703, 120, 185, 1457, 2473, 444, 2432,
1708, 2824, 0, 0, 3934, 4599, 793, 1170, 793, 547, 0, 0, 0, 1236, 0, 0, 3465, 3153, 3009, 1782, 1387, 1206, 4301, 4354, 0, 0, 0, 510, 0, 82, 0,
0, 4086, 0, 0, 2128, 0, 2242, 0, 1712, 3994, 1363, 1324, 1351, 0, 762, 0, 1776, 0, 0, 2878, 0, 0, 2127, 2042, 1946, 0, 0, 482, 179, 2065,
611, 2679, 29, 0, 4618, 0, 1210, 4341, 577, 0, 3508, 2454, 1598, 1887, 2940, 4187, 0, 4198, 4239, 2026, 129, 0, 0, 4085, 0, 2463, 237, 609, 0,
105, 2924, 0, 4479, 0, 417, 3833, 2295, 476, 0, 1799, 0, 0, 0, 2889, 503, 1535, 0, 0, 0, 0, 1903, 1683, 1213, 1683, 1275, 0, 0, 4229, 0,
1664, 2390, 585, 0, 0, 0, 0, 4401, 0, 0, 0, 2558, 1716, 0, 3604, 1853, 1153, 3037, 2186, 650, 0, 2218, 0, 0, 0, 2853, 4152, 0, 0, 0, 1684, 0,
0, 1630, 3949, 2149, 4352, 0, 0, 1603, 511, 1921, 346, 0, 1588, 486, 0, 3001, 1076, 1531, 4136, 514, 2223, 0, 122, 426, 2068, 0, 4242, 469,
261, 0, 292, 0, 2336, 1600, 2122, 4579, 1254, 4231, 4090, 219, 3720, 0, 2524, 2124, 0, 4393, 0, 1107, 0, 982, 0, 0, 3387, 0, 4325, 566, 0, 0,
0, 1939, 2055, 765, 2084, 0, 0, 0, 0, 4427, 4010, 0, 4223, 2581, 0, 93, 1085, 1380, 0, 3803, 3283, 1065, 4066, 699, 2172, 0, 1774, 0, 423,
3158, 0, 1338, 42, 0, 0, 4368, 0, 2990, 0, 3767, 646, 0, 0, 0, 0, 4102, 2423, 0, 0, 1868, 95, 2025, 0, 2502, 0, 3271, 1521, 3098, 2621, 1871,
0, 775, 2182, 686, 0, 888, 0, 1689, 0, 992, 2216, 3895, 2326, 536, 0, 532, 0, 2812, 0, 317, 0, 3737, 1136, 471, 47, 0, 4251, 1113, 1537,
3524, 192, 0, 0, 3998, 0, 2054, 2863, 755, 65, 0, 399, 0, 1976, 0, 2298, 0, 1217, 2484, 1430, 0, 413, 1597, 2857, 2060, 1296, 0, 0, 3917,
1711, 921, 0, 2103, 0, 0, 2551, 0, 987, 2054, 4310, 0, 929, 2412, 2267, 3855, 1676, 63, 0, 2060, 1316, 536, 0, 0, 1626, 2008, 1216, 1924, 0, 0,
2339, 0, 1035, 950, 3822, 329, 0, 2245, 4023, 0, 0, 528, 1510, 2180, 0, 1737, 1860, 1654, 0, 0, 4019, 1295, 348, 1843, 1462, 2410, 427, 1475,
1280, 1049, 0, 2638, 2410, 3267, 3553, 0, 4474, 1108, 0, 0, 4310, 1321, 1573, 2555, 2128, 1773, 1126, 0, 3359, 428, 0, 0, 1665, 1794, 3033,
716, 0, 0, 66, 0, 931, 0, 1772, 108, 0, 867, 0, 0, 0, 2636, 0, 0, 1487, 4076, 0, 0, 1994, 586, 492, 0, 4291, 810, 0, 3082, 258, 1906, 324,
3644, 0, 2933, 0, 0, 3726, 1761, 1821, 1768, 0, 0, 4504, 2429, 0, 2583, 4342, 2994, 0, 0, 0, 1911, 8, 1132, 0, 519, 0, 0, 2158, 0, 489, 1161,
0, 491, 0, 2061, 321, 1871, 0, 179, 0, 2378, 0, 0, 0, 0, 1726, 0, 0, 0, 422, 1381, 222, 1630, 3390, 3198, 2820, 3197, 0, 3735, 0, 2786, 4069,
0, 0, 1977, 3694, 1577, 0, 0, 0, 0, 0, 3880, 3409, 1676, 0, 3513, 0, 0, 538, 3719, 0, 4184, 3819, 2592, 0, 4235, 1841, 3575, 0, 3464, 429, 732,
0, 4389, 1625, 392, 0, 4059, 1101, 3443, 0, 0, 4414, 420, 2090, 1723, 0, 1185, 2763, 2742, 873, 0, 4349, 2085, 0, 0, 585, 1896, 0, 3756,
4393, 2073, 1230, 0, 233, 0, 64, 4047, 1015, 0, 280, 769, 0, 3116, 2508, 0, 0, 0, 0, 0, 1982, 0, 1363, 0, 2755, 0, 2166, 2454, 2483, 0,
1540, 0, 2637, 868, 0, 0, 1694, 3624, 0, 996, 3832, 2768, 551, 0, 0, 886, 0, 191, 3871, 332, 3807, 3135, 2161, 0, 0, 1525, 0, 4176, 667, 0,
4332, 597, 0, 955, 1967, 2351, 0, 0, 2162, 0, 1097, 4080, 4303, 0, 0, 2519, 3289, 3705, 0, 0, 2646, 233, 2796, 1151, 1477, 738, 1602, 3040,
2596, 169, 0, 3323, 0, 0, 1621, 0, 1207, 1925, 40, 0, 1379, 0, 2568, 686, 0, 496, 0, 0, 0, 2186, 0, 213, 871, 1731, 3502, 1354, 2287, 0, 0,
2200, 0, 0, 2230, 2517, 1465, 732, 3007, 0, 0, 0, 4022, 2420, 0, 0, 0, 2300, 0, 0, 0, 1687, 0, 4004, 1950, 166, 4213, 3484, 118, 0, 4380,
1709, 2499, 0, 0, 408, 0, 2729, 4191, 0, 1922, 3125, 2123, 1162, 3337, 1076, 1165, 2297, 2291, 3707, 2000, 2931, 0, 0, 0, 0, 0, 2243, 390, 0,
1061, 0, 0, 4613, 831, 48, 653, 0, 0, 0, 2854, 0, 0, 2097, 738, 4112, 348, 0, 2479, 0, 3366, 3715, 244, 0, 2385, 41, 528, 2336, 0, 0, 1285,
3482, 760, 0, 41, 3732, 2339, 649, 2031, 889, 2533, 2228, 0, 0, 711, 3238, 0, 0, 0, 306, 675, 1531, 133, 1177, 846, 0, 786, 0, 0, 1880,
1229, 72, 0, 3476, 1984, 1155, 657, 4051, 72, 4584, 2108, 4067, 362, 0, 2211, 2342, 3225, 40, 0, 0, 804, 574, 0, 1562, 1577, 0, 3185, 0, 527,
405, 188, 1070, 1436, 1501, 0, 3608, 3362, 0, 0, 3069, 0, 4026, 0, 0, 252, 0, 3676, 2352, 0, 656, 0, 0, 3364, 487, 125, 2163, 1610, 96,
3252, 0, 2688, 3776, 0, 2011, 0, 930, 317, 425, 1484, 1053, 3945, 0, 4083, 933, 3115, 3641, 544, 3112, 0, 337, 0, 0, 1888, 1967, 1294, 2965,
2877, 0, 2986, 584, 2366, 0, 3638, 1307, 1433, 0, 805, 3960, 573, 0, 1852, 1728, 552, 3477, 1669, 1253, 1917, 1289, 160, 2184, 1165, 2917,
2130, 0, 55, 0, 1137, 2418, 0, 0, 2560, 0, 3164, 0, 0, 406, 1774, 0, 0, 1561, 4193, 3328, 1476, 0, 1072, 3956, 800, 1357, 3841, 0, 2844, 0,
2336, 3059, 0, 0, 0, 0, 2110, 0, 0, 0, 70, 4537, 4337, 0, 2483, 2219, 0, 2879, 0, 2381, 1127, 0, 3128, 2968, 3694, 2061, 0, 2545, 606, 255,
0, 73, 718, 345, 1828, 2340, 0, 777, 3236, 1056, 794, 2152, 0, 2374, 529, 170, 3242, 1354, 3175, 0, 1395, 847, 0, 2240, 0, 3053, 17, 2048,
3592, 4318, 571, 2897, 236, 0, 2510, 0, 0, 4265, 265, 606, 4214, 99, 0, 0, 0, 4391, 1929, 1618, 0, 382, 3000, 0, 2272, 355, 1098, 1053,
2377, 1154, 500, 2125, 1163, 858, 3356, 2026, 4311, 1112, 1224, 0, 2282, 2914, 0, 2842, 376, 2228, 726, 0, 1156, 0, 1410, 0, 749, 4063,
4200, 1079, 3471, 0, 2476, 202, 2561, 1340, 1205, 0, 2024, 0, 581, 0, 2439, 0, 0, 0, 2621, 0, 3528, 2435, 0, 97, 1482, 694, 1194, 570, 3416,
4377, 382, 0, 3905, 322, 2770, 3299, 0, 2078, 485, 1064, 162, 1818, 3179, 3403, 1117, 0, 0, 1524, 943, 0, 0, 0, 0, 3575, 3773, 1936, 0, 0,
180, 0, 279, 4411, 4268, 0, 0, 1428, 2432, 340, 0, 0, 2053, 830, 55, 0, 0, 1401, 0, 0, 2159, 2996, 270, 0, 2332, 1361, 2981, 0, 579, 0, 3346,
4188, 611, 3976, 131, 1815, 2182, 84, 2253, 1201, 2467, 1196, 572, 0, 728, 0, 3494, 3405, 3445, 3435, 2653, 0, 1308, 2858, 3025, 2575, 3731,
0, 1003, 2379, 0, 867, 0, 0, 0, 0, 0, 0, 505, 0, 1080, 4504, 0, 2588, 605, 855, 0, 203, 4259, 3290, 1060, 95, 1420, 435, 0, 383, 1415, 45,
26, 2511, 2437, 3922, 3077, 0, 1941, 0, 0, 0, 1352, 0, 0, 1692, 0, 0, 1586, 117, 2280, 2435, 1389, 703, 0, 0, 2704, 31, 0, 2471, 3594, 1054,
338, 0, 563, 0, 1941, 3948, 0, 711, 0, 0, 1532, 812, 1408, 1682, 1413, 0, 1511, 0, 0, 1382, 0, 4258, 4301, 840, 286, 2344, 719, 1350, 3803,
148, 3032, 1839, 0, 3242, 2318, 2125, 933, 0, 0, 4100, 0, 2924, 2980, 183, 2098, 3975, 0, 0, 823, 2368, 4256, 0, 752, 1235, 5, 0, 3558, 98,
1429, 0, 1940, 0, 1915, 4036, 2174, 2000, 142, 1994, 4197, 35, 321, 3725, 694, 3455, 0, 3653, 875, 1383, 0, 547, 1804, 0, 70, 0, 715, 0, 0,
2689, 974, 0, 1471, 3746, 2148, 4142, 4507, 0, 0, 430, 3884, 0, 0, 486, 2494, 1860, 0, 4370, 3502, 779, 1873, 1031, 1727, 168, 3541, 274, 1808,
768, 0, 0, 417, 2494, 154, 4507, 1666, 909, 0, 4308, 0, 0, 1913, 3245, 0, 0, 0, 0, 0, 0, 0, 3285, 1309, 3407, 0, 0, 0, 113, 2126, 3166, 1249,
0, 569, 3216, 0, 0, 4038, 0, 0, 0, 2546, 3427, 477, 776, 2288, 3418, 0, 1876, 1375, 3355, 3352, 1112, 0, 1232, 836, 0, 2694, 375, 3155, 815,
507, 49, 4524, 0, 0, 0, 1325, 325, 1525, 2536, 1424, 2007, 0, 1703, 1889, 0, 0, 2998, 2383, 0, 0, 2114, 2168, 125, 1856, 0, 0, 0, 2371,
1866, 1233, 1005, 2069, 1703, 0, 0, 1045, 0, 2099, 2719, 2526, 3763, 0, 1324, 1017, 1445, 1438, 0, 0, 155, 4178, 0, 935, 1754, 772, 1828, 0, 0,
1462, 2049, 0, 1318, 4522, 0, 0, 0, 0, 0, 2551, 0, 0, 1844, 300, 3532, 628, 458, 1292, 3824, 1772, 2528, 983, 2535, 3680, 0, 742, 1619, 2192,
3431, 25, 0, 0, 0, 1109, 3458, 425, 2338, 0, 4481, 434, 0, 0, 0, 0, 0, 0, 1186, 4098, 800, 0, 2809, 2098, 2052, 3951, 3703, 2558, 0, 0, 1243,
929, 602, 0, 2798, 0, 0, 2209, 1195, 0, 459, 2461, 3700, 2498, 0, 1379, 559, 964, 0, 0, 1402, 3474, 0, 0, 2102, 3369, 1705, 0, 694, 0, 2957,
1008, 3235, 0, 0, 918, 481, 3063, 3335, 2131, 1794, 0, 2417, 3037, 0, 2106, 0, 0, 0, 4251, 1377, 1041, 3963, 4047, 0, 1047, 2778, 911, 0,
3953, 2382, 2800, 1063, 0, 130, 508, 617, 0, 953, 0, 2200, 1428, 0, 651, 0, 0, 1646, 0, 1111, 2369, 770, 3627, 4192, 2657, 3794, 1255, 632,
509, 1090, 706, 0, 0, 1053, 1078, 1095, 3225, 0, 279, 4481, 1017, 261, 4345, 0, 1269, 814, 2886, 0, 1826, 1773, 559, 0, 1327, 1508, 3242,
0, 769, 3943, 0, 904, 2208, 4550, 1043, 1455, 4042, 0, 1615, 0, 0, 232, 2335, 1589, 736, 3496, 1132, 2712, 2540, 287, 1260, 3176, 0, 977, 0,
0, 4529, 4364, 291, 0, 2695, 1372, 0, 4093, 30, 4458, 0, 0, 1641, 1591, 3067, 0, 979, 0, 885, 739, 0, 813, 722, 541, 745, 0, 0, 0, 1102, 1963,
0, 153, 0, 4125, 4607, 3057, 0, 0, 0, 0, 0, 0, 489, 2628, 0, 0, 3776, 202, 474, 865, 2386, 0, 0, 3839, 0, 0, 0, 100, 2822, 3620, 2002, 1675,
2763, 0, 4203, 3253, 1433, 0, 3664, 4492, 1090, 2882, 1172, 534, 2107, 1542, 2599, 2219, 0, 0, 454, 845, 1203, 377, 4169, 995, 1472, 3052,
0, 0, 4372, 2308, 2283, 1068, 0, 0, 0, 1178, 0, 0, 513, 0, 0, 3913, 3584, 0, 105, 172, 0, 1421, 2571, 2778, 0, 1267, 0, 2723, 1968, 0,
2052, 3633, 0, 1740, 763, 2495, 2480, 0, 0, 523, 1829, 1063, 937, 3636, 4399, 0, 674, 0, 458, 1260, 0, 0, 3957, 2224, 0, 0, 3089, 3191, 0, 628,
4050, 3903, 1740, 1349, 754, 0, 162, 338, 0, 749, 0, 0, 0, 0, 2914, 670, 1716, 0, 2399, 3592, 2059, 1928, 157, 0, 0, 2087, 494, 394, 2564,
3975, 593, 3893, 0, 630, 691, 1613, 1226, 3769, 736, 0, 0, 1491, 0, 0, 0, 32, 1717, 2195, 1172, 614, 430, 920, 0, 0, 2492, 1660, 1641,
2752, 0, 53, 0, 1298, 2746, 644, 786, 337, 0, 0, 0, 1472, 1598, 0, 3078, 1264, 0, 1306, 1070, 3264, 4001, 2046, 0, 397, 2258, 0, 3145, 0,
1855, 525, 0, 0, 1784, 2000, 0, 0, 0, 1905, 0, 964, 0, 3424, 0, 2308, 810, 890, 1173, 1401, 0, 1765, 0, 4338, 1898, 1553, 1196, 121, 3960,
733, 1151, 0, 0, 3882, 3829, 4368, 835, 3388, 624, 1803, 0, 0, 2647, 155, 664, 3982, 1729, 2399, 3649, 0, 716, 1128, 0, 3668, 4257, 2824, 0,
1332, 755, 0, 185, 247, 0, 1856, 2252, 0, 850, 1342, 4074, 375, 359, 1334, 0, 1175, 965, 2224, 2148, 0, 4046, 0, 701, 4032, 0, 89, 1743,
198, 2961, 0, 4040, 2496, 4058, 801, 0, 111, 2402, 0, 1110, 1312, 4064, 1640, 0, 0, 0, 0, 0, 2512, 1226, 1637, 0, 3275, 0, 0, 0, 10, 161, 1018,
1485, 585, 0, 0, 25, 537, 3268, 188, 3913, 1939, 3431, 1288, 4564, 0, 1071, 0, 2642, 0, 1164, 443, 2000, 1365, 3219, 1462, 3673, 0, 200, 0,
0, 4054, 0, 2422, 0, 1356, 1134, 91, 1543, 567, 2351, 1708, 0, 298, 0, 902, 0, 4273, 0, 3762, 145, 2267, 0, 3778, 3523, 1827, 0, 2992, 0,
1222, 0, 527, 2512, 2120, 0, 3788, 353, 2581, 1274, 2230, 843, 748, 0, 3764, 611, 2537, 0, 1782, 3215, 1431, 2215, 3921, 0, 3517, 173, 1272,
1248, 0, 1459, 4518, 0, 0, 1818, 517, 3677, 0, 1725, 276, 4496, 0, 1280, 1093, 3269, 1558, 2635, 0, 1984, 3180, 0, 832, 799, 0, 0, 357,
3446, 1981, 1094, 0, 0, 4216, 2501, 3849, 256, 4388, 840, 537, 0, 2186, 822, 1831, 1560, 0, 932, 2628, 197, 0, 2402, 0, 0, 0, 4253, 643, 0, 0,
1361, 3669, 291, 0, 508, 875, 4372, 0, 0, 353, 0, 15, 918, 0, 1648, 1279, 2908, 550, 1758, 0, 1425, 2708, 1600, 3974, 2768, 1014, 4152, 0,
3664, 2040, 2794, 0, 355, 4557, 0, 713, 787, 1782, 3242, 2635, 0, 908, 0, 802, 1107, 0, 0, 3642, 89, 0, 0, 2514, 0, 0, 2515, 264, 1509, 2255,
0, 3502, 1131, 1524, 1455, 4302, 2859, 16, 1083, 3320, 2213, 0, 0, 0, 3, 1345, 0, 309, 3321, 2734, 0, 0, 1086, 0, 761, 992, 703, 0, 0, 1345,
3614, 898, 2664, 1640, 0, 978, 0, 3580, 1575, 1617, 61, 0, 758, 2169, 1083, 3522, 1821, 2233, 2854, 2119, 0, 0, 0, 818, 1140, 0, 21, 0, 3888,
1058, 637, 417, 4227, 3482, 0, 1988, 3192, 385, 361, 0, 2922, 2515, 0, 3486, 1575, 667, 4209, 500, 1591, 0, 1484, 1787, 1125, 250, 0, 3646,
4523, 3395, 0, 0, 2809, 953, 0, 2551, 0, 1870, 1092, 1620, 281, 0, 597, 2638, 1516, 4135, 2525, 2271, 0, 1753, 1140, 293, 1379, 2505, 0, 1607,
211, 0, 1128, 0, 295, 3033, 1892, 0, 0, 3197, 971, 2556, 0, 841, 1783, 50, 3284, 1662, 1363, 270, 3990, 1567, 0, 0, 0, 1761, 0, 266, 4027,
58, 0, 0, 278, 2744, 1494, 2448, 4018, 0, 954, 2160, 125, 0, 407, 399, 645, 797, 0, 1219, 0, 0, 1417, 3244, 952, 4283, 0, 1135, 0, 1546, 4138,
4200, 57, 2688, 929, 1662, 2994, 3363, 3476, 0, 0, 3595, 1969, 115, 0, 1159, 3696, 0, 1266, 2859, 2009, 234, 0, 3336, 3659, 0, 1257, 3702,
661, 0, 0, 0, 0, 0, 3305, 2408, 4247, 1049, 4039, 2014, 0, 0, 105, 0, 962, 2309, 0, 2445, 3624, 3598, 660, 4238, 93, 1416, 2666, 0, 3857,
1424, 1345, 0, 2381, 0, 3168, 527, 3329, 912, 0, 2425, 3453, 2298, 762, 4192, 3368, 1239, 3967, 244, 1134, 3773, 3354, 0, 232, 2358, 0, 0,
2106, 639, 1438, 0, 0, 1151, 1067, 2378, 4021, 560, 3974, 2754, 1311, 4027, 3328, 151, 0, 0, 0, 0, 727, 0, 0, 1882, 3600, 4165, 0, 1729, 558,
1672, 1277, 4529, 3452, 2670, 0, 1752, 0, 2938, 3676, 230, 0, 788, 0, 0, 3936, 0, 2657, 3166, 1514, 835, 83, 3616, 3404, 142, 0, 1761, 4238,
0, 0, 62, 3571, 1787, 0, 2804, 1907, 2862, 1978, 0, 0, 787, 733, 99, 0, 3593, 401, 1386, 3302, 3578, 0, 631, 936, 0, 0, 4367, 625, 4249, 0,
1662, 3599, 0, 2812, 0, 1396, 2144, 0, 4503, 0, 0, 2537, 2051, 415, 2216, 3720, 0, 0, 0, 0, 1438, 4000, 1745, 0, 336, 0, 2868, 4358, 598,
4294, 1664, 471, 4340, 323, 0, 1311, 1297, 0, 0, 2308, 0, 779, 4, 1103, 0, 2460, 1123, 295, 0, 1459, 1305, 0, 2733, 0, 1635, 0, 3701, 4162,
4330, 2442, 0, 3335, 0, 410, 531, 985, 2976, 1567, 0, 2631, 0, 769, 523, 3026, 0, 4180, 344, 0, 0, 210, 4338, 0, 0, 1564, 0, 4222, 1530,
804, 1268, 282, 0, 2565, 4016, 1596, 2513, 4139, 0, 991, 1705, 0, 106, 277, 1774, 0, 1872, 2854, 3772, 1711, 2496, 1946, 3751, 2322, 1523,
575, 4249, 784, 641, 4059, 0, 0, 409, 1376, 0, 2102, 1028, 0, 0, 4191, 3707, 1407, 0, 3232, 781, 0, 1965, 0, 0, 4247, 0, 2017, 200, 693, 1538,
2864, 2566, 1412, 0, 915, 1069, 100, 0, 1893, 3193, 2953, 0, 0, 2288, 0, 2272, 1494, 0, 0, 320, 0, 0, 0, 3677, 3432, 0, 0, 0, 64, 1046, 3569,
0, 4520, 4249, 316, 2656, 1679, 0, 0, 3977, 2442, 0, 172, 2917, 0, 251, 921, 994, 2034, 3081, 3752, 951, 293, 1432, 883, 552, 0, 0, 0,
3671, 3445, 1176, 0, 0, 0, 0, 0, 1420, 2830, 996, 0, 0, 3400, 1255, 2362, 2151, 3946, 1234, 1417, 0, 2371, 2334, 2976, 2530, 3011, 0, 803,
405, 4100, 479, 2814, 0, 3721, 1301, 3927, 3937, 1306, 0, 3618, 2372, 1948, 2689, 0, 1059, 0, 8, 3765, 228, 1029, 0, 1861, 3736, 0, 2569, 0,
2491, 4458, 1046, 0, 1620, 3408, 985, 1277, 1061, 132, 2866, 97, 3735, 0, 1166, 788, 506, 0, 562, 269, 2355, 2231, 1723, 4375, 2557, 2903,
2192, 3608, 1612, 1503, 3895, 0, 38, 3902, 0, 0, 1099, 426, 2281, 0, 0, 1194, 793, 730, 0, 1264, 465, 1764, 2668, 366
509, 0, 1350, 0, 1529, 0, 0, 0, 1275, 1743, 3135, 0, 2612, 0, 0, 3016,
0, 692, 3102, 0, 862, 0, 3245, 0, 0, 0, 2568, 46, 4055, 1901, 764,
1128, 723, 2292, 2084, 1961, 0, 292, 0, 0, 0, 1121, 1959, 1203, 2409,
3790, 3260, 2185, 1274, 2701, 1253, 3058, 0, 2953, 1879, 2578, 0, 832,
425, 1739, 850, 487, 483, 469, 0, 511, 475, 1881, 1987, 860, 4489, 0,
0, 0, 1652, 0, 0, 0, 0, 4493, 0, 413, 519, 0, 1789, 3142, 1168, 0, 0,
612, 535, 0, 0, 103, 4165, 0, 3553, 0, 1302, 0, 2438, 0, 940, 1147,
3608, 1332, 719, 1032, 3148, 0, 2063, 927, 0, 0, 3054, 0
}; };
static size_t static size_t
@ -2897,16 +2889,16 @@ keysym_name_hash_f(const char *key, const char *T)
size_t sum = 0; size_t sum = 0;
for (size_t i = 0; key[i] != '\0'; i++) for (size_t i = 0; key[i] != '\0'; i++)
sum += T[i % 32] * key[i]; sum += T[i % 32] * key[i];
return sum % 4622; return sum % 4402;
} }
static size_t static size_t
keysym_name_perfect_hash(const char *key) keysym_name_perfect_hash(const char *key)
{ {
return ( return (
keysym_name_G[keysym_name_hash_f(key, "8TdWODhDmvfFNhdew6RS9Vmk6zoyzcIL")] + keysym_name_G[keysym_name_hash_f(key, "uM56WrSjHtofw6pFN02nkQwt57Rdsoin")] +
keysym_name_G[keysym_name_hash_f(key, "FLLuzXDPPF7o0mOVhnPFXhsuVPyEFt8h")] keysym_name_G[keysym_name_hash_f(key, "P4xqG53yOhBiCtHiRwf0Ws7SW4qxMJYi")]
) % 4622; ) % 4402;
} }

3274
src/xkbcomp/parser.c Normal file

File diff suppressed because it is too large Load Diff

171
src/xkbcomp/parser.h Normal file
View File

@ -0,0 +1,171 @@
/* A Bison parser, made by GNU Bison 3.8.2. */
/* Bison interface for Yacc-like parsers in C
Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2021 Free Software Foundation,
Inc.
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
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>. */
/* As a special exception, you may create a larger work that contains
part or all of the Bison parser skeleton and distribute that work
under terms of your choice, so long as that work isn't itself a
parser generator using the skeleton or a modified version thereof
as a parser skeleton. Alternatively, if you modify or redistribute
the parser skeleton itself, you may (at your option) remove this
special exception, which will cause the skeleton and the resulting
Bison output files to be licensed under the GNU General Public
License without this special exception.
This special exception was added by the Free Software Foundation in
version 2.2 of Bison. */
/* DO NOT RELY ON FEATURES THAT ARE NOT DOCUMENTED in the manual,
especially those whose name start with YY_ or yy_. They are
private implementation details that can be changed or removed. */
#ifndef YY__XKBCOMMON_SRC_XKBCOMP_PARSER_H_INCLUDED
# define YY__XKBCOMMON_SRC_XKBCOMP_PARSER_H_INCLUDED
/* Debug traces. */
#ifndef YYDEBUG
# define YYDEBUG 0
#endif
#if YYDEBUG
extern int _xkbcommon_debug;
#endif
/* Token kinds. */
#ifndef YYTOKENTYPE
# define YYTOKENTYPE
enum yytokentype
{
YYEMPTY = -2,
END_OF_FILE = 0, /* END_OF_FILE */
YYerror = 256, /* error */
YYUNDEF = 257, /* "invalid token" */
ERROR_TOK = 255, /* ERROR_TOK */
XKB_KEYMAP = 1, /* XKB_KEYMAP */
XKB_KEYCODES = 2, /* XKB_KEYCODES */
XKB_TYPES = 3, /* XKB_TYPES */
XKB_SYMBOLS = 4, /* XKB_SYMBOLS */
XKB_COMPATMAP = 5, /* XKB_COMPATMAP */
XKB_GEOMETRY = 6, /* XKB_GEOMETRY */
XKB_SEMANTICS = 7, /* XKB_SEMANTICS */
XKB_LAYOUT = 8, /* XKB_LAYOUT */
INCLUDE = 10, /* INCLUDE */
OVERRIDE = 11, /* OVERRIDE */
AUGMENT = 12, /* AUGMENT */
REPLACE = 13, /* REPLACE */
ALTERNATE = 14, /* ALTERNATE */
VIRTUAL_MODS = 20, /* VIRTUAL_MODS */
TYPE = 21, /* TYPE */
INTERPRET = 22, /* INTERPRET */
ACTION_TOK = 23, /* ACTION_TOK */
KEY = 24, /* KEY */
ALIAS = 25, /* ALIAS */
GROUP = 26, /* GROUP */
MODIFIER_MAP = 27, /* MODIFIER_MAP */
INDICATOR = 28, /* INDICATOR */
SHAPE = 29, /* SHAPE */
KEYS = 30, /* KEYS */
ROW = 31, /* ROW */
SECTION = 32, /* SECTION */
OVERLAY = 33, /* OVERLAY */
TEXT = 34, /* TEXT */
OUTLINE = 35, /* OUTLINE */
SOLID = 36, /* SOLID */
LOGO = 37, /* LOGO */
VIRTUAL = 38, /* VIRTUAL */
EQUALS = 40, /* EQUALS */
PLUS = 41, /* PLUS */
MINUS = 42, /* MINUS */
DIVIDE = 43, /* DIVIDE */
TIMES = 44, /* TIMES */
OBRACE = 45, /* OBRACE */
CBRACE = 46, /* CBRACE */
OPAREN = 47, /* OPAREN */
CPAREN = 48, /* CPAREN */
OBRACKET = 49, /* OBRACKET */
CBRACKET = 50, /* CBRACKET */
DOT = 51, /* DOT */
COMMA = 52, /* COMMA */
SEMI = 53, /* SEMI */
EXCLAM = 54, /* EXCLAM */
INVERT = 55, /* INVERT */
STRING = 60, /* STRING */
INTEGER = 61, /* INTEGER */
FLOAT = 62, /* FLOAT */
IDENT = 63, /* IDENT */
KEYNAME = 64, /* KEYNAME */
PARTIAL = 70, /* PARTIAL */
DEFAULT = 71, /* DEFAULT */
HIDDEN = 72, /* HIDDEN */
ALPHANUMERIC_KEYS = 73, /* ALPHANUMERIC_KEYS */
MODIFIER_KEYS = 74, /* MODIFIER_KEYS */
KEYPAD_KEYS = 75, /* KEYPAD_KEYS */
FUNCTION_KEYS = 76, /* FUNCTION_KEYS */
ALTERNATE_GROUP = 77 /* ALTERNATE_GROUP */
};
typedef enum yytokentype yytoken_kind_t;
#endif
/* Value type. */
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
union YYSTYPE
{
#line 165 "src/xkbcomp/parser.y"
int64_t num;
enum xkb_file_type file_type;
char *str;
xkb_atom_t atom;
enum merge_mode merge;
enum xkb_map_flags mapFlags;
xkb_keysym_t keysym;
ParseCommon *any;
struct { ParseCommon *head; ParseCommon *last; } anyList;
ExprDef *expr;
struct { ExprDef *head; ExprDef *last; } exprList;
VarDef *var;
struct { VarDef *head; VarDef *last; } varList;
VModDef *vmod;
struct { VModDef *head; VModDef *last; } vmodList;
InterpDef *interp;
KeyTypeDef *keyType;
SymbolsDef *syms;
ModMapDef *modMask;
GroupCompatDef *groupCompat;
LedMapDef *ledMap;
LedNameDef *ledName;
KeycodeDef *keyCode;
KeyAliasDef *keyAlias;
void *geom;
XkbFile *file;
struct { XkbFile *head; XkbFile *last; } fileList;
#line 158 "src/xkbcomp/parser.h"
};
typedef union YYSTYPE YYSTYPE;
# define YYSTYPE_IS_TRIVIAL 1
# define YYSTYPE_IS_DECLARED 1
#endif
int _xkbcommon_parse (struct parser_param *param);
#endif /* !YY__XKBCOMMON_SRC_XKBCOMP_PARSER_H_INCLUDED */

View File

@ -978,6 +978,14 @@ include_statement:
switch (tok = gettok(m, s)) { switch (tok = gettok(m, s)) {
case TOK_IDENTIFIER: case TOK_IDENTIFIER:
matcher_include(m, s, include_depth, m->val.string); matcher_include(m, s, include_depth, m->val.string);
goto include_statement_end;
default:
goto unexpected;
}
include_statement_end:
switch (tok = gettok(m, s)) {
case TOK_END_OF_LINE:
goto initial; goto initial;
default: default:
goto unexpected; goto unexpected;

View File

@ -156,6 +156,8 @@ main(void)
struct atom_table *table; struct atom_table *table;
xkb_atom_t atom1, atom2, atom3; xkb_atom_t atom1, atom2, atom3;
test_init();
table = atom_table_new(); table = atom_table_new();
assert(table); assert(table);

View File

@ -169,6 +169,8 @@ test_recursive(void)
int int
main(int argc, char *argv[]) main(int argc, char *argv[])
{ {
test_init();
struct xkb_context *ctx = test_get_context(0); struct xkb_context *ctx = test_get_context(0);
struct xkb_keymap *keymap; struct xkb_keymap *keymap;
char *original, *dump; char *original, *dump;

View File

@ -49,6 +49,17 @@
#include "utils.h" #include "utils.h"
#include "src/keysym.h" #include "src/keysym.h"
#include "tools/tools-common.h"
/* Setup test */
void
test_init(void)
{
/* Make stdout always unbuffered, to ensure we always get it entirely */
setbuf(stdout, NULL);
}
/* /*
* Test a sequence of keysyms, resulting from a sequence of key presses, * Test a sequence of keysyms, resulting from a sequence of key presses,
* against the keysyms they're supposed to generate. * against the keysyms they're supposed to generate.
@ -78,6 +89,7 @@ test_key_seq_va(struct xkb_keymap *keymap, va_list ap)
xkb_keysym_t sym; xkb_keysym_t sym;
unsigned int nsyms, i; unsigned int nsyms, i;
char ksbuf[XKB_KEYSYM_NAME_MAX_SIZE]; char ksbuf[XKB_KEYSYM_NAME_MAX_SIZE];
const char *opstr = NULL;
fprintf(stderr, "----\n"); fprintf(stderr, "----\n");
@ -88,19 +100,31 @@ test_key_seq_va(struct xkb_keymap *keymap, va_list ap)
kc = va_arg(ap, int) + EVDEV_OFFSET; kc = va_arg(ap, int) + EVDEV_OFFSET;
op = va_arg(ap, int); op = va_arg(ap, int);
switch (op) {
case DOWN: opstr = "DOWN"; break;
case REPEAT: opstr = "REPEAT"; break;
case UP: opstr = "UP"; break;
case BOTH: opstr = "BOTH"; break;
case NEXT: opstr = "NEXT"; break;
case FINISH: opstr = "FINISH"; break;
}
nsyms = xkb_state_key_get_syms(state, kc, &syms); nsyms = xkb_state_key_get_syms(state, kc, &syms);
if (nsyms == 1) { if (nsyms == 1) {
sym = xkb_state_key_get_one_sym(state, kc); sym = xkb_state_key_get_one_sym(state, kc);
syms = &sym; syms = &sym;
} }
fprintf(stderr, "got %u syms for keycode %u: [", nsyms, kc);
if (op == DOWN || op == BOTH) if (op == DOWN || op == BOTH)
xkb_state_update_key(state, kc, XKB_KEY_DOWN); xkb_state_update_key(state, kc, XKB_KEY_DOWN);
if (op == UP || op == BOTH) if (op == UP || op == BOTH)
xkb_state_update_key(state, kc, XKB_KEY_UP); xkb_state_update_key(state, kc, XKB_KEY_UP);
#if HAVE_TOOLS
tools_print_keycode_state("", state, NULL, kc, XKB_CONSUMED_MODE_XKB, PRINT_ALL_FIELDS);
#endif
fprintf(stderr, "op %-6s got %u syms for keycode %3u: [", opstr, nsyms, kc);
for (i = 0; i < nsyms; i++) { for (i = 0; i < nsyms; i++) {
keysym = va_arg(ap, int); keysym = va_arg(ap, int);
xkb_keysym_get_name(syms[i], ksbuf, sizeof(ksbuf)); xkb_keysym_get_name(syms[i], ksbuf, sizeof(ksbuf));
@ -108,15 +132,15 @@ test_key_seq_va(struct xkb_keymap *keymap, va_list ap)
if (keysym == FINISH || keysym == NEXT) { if (keysym == FINISH || keysym == NEXT) {
xkb_keysym_get_name(syms[i], ksbuf, sizeof(ksbuf)); xkb_keysym_get_name(syms[i], ksbuf, sizeof(ksbuf));
fprintf(stderr, "Did not expect keysym: %s.\n", ksbuf); fprintf(stderr, " Did not expect keysym: %s.\n", ksbuf);
goto fail; goto fail;
} }
if (keysym != syms[i]) { if (keysym != syms[i]) {
xkb_keysym_get_name(keysym, ksbuf, sizeof(ksbuf)); xkb_keysym_get_name(keysym, ksbuf, sizeof(ksbuf));
fprintf(stderr, "Expected keysym: %s. ", ksbuf);; fprintf(stderr, " Expected keysym: %s. ", ksbuf);;
xkb_keysym_get_name(syms[i], ksbuf, sizeof(ksbuf)); xkb_keysym_get_name(syms[i], ksbuf, sizeof(ksbuf));
fprintf(stderr, "Got keysym: %s.\n", ksbuf);; fprintf(stderr, " Got keysym: %s.\n", ksbuf);;
goto fail; goto fail;
} }
} }
@ -125,7 +149,7 @@ test_key_seq_va(struct xkb_keymap *keymap, va_list ap)
keysym = va_arg(ap, int); keysym = va_arg(ap, int);
if (keysym != XKB_KEY_NoSymbol) { if (keysym != XKB_KEY_NoSymbol) {
xkb_keysym_get_name(keysym, ksbuf, sizeof(ksbuf)); xkb_keysym_get_name(keysym, ksbuf, sizeof(ksbuf));
fprintf(stderr, "Expected %s, but got no keysyms.\n", ksbuf); fprintf(stderr, " Expected %s, but got no keysyms.\n", ksbuf);
goto fail; goto fail;
} }
} }

View File

@ -942,6 +942,8 @@ main(int argc, char *argv[])
{ {
struct xkb_context *ctx; struct xkb_context *ctx;
test_init();
ctx = test_get_context(CONTEXT_NO_FLAG); ctx = test_get_context(CONTEXT_NO_FLAG);
assert(ctx); assert(ctx);

View File

@ -290,6 +290,8 @@ test_include_order(void)
int int
main(void) main(void)
{ {
test_init();
struct xkb_context *context = test_get_context(0); struct xkb_context *context = test_get_context(0);
xkb_atom_t atom; xkb_atom_t atom;

View File

@ -0,0 +1 @@
! include %S/inc-dst-simple !include %S/inc-dst-simple ! layout = symbols

View File

@ -40,6 +40,8 @@ test_file(struct xkb_context *ctx, const char *path_rel)
int int
main(void) main(void)
{ {
test_init();
struct xkb_context *ctx = test_get_context(0); struct xkb_context *ctx = test_get_context(0);
assert(test_file(ctx, "keymaps/basic.xkb")); assert(test_file(ctx, "keymaps/basic.xkb"));

View File

@ -233,6 +233,8 @@ test_multiple_keysyms_per_level(void)
int int
main(void) main(void)
{ {
test_init();
test_garbage_key(); test_garbage_key();
test_keymap(); test_keymap();
test_numeric_keysyms(); test_numeric_keysyms();

View File

@ -29,6 +29,8 @@
int int
main(void) main(void)
{ {
test_init();
struct xkb_context *ctx = test_get_context(0); struct xkb_context *ctx = test_get_context(0);
struct xkb_keymap *keymap; struct xkb_keymap *keymap;
@ -299,7 +301,7 @@ main(void)
KEY_RIGHTALT, DOWN, XKB_KEY_ISO_Level5_Shift, NEXT, KEY_RIGHTALT, DOWN, XKB_KEY_ISO_Level5_Shift, NEXT,
/* XXX: xkeyboard-config is borked when de(neo) is /* XXX: xkeyboard-config is borked when de(neo) is
* not the first group - not our fault. We test * not the first group - not our fault. We test
* Level5 seprately below with only de(neo). */ * Level5 separately below with only de(neo). */
/* KEY_5, BOTH, XKB_KEY_periodcentered, NEXT, */ /* KEY_5, BOTH, XKB_KEY_periodcentered, NEXT, */
/* KEY_E, BOTH, XKB_KEY_Up, NEXT, */ /* KEY_E, BOTH, XKB_KEY_Up, NEXT, */
/* KEY_SPACE, BOTH, XKB_KEY_KP_0, NEXT, */ /* KEY_SPACE, BOTH, XKB_KEY_KP_0, NEXT, */

View File

@ -298,6 +298,8 @@ test_utf32_to_keysym(uint32_t ucs, xkb_keysym_t expected)
int int
main(void) main(void)
{ {
test_init();
/* Bounds */ /* Bounds */
assert(XKB_KEYSYM_MIN == 0); assert(XKB_KEYSYM_MIN == 0);
assert(XKB_KEYSYM_MIN < XKB_KEYSYM_MAX); assert(XKB_KEYSYM_MIN < XKB_KEYSYM_MAX);

View File

@ -75,6 +75,8 @@ main(void)
struct xkb_context *ctx; struct xkb_context *ctx;
int ret; int ret;
test_init();
ret = setenv("XKB_LOG_LEVEL", "warn", 1); ret = setenv("XKB_LOG_LEVEL", "warn", 1);
assert(ret == 0); assert(ret == 0);
ret = setenv("XKB_LOG_VERBOSITY", "5", 1); ret = setenv("XKB_LOG_VERBOSITY", "5", 1);

View File

@ -59,5 +59,7 @@ test_message_get(void)
int int
main(void) main(void)
{ {
test_init();
test_message_get(); test_message_get();
} }

View File

@ -154,6 +154,8 @@ test_modmap_none(void)
int int
main(void) main(void)
{ {
test_init();
test_modmap_none(); test_modmap_none();
return 0; return 0;

View File

@ -1068,6 +1068,8 @@ test_invalid_include(void)
int int
main(void) main(void)
{ {
test_init();
test_no_include_paths(); test_no_include_paths();
test_invalid_include(); test_invalid_include();
test_load_basic(); test_load_basic();

View File

@ -93,6 +93,8 @@ main(int argc, char *argv[])
{ {
struct xkb_context *ctx; struct xkb_context *ctx;
test_init();
setenv("XKB_CONFIG_ROOT", TEST_XKB_CONFIG_ROOT, 1); setenv("XKB_CONFIG_ROOT", TEST_XKB_CONFIG_ROOT, 1);
ctx = test_get_context(0); ctx = test_get_context(0);
@ -159,6 +161,12 @@ main(int argc, char *argv[])
}; };
assert(test_rules(ctx, &test6)); assert(test_rules(ctx, &test6));
struct test_data test7 = {
.rules = "inc-no-newline",
.should_fail = true,
};
assert(test_rules(ctx, &test7));
xkb_context_unref(ctx); xkb_context_unref(ctx);
return 0; return 0;
} }

View File

@ -91,6 +91,8 @@ main(int argc, char *argv[])
{ {
struct xkb_context *ctx; struct xkb_context *ctx;
test_init();
ctx = test_get_context(0); ctx = test_get_context(0);
assert(ctx); assert(ctx);

View File

@ -110,6 +110,8 @@ test_rmlvo_env(struct xkb_context *ctx, const char *rules, const char *model,
int int
main(int argc, char *argv[]) main(int argc, char *argv[])
{ {
test_init();
struct xkb_context *ctx = test_get_context(CONTEXT_ALLOW_ENVIRONMENT_NAMES); struct xkb_context *ctx = test_get_context(CONTEXT_ALLOW_ENVIRONMENT_NAMES);
assert(ctx); assert(ctx);

View File

@ -712,6 +712,8 @@ test_ctrl_string_transformation(struct xkb_keymap *keymap)
int int
main(void) main(void)
{ {
test_init();
struct xkb_context *context = test_get_context(0); struct xkb_context *context = test_get_context(0);
struct xkb_keymap *keymap; struct xkb_keymap *keymap;

View File

@ -34,6 +34,8 @@
int int
main(int argc, char *argv[]) main(int argc, char *argv[])
{ {
test_init();
struct xkb_context *ctx = test_get_context(0); struct xkb_context *ctx = test_get_context(0);
struct xkb_keymap *keymap; struct xkb_keymap *keymap;
char *original, *dump, *dump2; char *original, *dump, *dump2;

View File

@ -44,6 +44,9 @@
assert_printf(streq_not_null(expected, got), \ assert_printf(streq_not_null(expected, got), \
test_name ". Expected \"%s\", got: \"%s\"\n", expected, got) test_name ". Expected \"%s\", got: \"%s\"\n", expected, got)
void
test_init(void);
/* The offset between KEY_* numbering, and keycodes in the XKB evdev /* The offset between KEY_* numbering, and keycodes in the XKB evdev
* dataset. */ * dataset. */
#define EVDEV_OFFSET 8 #define EVDEV_OFFSET 8

View File

@ -29,6 +29,7 @@
#include <stddef.h> #include <stddef.h>
#include <string.h> #include <string.h>
#include "test.h"
#include "utf8.h" #include "utf8.h"
#include "utils.h" #include "utils.h"
@ -180,6 +181,8 @@ test_utf32_to_utf8(void)
int int
main(void) main(void)
{ {
test_init();
test_is_valid_utf8(); test_is_valid_utf8();
test_utf32_to_utf8(); test_utf32_to_utf8();

View File

@ -36,6 +36,8 @@ main(void)
{ {
char buffer[10]; char buffer[10];
test_init();
assert(!snprintf_safe(buffer, 0, "foo")); assert(!snprintf_safe(buffer, 0, "foo"));
assert(!snprintf_safe(buffer, 1, "foo")); assert(!snprintf_safe(buffer, 1, "foo"));
assert(!snprintf_safe(buffer, 3, "foo")); assert(!snprintf_safe(buffer, 3, "foo"));

View File

@ -86,5 +86,7 @@ err_conn:
} }
int main(void) { int main(void) {
test_init();
return x11_tests_run(); return x11_tests_run();
} }

View File

@ -117,5 +117,7 @@ err_conn:
} }
int main(void) { int main(void) {
test_init();
return x11_tests_run(); return x11_tests_run();
} }

View File

@ -53,6 +53,7 @@ struct keyboard {
struct keyboard *next; struct keyboard *next;
}; };
static bool verbose = false;
static bool terminate; static bool terminate;
static int evdev_offset = 8; static int evdev_offset = 8;
static bool report_state_changes; static bool report_state_changes;
@ -383,6 +384,7 @@ usage(FILE *fp, char *progname)
fprintf(fp, " or: %s --keymap <path to keymap file>\n", fprintf(fp, " or: %s --keymap <path to keymap file>\n",
progname); progname);
fprintf(fp, "For both:\n" fprintf(fp, "For both:\n"
" --verbose (enable verbose debugging output)\n"
#ifdef ENABLE_PRIVATE_APIS #ifdef ENABLE_PRIVATE_APIS
" --print-modmaps (print real & virtual key modmaps)\n" " --print-modmaps (print real & virtual key modmaps)\n"
#endif #endif
@ -415,6 +417,7 @@ main(int argc, char *argv[])
const char *locale; const char *locale;
struct sigaction act; struct sigaction act;
enum options { enum options {
OPT_VERBOSE,
OPT_INCLUDE, OPT_INCLUDE,
OPT_INCLUDE_DEFAULTS, OPT_INCLUDE_DEFAULTS,
OPT_RULES, OPT_RULES,
@ -434,6 +437,7 @@ main(int argc, char *argv[])
}; };
static struct option opts[] = { static struct option opts[] = {
{"help", no_argument, 0, 'h'}, {"help", no_argument, 0, 'h'},
{"verbose", no_argument, 0, OPT_VERBOSE},
{"include", required_argument, 0, OPT_INCLUDE}, {"include", required_argument, 0, OPT_INCLUDE},
{"include-defaults", no_argument, 0, OPT_INCLUDE_DEFAULTS}, {"include-defaults", no_argument, 0, OPT_INCLUDE_DEFAULTS},
{"rules", required_argument, 0, OPT_RULES}, {"rules", required_argument, 0, OPT_RULES},
@ -464,6 +468,9 @@ main(int argc, char *argv[])
break; break;
switch (opt) { switch (opt) {
case OPT_VERBOSE:
verbose = true;
break;
case OPT_INCLUDE: case OPT_INCLUDE:
if (num_includes >= ARRAY_SIZE(includes)) { if (num_includes >= ARRAY_SIZE(includes)) {
fprintf(stderr, "error: too many includes\n"); fprintf(stderr, "error: too many includes\n");
@ -539,6 +546,11 @@ main(int argc, char *argv[])
goto out; goto out;
} }
if (verbose) {
xkb_context_set_log_level(ctx, XKB_LOG_LEVEL_DEBUG);
xkb_context_set_log_verbosity(ctx, 10);
}
if (num_includes == 0) if (num_includes == 0)
includes[num_includes++] = DEFAULT_INCLUDE_PATH_PLACEHOLDER; includes[num_includes++] = DEFAULT_INCLUDE_PATH_PLACEHOLDER;

View File

@ -146,7 +146,7 @@ print_keys_modmaps(struct xkb_keymap *keymap) {
#endif #endif
void void
tools_print_keycode_state(char *prefix, tools_print_keycode_state(const char *prefix,
struct xkb_state *state, struct xkb_state *state,
struct xkb_compose_state *compose_state, struct xkb_compose_state *compose_state,
xkb_keycode_t keycode, xkb_keycode_t keycode,

View File

@ -61,7 +61,7 @@ print_keys_modmaps(struct xkb_keymap *keymap);
#endif #endif
void void
tools_print_keycode_state(char *prefix, tools_print_keycode_state(const char *prefix,
struct xkb_state *state, struct xkb_state *state,
struct xkb_compose_state *compose_state, struct xkb_compose_state *compose_state,
xkb_keycode_t keycode, xkb_keycode_t keycode,