Sophie

Sophie

distrib > Mageia > 1 > i586 > media > core-updates-src > by-pkgid > d043847aa27480c55fe107cb41a6f83f > files > 9

gdm-2.32.1-1.1.mga1.src.rpm

--- gdm-2.29.5/data/PreSession.in.defaultconf	2010-01-13 18:21:31.000000000 +0100
+++ gdm-2.29.5/data/PreSession.in	2010-01-20 18:49:45.000000000 +0100
@@ -6,4 +6,4 @@
 #
 # Note that output goes into the .xsession-errors file for easy debugging
 #
-PATH="@X_PATH@:$PATH"
+PATH="$PATH"
--- gdm-2.29.5/data/Init.in.defaultconf	2010-01-13 18:21:31.000000000 +0100
+++ gdm-2.29.5/data/Init.in	2010-01-20 18:48:30.000000000 +0100
@@ -4,86 +4,24 @@
 #  -George
 
 PATH="@X_PATH@:$PATH"
-OLD_IFS=$IFS
 
-gdmwhich () {
-  COMMAND="$1"
-  OUTPUT=
-  IFS=:
-  for dir in $PATH
-  do
-    if test -x "$dir/$COMMAND" ; then
-      if test "x$OUTPUT" = "x" ; then
-        OUTPUT="$dir/$COMMAND"
-      fi
-    fi
-  done
-  IFS=$OLD_IFS
-  echo "$OUTPUT"
-}
-
-sysresources=/etc/X11/Xresources
-
-# merge in defaults
-if [ -f "$sysresources" ]; then
-    xrdb -merge "$sysresources"
+if [ -x /etc/X11/xinit/fixkeyboard ]; then
+   /etc/X11/xinit/fixkeyboard
 fi
 
-sysmodmap=/etc/X11/Xmodmap
-
-XMODMAP=`gdmwhich xmodmap`
-if [ "x$XMODMAP" != "x" ] ; then
-  if [ "x$GDM_PARENT_DISPLAY" = "x" ]; then
-    if [ -f $sysmodmap ]; then
-      $XMODMAP $sysmodmap
-    fi
-  else
-    ( DISPLAY=$GDM_PARENT_DISPLAY XAUTHORITY=$GDM_PARENT_XAUTHORITY $XMODMAP -pke ) | $XMODMAP -
-  fi
-
-  #
-  # Switch Sun's Alt and Meta mod mappings
-  #
-
-  UNAME=`gdmwhich uname`
-  PROCESSOR=`$UNAME -p`
-  if [ "x$PROCESSOR" = "xsparc" ]; then
-    if $XMODMAP | /usr/bin/grep mod4 | /usr/bin/grep Alt > /dev/null 2>/dev/null
-    then
-      $XMODMAP -e "clear Mod1" \
-               -e "clear Mod4" \
-               -e "add Mod1 = Alt_L" \
-               -e "add Mod1 = Alt_R" \
-               -e "add Mod4 = Meta_L" \
-               -e "add Mod4 = Meta_R"
-    fi
-  fi
+if [ -x /etc/X11/xinit.d/numlock ]; then
+  /etc/X11/xinit.d/numlock &
 fi
-
-SETXKBMAP=`gdmwhich setxkbmap`
-if [ "x$SETXKBMAP" != "x" ] ; then
-  # FIXME: is this all right?  Is this completely on crack?
-  # What this does is move the xkb configuration from the GDM_PARENT_DISPLAY
-  # FIXME: This should be done in code.  Or there must be an easier way ...
-  if [ -n "$GDM_PARENT_DISPLAY" ]; then
-    XKBSETUP=`( DISPLAY=$GDM_PARENT_DISPLAY XAUTHORITY=$GDM_PARENT_XAUTHORITY $SETXKBMAP -v )`
-    if [ -n "$XKBSETUP" ]; then
-      XKBKEYMAP=`echo "$XKBSETUP" | grep '^keymap' | awk '{ print $2 }'`
-      XKBTYPES=`echo "$XKBSETUP" | grep '^types' | awk '{ print $2 }'`
-      XKBCOMPAT=`echo "$XKBSETUP" | grep '^compat' | awk '{ print $2 }'`
-      XKBSYMBOLS=`echo "$XKBSETUP" | grep '^symbols' | awk '{ print $2 }'`
-      XKBGEOMETRY=`echo "$XKBSETUP" | grep '^geometry' | awk '{ print $2 }'`
-      if [ -n "$XKBKEYMAP" ]; then
-        $SETXKBMAP -keymap "$XKBKEYMAP"
-      elif [ -n "$XKBTYPES" -a -n "$XKBCOMPAT" -a -n "$XKBSYMBOLS" -a -n "$XKBGEOMETRY" ]; then
-        $SETXKBMAP -types "$XKBTYPES" -compat "$XKBCOMPAT" -symbols "$XKBSYMBOLS" -geometry "$XKBGEOMETRY"
-      elif [ -n "$XKBTYPES" -a -n "$XKBCOMPAT" -a -n "$XKBSYMBOLS" ]; then
-        $SETXKBMAP -types "$XKBTYPES" -compat "$XKBCOMPAT" -symbols "$XKBSYMBOLS"
-      elif [ -n "$XKBSYMBOLS" ]; then
-        $SETXKBMAP -symbols "$XKBSYMBOLS"
+for i in /etc/X11/xsetup.d/*.xsetup ; do
+   [ -d $i ] && continue
+    
+   if [ -x $i ]; then
+      if grep -q "# to be sourced" $i; then
+         . $i
+      else
+         $i &
       fi
-    fi
-  fi
-fi
+   fi
+done
 
 exit 0