68
68
xout=`$xorgbin -version 2>&1`
69
69
if echo "$xout" | grep "1\.4\.99\.90[12345]" > /dev/null
71
echo "Warning: the version of the X Window system on your guest has a known"
72
echo "problem. Because of this, dynamic resizing and seamless mode will not work."
71
echo "Warning: the version of the X Window system on your guest has known"
72
echo "problems which prevent dynamic resizing and seamless mode from working."
76
# Check to see if the server is configured to use static modes only.
77
for conf in "/etc/X11/xorg.conf-4" "/etc/X11/xorg.conf" "/etc/X11/.xorg.conf" "/etc/xorg.conf" \
78
"/usr/etc/X11/xorg.conf-4" "/usr/etc/X11/xorg.conf" "/usr/lib/X11/xorg.conf-4" \
79
"/usr/lib/X11/xorg.conf"
83
if awk -v IN_SECTION=0 \
84
'tolower($0) ~ /^[ \t]*section/ { IN_SECTION=1 } '\
85
'tolower($0) ~ /^[ \t]*modes/ { if (IN_SECTION) { print "mode"; exit } } '\
86
'tolower($0) ~ /^[ \t]*option[ \t]+\"preferredmode\"/ { if (IN_SECTION) { print "mode"; exit } } '\
87
'tolower($0) ~ /endsection/ { IN_SECTION=0 }' \
88
$conf 2>/dev/null | grep mode > /dev/null
90
echo "Disabling dynamic resizing as the X server is configured to only use static"
91
echo "resolutions. To fix this, edit the server configuration file, remove all"
92
echo "\"Modes\" lines from the \"Screen\" section and any Option \"PreferredMode\""
93
echo "lines from \"Monitor\" sections and restart the server."
99
76
# Don't write out error information in this case, as this script is also
100
77
# called from the installer, and vboxvideo will not yet be in place yet in