xserver-nodm-init: set USER and HOME

* when it's executed from init then HOME is set to '/'
* shadow/agetty set HOME fine and Xinit is doing the same, but for xinit Xsession it didn't work

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
This commit is contained in:
Martin Jansa 2011-10-21 17:22:59 +02:00 committed by Koen Kooi
parent e10965933f
commit 7206edddeb
2 changed files with 8 additions and 1 deletions

View File

@ -17,6 +17,13 @@ case "$1" in
if [ "$2" != "background" ]; then
$0 $1 background &
else
# work around from /etc/X11/Xinit
export USER=root
export HOME=/home/root
if [ ! -d $HOME ] && [ -d /root ]; then
HOME=/root
fi
. /etc/profile
echo "Starting Xserver"

View File

@ -3,7 +3,7 @@ LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
SECTION = "x11"
PR = "r10"
PR = "r11"
SRC_URI = "file://xserver-nodm \
file://xserver-nodm.service \