2.12.a calcboot

Purpose

calcboot is a module for Syslinux (calcmenu.c32), designed to remember the choice when using multiple boot menus. It also stores the background images for Grub and Syslinux.

calcmenu.c32 description

calcmenu.c32 is based on vesamenu.c32 and implements all features of the latter, while also adding new functionality.

1. stores the setting values

If you use multiple menus, the name of the menu file you want to go to when you choose this item is entered in the APPEND field. Unlike in a standard vesamenu.c32, these parameters are not reset.

Here is an example of a menu item:

APPEND isolinux.cfg calculate=,be_BY

If you select this item, the menu will be loaded from isolinux.cfg and the calculate=,be_BY option will be saved. As the result, when you choose the menu item from isolinux.cfg, containing

KERNEL /boot/vmlinuz
APPEND root=/dev/ram0 initrd=/boot/initrd init=/linuxrc looptype=squashfs unionfs

the kernel will boot with the parameter specified in APPEND, plus calculate=,be_BY.

2. overrides repeated values

The settings that were saved are not repeated. That is, if your calculate parameter is already saved, when you select the menu item which also specifies a calculate parameter, the old value of calculate will be overriden.

3. replaces values by position

Each parameter can store multiple values, comma-separated. For instance, the calculate parameter would store the language and the time zone (calculate = it_IT, Europe/Rome). To implement this, two menus will be created (lang.cfg, timezone.cfg), containing the following APPEND:

lang.cfg
...
APPEND timzone.cfg calculate=it_IT,
...

timezone.cfg
...
APPEND othermenu.cfg calculate=,Europe/Rome
...

If you choose this menu item, the calculate parameter will be saved for othermenu.cfg with the following values: it_IT,Europe/Rome.

4. restores the initial cursor position by parameter

To save the cursor position in the language menu, in the time zone menu, etc., use the following syntax in the menu file:

MENUPARAM <parameter> <number>

where parameter is the parameter that stores the selected value, and number is the position number. For instance, the following will be used for timezone.cfg (which describes the timezone menu):

MENUPARAM calculate 1

i.e. calculate, the second value. Thus, when timezone.cfg appears, if you have saved the calculate parameter and if it has a value in the second position, the cursor will point to the relevant menu item.

5. specifies the default values (added in version 3.86.5)

Use the following syntax to specify the default values:

DEFAULTPARAM <parameters>

For instance, if you want French to be the default language:

DEFAULTPARAM calculate=lang:fr_FR,keymap:fr_FR

Thank you!