summaryrefslogtreecommitdiffstats
path: root/make_slackware_live.sh
diff options
context:
space:
mode:
author Eric Hameleers <alien@slackware.com>2016-01-05 09:36:14 +0100
committer Eric Hameleers <alien@slackware.com>2016-01-05 09:36:14 +0100
commitcea6043290fb411ad7c693007e4f62fc8687a02d (patch)
treeb29192a67506b32ace2cdbf5fe91b46be65390c1 /make_slackware_live.sh
parent65901f0dd71776c98e228e9df05e900e431224d2 (diff)
downloadliveslak-cea6043290fb411ad7c693007e4f62fc8687a02d.tar.gz
liveslak-cea6043290fb411ad7c693007e4f62fc8687a02d.tar.xz
Added support for separate configuration of X keyboard layout/variant.
New parameter for the boot commandline: xkb=[language],variant Examples: # Only specify a Xkbvariant, and inherit the console keyboard layout in X: kbd=nl xkb=,sundeadkeys # Define a 'french swiss' layout in X, independent of the console: xkb=ch,fr Two new keyboard/language choices have been added which use this functionality: - german swiss - french swiss (requested by Niki Kovacs). New: if a non-US keyboard layout is selected, the US layout will be added as a secondary layout. Toggling between the two layouts is possible using the Shift-LeftAlt key combo. Also new: the RightAlt key is now defined as the Compose Key in X. Meaning, the combo <RightAlt><"><e> will generate a 'ë character'.
Diffstat (limited to 'make_slackware_live.sh')
-rwxr-xr-xmake_slackware_live.sh23
1 files changed, 12 insertions, 11 deletions
diff --git a/make_slackware_live.sh b/make_slackware_live.sh
index ed60869..0200ceb 100755
--- a/make_slackware_live.sh
+++ b/make_slackware_live.sh
@@ -330,10 +330,10 @@ function gen_bootmenu() {
-e "s/@SL_VERSION@/$SL_VERSION/g" \
> ${MENUROOTDIR}/vesamenu.cfg
- for KBD in $(cat ${LIVE_TOOLDIR}/languages |grep -Ev "(^ *#|^$)" |cut -d, -f3)
+ for LANCOD in $(cat ${LIVE_TOOLDIR}/languages |grep -Ev "(^ *#|^$)" |cut -d: -f1)
do
- LANCOD=$(cat ${LIVE_TOOLDIR}/languages |grep ",$KBD," |cut -d, -f1)
- LANDSC=$(cat ${LIVE_TOOLDIR}/languages |grep ",$KBD," |cut -d, -f2)
+ LANDSC=$(cat ${LIVE_TOOLDIR}/languages |grep "^$LANCOD:" |cut -d: -f2)
+ KBD=$(cat ${LIVE_TOOLDIR}/languages |grep "^$LANCOD:" |cut -d: -f3)
# First, create keytab files if they are missing:
if [ ! -f ${MENUROOTDIR}/${KBD}.ktl ]; then
keytab-lilo $(find /usr/share/kbd/keymaps/i386 -name "us.map.gz") $(find /usr/share/kbd/keymaps/i386 -name "${KBD}.map.gz") > ${MENUROOTDIR}/${KBD}.ktl
@@ -362,17 +362,18 @@ EOL
> ${MENUROOTDIR}/menu_${LANCOD}.cfg
# Generate custom language selection submenu for selected keyboard:
- for SUBKBD in $(cat ${LIVE_TOOLDIR}/languages |grep -Ev "(^ *#|^$)" |cut -d, -f3) ; do
+ for SUBCOD in $(cat ${LIVE_TOOLDIR}/languages |grep -Ev "(^ *#|^$)" |cut -d: -f1) ; do
+ SUBKBD=$(cat ${LIVE_TOOLDIR}/languages |grep "^$SUBCOD:" |cut -d: -f3)
cat <<EOL >> ${MENUROOTDIR}/lang_${LANCOD}.cfg
-label $(cat ${LIVE_TOOLDIR}/languages |grep ",$SUBKBD," |cut -d, -f1)
- menu label $(cat ${LIVE_TOOLDIR}/languages |grep ",$SUBKBD," |cut -d, -f2)
+label $(cat ${LIVE_TOOLDIR}/languages |grep "^$SUBCOD:" |cut -d: -f1)
+ menu label $(cat ${LIVE_TOOLDIR}/languages |grep "^$SUBCOD:" |cut -d: -f2)
EOL
if [ "$SUBKBD" = "$KBD" ]; then
echo " menu default" >> ${MENUROOTDIR}/lang_${LANCOD}.cfg
fi
cat <<EOL >> ${MENUROOTDIR}/lang_${LANCOD}.cfg
kernel /boot/generic
- append initrd=/boot/initrd.img load_ramdisk=1 prompt_ramdisk=0 rw printk.time=0 kbd=$KBD tz=$(cat ${LIVE_TOOLDIR}/languages |grep ",$SUBKBD," |cut -d, -f4) locale=$(cat ${LIVE_TOOLDIR}/languages |grep ",$SUBKBD," |cut -d, -f5)
+ append initrd=/boot/initrd.img load_ramdisk=1 prompt_ramdisk=0 rw printk.time=0 kbd=$KBD tz=$(cat ${LIVE_TOOLDIR}/languages |grep "^$SUBCOD:" |cut -d: -f4) locale=$(cat ${LIVE_TOOLDIR}/languages |grep "^$SUBCOD:" |cut -d: -f5)
EOL
done
@@ -424,10 +425,10 @@ set default = $sl_lang
EOL
# Create the remainder of the selection menus:
- for KBD in $(cat languages |grep -Ev "(^ *#|^$)" |cut -d, -f3) ; do
- LANCOD=$(cat languages |grep ",$KBD," |cut -d, -f1)
- LANDSC=$(cat languages |grep ",$KBD," |cut -d, -f2)
- LANLOC=$(cat languages |grep ",$KBD," |cut -d, -f5)
+ for LANCOD in $(cat languages |grep -Ev "(^ *#|^$)" |cut -d: -f1) ; do
+ LANDSC=$(cat languages |grep "^$LANCOD:" |cut -d: -f2)
+ KBD=$(cat languages |grep "^$LANCOD:" |cut -d: -f3)
+ LANLOC=$(cat languages |grep "^$LANCOD:" |cut -d: -f5)
# Add this entry to the keyboard selection menu:
cat <<EOL >> ${GRUBDIR}/kbd.cfg
menuentry "${LANDSC}" {