]> code.ossystems Code Review - openembedded-core.git/commitdiff
xserver-nodm-init: option to remove cursor
authorTrevor Woerner <twoerner@gmail.com>
Sat, 25 Mar 2017 05:19:47 +0000 (01:19 -0400)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sat, 25 Mar 2017 10:56:32 +0000 (10:56 +0000)
Add a PACKAGECONFIG option to allow the user to disable the mouse
cursor/pointer in the X server. This might be useful where a
touchscreen is used.

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-graphics/x11-common/xserver-nodm-init/xserver-nodm.conf.in
meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb

index 757c23d95a6905542dfe2d34899b693d70efc0e8..4a9670d8d23ccde006ead83724ef4bfb2e493d85 100644 (file)
@@ -2,6 +2,6 @@
 
 XSERVER=/usr/bin/Xorg
 DISPLAY=:0
-ARGS=" -br -pn @BLANK_ARGS@ "
+ARGS=" -br -pn @BLANK_ARGS@ @NO_CURSOR_ARG@ "
 HOME=@HOME@
 USER=@USER@
index 62da11800c2607e53ee147589987175c5f455178..345b58969696c43a716f9161ace721c700f36f1a 100644 (file)
@@ -24,6 +24,7 @@ REQUIRED_DISTRO_FEATURES = "x11"
 PACKAGECONFIG ??= "blank"
 # dpms and screen saver will be on only if 'blank' is in PACKAGECONFIG
 PACKAGECONFIG[blank] = ""
+PACKAGECONFIG[nocursor] = ""
 
 do_install() {
     install -d ${D}${sysconfdir}/default
@@ -35,6 +36,7 @@ do_install() {
     install X11/Xsession ${D}${sysconfdir}/X11/
 
     BLANK_ARGS="${@bb.utils.contains('PACKAGECONFIG', 'blank', '', '-s 0 -dpms', d)}"
+    NO_CURSOR_ARG="${@bb.utils.contains('PACKAGECONFIG', 'nocursor', '-nocursor', '', d)}"
     if [ "${ROOTLESS_X}" = "1" ] ; then
         XUSER_HOME="/home/xuser"
         XUSER="xuser"
@@ -44,6 +46,7 @@ do_install() {
     fi
     sed -i "s:@HOME@:${XUSER_HOME}:; s:@USER@:${XUSER}:; s:@BLANK_ARGS@:${BLANK_ARGS}:" \
         ${D}${sysconfdir}/default/xserver-nodm
+    sed -i "s:@NO_CURSOR_ARG@:${NO_CURSOR_ARG}:" ${D}${sysconfdir}/default/xserver-nodm
 
     if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
         install -d ${D}${systemd_unitdir}/system