Results 1 to 1 of 1

Thread: Create an ISO with different language settings

  1. #1

    Create an ISO with different language settings

    I want to make a Kali XFCE Iso in spanish

    How could i smartly intgerate the changes and have activated by default spanish language and spanish keyboard?

    Modifing in chroot /etc/default/locale and etc/default/keyboard would be enough?
    If i have to run dpkg-reconfigure
    Can it be done in a root shell from live-build directory ?
    I am a bit confused about what can be done before building from the shell, I guess it has to be done with a script.

    --------------EDIT--------------------------------------------------------


    After playing around and trying different stuff I guess the easiest way is to add a script in your live-build-config/config/hooks directory and add some files in your includes.chroot folder




    ADD FILES IN YOUR INCLUDES.CHROOT FOLDERS

    /live-build-config/config/includes.chroot/etc/locale.gen

    create a folder etc if you do not have it
    Go inside the folder etc and copy paste form your system the file /etc/locale.gen,
    Open the version that your copied in your /live-build-config/config/includes.chroot/etc/ folder and unquote ( remove the # ) form the locale you want to use.

    /live-build-config/config/includes.chroot/etc/timezone

    just create a simple text file that you name timezone and simply write : Your continent/Your capital
    example >
    Code:
    Europe/Madrid

    /live-build-config/config/includes.chroot/etc/default/console-setup

    Now you need to create a folder called default in your etc folder
    open it and or paste the original file from a configuration made with the desired settings or create a file...
    for spanish, as an example, we need to make some change due to the special ascii characters used in common alphabet so we declare "Lat 15" for the CODESET
    Code:
    # CONFIGURATION FILE FOR SETUPCON
    
    # Consult the console-setup(5) manual page.
    
    ACTIVE_CONSOLES="/dev/tty[1-6]"
    
    CHARMAP="UTF-8"
    
    CODESET="Lat15"
    FONTFACE="Fixed"
    FONTSIZE="8x16"

    /live-build-config/config/includes.chroot/etc/default/crda


    create a file called crda where you write
    Code:
    REGDOMAIN=BO
    In order to be able to use high-power chipset with full power with defaults settings


    /live-build-config/config/includes.chroot/etc/default/keyboard

    mine look like this, the important variable is XKBLAYOUT, put the identifier of your country


    Code:
    # KEYBOARD CONFIGURATION FILE
    
    # Consult the keyboard(5) manual page.
    
    XKBMODEL="pc105"
    XKBLAYOUT="es"
    XKBVARIANT=""
    XKBOPTIONS=""
    
    BACKSPACE="guess"


    /live-build-config/config/includes.chroot/etc/default/locale

    adapt the following with your locale and save it

    Code:
    #  File generated by update-locale
    export LANG="es_ES.utf8"
    export LANGUAGE="es_ES.utf8"
    export LC_TYPE="ISO-8859-1"
    export LC_CTYPE="es_ES.utf8"
    export LC_NUMERIC="es_ES.utf8"
    export LC_TIME="es_ES.utf8"
    export LC_COLLATE="es_ES.utf8"
    export LC_MONETARY="es_ES.utf8"
    export LC_MESSAGES="es_ES.utf8"
    export LC_PAPER="es_ES.utf8"
    export LC_NAME="es_ES.utf8"
    export LC_ADDRESS="es_ES.utf8"
    export LC_TELEPHONE="es_ES.utf8"
    export LC_MEASUREMENT="es_ES.utf8"
    export LC_IDENTIFICATION="es_ES.utf8"



    MAKE A SCRIPT IN HOOKS TO LAUNCH LOCALES CONFIGURATION WHILE BUILDING

    It worked nice compiling form Kali GNOME 64 in french to Kali 32 bits Spanish so i t seems to be a pretty efficient way

    The script just need a bang line and then the orders you want to execute,
    you can see in your folders two kinds of extension for the scripts placed in hoock.
    So I named mine with *.hoock extension and put a second one with *binary extension to be sure it works...
    right now i am not sure if the one called binary or hoock was the one...
    I think it was the hoock one, but i have the red-blue wire dilemma right now...
    anyway, make two copies and that it.

    That "the script"

    Code:
    #!/bin/sh
    
    dpkg-reconfigure tzdata
    dpkg-reconfigure locales
    locale-gen new_locale


    You might think that it doesn't work because you will not see queyring or downloading from (...)translate_yourlanguage
    And until the very last moment you will thing nothing has been done and that you have to build again...

    Don't worry just before the end, check your console and you will see that you are first asked to configure your localization because the script is running "tzdata"



    once it is done it will start running the "reconfiguration" of your locales, that will make your desktop ISO in the choosen language



    and now you just have to press the down arrow to select the language you set up as the default one



    you will see the results in your building shell

    Code:
    P: Begin executing hooks...
    
    Current default time zone: 'Europe/Madrid'
    Local time is now:      Thu May 22 18:58:46 CEST 2014.
    Universal Time is now:  Thu May 22 16:58:46 UTC 2014.
    
    locales-all installed, skipping locales generation
    Generating locales (this might take a while)...
      es_ES.UTF-8... done





    ADD PACKAGES IN YOUR KALI.LIST.CHROOT


    Don't forget to had some packages to your kali.list.chroot if you want a nice and full language change.
    That the packages i added in order to have Kali XFCE in spanish and as far as i can see everything from the shell to the desktop untill the web browser is well set in Spanish


    Code:
    aspell-es
    task-spanish
    manpages-es
    util-linux-locales
    util-linux
    tasksel
    localization-config
    iceweasel-l10n-es-es
    myspell-es
    ispanish
    calligra-l10n-es

    ............



    .........Now you are done and can launch lb --config with your parameter and lb --build, you will see that you will be prompted to configure your locale as showed in the images above

    enjoy your ISO


    Cheers
    Last edited by kcdtv; 2014-05-23 at 00:02. Reason: fully solved

Similar Threads

  1. Create an ISO with different language settings
    By mtopp in forum Building Archive
    Replies: 0
    Last Post: 2021-05-07, 00:15
  2. Unable to open settings and VPN settings in Kali 2.0
    By jesusadolforodriguez in forum TroubleShooting Archive
    Replies: 0
    Last Post: 2015-09-09, 00:53

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •