aboutsummaryrefslogtreecommitdiff
path: root/ui
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2019-07-15 16:00:36 +0400
committerPaolo Bonzini <pbonzini@redhat.com>2020-08-21 06:30:13 -0400
commit2d78b56e7abe327fc411d4c96ce0b3cffc0d9282 (patch)
treea22f7537b17f255cb04f0cf3a34f519cf2a2813b /ui
parentec0d5893da20a5f35dcbd901d98be24346bf9cc2 (diff)
downloadqemu-2d78b56e7abe327fc411d4c96ce0b3cffc0d9282.zip
qemu-2d78b56e7abe327fc411d4c96ce0b3cffc0d9282.tar.gz
qemu-2d78b56e7abe327fc411d4c96ce0b3cffc0d9282.tar.bz2
meson: keymap-gen
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'ui')
-rw-r--r--ui/meson.build34
1 files changed, 34 insertions, 0 deletions
diff --git a/ui/meson.build b/ui/meson.build
new file mode 100644
index 0000000..a6aa7f2
--- /dev/null
+++ b/ui/meson.build
@@ -0,0 +1,34 @@
+keymaps = [
+ ['atset1', 'qcode'],
+ ['linux', 'qcode'],
+ ['qcode', 'atset1'],
+ ['qcode', 'atset2'],
+ ['qcode', 'atset3'],
+ ['qcode', 'linux'],
+ ['qcode', 'qnum'],
+ ['qcode', 'sun'],
+ ['qnum', 'qcode'],
+ ['usb', 'qcode'],
+ ['win32', 'qcode'],
+ ['x11', 'qcode'],
+ ['xorgevdev', 'qcode'],
+ ['xorgkbd', 'qcode'],
+ ['xorgxquartz', 'qcode'],
+ ['xorgxwin', 'qcode'],
+ ['osx', 'qcode'],
+]
+
+if have_system
+ foreach e : keymaps
+ output = 'input-keymap-@0@-to-@1@.c.inc'.format(e[0], e[1])
+ genh += custom_target(output,
+ output: output,
+ capture: true,
+ build_by_default: true, # to be removed when added to a target
+ input: files('keycodemapdb/data/keymaps.csv'),
+ command: [python.full_path(), files('keycodemapdb/tools/keymap-gen'),
+ '--lang', 'glib2',
+ '--varname', 'qemu_input_map_@0@_to_@1@'.format(e[0], e[1]),
+ 'code-map', '@INPUT0@', e[0], e[1]])
+ endforeach
+endif