Tiny Core Linux
Tiny Core Extensions => TCE Q&A Forum => Topic started by: ferran on March 31, 2020, 07:01:14 AM
-
I need to display on my aterm terminal the letters ñ, ç, and vowels with accents when I print a message in my language.
Thus, I downloaded and executed the getlocale.sh program and I selected my ideal local configuration "ca_ES@euro/ISO-8859-15" and once this was done a green message appeared saying
Done.The extensions at /mnt/sda1/tce/optional/mylocale.tcz in onboot.lst
Reboot with lang =xyz (for example lang=ca_ES@euro) to star using this.
Press enter to quit.
But I don't know where I must to change this "lang= " before I reboot my laptop (tell me the path exactly)
Thanks in advance.
-
The path depends on which boot loader you use (syslinux, grub, etc), but basically you need to edit syslinux.cfg, grub.cfg, etc.
..and aterm cannot display utf8 characters - you need gnome-terminal, rxvt, or similar.
-
HJi ferran
You need to add it to your boot loaders config file. Check under /mnt or your tce directory for a directory called boot. Under
there look for a configuration file (extlinux.conf, syslinux.cfg, or menu.lst). Add lang= to the line containing the word quiet.
-
At /mnt/sda1/boot/extlinux/extlinux.conf only have:
DEFAULT core
LABEL core
KERNEL /boot/vmlinuz
INITRD /boot/core.gz
APPEND quiet waitusb=5:UUID="88db56..." tce=UUID=88db56..."
I did too
find / -name "syconfig.cfg"
No such file or directory
find / -name "menu.lst"
No such file or directory
find / -name "grub.cfg"
No such file or directory
But now i have a doubt about it:
One thing is the local lang and other is the font. All fonts I selected in aterm termnal can't to display accents, Ñ or Ç etc. So, If i change to rxvt terminal : Will i able to diplay the Ñ, Ç etc. without change the "lang=" (wherever is it)?. Will getlocale.sh be able to fix this?
-
Sorry in the previous post I did a syntax mistake
I did too
find / -type f -name "syslinux.cfg"
No such file or directory
find / -type f -name "menu.lst"
No such file or directory
find / -type f -name "grub.cfg"
No such file or directory
-
Hi ferran
At /mnt/sda1/boot/extlinux/extlinux.conf only have:
DEFAULT core
LABEL core
KERNEL /boot/vmlinuz
INITRD /boot/core.gz
APPEND quiet waitusb=5:UUID="88db56..." tce=UUID=88db56..." ...
That's what you want. You want to add to the APPEND line so it looks something like this:
DEFAULT core
LABEL core
KERNEL /boot/vmlinuz
INITRD /boot/core.gz
APPEND quiet waitusb=5:UUID="88db56..." tce=UUID=88db56..." lang=ca_ES@euro
-
Actually aterm should be fine for this locale and those letters, they're iso-8859-15. You may need a different font though.
edit: The files you're using need to be in that encoding though. If you tested utf-8 files, they wouldn't display.
-
I saw that it don't worked fine... with "lang=ca_ES@euro" the aterm terminal displays ugly symbols for Ñ, Ç, @, vowels with accents, etc. After I tried with "lang=ca_ES/UTF-8" but is unable for the Editor program. Finally I changed to "lang=ca_ES" (with ISO-8859-1), not works in aterm terminal but the rest works well.
I'm start to think this don't have a good solution.
-
I'm going to take this back once I've checked the following:
a) Actually the /mnt/sda1/boot/extlinux/extlinux.conf works fine to set lang=ca_ES. (SOLVED)
b) The console (whit Ctrl+Alt+F1) works fine and displays Ñ, Ç, volwes with accents, @, etc. etc. typical in ca_ES settings. (SOLVED)
c) On the desktop:
1) gedit works fine with lang=ca_ES settings. (SOLVED)
2) the aterm terminal (by default with CorePlus v.11.0) NOT recognizes the ca_ES settings
3) Alternatively I got the rxvut terminal: it NOT recognizes too the ca_ES settings
In short, I still don't see my local keyboard settings on any used terminal.
Is there a solution to this?
-
3) Alternatively I got the rxvut terminal: it NOT recognizes too the ca_ES settings
It should. Works for me. I'll help you fix it.
Please post the output of locale and cat /proc/cmdline commands, like this:
bruno@box:~$ locale
LANG=en_US.UTF-8
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=
bruno@box:~$ cat /proc/cmdline
BOOT_IMAGE=/boot/vmlinuz64 tce=sda3/tce opt=sda3 blacklist=pcspkr,uvcvideo tz=EST+5EDT,M3.2.0/2,M11.1.0/2 syslog lang=en_US.UTF-8 user=bruno loglevel=0
-
GNUser:
In my locale I've all like you but with LANG=ca_ES and the rest options i've "ca_ES"
In my /proc/cmdline i've this (more different you have):
BOOT_IMAGE=/boot/vmlinuz quiet waitusb=5:UUID="88db5b6b-ae92-4d5a-999a-f536ea6cc4b6" tce=UUID="88db5b6b-ae92-4d5a-999a-f536ea6cc4b6" lang=ca_ES initrd=/boot/core.gz
What do you think i need to change about it ?
-
ferran, you would be better off with a UTF-8 locale. It's the standard and will prevent headaches such as this.
To solve all UTF8 issues I can think of, you need 4 things:
1. First, you need a UTF-8 locale extension. Re-run getlocale.sh and select ca_ES.UTF-8/UTF-8 (it's listed 17% down the list). This will create mylocale.tcz extension in your tce/optional/ directory
2. You also need the appropriate boot code. In your extlinux.conf make sure you have lang=ca_ES.UTF-8
3. You need a terminal font that supports UTF-8. I know that Luxi Mono supports UTF8 and is included by default, so please make sure you have this line in your ~/.Xdefaults:
URxvt*font: xft:Luxi Mono:pixelsize=14After we know your problem is gone, you can change the font to something else.
4. This is unrelated to UTF8 support in terminal, but you need to set G_FILENAME_ENCODING to something sensible so that gtk3 applications can handle UTF8 characters in filenames. Just add this line to your ~/.profile:
export G_FILENAME_ENCODING=@locale
After you do steps 1-3 above, I promise your terminal issues will go away (in urxvt, anyway. aterm does not support UTF8).
Let me know if you encounter any difficulties.
-
GNUser: right now i will try it changing first getlocale.sh and after the rest. I'll be back soon to tell you how it's going.
-
GNUser it works perfectly now !!
I can finally see the terminal with my language settings just as I wanted from the beginning i wanted.
This issue is completly solved.
Two suggestions:
1) Why don't you add the default getlocale.sh to the Tiny CorePlus v.11 installation and the subsequent changes to mylocale.tz, extlinux.conf and /proc/cmdline, in the non-US keyboard cases?
2) You could add by default the gedit and the xvrt terminal on the desktop.
GNUser I can't tell you how much I appreciate your help. Now I really do have a computer that works well.
Thank you very much.
-
I'm just a user, not a developer, but I think I can speak to your suggestions:
1. That won't work because people and their systems are too variable. Not everyone needs a UTF-8 locale. For those who do, some will want ca_ES.UTF-8, others will want en_US.UTF-8, others will want something else. The boot code (which is what you see in /proc/cmdline) has to match the desired locale. Also, not everybody has extlinux.conf (for instance, I use grub2 and don't have that file).
2. As above. Different strokes for different folks. I prefer geany as my GUI text editor, not gedit. For folks who don't need UTF8 support, the more minimalistic aterm may be preferable over urxvt.
TCL caters to all by "baking in" only the absolute bare minimum. Each user can then add to that minimum base whatever he needs or wants. The end result is a bloat-free system that has only a tiny base and the things you've added. There are no unused things sitting around to clutter your machine or for you to figure out what can be safely removed.
I hope you can now enjoy your TCL system as much as I enjoy mine. I'm glad I could help you :)
P.S. Now that your locale is properly configured, you can use whatever text editor you want--you are no longer tied down to gedit. Most text editors have built-in support for UTF-8.
-
You're right.
From now on I can focus on writing scripts in bash and I can use the zenity GUI, or develop rare languages with C and flex, etc. It will be fun.
-
@Rich please maybe you should put this topic as [SOLVED] :D
-
Hi ferran
@Rich please maybe you should put this topic as [SOLVED] :D
Done. :)