Start ${daemon} in the background to prevent '/etc/rc.d/gdm start' from

never ending.
This commit is contained in:
ajacoutot 2015-06-11 11:56:15 +00:00
parent 0801a3305f
commit 475cf6601f
2 changed files with 5 additions and 4 deletions

View File

@ -1,4 +1,4 @@
# $OpenBSD: Makefile,v 1.229 2015/05/08 09:08:44 espie Exp $
# $OpenBSD: Makefile,v 1.230 2015/06/11 11:56:15 ajacoutot Exp $
SHARED_ONLY= Yes
@ -6,6 +6,7 @@ COMMENT= GNOME display manager
GNOME_PROJECT= gdm
GNOME_VERSION= 3.16.1.1
REVISION= 0
DISTFILES= ${DISTNAME}${EXTRACT_SUFX} puflogh1000X248.gif:0
EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}

View File

@ -1,6 +1,6 @@
#!/bin/sh
#
# $OpenBSD: gdm.rc,v 1.31 2014/11/01 15:27:52 ajacoutot Exp $
# $OpenBSD: gdm.rc,v 1.32 2015/06/11 11:56:15 ajacoutot Exp $
daemon="${TRUEPREFIX}/sbin/gdm"
@ -16,14 +16,14 @@ rc_pre() {
# on boot: wait for ttys to be initialized
if [ -n "${INRC}" ]; then
unset rc_bg
unset rc_bg
rc_start() {
( local i=0
while ! pgrep -qf "^/usr/libexec/getty "; do
sleep 1
[ $((i++)) -ge 10 ] && return 1
done
${rcexec} "${daemon} ${daemon_flags}" ) &
${rcexec} "${daemon} ${daemon_flags} &" ) &
}
fi