Hows bout I try to simplify init and xinit into a single shorty (ported from my c implementation to shell)
Code: Select all
#!/bin/sh
#Normally these variables would be in a sourced config file - here for brevity
#X="Xorg"
X="Xvesa -screen 1280x800x24 -nolisten tcp"
wm="jwm"
PATH=/bin #... etc (all my binary dirs symlink to /bin :) )
HOME=/root
TERM=rxvt
PS1=" > "
SHELL=/bin/sh
export X wm PATH HOME TERM PS1 SHELL
waitforX(){
while [ ! -S /tmp/.X11-unix/X0]; do sleep .1;done
[ "$DISPLAY" ] || export DISPLAY=":0"
}
mount -t proc none /proc
mount -t sysfs none /sys
mount -t devtmpfs none /dev #or config kernel to do this
$X & waitforX && $wm
for x in $HOME/.autostart/*;do $x;done