--- usr/sbin/mkxf86config.sh.orig 2007-05-24 15:25:55.000000000 -0500 +++ usr/sbin/mkxf86config.sh 2007-06-01 07:03:47.000000000 -0500 @@ -98,6 +98,16 @@ esac fi +# Pick a default if no module is defined or it does not exist +DRIVER_PATH="/usr/lib/xorg/modules/drivers" +if [ -z "${XMODULE}" -o ! -e "${DRIVER_PATH}/${XMODULE}_drv.so" ]; then + if [ -e "/dev/fb" -a -e "${DRIVER_PATH}/fbdev_drv.so" ]; then + XMODULE="fbdev" + elif [ -e "${DRIVER_PATH}/vesa_drv.so" ]; then + XMODULE="vesa" + fi +fi + # We used to use ddcxinfo-knoppix for monitor information, now we will just let # X choose for itself. This will probably break older machines. # You can uncomment the following to re-enable dccxinfo-knoppix, but this only @@ -250,7 +260,7 @@ -e 's|@@XMODULE@@|'"${XMODULE}"'|g;'"${VMWARE}""${VPC}""${SERIALMOUSE}""${USBMOUSE}""${PSMOUSE}""${SWCURSOR}""${WHEEL}""${SYNMOUSE}""${MOUSEDRIVER}" \ -e 's|@@SYNDEV@@|'"${SYNDEV}"'|g' \ -e 's|@@MODES@@|'"${MODES}"'|g;'"${DEPTH}" \ - -e 's|"XkbLayout" *"[^"]*"|"XkbLayout" "'"${XKEYBOARD}"'"|g;'"${DEADKEYS}" \ + ${XKEYBOARD:+-e 's|"XkbLayout" *"[^"]*"|"XkbLayout" "'"${XKEYBOARD}"'"|g;'"${DEADKEYS}"} \ /etc/X11/xorg.conf.in >/etc/X11/xorg.conf if [ -n "${DPMS}" ]