From: "ruippan(潘睿)" <ruippan@tencent.com>
To: "kraxel@redhat.com" <kraxel@redhat.com>
Cc: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Subject: ui: fix potential compile error.
Date: Wed, 2 Sep 2020 03:04:24 +0000 [thread overview]
Message-ID: <370e6ed66acf43e68f1ef2bffc3026f7@tencent.com> (raw)
[-- Attachment #1.1: Type: text/plain, Size: 629 bytes --]
We compiled the upstream qemu and result in this GEN code error:
‘’’
GEN ui/input-keymap-atset1-to-qcode.c
usage: keymap-gen [-h]
{code-map,code-table,name-map,name-table,code-docs,name-docs}
...
keymap-gen: error: invalid choice: 'glib2' (choose from 'code-map', 'code-table', 'name-map', 'name-table', 'code-docs', 'name-docs')
‘’’
My environment:
1. CentOS7 with Python 2.7.5
2. upstream's keycodemapdb
3. argparse 1.1
Root cause is my argparse and python version. But change the invoking order can adapt both new and old argparse.
Thanks.
[-- Attachment #1.2: Type: text/html, Size: 6333 bytes --]
[-- Attachment #2: 0001-ui-fix-potential-compile-error.patch --]
[-- Type: application/octet-stream, Size: 1350 bytes --]
From 7f262b160d57559bace1f877f74b1c4e5a872b41 Mon Sep 17 00:00:00 2001
From: ruippan <ruippan@tencent.com>
Date: Wed, 2 Sep 2020 10:40:29 +0800
Subject: [PATCH] ui: fix potential compile error.
Fix code GEN error with info "keymap-gen: error: invalid choice: 'glib2'".
Compile environment:
1. CentOS7 with Python 2.7.5
2. upstream's keycodemapdb
3. argparse 1.1
Change arg order to adapt old version of argparse.
Signed-off-by: ruippan <ruippan@tencent.com>
---
ui/meson.build | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/ui/meson.build b/ui/meson.build
index 962e776569..47e139903b 100644
--- a/ui/meson.build
+++ b/ui/meson.build
@@ -105,9 +105,9 @@ if have_system or xkbcommon.found()
capture: true,
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]])
+ 'code-map', '@INPUT0@', e[0], e[1],
+ '--lang', 'glib2',
+ '--varname', 'qemu_input_map_@0@_to_@1@'.format(e[0], e[1])])
endforeach
endif
--
2.19.1
next reply other threads:[~2020-09-02 5:03 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-02 3:04 ruippan(潘睿) [this message]
2020-09-02 5:23 ` ui: fix potential compile error kraxel
2020-09-02 8:17 ` Daniel P. Berrangé
2020-09-02 10:12 ` Thomas Huth
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=370e6ed66acf43e68f1ef2bffc3026f7@tencent.com \
--to=ruippan@tencent.com \
--cc=kraxel@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).