+FILESEXTRAPATHS_append := "${THISDIR}/user-session-units"
+
+SRC_URI += "file://0001-Modify-user-session-.service-for-the-yocto-build.patch"
+
do_install_append() {
rm -f ${D}/lib/systemd/user/dbus.socket
- mkdir -p ${D}/lib/systemd/system/multi-user-target.wants
+ mkdir -p ${D}/lib/systemd/system/multi-user.target.wants
- ln -sf ${D}/lib/systemd/system/user-session-launch@.service ${D}/lib/systemd/system/multi-user-target.wants/user-session-launch@5001.service
- ln -sf ${D}/lib/systemd/system/user-session-launch@.service ${D}/lib/systemd/system/multi-user-target.wants/user-session-launch@5002.service
- ln -sf ${D}/lib/systemd/system/user-session-launch@.service ${D}/lib/systemd/system/multi-user-target.wants/user-session-launch@5003.service
- ln -sf ${D}/lib/systemd/system/user-session-launch@.service ${D}/lib/systemd/system/multi-user-target.wants/user-session-launch@9999.service
-
- ln -sf ${D}/lib/systemd/system/user-session@.service ${D}/lib/systemd/system/multi-user-target.wants/user-session@5001.service
- ln -sf ${D}/lib/systemd/system/user-session@.service ${D}/lib/systemd/system/multi-user-target.wants/user-session@5002.service
- ln -sf ${D}/lib/systemd/system/user-session@.service ${D}/lib/systemd/system/multi-user-target.wants/user-session@5003.service
- ln -sf ${D}/lib/systemd/system/user-session@.service ${D}/lib/systemd/system/multi-user-target.wants/user-session@9999.service
+ ln -sf ../user-session-launch@.service ${D}/lib/systemd/system/multi-user.target.wants/user-session-launch@seat0-5001.service
+ ln -sf ../user-session-launch@.service ${D}/lib/systemd/system/multi-user.target.wants/user-session-launch@seat0-5002.service
+ ln -sf ../user-session-launch@.service ${D}/lib/systemd/system/multi-user.target.wants/user-session-launch@seat0-5003.service
+ ln -sf ../user-session-launch@.service ${D}/lib/systemd/system/multi-user.target.wants/user-session-launch@seat0-9999.service
- mkdir -p ${D}/lib/systemd/user/default.target.wants
+ ln -sf ../user-session@.service ${D}/lib/systemd/system/multi-user.target.wants/user-session@5001.service
+ ln -sf ../user-session@.service ${D}/lib/systemd/system/multi-user.target.wants/user-session@5002.service
+ ln -sf ../user-session@.service ${D}/lib/systemd/system/multi-user.target.wants/user-session@5003.service
+ ln -sf ../user-session@.service ${D}/lib/systemd/system/multi-user.target.wants/user-session@9999.service
echo "[Unit]" > ${D}/lib/systemd/user/default.target
echo "Description=User session default target" >> ${D}/lib/systemd/user/default.target
- ln -sf ${D}/lib/systemd/user/weston-user.service ${D}/lib/systemd/user/default.target.wants/weston-user.service
-
- ln -sf ${D}/lib/systemd/user/dbus.service ${D}/lib/systemd/user/default.target.wants/dbus.service
+ mkdir -p ${D}/lib/systemd/user/default.target.wants
+ ln -sf ../dbus.service ${D}/lib/systemd/user/default.target.wants/dbus.service
+ rm ${D}/lib/systemd/user/dbus.service
}
user-session-units_files += "/lib/systemd/user/*"
--- /dev/null
+From 09231101a7e21627c3d09a8e4bda9286d1a8e90e Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?K=C3=A9vin=20THIERRY?= <kevin.thierry@open.eurogiciel.org>
+Date: Wed, 28 May 2014 21:07:40 +0200
+Subject: [PATCH] meta-tizen: Modify user-session@.service for the yocto build
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Signed-off-by: Kévin THIERRY <kevin.thierry@open.eurogiciel.org>
+---
+ units/system/user-session@.service.in | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+diff --git a/units/system/user-session@.service.in b/units/system/user-session@.service.in
+index 626d425..2d32433 100644
+--- a/units/system/user-session@.service.in
++++ b/units/system/user-session@.service.in
+@@ -15,15 +15,13 @@ Conflicts=getty@tty1.service
+ User=%I
+ PAMName=user-session
+ # Note memory:/ required kernel memory CGroups support
+-ControlGroup=%R/user/%u/shared cpu:/ memory:/
+-ControlGroupModify=yes
+ Type=notify
+ StandardInput=tty
+ TTYPath=/dev/tty1
+ ExecStart=-@SYSTEMDUTILDIR@/systemd --user
+ Environment=DISPLAY=:0
+ Environment=XDG_RUNTIME_DIR=/run/user/%U
+-Environment=DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/%U/dbus/user_bus_socket
++Environment=DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/%I/dbus/user_bus_socket
+
+ [Install]
+ Alias=user-session@%i.service
+--
+1.8.1.4
+