X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=grml-x;h=c36b04daaa29a32fa6a80a21715c599e91c8772c;hb=3256f1f7cbead262acc175f37e80bbcd8d4225c5;hp=4b7594c34874b0299187c3f5662c23a06eec4170;hpb=8891849ec066325231071baf4713ec8d16d681e7;p=grml-x.git diff --git a/grml-x b/grml-x index 4b7594c..c36b04d 100755 --- a/grml-x +++ b/grml-x @@ -4,7 +4,6 @@ # Authors: grml-team (grml.org), (c) Michael Prokop # Bug-Reports: see http://grml.org/bugs/ # License: This file is licensed under the GPL v2. -# Latest change: Mon Mär 26 21:26:31 CEST 2007 [mika] ################################################################################ # debugging {{{ @@ -21,15 +20,16 @@ [ -r /etc/grml_colors ] && . /etc/grml_colors fi - # some functions like getbootparam - if [ -r /etc/grml/script-functions ] ; then + # some functions like getBootParam + if [ -r /etc/grml/script-functions -a -r /etc/grml/sh-lib ] ; then source /etc/grml/script-functions + source /etc/grml/sh-lib else - echo 'Error: sourcing /etc/grml/script-functions failed. Exiting.' + echo 'Error: sourcing function files failed. Exiting.' exit 1 fi - check4root && ROOT='1' || ROOT='' + check4root &>/dev/null && ROOT='1' || ROOT='' # }}} # set variables {{{ @@ -39,9 +39,16 @@ [ -n "$XINITRC" ] || XINITRC="$HOME/.xinitrc" # temporary files - HWINFO_TMP="/tmp/hwinfo.$$" - MONITORINFO="/tmp/monitorinfo.$$" - MOUSEINFO="/tmp/mouse.$$" + # notice: we need the unsafe option, otherwise users other than root + # can not write to HWINFO_TMP, but we don't want to run hwinfo as root + HWINFO_TMP="$(mktemp -u)" || exit 1 + MONITORINFO="$(mktemp)" || exit 1 + MOUSEINFO="$(mktemp)" || exit 1 + + if [ -z "$HWINFO_TMP" ] ; then + echo "Fatal: could not create temporary file. Exiting.">&2 + bailout 1 + fi if [ -r /etc/sysconfig/keyboard ] ; then source /etc/sysconfig/keyboard @@ -51,12 +58,12 @@ XSERVER="Xorg" XCONFIG='/etc/X11/xorg.conf' - KEYBOARD="Driver \"kbd\" - # Option \"XkbRules\" \"xfree86\" - Option \"XkbRules\" \"xorg\" - Option \"XkbModel\" \"pc105\" - Option \"XkbLayout\" \"${XKEYBOARD},us\" - # Option \"XkbVariant\" \"nodeadkeys\"" + KEYBOARD="# Driver \"kbd\" +# Option \"XkbRules\" \"xfree86\" +# Option \"XkbRules\" \"xorg\" +# Option \"XkbModel\" \"pc105\" +# Option \"XkbLayout\" \"${XKEYBOARD},us\" +# Option \"XkbVariant\" \"nodeadkeys\"" # check for font path if [ -d /usr/share/fonts/X11 ] ; then @@ -119,18 +126,17 @@ usage() Usage: $PROGRAMNAME $PROGRAMNAME [-options] windowmanager -Examples: - $PROGRAMNAME wmii - $PROGRAMNAME pekwm +Usage examples: + $PROGRAMNAME fluxbox $PROGRAMNAME fluxbox $PROGRAMNAME -force -nostart fluxbox $PROGRAMNAME -nosynaptics fluxbox $PROGRAMNAME -nosync fluxbox - $PROGRAMNAME -noddc wmii - $PROGRAMNAME -nousb fluxbox - $PROGRAMNAME -module radeon -mode 1024x768 -vsync 60 wmi - XINITRC=~/.xinitrc $PROGRAMNAME ion - $PROGRAMNAME -display 8 wmii + $PROGRAMNAME -noddc fluxbox + $PROGRAMNAME -xinerama -composite fluxbox + $PROGRAMNAME -module radeon -mode 1024x768 -vsync 60 fluxbox + XINITRC=~/.xinitrc $PROGRAMNAME fluxbox + $PROGRAMNAME -display 8 fluxbox More information on grml-x can be found in the manual page: man grml-x @@ -166,12 +172,97 @@ mode() [ -r "$MONITORINFO" ] || monitor # get monitor settings modes=$(perl -e 'while () {if (/ Resolution:/) { s/.*\s+(\d+x\d+).*/$1/; print} }' < $MONITORINFO | sort -nur | perl -ne 's/\s+/ /; s/(\d+x\d+)/"$1"/; print') + + if [ -n "$XINERAMA" ] ; then + + print "$fg[green] + +Option for $fg[yellow]Xinerama$fg[green] found, please use xrandr inside X.org for your further configuration! +Trying to identify monitors now..." + + # make sure we have information from 2 monitors: + # - first one from 'hwinfo --monitor' => $MONITORINFO + # - second one from 'hwinfo --framebuffer' => $FRAMEBUFFER + FRAMEBUFFER=$(hwinfo --framebuffer | grep 'Mode 0x.* bits' | head -1) + if [ -z "$FRAMEBUFFER" ] ; then + print "$fg[red] +Fatal: could not identify two monitors - no chance to + set up multihead using Xinerama - sorry. :-( + +Please run grml-x without the -xinerama option to start +X anyway (dropping support for Xinerama of course) and +contact grml developers if you have any further useful +information. => http://grml.org/bugs/ +" + bailout 10 + fi + + # check whether we can read the $MONITORINFO file + if ! [ -r "$MONITORINFO" ] ; then + print "$fg[red] +Fatal: could not identify monitor - no chance to + set up multihead using Xinerama - sorry. :-( +" + bailout 11 + else + # Currently we only know that it works with current intel driver, + # so inform user about that: + if [[ "$MODULE" != "intel" ]] ; then + print "$fg[red] + +Warning: using a non-intel driver - trying Xinerama setup anyway. +If it worked please contact grml developers providing information +about your setup so we can adjust grml-x according! + + -> http://grml.org/contact/ + +Sleeping for 10 seconds now... Will continue then... +Just press Ctrl-C to cancel operation. +" + sleep 10 + fi + + # now calculate Virtual size for use with Xinerama + HORIZ_RES1="$(grep 'Max. Resolution:' $MONITORINFO | sed 's/ Max\. Resolution: \(.*\)x\(.*\)/\1/')" + VERIZ_RES1="$(grep 'Max. Resolution:' $MONITORINFO | sed 's/ Max\. Resolution: \(.*\)x\(.*\)/\2/')" + # it might happen that we don't have a Max Resolution in hwinfo output :-/ + # fall back to a generic value then... + # TODO: check out how to get resolution of external monitor from console + if [ -z "$HORIZ_RES1" ] ; then + HORIZ_RES1="1024" + VERIZ_RES1="768" + fi + + # get maximum of output + HORIZ_RES2="$(echo $FRAMEBUFFER | grep 'Mode 0x' | sed 's/ Mode 0x.*: \(.*\)x.*/\1/'| sort -u | head -1)" + VERIZ_RES2="$(echo $FRAMEBUFFER | grep 'Mode 0x' | sed 's/ Mode 0x.*x\(.*\) (.*/\1/' | sort -u | head -1)" + + if [ -n "$HORIZ_RES1" -a -n "$VERIZ_RES1" -a -n "$HORIZ_RES2" -a -n "$VERIZ_RES2" ] ; then + if [ "$(echo $VERIZ_RES1" - "$VERIZ_RES2 | bc -l)" -eq 0 ] ; then + VERIZ_RESULT="$VERIZ_RES1" + elif [ "$VERIZ_RES1" -gt "$VERIZ_RES2" ] ; then + VERIZ_RESULT="$VERIZ_RES1" + else + VERIZ_RESULT="$VERIZ_RES2" + fi + + HORIZ_RESULT=$(echo $HORIZ_RES1 + $HORIZ_RES2 | bc -l) + + # important: keep newline for appropriate placing below $MODES! + if [ -n "$HORIZ_RESULT" ] ; then + VIRTUAL=" + Virtual $HORIZ_RESULT $VERIZ_RES1" + fi + fi + fi + fi + if [[ -n $NODDC ]] ; then - MODES='Modes "1024x768" "800x600" "640x480" "1600x1200" "1280x1024" "1280x960"' + MODES="Modes \"1024x768\" \"800x600\" \"640x480\" \"1600x1200\" \"1280x1024\" \"1280x960\"$VIRTUAL" elif [[ "$modes" == "\"1024x768\" " || -z $modes ]] ; then - MODES='# Modes "1024x768" "800x600" "640x480" "1600x1200" "1280x1024" "1280x960"' + MODES="# Modes \"1024x768\" \"800x600\" \"640x480\" \"1600x1200\" \"1280x1024\" \"1280x960\"$VIRTUAL" else - MODES="# Modes $modes" + MODES="# Modes $modes$VIRTUAL" fi } # }}} @@ -180,6 +271,7 @@ sort -nur | perl -ne 's/\s+/ /; s/(\d+x\d+)/"$1"/; print') sync() { [ -r "$MONITORINFO" ] || monitor # get monitor settings + [ -r "$MONITORINFO" ] || bailout 1 vsyncval=$(awk '/Vert. Sync Range:/{print $4}' $MONITORINFO | sed 's/-/.0 - / ; s/$/.0/' | head -1) hsyncval=$(awk '/Hor. Sync Range:/{print $4}' $MONITORINFO | sed 's/-/.0 - / ; s/$/.0/' | head -1) if [ -z $vsyncval ] ; then @@ -200,7 +292,7 @@ mouse() if grep -q 'Device:.*Synaptics' "$MOUSEINFO" ; then if [[ "$SYNAPTICS" == "yes" ]] ; then # check for '-nosynaptics'-option MOUSEDRIVER='synaptics' - SYNMOUSE='InputDevice "Synaptics" "AlwaysCore"' + SYNMOUSE='InputDevice "Synaptics" # "AlwaysCore"' SYNMOUSEDETAIL=" Section \"InputDevice\" Driver \"synaptics\" @@ -235,8 +327,7 @@ EndSection if grep -q 'Device:.*ALPS' "$MOUSEINFO" ; then if [[ "$SYNAPTICS" == "yes" ]] ; then # check for '-nosynaptics'-option MOUSEDRIVER='synaptics' - # SYNMOUSE='InputDevice "Synaptics" "CorePointer"' - SYNMOUSE='InputDevice "Synaptics" "AlwaysCore"' + SYNMOUSE='InputDevice "Synaptics" # "AlwaysCore"' SYNMOUSEDETAIL=" Section \"InputDevice\" Driver \"synaptics\" @@ -273,14 +364,13 @@ EndSection SYNMOUSE='# No alps touchpad detected.' fi else - SYNMOUSE='# No alps touchpad present.' + SYNMOUSE='# No synaptics/alps touchpad present.' fi fi # USB-PS/2 Optical Mouse - if ! [[ -n $NOUSB ]] ; then - USB='yes' - USBMOUSE='InputDevice "USB Mouse" "CorePointer"' + if [ -n "$USE_USB" ] ; then + USBMOUSE='InputDevice "USB Mouse" "CorePointer"' USBMOUSEDETAIL=" Section \"InputDevice\" Identifier \"USB Mouse\" @@ -293,12 +383,13 @@ Section \"InputDevice\" EndSection " else - USBMOUSE='# Deactivated USB Mouse as requested.' + USBMOUSE='# InputDevice "USB Mouse" "CorePointer"' + USBMOUSEDETAIL='' fi if grep -q 'Device:.*Serial' "$MOUSEINFO" ; then SERIAL='yes' - SERMOUSE='InputDevice "Serial Mouse" "CorePointer"' + SERMOUSE='InputDevice "Serial Mouse" "CorePointer"' SERMOUSEDETAIL=" Section \"InputDevice\" Identifier \"Serial Mouse\" @@ -312,15 +403,15 @@ EndSection " else SERMOUSE='# No serial mouse detected.' + SERMOUSEDETAIL='' fi # ImExPS/2 Logitech Explorer Mouse # "PS2++ Logitech MX Mouse" - if ! [[ -n $NOPS2 ]] ; then - if grep -qE 'Device:.*PS.?2' "$MOUSEINFO" ; then - PS2='yes' - PS2MOUSE='InputDevice "PS/2 Mouse" "CorePointer"' - PS2MOUSEDETAIL=" + if [ -n "$USE_PS2" ] ; then + PS2='yes' + PS2MOUSE='InputDevice "PS/2 Mouse" "CorePointer"' + PS2MOUSEDETAIL=" Section \"InputDevice\" Identifier \"PS/2 Mouse\" Driver \"mouse\" @@ -333,34 +424,25 @@ Section \"InputDevice\" EndSection " else - PS2MOUSE='# No PS/2 mouse detected.' - PS2MOUSEDETAIL="" + PS2MOUSE='# InputDevice "PS/2 Mouse" "CorePointer"' + PS2MOUSEDETAIL='' fi - else - PS2MOUSE='# Deactivated PS/2 Mouse as requested.' - fi - if [[ -n $GENERICMOUSE ]] ; then - GENERIC='yes' - GENERICMOUSE='InputDevice "Generic Mouse" "CorePointer"' - GENERICMOUSEDETAIL=" -Section \"InputDevice\" - Identifier \"Generic Mouse\" - Driver \"mouse\" - Option \"Device\" \"/dev/input/mice\" - Option \"Protocol\" \"auto\" - Option \"Buttons\" \"5\" - Option \"ZAxisMapping\" \"4 5\" -EndSection + EVDEV_MOUSE=" +# Section \"InputDevice\" +# Identifier \"Generic Mouse\" +# Driver \"evdev\" +# Option \"Device\" \"/dev/input/mice\" +# Option \"Protocol\" \"auto\" +# Option \"ZAxisMapping\" \"4 5\" +# Option \"Buttons\" \"5\" +# Option \"SendCoreEvents\" \"true\" +# EndSection " - else - GENERICMOUSE='# No generic mouse configured.' - fi MOUSE=" $USBMOUSE $PS2MOUSE $SYNMOUSE - $GENERICMOUSE $SERMOUSE" } # }}} @@ -372,7 +454,8 @@ parse_options() vsync:=o_vsync hsync:=o_hsync mode:=o_mode force=o_force display:=o_display \ nostart=o_nostart nodpms=o_nodpms nosynaptics=o_nosynaptics nousb=o_nousb \ nops2=o_nops2 genmouse=o_genmouse novref=o_novref nohsync=o_nohsync \ - fallback=o_fallback + fallback=o_fallback usb=o_usb ps2=o_ps2 composite=o_composite \ + xinerama=o_xinerama if [[ $# == 0 || "$o_help" != "" || "$1" == '-h' || "$1" == '--help' ]]; then usage @@ -412,11 +495,19 @@ parse_options() fi if [[ "$o_nousb" != "" ]]; then - NOUSB='yes' + echo 'Warning: option -nousb is deprecated.'>&2 + fi + + if [[ "$o_usb" != "" ]]; then + USE_USB='yes' fi if [[ "$o_nops2" != "" ]]; then - NOPS2='yes' + echo 'Warning: optino -nops2 is deprecated˙'>&2 + fi + + if [[ "$o_ps2" != "" ]]; then + USE_PS2='yes' fi if [[ "$o_genmouse" != "" ]]; then @@ -439,7 +530,7 @@ parse_options() if [[ "$XKEYBOARD" == de ]] ; then KEYBOARD="$KEYBOARD - Option \"XkbVariant\" \"nodeadkeys\"" +# Option \"XkbVariant\" \"nodeadkeys\"" fi if [ -n "$FORCE" -o ! -r "$XCONFIG" -a -z "$FALLBACK" ] ; then @@ -480,17 +571,32 @@ parse_options() VERTISYNC="# VertRefresh 50.0 - 60.0 # deactivated via -novref option of grml-x" fi + if [[ "$o_xinerama" != "" ]]; then + XINERAMA=1 + fi + + if [[ "$o_composite" != "" ]]; then + COMPOSITE="Section \"Extensions\" + Option \"Composite\" \"Enable\" +EndSection" + else + COMPOSITE="#Section \"Extensions\" +# Option \"Composite\" \"Enable\" +#EndSection" + fi + # write hwinfo stuff writehwinfo # monitor stuff + [ -r "$HWINFO_TMP" ] || bailout 1 MONITOR=$(awk '/monitor.1:/{print $3}' $HWINFO_TMP) [[ $MONITOR != 'ddc' ]] && NODDC=yes # module handling MODULE=$o_module[2] if [ -z "$MODULE" ] ; then - MODULE="$(getbootparam xmodule 2>/dev/null)" + MODULE="$(getBootParam xmodule 2>/dev/null)" if [ -z "$MODULE" ] ; then MODULE=$(grep 'XFree86 v4 Server Module:' "${HWINFO_TMP}" | head -1 | awk '{print $5}') if [ -z "$MODULE" ] ; then @@ -510,7 +616,7 @@ parse_options() MODE=$o_mode[2] if [ -z $MODE ] ; then - B_MODE="$(getbootparam xmode 2>/dev/null)" + B_MODE="$(getBootParam xmode 2>/dev/null)" if [ -n "$B_MODE" ] ; then MODES="Modes \"$B_MODE\"" FORCE="yes" @@ -544,7 +650,7 @@ requirements() { if ! [ -x $(which hwinfo) ] ; then print "$bg[black]$fg[red]${bold_color}Error: hwinfo not found in path.${reset_color} -Note: run 'apt-get install hwinfo' on systems running debian. +Note: run 'aptitude install hwinfo' on systems running debian. Exiting.${reset_color}" exit -1 fi @@ -574,10 +680,14 @@ cat << EOX # /usr/share/doc/xserver-xorg/ and # http://wiki.x.org/wiki/Home and # http://ftp.x.org/pub/X11R7.0/doc/html/index.html for information on Xorg +# # Refer to the xorg.conf man page and to # http://ftp.x.org/pub/X11R7.0/doc/html/xorg.conf.5.html # for details about the format of this file. # +# See http://wiki.debian.org/XStrikeForce/FAQ for information +# regarding Xorg packages within Debian. +# # If you would like this file to be automatically reconfigured by debian, # run the following command: # sudo dpkg-reconfigure -phigh xserver-xorg @@ -586,14 +696,16 @@ cat << EOX Section "ServerLayout" Identifier "XServer Configured" Screen 0 "Screen0" 0 0 - InputDevice "Keyboard0" "CoreKeyboard" + # InputDevice "Keyboard0" "CoreKeyboard" + # InputDevice "Generic Mouse" "CorePointer" + Option "AutoAddDevices" "off" # do not depend on running dbus/hal $MOUSE EndSection Section "ServerFlags" Option "AllowMouseOpenFail" "true" # allows the server to start up even if the mouse does not work Option "DontVTSwitch" "false" # allow switching between virtual terminal - # Option "DontZap" "true" # disable (server abort) + Option "DontZap" "false" # enable (server abort) # Option "DontZoom" "true" # disable / (resolution switching) EndSection @@ -607,24 +719,26 @@ $XFONTS FontPath "/var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType" EndSection -# Modules - see /usr/X11R6/lib/modules/fonts and /usr/X11R6/lib/modules/extensions +# Modules - see /usr/lib/xorg/modules/fonts and /usr/lib/xorg/modules/extensions Section "Module" Load "dbe" # double buffer extension Load "dri" # direct rendering - Load "glx" # 3D layer - Load "type1" # font module - Load "freetype" # font rendering + Load "glx" # 3D layer / GLX extension + Load "type1" # type1 font module + Load "freetype" # freetype fonts rendering Load "extmod" # some commonly used server extensions (e.g. shape extension) Load "record" # recording extension + Load "evdev" # generic input handling driver on Linux + Load "xtrap" # X Trap extension # Load "vbe" # Vesa BIOS Extension - # Load "ddc" # ddc probing of monitor - # Load "bitmap" # bitmap fonts - # Load "GLcore" # render OpenGL in software # Load "i2c" # I2C bus # Load "int10" # initialize graphics cards via int10 call to the BIOS - # Load "speedo" # font module # Load "v4l" # Video for Linux - # Load "evdev" # generic input handling driver on Linux + ## Deprecated/unneeded modules with Xorg >=7.0: + # Load "speedo" # font module (does not exist anymore) + # Load "ddc" # ddc probing of monitor (automatically loaded) + # Load "GLcore" # render OpenGL in software (automatically loaded) + # Load "bitmap" # bitmap fonts (automatically loaded) # Valid entries - see /usr/lib/xorg/modules/[extensions/] # afb bitmap cfb cfb16 cfb24 cfb32 cw damage dbe ddc dri drm extmod fb # fbdevhw freetype GLcore glx i2c int10 int10 layer mfb pcidata rac ramdac @@ -637,19 +751,15 @@ EndSection # Or if you just want both to be control, use: # Option "XkbOptions" "ctrl:nocaps" # More information: http://ftp.x.org/pub/X11R7.0/doc/html/XKB-Config.html -Section "InputDevice" - Identifier "Keyboard0" - Option "CoreKeyboard" - $KEYBOARD - # Option "XkbOptions" "ctrl:swapcaps,grp:alt_shift_toggle,grp_led:scroll,compose:menu" -EndSection +# Section "InputDevice" +# Identifier "Keyboard0" +# Option "CoreKeyboard" +# $KEYBOARD +# # Option "XkbOptions" "ctrl:swapcaps,grp:alt_shift_toggle,grp_led:scroll,compose:menu" +# EndSection # More information: http://ftp.x.org/pub/X11R7.0/doc/html/mouse.html -$GENERICMOUSEDETAIL -$USBMOUSEDETAIL -$PS2MOUSEDETAIL -$SERMOUSEDETAIL -$SYNMOUSEDETAIL +${USBMOUSEDETAIL}${PS2MOUSEDETAIL}${SERMOUSEDETAIL}${SYNMOUSEDETAIL}${EVDEV_MOUSE} Section "Monitor" Identifier "Monitor0" # ModelName "Old Monitor (no DDC)" @@ -727,13 +837,13 @@ Section "Screen" EndSubSection EndSection +# Make sure you have the relevant Debian packages on your system +# to be able to use DRI (libgl1-mesa-dri for example) Section "DRI" Mode 0666 EndSection -#Section "Extensions" -# Option "Composite" "Enable" -#EndSection +$COMPOSITE ## END OF FILE ################################################################# EOX @@ -742,8 +852,14 @@ EOX # writeit {{{ writeit() { - XCONFTMP="/tmp/xconfig.$$" + XCONFTMP="$(mktemp)" xconfig > $XCONFTMP + # we do not want to have two CorePointers, deactivate one therefore + if grep -Eq '^[[:space:]]+InputDevice[ ]+"USB Mouse"[ ]+"CorePointer"' $XCONFTMP ; then + if grep -Eq '^[[:space:]]+InputDevice[ ]+"PS/2 Mouse"[ ]+"CorePointer"' $XCONFTMP ; then + sed -i 's|InputDevice.*PS/2.*CorePointer|# & # deactivated to avoid two CorePointers|' $XCONFTMP + fi + fi [ -f $XCONFIG ] && sudo mv -f $XCONFIG $XCONFIG.old sudo mv $XCONFTMP $XCONFIG sudo chown root.root $XCONFIG @@ -776,6 +892,11 @@ $fg[red]" function runit { writeconfig + if [ "$(readlink /etc/X11/X)" = /bin/true ] ; then + print "$bold_color$fg[red]Fatal: /etc/X11/X is a symlink to /bin/true." + print "Fix it via running 'ln -sf /usr/bin/Xorg /etc/X11/X'" + exit 10 + fi if [ -z "$NOSTART" ] ; then print "$reset_color" if [ -x /etc/init.d/xorg-common ] ; then @@ -788,15 +909,16 @@ function runit print "" if [ -z "$DISPLAY" ] ; then print "$bold_color$fg[green]Now trying to run startx.$reset_color" - startx ~/.xinitrc -- $XOPTS + startx $XINITRC -- $XOPTS + return 1 else print "$bold_color$fg[green]Now trying to run startx on display $DISPLAY.$reset_color" - startx ~/.xinitrc -- :$DISPLAY $XOPTS + startx $XINITRC -- :$DISPLAY $XOPTS + return 1 fi else print "$bold_color$fg[blue]Not running startx as requested via option.$reset_color" fi - return 1 } # }}} @@ -818,8 +940,8 @@ Please exit screen and try to run $PROGRAMNAME again." get-edid | parse-edid Do you want to go the debian way of life? Run: - apt-get install x-window-system-core read-edid mdetect hwinfo xdebconfigurator - dpkg-reconfigure x-window-system-core (or xserver-xorg depending on your system) + aptitude install xorg read-edid mdetect hwinfo xdebconfigurator + dpkg-reconfigure -phigh xserver-xorg Problems with the module used for X? Try to load another one or fall back to module vesa: @@ -873,6 +995,10 @@ cleanup # }}} # xinitrc {{{ + if ! [ -x "$(which $WINDOWMANAGER)" ] ; then + print "$bg[black]$fg[red]${bold_color}Fatal: windowmanager $fg[blue]$WINDOWMANAGER$fg[red] not executable, startx will not work.${reset_color}">&2 + bailout + fi if [ -w "$XINITRC" ] ; then sed -i "s|^[^#]*exec.*| exec $WINDOWMANAGER|g" $XINITRC runit || failed @@ -883,4 +1009,4 @@ cleanup # }}} ## END OF FILE ################################################################# -# vim:foldmethod=marker +# vim:foldmethod=marker expandtab ai ft=zsh