#!/bin/bash # $Header: /root/magellan-cvs/src/xorg/startxdm,v 1.1 2005-07-02 17:07:55 niro Exp $ source /etc/profile source /etc/rc.config # enable antialias by default for gnome export GDK_USE_XFT=1 get_login() { case "${GLOGIN}" in kdm|KDM) GLOGINCMD="$(which kdm 2> /dev/null)" if [ ! -f "${GLOGINCMD}" ] then echo "Failure: KDE Login Manager not found." exit 1 fi ;; xdm|XDM) GLOGINCMD="$(which xdm 2> /dev/null)" if [ ! -f "${GLOGINCMD}" ] then echo "Failure: XDM Login Manager not found." exit 1 fi ;; *) GLOGINCMD="$(which ${GLOGIN} 2> /dev/null)" if [ ! -e "${GLOGINCMD}" ] then echo "Failure: \"${GLOGIN}\" Login Manager not found." exit 1 fi ;; esac } if [ -n "${GLOGIN}" ] then get_login /sbin/start-stop-daemon --start --quiet --exec ${GLOGINCMD} retval="$?" wait; sleep 2 if [ "${retval}" -ne 0 ] then echo "Could not start your Displaymanager" killall -9 ${GLOGIN##*/} fi fi