core/chakra-initscripts/chakra-initscripts-2011.02-2.patch
2011-03-07 21:32:13 +00:00

618 lines
19 KiB
Diff

diff -Npur pkg/etc/rc.d/functions pkg.ch/etc/rc.d/functions
--- pkg/etc/rc.d/functions 2011-02-12 22:50:01.943333498 +0100
+++ pkg.ch/etc/rc.d/functions 2011-02-19 09:17:30.000000000 +0100
@@ -54,6 +54,8 @@ if [[ $USECOLOR = YES || $USECOLOR = yes
C_MAIN="\033[1;37;40m" # main text
C_OTHER="\033[1;34;40m" # prefix & brackets
+ C_OTHER2="\033[1;32;40m" # prefix & brackets (green)
+ C_OTHER3="\033[1;31;40m" # prefix & brackets (red)
C_SEPARATOR="\033[1;30;40m" # separator
C_BUSY="\033[0;36;40m" # busy
@@ -92,6 +94,14 @@ printhl() {
printf "${C_OTHER}${PREFIX_HL} ${C_H1}${1}${C_CLEAR} \n"
}
+printhl2() {
+ printf "${C_OTHER2}${PREFIX_HL} ${C_H1}${1}${C_CLEAR}\n"
+}
+
+printhl3() {
+ printf "${C_OTHER3}${PREFIX_HL} ${C_H1}${1}${C_CLEAR}\n"
+}
+
printsep() {
printf "\n${C_SEPARATOR} ------------------------------\n"
}
diff -Npur pkg/etc/rc.d/functions.d/cmdline pkg.ch/etc/rc.d/functions.d/cmdline
--- pkg/etc/rc.d/functions.d/cmdline 1970-01-01 01:00:00.000000000 +0100
+++ pkg.ch/etc/rc.d/functions.d/cmdline 2011-02-19 09:17:30.000000000 +0100
@@ -0,0 +1,52 @@
+get_bootparam_value()
+{
+ [ -z "$CMDLINE" ] && CMDLINE="$(< /proc/cmdline)"
+ case "$CMDLINE" in *\ $1=*) ;; *) return 1; ;; esac
+ local result="${CMDLINE##*$1=}"
+ echo ${result%%[ ]*}
+}
+
+get_country()
+{
+ local COUNTRY=`get_bootparam_value lang`
+ echo $COUNTRY
+}
+
+get_xmode()
+{
+ local XMODE=`get_bootparam_value xmode`
+ echo $XMODE
+}
+
+get_xdepth()
+{
+ local XDEPTH=`get_bootparam_value xdepth`
+ echo $XDEPTH
+}
+
+get_xres()
+{
+ local XRES=`get_bootparam_value xres`
+ echo $XRES
+}
+
+get_xdisplay()
+{
+ local XDISP=`get_bootparam_value xdisplay`
+ echo $XDISP
+}
+
+get_nonfree()
+{
+ local NONFREE=`get_bootparam_value nonfree`
+ echo $NONFREE
+}
+
+get_xdriver()
+{
+ local XDRIVER=`get_bootparam_value xdriver`
+ echo $XDRIVER
+}
+
+# End of file
+# vim: set ts=2 noet:
diff -Npur pkg/etc/rc.d/functions.d/sysinit pkg.ch/etc/rc.d/functions.d/sysinit
--- pkg/etc/rc.d/functions.d/sysinit 1970-01-01 01:00:00.000000000 +0100
+++ pkg.ch/etc/rc.d/functions.d/sysinit 2011-02-19 09:17:30.000000000 +0100
@@ -0,0 +1,92 @@
+# Functions used by rc.sysinit
+# These can be overwritten by sourcing another file, for example so that
+# modified versions for a live CD can be used.
+
+f_header ()
+{
+ echo " "
+ printhl "${C_CLEAR}CH${C_MAIN}A${C_OTHER}K${C_CLEAR}RA Linux\n"
+ printhl "${C_H2}http://www.chakra-project.org"
+ printhl "${C_CLEAR}Copyright 2006-2011 Chakra Developers Team"
+ printsep
+}
+
+f_fscheck ()
+{
+ status "Mounting Root Read-only" /bin/mount -n -o remount,ro /
+
+ if [ -x /sbin/fsck ]; then
+ stat_busy "Checking Filesystems"
+ if /bin/grep -qw quiet /proc/cmdline; then
+ /sbin/fsck -A -T -C -a -t $NETFS $FORCEFSCK >/dev/null 2>&1
+ else
+ /sbin/fsck -A -T -C -a -t $NETFS $FORCEFSCK 2>/dev/null
+ fi
+ fsckret=$?
+ if [ ${fsckret} -gt 1 ]; then
+ stat_fail
+ if [ $((${fsckret}&2)) -eq 2 ]; then
+ echo
+ echo "********************** REBOOT REQUIRED *********************"
+ echo "* *"
+ echo "* The system will be rebooted automatically in 15 seconds. *"
+ echo "* *"
+ echo "************************************************************"
+ echo
+ /bin/sleep 15
+ else
+ echo
+ echo "***************** FILESYSTEM CHECK FAILED ****************"
+ echo "* *"
+ echo "* Please repair manually and reboot. Note that the root *"
+ echo "* file system is currently mounted read-only. To remount *"
+ echo "* it read-write type: mount -n -o remount,rw / *"
+ echo "* When you exit the maintenance shell the system will *"
+ echo "* reboot automatically. *"
+ echo "* *"
+ echo "************************************************************"
+ echo
+ /sbin/sulogin -p
+ fi
+ echo "Automatic reboot in progress..."
+ /bin/umount -a
+ /bin/mount -n -o remount,ro /
+ /sbin/reboot -f
+ exit 0
+ fi
+ stat_done
+ fi
+
+ stat_busy "Mounting Local Filesystems"
+ /bin/mount -n -o remount,rw /
+ /bin/rm -f /etc/mtab*
+ # make sure / gets written to /etc/mtab
+ /bin/mount -o remount,rw /
+
+ f_mountlocal
+ stat_done
+}
+
+f_mountlocal ()
+{
+ # re-mount /proc , /sys and usbfs so they can be written to /etc/mtab
+ /bin/umount /proc/bus/usb
+ if [ -e /proc/mounts ]; then
+ /bin/grep -e "/proc " -e "/sys " -e "/dev " /proc/mounts >> /etc/mtab
+ fi
+ if /bin/grep -qw usbfs /proc/filesystems; then
+ # Some people use custom permissions for their usbfs
+ if /bin/grep -v "^#" /etc/fstab | /bin/grep -qw /proc/bus/usb ; then
+ /bin/mount /proc/bus/usb
+ else
+ /bin/mount -t usbfs none /proc/bus/usb
+ fi
+ fi
+ # now mount all the local filesystems
+ /bin/mount -a -t $NETFS
+}
+
+f_swapon ()
+{
+ status "Activating Swap" /sbin/swapon -a
+}
diff -Npur pkg/etc/rc.d/functions.d/sysinit-chakra pkg.ch/etc/rc.d/functions.d/sysinit-chakra
--- pkg/etc/rc.d/functions.d/sysinit-chakra 1970-01-01 01:00:00.000000000 +0100
+++ pkg.ch/etc/rc.d/functions.d/sysinit-chakra 2011-02-19 09:17:30.000000000 +0100
@@ -0,0 +1,55 @@
+# Functions used by rc.sysinit
+# Modified versions for larch live systems
+
+f_header ()
+{
+printsep
+echo " "
+printhl "${C_CLEAR}CH${C_MAIN}A${C_OTHER}K${C_CLEAR}RA >= 2010.07 (${C_FAIL}beta1-preview${C_CLEAR})\n"
+printhl "${C_H2}http://www.chakra-project.org"
+printhl "${C_CLEAR}Copyright 2006-2010 Chakra Developers Team"
+printsep
+echo " "
+}
+
+f_fscheck ()
+{
+ stat_busy "Initializing /etc/mtab"
+ #/bin/mount -n -o remount,rw /
+
+ /bin/rm -f /etc/mtab*
+
+ # Make entries for aufs/unionfs, tmpfs and live medium in /etc/mtab
+ grep "^aufs */ " /proc/mounts >>/etc/mtab
+ grep "^unionfs */ " /proc/mounts >>/etc/mtab
+ grep "^tmpfs */.livesys " /proc/mounts >>/etc/mtab
+ if [ -d /.livesys/medium/larch ]; then
+ grep " /.livesys/medium " /proc/mounts >>/etc/mtab
+ fi
+
+ f_mountlocal
+ stat_done
+
+ if [ -z "$( cat /etc/fstab | grep "^#KEEP" )" ]; then
+ stat_busy "Generating fresh /etc/fstab"
+ /opt/larch-live/run/gen_fstab -l
+ stat_done
+ fi
+
+ # now mount all the local filesystems
+ stat_busy "Mounting Local Filesystems"
+ /bin/mount -a -t $NETFS
+ stat_done
+}
+
+f_swapon ()
+{
+ #+*** Copy session-save flag-file (if it exists)
+ [ -f /larch/nosave ] && cp /larch/nosave /.livesys
+ #-***
+
+ #*** Conditional swap activation
+ if [ -e /.livesys/swapon ]; then
+ status "Activating Swap" /sbin/swapon -a
+ fi
+}
diff -Npur pkg/etc/rc.local pkg.ch/etc/rc.local
--- pkg/etc/rc.local 2011-02-12 22:50:01.933333498 +0100
+++ pkg.ch/etc/rc.local 2011-02-19 09:17:30.000000000 +0100
@@ -3,4 +3,15 @@
# /etc/rc.local: Local multi-user startup script.
#
+# set correct permissions for live user
+/bin/chown -R live:users /home/live
+# fix sudoers file
+/bin/chown root:root /etc/sudoers
+/bin/chmod 0440 /etc/sudoers
+
+# misc exports
+export KDE_NO_IPV6="TRUE"
+export OPERAPLUGINWRAPPER_PRIORITY=0
+export OOO_FORCE_DESKTOP=kde4
+export SAL_NOOPENGL=true
diff -Npur pkg/etc/rc.sysinit pkg.ch/etc/rc.sysinit
--- pkg/etc/rc.sysinit 2011-02-12 22:50:01.940000165 +0100
+++ pkg.ch/etc/rc.sysinit 2011-02-19 09:17:30.000000000 +0100
@@ -354,6 +354,346 @@ status "Updating Module Dependencies" /s
# Flush old locale settings
: >| /etc/profile.d/locale.sh
/bin/chmod 755 /etc/profile.d/locale.sh
+
+#
+# hack to be able to set the locale on bootup
+#
+COUNTRY=`get_country`
+[ -n "$COUNTRY" ] || COUNTRY="enus"
+
+ case "$COUNTRY" in
+ ast)
+ # Asturian
+ LOCALE="ast_ES.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Madrid"
+ KEYMAP="es"
+ XKEYMAP="es"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"es"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ be)
+ # Belarusian
+ LOCALE="be_BY.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Brussels"
+ KEYMAP="be"
+ XKEYMAP="be"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"be"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ bg)
+ # Bulgarian
+ LOCALE="bg_BG.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Sofia"
+ KEYMAP="bg"
+ XKEYMAP="bg"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"bg"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ ca)
+ # Catalan
+ LOCALE="ca_ES.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Madrid"
+ KEYMAP="es"
+ XKEYMAP="es"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"es"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ cs)
+ # Czech
+ LOCALE="cs_CZ.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Prague"
+ KEYMAP="cz-lat2"
+ XKEYMAP="cz"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"cz"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ de)
+ # German
+ LOCALE="de_DE.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Berlin"
+ KEYMAP="de"
+ XKEYMAP="de"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"de"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ dk)
+ # Danish
+ LOCALE="da_DK.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Copenhagen"
+ KEYMAP="dk"
+ XKEYMAP="dk"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"dk"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ engb)
+ # British
+ LOCALE="en_GB.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/London"
+ KEYMAP="us"
+ XKEYMAP="us"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"us"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ enus)
+ # English
+ LOCALE="en_US.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Canada/Pacific"
+ KEYMAP="us"
+ XKEYMAP="us"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"us"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ es)
+ # Spain
+ LOCALE="es_ES.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Madrid"
+ KEYMAP="es"
+ XKEYMAP="es"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"es"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ eu)
+ # Basque
+ LOCALE="eu_ES.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Madrid"
+ KEYMAP="es"
+ XKEYMAP="es"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"es"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ fi)
+ # Finland
+ LOCALE="fi_FI.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Helsinki"
+ KEYMAP="fi"
+ XKEYMAP="fi"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"fi"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ fr)
+ # France
+ LOCALE="fr_FR.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Paris"
+ KEYMAP="fr"
+ XKEYMAP="fr"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"fr"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ gl)
+ # Galician
+ LOCALE="gl_ES.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Madrid"
+ KEYMAP="es"
+ XKEYMAP="es"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"es"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ hu)
+ # Hungary
+ LOCALE="hu_HU.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Budapest"
+ KEYMAP="hu"
+ XKEYMAP="hu"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"hu"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ hr)
+ # Croatian
+ LOCALE="hr_HR.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Zagreb"
+ KEYMAP="hr"
+ XKEYMAP="hr"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"hr"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ it)
+ # Italy
+ LOCALE="it_IT.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Rome"
+ KEYMAP="it"
+ XKEYMAP="it"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"it"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ ja)
+ # Japanese
+ LOCALE="ja_JP.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Asia/Tokyo"
+ KEYMAP="us"
+ XKEYMAP="us"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"us"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ nl)
+ # Dutch
+ LOCALE="nl_NL.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Amsterdam"
+ KEYMAP="us"
+ XKEYMAP="us"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"us"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ no)
+ # Norway
+ LOCALE="nb_NO.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Oslo"
+ KEYMAP="no"
+ XKEYMAP="no"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"no"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ pl)
+ # Poland
+ LOCALE="pl_PL.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Warsaw"
+ KEYMAP="pl"
+ XKEYMAP="pl"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"pl"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ ptbr)
+ # Poland
+ LOCALE="pt_BR.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="America/Belem"
+ KEYMAP="br-abnt2"
+ XKEYMAP="pt"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"pt"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ ru)
+ # Russia
+ LOCALE="ru_RU.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Moscow"
+ KEYMAP="ru"
+ XKEYMAP="ru"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"ru"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ sk)
+ # Slovak
+ LOCALE="sk_SK.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Bratislava"
+ KEYMAP="sk"
+ XKEYMAP="sk"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"sk"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ sl)
+ # Slovenian
+ LOCALE="sl_SI.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Ljubljana"
+ KEYMAP="slovene"
+ XKEYMAP="si"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"si"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ sr)
+ # Serbian
+ LOCALE="sr_RS.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Belgrade"
+ KEYMAP="sr"
+ XKEYMAP="sr"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"sr"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ tr)
+ # Turkish
+ LOCALE="tr_TR.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Istanbul"
+ KEYMAP="tr"
+ XKEYMAP="trq"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"tr"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ vcia)
+ # Catalan (valencia)
+ LOCALE="ca_ES.utf8@valencia"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Europe/Madrid"
+ KEYMAP="es"
+ XKEYMAP="es"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"es"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ zhcn)
+ # Simplified Chinese
+ LOCALE="zh_CN.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Asia/Shanghai"
+ KEYMAP="us"
+ XKEYMAP="us"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"us"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ *)
+ # American
+ LOCALE="en_US.utf8"
+ HARDWARECLOCK="localtime"
+ TIMEZONE="Canada/Pacific"
+ KEYMAP="us"
+ XKEYMAP="us"
+ # add HAL config for Xorg input stuff
+ cp -f /etc/skel/10-keyboard.conf /etc/X11/xorg.conf.d/10-keyboard.conf
+ sed -i "/XkbLayout/ s/us/"us"/" /etc/X11/xorg.conf.d/10-keyboard.conf
+ ;;
+ esac
+
# Set user defined locale
[[ $LOCALE ]] || LOCALE="en_US"
stat_busy "Setting Locale: $LOCALE"
diff -Npur pkg/etc/skel/10-keyboard.conf pkg.ch/etc/skel/10-keyboard.conf
--- pkg/etc/skel/10-keyboard.conf 1970-01-01 01:00:00.000000000 +0100
+++ pkg.ch/etc/skel/10-keyboard.conf 2011-02-19 09:17:30.000000000 +0100
@@ -0,0 +1,5 @@
+Section "InputClass"
+ Identifier "Keyboard Defaults"
+ MatchIsKeyboard "yes"
+ Option "XkbLayout" "us"
+EndSection
\ Kein Zeilenumbruch am Dateiende.