1 FILESEXTRAPATHS_append := "${THISDIR}/weston-common"
3 SRC_URI += "file://0001-Yocto-correct-paths-to-ln-and-chmod.patch"
4 SRC_URI += "file://0002-Add-a-script-to-export-UID.patch"
6 DEPENDS += "config-tizen-common"
7 RDEPENDS_${PN} += "config-tizen-common"
11 USERADD_PACKAGES = "${PN}"
12 GROUPADD_PARAM_${PN} += "--system display;"
13 GROUPADD_PARAM_${PN} += "--system input;"
14 GROUPADD_PARAM_${PN} += "--system weston-launch"
17 install -m 755 uid.sh ${D}/etc/profile.d
19 mkdir -p ${D}${prefix}/lib/systemd/user/default.target.requires
20 ln -sf ../weston-user.service ${D}${prefix}/lib/systemd/user/default.target.requires/weston-user.service
22 mkdir -p ${D}/lib/systemd/system/graphical.target.wants
23 ln -sf ../user-session-launch@.service ${D}/lib/systemd/system/graphical.target.wants/user-session-launch@seat0-5001.service
24 ln -sf ../user-session-launch@.service ${D}/lib/systemd/system/graphical.target.wants/user-session-launch@seat0-5002.service
25 ln -sf ../user-session-launch@.service ${D}/lib/systemd/system/graphical.target.wants/user-session-launch@seat0-5003.service
26 ln -sf ../user-session-launch@.service ${D}/lib/systemd/system/graphical.target.wants/user-session-launch@seat0-9999.service
28 mkdir -p ${D}${systemd_unitdir}/system/multi-user.target.wants
29 ln -sf ../systemd-udev-settle.service ${D}${systemd_unitdir}/system/multi-user.target.wants/systemd-udev-settle.service
35 # setup display manager service
36 mkdir -p $D${systemd_unitdir}/system/graphical.target.wants/
37 ln -sf ../display-manager.path $D${systemd_unitdir}/system/graphical.target.wants/
38 # setup display manager access (inside user session)
39 mkdir -p $D${prefix}/lib/systemd/user/default.target.requires/
40 ln -sf ../weston-user.service $D${prefix}/lib/systemd/user/default.target.requires/
44 pkg_postinst_${PN} () {
45 for user in alice bob carol guest; do
46 for appdir in desktop manifest dbspace; do
47 mkdir -p $D/home/$user/.applications/$appdir
49 find $D/home/$user/ -type d -exec chsmack -a User {} \;
50 chown -R $user:users $D/home/$user/
53 SERVICE_PATH=$D/lib/systemd/system/user-session-launch@.service
54 grep -q display-manager.path $SERVICE_PATH || sed -i 's@systemd-logind.service@systemd-logind.service display-manager.path@g' $SERVICE_PATH
57 weston-common_files += "${prefix}/lib/systemd/user/default.target.requires/weston-user.service/*"
58 weston-common_files += "/home/*"
60 FILES_${PN} += "/lib/systemd/system/graphical.target.wants/user-session-launch@seat0-5001.service"
61 FILES_${PN} += "/lib/systemd/system/graphical.target.wants/user-session-launch@seat0-5002.service"
62 FILES_${PN} += "/lib/systemd/system/graphical.target.wants/user-session-launch@seat0-5003.service"
63 FILES_${PN} += "/lib/systemd/system/graphical.target.wants/user-session-launch@seat0-9999.service"
64 FILES_${PN} += "/lib/systemd/system/graphical.target.wants/user-session@5001.service"
65 FILES_${PN} += "/lib/systemd/system/graphical.target.wants/user-session@5002.service"
66 FILES_${PN} += "/lib/systemd/system/graphical.target.wants/user-session@5003.service"
67 FILES_${PN} += "/lib/systemd/system/graphical.target.wants/user-session@9999.service"