summaryrefslogtreecommitdiffstats
path: root/meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb
diff options
context:
space:
mode:
authorJussi Kukkonen <jussi.kukkonen@intel.com>2016-11-15 13:41:57 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-11-30 15:48:05 +0000
commitc63811fa5b28b34edf3b34cdcc68b364dacbaa1b (patch)
tree7cec349f4f1768112e445beb6edbc38f56d496a3 /meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb
parent8a81facc23fd54b095940372e05de2356579c97c (diff)
downloadpoky-c63811fa5b28b34edf3b34cdcc68b364dacbaa1b.tar.gz
xserver-nodm-init: Bump PV to ensure upgrade from 2.0
meta-oe provides a 2.0 version of this recipe, but this one now does everything the meta-oe version does. There's one exception though: xserver-common is not a runtime dependency. This needs to be added elsewhere for the platforms that require it. (From OE-Core rev: bf6fd144b6f3539009089df5f188d09c7c899140) Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb')
-rw-r--r--meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb61
1 files changed, 61 insertions, 0 deletions
diff --git a/meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb b/meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb
new file mode 100644
index 0000000000..a6d0d5eeea
--- /dev/null
+++ b/meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb
@@ -0,0 +1,61 @@
1SUMMARY = "Simple Xserver Init Script (no dm)"
2LICENSE = "GPLv2"
3LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
4SECTION = "x11"
5PR = "r31"
6
7SRC_URI = "file://xserver-nodm \
8 file://Xserver \
9 file://gplv2-license.patch \
10 file://xserver-nodm.service.in \
11 file://xserver-nodm.conf.in \
12"
13
14S = "${WORKDIR}"
15
16# Since we refer to ROOTLESS_X which is normally enabled per-machine
17PACKAGE_ARCH = "${MACHINE_ARCH}"
18
19inherit update-rc.d systemd distro_features_check
20
21REQUIRED_DISTRO_FEATURES = "x11"
22
23PACKAGECONFIG ??= "blank"
24# dpms and screen saver will be on only if 'blank' is in PACKAGECONFIG
25PACKAGECONFIG[blank] = ""
26
27do_install() {
28 install -d ${D}${sysconfdir}/default
29 install xserver-nodm.conf.in ${D}${sysconfdir}/default/xserver-nodm
30 install -d ${D}${sysconfdir}/xserver-nodm
31 install Xserver ${D}${sysconfdir}/xserver-nodm/Xserver
32
33 BLANK_ARGS="${@bb.utils.contains('PACKAGECONFIG', 'blank', '', '-s 0 -dpms', d)}"
34 if [ "${ROOTLESS_X}" = "1" ] ; then
35 XUSER_HOME="/home/xuser"
36 XUSER="xuser"
37 else
38 XUSER_HOME=${ROOT_HOME}
39 XUSER="root"
40 fi
41 sed -i "s:@HOME@:${XUSER_HOME}:; s:@USER@:${XUSER}:; s:@BLANK_ARGS@:${BLANK_ARGS}:" \
42 ${D}${sysconfdir}/default/xserver-nodm
43
44 if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
45 install -d ${D}${systemd_unitdir}/system
46 install -m 0644 ${WORKDIR}/xserver-nodm.service.in ${D}${systemd_unitdir}/system/xserver-nodm.service
47 sed -i "s:@USER@:${XUSER}:" ${D}${systemd_unitdir}/system/xserver-nodm.service
48 fi
49
50 if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)}; then
51 install -d ${D}${sysconfdir}/init.d
52 install xserver-nodm ${D}${sysconfdir}/init.d
53 fi
54}
55
56RDEPENDS_${PN} = "xinit ${@base_conditional('ROOTLESS_X', '1', 'xuser-account', '', d)}"
57
58INITSCRIPT_NAME = "xserver-nodm"
59INITSCRIPT_PARAMS = "start 9 5 . stop 20 0 1 2 3 6 ."
60SYSTEMD_SERVICE_${PN} = "xserver-nodm.service"
61