You don't say what WM you are trying to install, but I'll tell you about what I did with fluxbox.
If you have a file called .xintrc in your home directory, add a line to the file as shown below:
Code:
#
# choose a window manager
#
if test -n "$WINDOWMANAGER" ; then
WINDOWMANAGER=`type -p $WINDOWMANAGER`
fi
if test -z "$WINDOWMANAGER" ; then
if test -x /usr/X11R6/bin/kde ; then
WINDOWMANAGER=/usr/X11R6/bin/kde
elif test -x /usr/X11R6/bin/startkde ; then
WINDOWMANAGER=/usr/X11R6/bin/startkde
elif test -x /usr/X11R6/bin/fvwm2 ; then
WINDOWMANAGER=/usr/X11R6/bin/fvwm2
elif test -x/usr/local/bin/fluxbox ; then <---- LOOK
WINDOWMANAGER=/usr/local/bin/fluxbox <---- LOOK
elif test -x /usr/X11R6/bin/wmlist ; then
for i in `/usr/X11R6/bin/wmlist` ; do
WINDOWMANAGER=`type -p $i`
test -n "$WINDOWMANAGER" && break
done
elif test -x /usr/X11R6/bin/twm ; then
WINDOWMANAGER=/usr/X11R6/bin/twm
fi
fi
I changed the /root/.xinitrc and it appears to act globally. This worked great for SuSE which comes with all kinds of WM's and a pre-existing .xinitrc to work off of.
I then (in KDE) opened the control center as root and went to system-login manager, went to the sessions tab and in the blank space on the bottom left typed "fluxbox" and clicked add - fluxbox will appear on the bottom right list..
RedHat was a bit different. No .xinitrc and adding one didn't work correctly. Open the /etc/X11/xdm/.Xsessions file and add the line as follows:
Code:
# now, we see if xdm/gdm/kdm has asked for a specific environment
case $# in
1)
if [ -x /usr/share/apps/switchdesk/Xclients.$1 ]; then
exec -l $SHELL -c "/usr/share/apps/switchdesk/Xclients.$1";
fi;
case $1 in
failsafe)
exec -l $SHELL -c "xterm -geometry 80x24-0-0"
;;
gnome)
exec -l $SHELL -c "gnome-session"
;;
kde|kde1|kde2)
exec -l $SHELL -c "/usr/share/apps/switchdesk/Xclients.kde"
;;
twm)
# fall back to twm
exec -l $SHELL -c "/usr/share/apps/switchdesk/Xclients.twm"
;;
fluxbox)
exec /usr/local/bin/fluxbox <------LOOK
;; <------ LOOK
esac
esac
Enter the refrence to fluxbox in the sessions list as stated above.
Please note that the entries refrence the location of the WM you wish to install. In my case, the fluxbox executable is locate at /usr/local/bin/fluxbox. Your's may be different.
Both these methods alowed me to access fluxbox from the KDM login and return to KDM when exiting fluxbox. Don't add the "<----- LOOK'
hope this helps