Skip to contentSkip to conversation

X apps: some bug fix, Dec12, 2010

PATCH In review Zhai Edwin 2 participants 5 messages Dec 22, 2010 – Jan 6, 2011

lore
Share & tools
lore

Zhai Edwin

author
#0 lore raw

cover X apps: some bug fix, Dec12, 2010

Saul/RP,
These are fixes for bug 509&599. Pls. have a look then pull.

Thanks,
edwin

Pull URL: git://git.pokylinux.org/poky-contrib.git
Branch: gzhai/distro06
Browse: http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=gzhai/distro06

Thanks,
Zhai Edwin <[email protected]>
---

Zhai Edwin (3):
matchbox-keyboard: Make as singleton
matchbox-stroke: Make as singleton
qemu: Add some checks before enabling KVM

 .../matchbox-keyboard/files/single-instance.patch  |   22 +++++++++++++++++
 .../matchbox-keyboard/matchbox-keyboard_svn.bb     |    1 +
 .../matchbox-stroke/files/single-instance.patch    |   19 +++++++++++++++
 .../matchbox-stroke/matchbox-stroke_svn.bb         |    1 +
 scripts/poky-qemu                                  |   25 +++++++++++++++++--
 5 files changed, 65 insertions(+), 3 deletions(-)
 create mode 100644 meta/recipes-sato/matchbox-keyboard/files/single-instance.patch
 create mode 100644 meta/recipes-sato/matchbox-stroke/files/single-instance.patch
author
#1 lore raw

PATCH 1/3 matchbox-keyboard: Make as singleton

Multiple matchbox-keyboard instances would occupy whole screen and cause X window segfault. Making matchbox-keyboard singleton is one work around.

This patch allow only one instance of matchbox-keyboard based on some mechanism in matchbox-desktop. In future, an applet and GTK-IM modules in matchbox-keyboard can be used to automatically map/unmap the virtual keyboard on demand.

[BUGID #509] got fixed.

---
 .../matchbox-keyboard/files/single-instance.patch  |   22 ++++++++++++++++++++
 .../matchbox-keyboard/matchbox-keyboard_svn.bb     |    1 +
 2 files changed, 23 insertions(+), 0 deletions(-)
 create mode 100644 meta/recipes-sato/matchbox-keyboard/files/single-instance.patch
meta/recipes-sato/matchbox-keyboard/files/single-instance.patch new file +22 -0
new file mode 100644
index 0000000..d0adc47
@@ -0,0 +1,22 @@
+Multiple matchbox-keyboard instances would occupy whole screen and cause X
+window segfault(Bug 509). Making matchbox-keyboard singleton is one work
+around.
+
+This patch allow only one instance of matchbox-keyboard based on some mechanism
+in matchbox-desktop. In future, an applet and GTK-IM modules in
+matchbox-keyboard can be used to automatically map/unmap the virtual keyboard
+on demand.
+
+Signed-off-by: Zhai Edwin <[email protected]>
+
+
+Index: matchbox-keyboard/matchbox-keyboard.desktop
+===================================================================
+--- matchbox-keyboard.orig/matchbox-keyboard.desktop	2010-12-22 20:41:40.000000000 +0800
++++ matchbox-keyboard/matchbox-keyboard.desktop	2010-12-22 20:42:12.000000000 +0800
+@@ -6,3 +6,5 @@
+ Icon=matchbox-keyboard.png
+ Categories=Panel;Utility;MB
+ X-MB-INPUT-MECHANSIM=True
++X-MB-SingleInstance=true
++StartupNotify=true
meta/recipes-sato/matchbox-keyboard/matchbox-keyboard_svn.bb +1 -0
index 0425fec..337738e 100644
@@ -15,6 +15,7 @@ PR = "r4"
 
 SRC_URI = "svn://svn.o-hand.com/repos/matchbox/trunk;module=${PN};proto=http \
            file://configure_fix.patch;patch=1;maxrev=1819 \
+           file://single-instance.patch;patch=1 \
 	   file://80matchboxkeyboard.shbg"
 
 S = "${WORKDIR}/${PN}"
Signature · 1 line
1.7.0.4
author
#2 lore raw

PATCH 2/3 matchbox-stroke: Make as singleton

In reply to Zhai Edwin

Multiple matchbox-stroke instances would occupy whole screen and cause end user confusing. Making matchbox-stroke singleton is one work around.

This patch allow only one instance of matchbox-stroke based on some mechanism in matchbox-desktop.

---
 .../matchbox-stroke/files/single-instance.patch    |   19 +++++++++++++++++++
 .../matchbox-stroke/matchbox-stroke_svn.bb         |    1 +
 2 files changed, 20 insertions(+), 0 deletions(-)
 create mode 100644 meta/recipes-sato/matchbox-stroke/files/single-instance.patch
meta/recipes-sato/matchbox-stroke/files/single-instance.patch new file +19 -0
new file mode 100644
index 0000000..f4fec07
@@ -0,0 +1,19 @@
+Multiple matchbox-stroke instances would occupy whole screen and cause end user
+confusing. Making matchbox-stroke singleton is one work around.
+
+This patch allow only one instance of matchbox-stroke based on some mechanism
+in matchbox-desktop.
+
+Signed-off-by: Zhai Edwin <[email protected]>
+
+
+Index: matchbox-stroke/matchbox-stroke.desktop
+===================================================================
+--- matchbox-stroke.orig/matchbox-stroke.desktop	2010-07-10 10:23:26.000000000 +0800
++++ matchbox-stroke/matchbox-stroke.desktop	2010-12-22 20:59:26.000000000 +0800
+@@ -6,3 +6,5 @@
+ Icon=matchbox-stroke.png
+ Categories=Panel;Utility;MB
+ X-MB-INPUT-MECHANSIM=True
++X-MB-SingleInstance=true
++StartupNotify=true
meta/recipes-sato/matchbox-stroke/matchbox-stroke_svn.bb +1 -0
index 1e25369..b0e77ac 100644
@@ -10,6 +10,7 @@ SECTION = "x11/wm"
 PV = "0.0+svnr${SRCREV}"
 
 SRC_URI = "svn://svn.o-hand.com/repos/matchbox/trunk;module=${PN};proto=http \
+           file://single-instance.patch;patch=1 \
            file://configure_fix.patch;patch=1;maxrev=1819 "
 
 S = "${WORKDIR}/${PN}"
Signature · 1 line
1.7.0.4
author
#3 lore raw

PATCH 3/3 qemu: Add some checks before enabling KVM

In reply to Zhai Edwin

Check the missing modules and permission with informative output.

[BUGID #599] got fixed.

---
 scripts/poky-qemu |   25 ++++++++++++++++++++++---
 1 files changed, 22 insertions(+), 3 deletions(-)
scripts/poky-qemu +22 -3
index 313248f..b19a89d 100755
@@ -29,7 +29,7 @@ usage() {
     echo "  Additional QEMU command-line options can be passed with:"
     echo "    nographic - disables video console"
     echo "    serial - enables a serial console on /dev/ttyS0"
-    echo "    kvm - enables kvm"
+    echo "    kvm - enables KVM when running qemux86/qemux86-64, VT capable CPU required"
     echo "    \"<extra-qemu-options>\" - enables extra qemu options, excluding serial and kvm"
     echo ""
     echo "Examples:"
@@ -171,10 +171,29 @@ while [ $i -le $# ]; do
     i=$((i + 1))
 done
 
+POKY_KVM_WIKI="https://wiki.yoctoproject.org/wiki/How_to_enable_KVM_for_Poky_qemu"
 # Detect KVM configuration
-if [[ "x$KVM_ENABLED" == "xyes" && ! -z "$KVM_CAPABLE" ]]; then
-    if [[ "x$MACHINE" == "xqemux86" || "x$MACHINE" == "xqemux86-64" ]]; then
+if [[ "x$KVM_ENABLED" == "xyes" ]]; then
+    if [[ -z "$KVM_CAPABLE" ]]; then
+        echo "You are tring to enable KVM on cpu without VT support. Remove kvm from the command-line, or refer";
+        echo "$POKY_KVM_WIKI";
+        exit 1;
+    fi
+    if [[ "x$MACHINE" != "xqemux86" && "x$MACHINE" != "xqemux86-64" ]]; then
+        echo "KVM only support x86 & x86-64. Remove kvm from the command-line";
+        exit 1;
+    fi
+    if [ ! -e /dev/kvm ]; then
+        echo "Missing KVM device. Have you inserted kvm modules? Pls. refer";
+        echo "$POKY_KVM_WIKI";
+        exit 1;
+    fi
+    if 9<>/dev/kvm ; then
         SCRIPT_QEMU_OPT="$SCRIPT_QEMU_OPT -enable-kvm"
+    else
+        echo "You have no rights on /dev/kvm. Pls. change the owndership as described at";
+        echo "$POKY_KVM_WIKI";
+        exit 1;
     fi
 fi
 
Signature · 1 line
1.7.0.4
#4 lore raw
In reply to Zhai Edwin
Quoted 26 lines · Zhai Edwin

Saul/RP,
These are fixes for bug 509&599. Pls. have a look then pull.

Thanks,
edwin

Pull URL: git://git.pokylinux.org/poky-contrib.git
Branch: gzhai/distro06
Browse: http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=gzhai/distro06

Thanks,
Zhai Edwin<[email protected]>
---

Zhai Edwin (3):
matchbox-keyboard: Make as singleton
matchbox-stroke: Make as singleton
qemu: Add some checks before enabling KVM

  .../matchbox-keyboard/files/single-instance.patch  |   22 +++++++++++++++++
  .../matchbox-keyboard/matchbox-keyboard_svn.bb     |    1 +
  .../matchbox-stroke/files/single-instance.patch    |   19 +++++++++++++++
  .../matchbox-stroke/matchbox-stroke_svn.bb         |    1 +
  scripts/poky-qemu                                  |   25 +++++++++++++++++--
  5 files changed, 65 insertions(+), 3 deletions(-)
Quoted 8 lines

create mode 100644 meta/recipes-sato/matchbox-keyboard/files/single-instance.patch create mode 100644 meta/recipes-sato/matchbox-stroke/files/single-instance.patch

_______________________________________________
poky mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/poky

Pulled into Master

Thanks, Sau!