diff mbox series

weston-init: Let weston run without pam on distros without pam

Message ID 20200109183753.2696071-1-raj.khem@gmail.com
State New
Headers show
Series weston-init: Let weston run without pam on distros without pam | expand

Commit Message

Khem Raj Jan. 9, 2020, 6:37 p.m. UTC
When pam is not part of distro, user specific XDG_* environment
variables are not available since PAMName=login is in-effective and as a
result weston can not start because it direly needs XDG_RUNTIME_DIR
defined, therefore launching weston directly in systemd service will not
work, therefore call the helper script weston-start, which is also used
with sysvinit

extend enabling fbdev backend fallback to all qemu machines

Reported-by: Marek Vasut <marex@denx.de>
Signed-off-by: Khem Raj <raj.khem@gmail.com>

---
 .../{qemux86-64 => qemuall}/weston.ini        |  0
 .../wayland/weston-init/qemux86/weston.ini    |  2 --
 .../wayland/weston-init/weston@.service       | 34 ++++---------------
 3 files changed, 6 insertions(+), 30 deletions(-)
 rename meta/recipes-graphics/wayland/weston-init/{qemux86-64 => qemuall}/weston.ini (100%)
 delete mode 100644 meta/recipes-graphics/wayland/weston-init/qemux86/weston.ini

-- 
2.24.1

-- 
_______________________________________________
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core

Comments

Marek Vasut Jan. 10, 2020, 12:30 a.m. UTC | #1
On 1/9/20 7:37 PM, Khem Raj wrote:
> When pam is not part of distro, user specific XDG_* environment

> variables are not available since PAMName=login is in-effective and as a

> result weston can not start because it direly needs XDG_RUNTIME_DIR

> defined, therefore launching weston directly in systemd service will not

> work, therefore call the helper script weston-start, which is also used

> with sysvinit

> 

> extend enabling fbdev backend fallback to all qemu machines


Looks good to me, thanks !
-- 
_______________________________________________
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core
diff mbox series

Patch

diff --git a/meta/recipes-graphics/wayland/weston-init/qemux86-64/weston.ini b/meta/recipes-graphics/wayland/weston-init/qemuall/weston.ini
similarity index 100%
rename from meta/recipes-graphics/wayland/weston-init/qemux86-64/weston.ini
rename to meta/recipes-graphics/wayland/weston-init/qemuall/weston.ini
diff --git a/meta/recipes-graphics/wayland/weston-init/qemux86/weston.ini b/meta/recipes-graphics/wayland/weston-init/qemux86/weston.ini
deleted file mode 100644
index 17ebd7fdab..0000000000
--- a/meta/recipes-graphics/wayland/weston-init/qemux86/weston.ini
+++ /dev/null
@@ -1,2 +0,0 @@ 
-[core]
-backend=fbdev-backend.so
diff --git a/meta/recipes-graphics/wayland/weston-init/weston@.service b/meta/recipes-graphics/wayland/weston-init/weston@.service
index 9ecf2ab069..39e193014a 100644
--- a/meta/recipes-graphics/wayland/weston-init/weston@.service
+++ b/meta/recipes-graphics/wayland/weston-init/weston@.service
@@ -1,37 +1,15 @@ 
 [Unit]
-Description=Weston Wayland Compositor (on tty7)
+Description=Weston Wayland Compositor
 RequiresMountsFor=/run
-Conflicts=getty@tty7.service plymouth-quit.service
-After=systemd-user-sessions.service getty@tty7.service plymouth-quit-wait.service
+Conflicts=plymouth-quit.service
+After=systemd-user-sessions.service plymouth-quit-wait.service
 
 [Service]
 User=%i
-PermissionsStartOnly=true
-
-# Log us in via PAM so we get our XDG & co. environment and
-# are treated as logged in so we can use the tty:
 PAMName=login
-
-# Grab tty7
-UtmpIdentifier=tty7
-TTYPath=/dev/tty7
-TTYReset=yes
-TTYVHangup=yes
-TTYVTDisallocate=yes
-
-# stderr to journal so our logging doesn't get thrown into /dev/null
-StandardOutput=tty
-StandardInput=tty
-StandardError=journal
-
 EnvironmentFile=-/etc/default/weston
-
-# Weston does not successfully change VT, nor does systemd place us on
-# the VT it just activated for us. Switch manually:
-ExecStartPre=/usr/bin/chvt 7
-ExecStart=/usr/bin/weston --log=${XDG_RUNTIME_DIR}/weston.log $OPTARGS
-
+StandardError=journal
+PermissionsStartOnly=true
 IgnoreSIGPIPE=no
 
-#[Install]
-#Alias=multi-user.target.wants/weston.service
+ExecStart=/usr/bin/weston-start -v -e -- $OPTARGS