diff options
author | Andreas Müller <schnitzeltony@googlemail.com> | 2013-04-27 18:33:57 +0000 |
---|---|---|
committer | Martin Jansa <Martin.Jansa@gmail.com> | 2013-05-03 16:12:53 +0200 |
commit | ded05523d2530b44568980face1a057c1bb78249 (patch) | |
tree | 2645b18c1579f7016f1a786e086ef50ce26d6bb6 /meta-gnome | |
parent | 69f466b5a2d24a933010ac9d3ae1b8bd777b0681 (diff) | |
download | meta-openembedded-ded05523d2530b44568980face1a057c1bb78249.tar.gz |
gdm: fix postinst-code to unbreak first boot issues
Exiting postinst code leaves systemd.bbclass offline postinst code unexecuted,
causes postinst not to finish at first boot (gdm.service is not aliased to
display-manager.service -> started much too early) and is not neccesary:
language preparation can be done offline.
Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Diffstat (limited to 'meta-gnome')
-rw-r--r-- | meta-gnome/recipes-gnome/gdm/gdm_2.32.2.bb | 31 |
1 files changed, 12 insertions, 19 deletions
diff --git a/meta-gnome/recipes-gnome/gdm/gdm_2.32.2.bb b/meta-gnome/recipes-gnome/gdm/gdm_2.32.2.bb index 1e55dd988..87efc28e8 100644 --- a/meta-gnome/recipes-gnome/gdm/gdm_2.32.2.bb +++ b/meta-gnome/recipes-gnome/gdm/gdm_2.32.2.bb | |||
@@ -4,9 +4,9 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" | |||
4 | 4 | ||
5 | DEPENDS = "xinput gnome-panel tcp-wrappers libcanberra libxklavier grep consolekit libpam gnome-doc-utils gtk+ xrdb" | 5 | DEPENDS = "xinput gnome-panel tcp-wrappers libcanberra libxklavier grep consolekit libpam gnome-doc-utils gtk+ xrdb" |
6 | 6 | ||
7 | PR = "r15" | 7 | PR = "r16" |
8 | 8 | ||
9 | inherit gnome update-rc.d systemd | 9 | inherit gnome update-rc.d systemd useradd |
10 | 10 | ||
11 | SRC_URI += " \ | 11 | SRC_URI += " \ |
12 | file://cross-xdetection.diff \ | 12 | file://cross-xdetection.diff \ |
@@ -33,8 +33,8 @@ do_configure_prepend() { | |||
33 | } | 33 | } |
34 | 34 | ||
35 | do_install_prepend() { | 35 | do_install_prepend() { |
36 | mkdir -p ${D}/var/lib/gdm/.gconf.mandatory | 36 | install -d ${D}/${localstatedir}/lib/gdm/.gconf.mandatory |
37 | cp ${WORKDIR}/%gconf-tree.xml ${D}/var/lib/gdm/.gconf.mandatory/ | 37 | install ${WORKDIR}/%gconf-tree.xml ${D}/${localstatedir}/lib/gdm/.gconf.mandatory/ |
38 | } | 38 | } |
39 | 39 | ||
40 | do_install_append() { | 40 | do_install_append() { |
@@ -54,6 +54,9 @@ do_install_append() { | |||
54 | sed -e 's,%sbindir%,${sbindir},g' \ | 54 | sed -e 's,%sbindir%,${sbindir},g' \ |
55 | < ${WORKDIR}/gdm.service.in \ | 55 | < ${WORKDIR}/gdm.service.in \ |
56 | > ${D}${systemd_unitdir}/system/gdm.service | 56 | > ${D}${systemd_unitdir}/system/gdm.service |
57 | |||
58 | chown -R gdm:gdm ${D}${localstatedir}/lib/gdm | ||
59 | chmod 0750 ${D}${localstatedir}/lib/gdm | ||
57 | } | 60 | } |
58 | 61 | ||
59 | FILES_${PN} += "${datadir}/icon* \ | 62 | FILES_${PN} += "${datadir}/icon* \ |
@@ -72,23 +75,13 @@ SYSTEMD_SERVICE_${PN} = "gdm.service" | |||
72 | INITSCRIPT_NAME = "gdm" | 75 | INITSCRIPT_NAME = "gdm" |
73 | INITSCRIPT_PARAMS = "start 99 5 2 . stop 20 0 1 6 ." | 76 | INITSCRIPT_PARAMS = "start 99 5 2 . stop 20 0 1 6 ." |
74 | 77 | ||
75 | pkg_postinst_${PN} () { | 78 | USERADD_PACKAGES = "${PN}" |
76 | # can't do this offline | 79 | USERADD_PARAM_${PN} = "--system --no-create-home --home ${localstatedir}/lib/gdm --user-group gdm" |
77 | if [ "x$D" != "x" ]; then | ||
78 | exit 1 | ||
79 | fi | ||
80 | grep "^gdm:" /etc/group > /dev/null || addgroup gdm | ||
81 | grep "^gdm:" /etc/passwd > /dev/null || adduser --disabled-password --system --home /var/lib/gdm gdm --ingroup gdm -g gdm | ||
82 | |||
83 | if [ -d /var/lib/gdm ]; then | ||
84 | chown -R gdm:gdm /var/lib/gdm | ||
85 | chmod 0750 /var/lib/gdm | ||
86 | fi | ||
87 | 80 | ||
81 | pkg_postinst_${PN} () { | ||
88 | # Register up as default dm | 82 | # Register up as default dm |
89 | mkdir -p ${sysconfdir}/X11/ | 83 | mkdir -p $D${sysconfdir}/X11/ |
90 | echo "${bindir}/gdm" > ${sysconfdir}/X11/default-display-manager | 84 | echo "${bindir}/gdm" > $D${sysconfdir}/X11/default-display-manager |
91 | |||
92 | } | 85 | } |
93 | 86 | ||
94 | pkg_postrm_${PN} () { | 87 | pkg_postrm_${PN} () { |