summaryrefslogtreecommitdiffstats
path: root/os-plugins/plugins/xserver/XX_xserver.sh
diff options
context:
space:
mode:
authorBastian Wissler2009-01-22 15:55:52 +0100
committerBastian Wissler2009-01-22 15:55:52 +0100
commit49014d364950e5930a7218e324fba24bc5525593 (patch)
tree9f650779d14e2c6e937e9ce07b1efacc047bb0a9 /os-plugins/plugins/xserver/XX_xserver.sh
parentIf vmplayer is still to noisy we should try the following two options (diff)
downloadcore-49014d364950e5930a7218e324fba24bc5525593.tar.gz
core-49014d364950e5930a7218e324fba24bc5525593.tar.xz
core-49014d364950e5930a7218e324fba24bc5525593.zip
xserver plugin fixes:
* various fixes for suse-11.0 * various fixes for ubuntu-8.10 (thanks to Sebastian Schmelzer) * rewritten linkage Module (now in Perl) git-svn-id: http://svn.openslx.org/svn/openslx/openslx/trunk@2515 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'os-plugins/plugins/xserver/XX_xserver.sh')
-rw-r--r--os-plugins/plugins/xserver/XX_xserver.sh98
1 files changed, 38 insertions, 60 deletions
diff --git a/os-plugins/plugins/xserver/XX_xserver.sh b/os-plugins/plugins/xserver/XX_xserver.sh
index 10960d5a..5b2f3815 100644
--- a/os-plugins/plugins/xserver/XX_xserver.sh
+++ b/os-plugins/plugins/xserver/XX_xserver.sh
@@ -36,7 +36,8 @@ testmkd ${glliblinks}
if [ -e /initramfs/plugin-conf/xserver.conf -a \
! -f /rootfs/etc/X11/xorg.conf ]; then
. /initramfs/plugin-conf/xserver.conf
-
+ # keyboard setup
+ localization "${country}"
# do not start any configuration if the admin provided a preconfigured
# xorg.conf in /rootfs/etc/X11/xorg.conf
if [ $xserver_active -ne 0 -a ! -f /rootfs/${xfc#/mnt} ]; then
@@ -45,12 +46,12 @@ if [ -e /initramfs/plugin-conf/xserver.conf -a \
sed "s/.*v4 Server Module: //")
# proprietary ATI/NVidia modules listed a different way with hwinfo
[ -z "$xmodule" ] || error "${hcfg_hwsetup}" nonfatal
-
+
######################################################################
# begin proprietary drivers section (xorg.conf part)
######################################################################
+ set -x
- waitfor /etc/hwinfo.data 10000
if [ $(grep -i -m 1 'Module: fglrx' \
/etc/hwinfo.data | wc -l) -ge "1" -a $xserver_prefnongpl -eq 1 ]
then
@@ -102,9 +103,9 @@ ${PLUGIN_ROOTFS}/usr/X11R6/lib/modules/\,"
######################################################################
- echo -e "# ${xfc#/mnt*}\n# autogenerated X hardware configuration by the \
-xserver plugin in OpenSLX stage3\n# DO NOT EDIT THIS FILE BUT THE PLUGIN \
-INSTEAD" > $xfc
+ echo -e "# $xfc\n# autogenerated X hardware configuration by the xserver \
+plugin in OpenSLX stage3\n# DO NOT EDIT THIS FILE BUT THE PLUGIN INSTEAD" \
+ > $xfc
echo '
Section "Files"
ModulePath "/usr/lib/xorg/modules/"
@@ -128,12 +129,13 @@ Section "Module"
Load "dri"
EndSection
Section "InputDevice"
- Identifier "Generic Keyboard"
+ Identifier "Generic Keyboard"
Driver "kbd"
Option "CoreKeyboard"
Option "XkbRules" "xorg"
Option "XkbModel" "pc105"
Option "XkbLayout" "us"
+ Option "XkbVariant" "nodeadkeys"
EndSection
Section "InputDevice"
Identifier "Generic Mouse"
@@ -144,6 +146,27 @@ Section "InputDevice"
# Option "Emulate3Buttons" "true"
Option "CorePointer"
EndSection
+Section "InputDevice"
+ Driver "wacom"
+ Identifier "Stylus"
+ Option "Device" "/dev/input/wacom"
+ Option "Type" "stylus"
+ Option "ForceDevice" "ISDV4" # Tablet PC ONLY
+EndSection
+Section "InputDevice"
+ Driver "wacom"
+ Identifier "Eraser"
+ Option "Device" "/dev/input/wacom"
+ Option "Type" "eraser"
+ Option "ForceDevice" "ISDV4" # Tablet PC ONLY
+EndSection
+Section "InputDevice"
+ Driver "wacom"
+ Identifier "Cursor"
+ Option "Device" "/dev/input/wacom"
+ Option "Type" "cursor"
+ Option "ForceDevice" "ISDV4" # Tablet PC ONLY
+EndSection
Section "Device"
Identifier "Generic Video Card"
Driver "vesa"
@@ -171,23 +194,20 @@ Section "ServerLayout"
Screen "Default Screen"
InputDevice "Generic Keyboard"
InputDevice "Generic Mouse"
+ InputDevice "Stylus" "SendCoreEvents"
+ InputDevice "Cursor" "SendCoreEvents"
+ InputDevice "Eraser" "SendCoreEvents"
EndSection
Section "DRI"
Mode 0666
-EndSection' >> $xfc
- # keyboard setup (fill XKEYBOARD)
- localization "${country}"
+EndSection
+' >> $xfc
# if no module was detected, stick to vesa module
if [ -n "$xmodule" ] ; then
sed "s/vesa/$xmodule/;s/\"us\"/\"${XKEYBOARD}\"/" -i $xfc
else
sed "s/\"us\"/\"${XKEYBOARD}\"/" -i $xfc
fi
- # set nodeadkeys for special layouts
- if [ ${XKEYBOARD} = "de" ]; then
- sed -e '/\"XkbLayout\"/a\\ \ Option "XkbVariant" "nodeadkeys"' \
- -i $xfc
- fi
# these directories might be distro specific
for file in /var/lib/xkb/compiled ; do
testmkd /mnt/${file}
@@ -247,45 +267,9 @@ a\ \ InputDevice\ \ "Synaptics TP"\ \ \ \ \ \ "SendCoreEvents"
ln -sf /usr/lib/libGL_MESA.so.1.2 /mnt/var/X11R6/lib/libGL.so.1.2
fi
fi
-
- # check if tablet hardware available, read device information from file
- if [ -e /etc/tablet.conf ]; then
- . /etc/tablet.conf
- echo -e 'Section "InputDevice"
- Driver "wacom"
- Identifier "Stylus"
- Option "Device" "/dev/input/wacom"
- Option "Type" "stylus"
- Option "ForceDevice" "ISDV4" # Tablet PC ONLY
-EndSection
-Section "InputDevice"
- Driver "wacom"
- Identifier "Pad"
- Option "Device" "/dev/input/wacom"
- Option "Type" "pad"
- Option "ForceDevice" "ISDV4" # Tablet PC ONLY
-EndSection
-Section "InputDevice"
- Driver "wacom"
- Identifier "Eraser"
- Option "Device" "/dev/input/wacom"
- Option "Type" "eraser"
- Option "ForceDevice" "ISDV4" # Tablet PC ONLY
-EndSection
-Section "InputDevice"
- Driver "wacom"
- Identifier "Cursor"
- Option "Device" "/dev/input/wacom"
- Option "Type" "cursor"
- Option "ForceDevice" "ISDV4" # Tablet PC ONLY
-EndSection' >> ${xfc}
- sed -e "s,/dev/input/wacom,/dev/${wacomdev}," \
- -e '/e \"Generic Mouse\"/a\\ \ InputDevice "Stylus" "SendCoreEvents"' \
- -e '/e \"Generic Mouse\"/a\\ \ InputDevice "Pad" "SendCoreEvents"' \
- -e '/e \"Generic Mouse\"/a\\ \ InputDevice "Cursor" "SendCoreEvents"' \
- -e '/e \"Generic Mouse\"/a\\ \ InputDevice "Eraser" "SendCoreEvents"' \
- -i ${xfc}
- fi
+
+
+ [ $DEBUGLEVEL -gt 0 ] && echo "done with 'xserver' os-plugin ...";
# some configurations produce no proper screen resolution without
# Horizsync and Vertrefresh set (more enhancements might be needed for
@@ -319,11 +303,5 @@ EndSection' >> ${xfc}
# run distro specific generated stage3 script
[ -e /mnt/opt/openslx/plugin-repo/xserver/xserver.sh ] && \
. /mnt/opt/openslx/plugin-repo/xserver/xserver.sh
-
- [ $DEBUGLEVEL -gt 0 ] && echo "done with 'xserver' os-plugin ..."
-
fi
-elif [ ! -e /initramfs/plugin-conf/xserver.conf ]; then
- [ $DEBUGLEVEL -gt 2 ] && \
- echo "No configuration file found for xserver plugin."
fi