LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices



Reply
 
Search this Thread
Old 12-22-2008, 04:34 PM   #1
levantis
LQ Newbie
 
Registered: Nov 2008
Posts: 9

Rep: Reputation: 0
Language-tolerant Slackware (12.1)


I am russian and I learn japanese, and I use Windows, so I need some of my files on NTFS to be named in these languages (As well as other filesystems, of course). I tried a number of "Slackware language how-to"`s, but they didn`t lead to anything, except broken setcolsolefont dialog or undisplayable russian system alerts. Also, I`ve got a problem with languages in X - typing in russian or japanese to some programs (i.e. Skype). However, OpenSuSE didn`t have any of those problems (10.3 and 11.0 at least) - neihter in X, nor in console.

What is the difference between language-handling in those and what do I need to bring from SuSE to Slackware to make it as language-tolerant as SuSE is? I don`t mind recompiling the kernel, but not the loads of programs I have - unless it`s inevitable.

P.S. I`d also appreciate hints on fixing the setconsolefont script (Line 41 : ambigous redirect - the line where DIALOG command is executed)
 
Old 12-22-2008, 04:37 PM   #2
indienick
Senior Member
 
Registered: Dec 2005
Location: London, ON, Canada
Distribution: Arch, Ubuntu, Slackware, OpenBSD, FreeBSD
Posts: 1,853

Rep: Reputation: 65
Now, out of curiosity, why did you switch from OpenSuSE to Slackware if the language handling worked in OpenSuSE?
 
Old 12-22-2008, 04:52 PM   #3
Su-Shee
Member
 
Registered: Sep 2007
Location: Berlin
Distribution: Slackware
Posts: 509

Rep: Reputation: 41
Suse has several employees doing all this and as Suse started out as a German Linux distribution "a foreign language" has been an issue from the beginning.

Anyway - it all works on Slackware too.

I've written this little intro some time ago and it still applies.

In short, you have to do the following:

* enable Unicode support by setting the correct environment.

* choose the right fonts for either russian or/and japanese (Arial for example)

* install "scim" as an input engine - essentially, you type japanese in romanji like "nihon go" and the engine translates this into kana and makes suggestions for the appropriate kanji. Russian can be typed in three ways: plug in a russian keyboard and change the X/console keyboard layout entirely or ese a transparent foliage for a standard keyboard and switch the X/console layout (can be done on the fly with a running system back and forth) or you use scim. (Which is probably extremly annoying and slow for a native...)

* use as many Gtk applications as possible - Gtk - the underlying Pango to be precise has the _very_ helpful feature of supporting direct input of Unicode code points while pressing Ctrl-Shift-U<code point> - perfect for just typing an URL with a japanese domain or just needing some single letter in a foreign language.

To convert your Windows files (which use UTF-16 and not UTF-8 Unicode as Linux does), you ideally use "iconv".

It's definitely some tweaking involved, but you actually can have pretty decent support for mixed languages not being just ASCII or even not have roman letters.

I've got a setup essentially leaving everything English but being able to type German and read, input and print Japanese.

Last edited by Su-Shee; 12-22-2008 at 04:53 PM.
 
Old 12-22-2008, 04:58 PM   #4
ErV
Senior Member
 
Registered: Mar 2007
Location: Russia
Distribution: Slackware 12.2
Posts: 1,202
Blog Entries: 3

Rep: Reputation: 62
Hi.
Quote:
Originally Posted by levantis View Post
I am russian and I learn japanese, and I use Windows, so I need some of my files on NTFS to be named in these languages (As well as other filesystems, of course). I tried a number of "Slackware language how-to"`s, but they didn`t lead to anything, except broken setcolsolefont dialog or undisplayable russian system alerts. Also, I`ve got a problem with languages in X - typing in russian or japanese to some programs (i.e. Skype). However, OpenSuSE didn`t have any of those problems (10.3 and 11.0 at least) - neihter in X, nor in console.

What is the difference between language-handling in those and what do I need to bring from SuSE to Slackware to make it as language-tolerant as SuSE is? I don`t mind recompiling the kernel, but not the loads of programs I have - unless it`s inevitable.

P.S. I`d also appreciate hints on fixing the setconsolefont script (Line 41 : ambigous redirect - the line where DIALOG command is executed)
I had no problems with displaying russian and japanese filenames on ntfs volumes, and typing in english/russian. So, what exactly did you try to configure your system? And exactly which howtos have you tried?

Check this link. But since you want japanese, then you'll need utf8, not koi8-r, so you might also want to check this link too.

Last edited by ErV; 12-22-2008 at 04:59 PM.
 
Old 12-22-2008, 05:05 PM   #5
Su-Shee
Member
 
Registered: Sep 2007
Location: Berlin
Distribution: Slackware
Posts: 509

Rep: Reputation: 41
And just to advertise it a little more: Slackware is very Unicode-ready.

All one has to do is enabling it everywhere.
 
Old 12-25-2008, 01:06 PM   #6
levantis
LQ Newbie
 
Registered: Nov 2008
Posts: 9

Original Poster
Rep: Reputation: 0
At first, great thanks for such a fast response

Quote:
Originally Posted by indienick View Post
Now, out of curiosity, why did you switch from OpenSuSE to Slackware if the language handling worked in OpenSuSE?
It`s much more stable than SuSE is. For example, SuSE couldn`t normally handle several window managers or desktop environments. On Slackware, I`ve got awesome, gnome (GSB), KDE, Xfce, ion, ratpoison, and everything runs flawelssly, even if simultaneous on different X servers. I`ve never had any problems after installing new programs, unlike SuSE. Slackware is faster than SuSE, at least on my computer. Also, the whole system is very clear - everything is documented, commented and how-to`ed

Quote:
Originally Posted by ErV
So, what exactly did you try to configure your system? And exactly which howtos have you tried?
Editing files in /usr/share/kbd (as coosing locale, mapping, etc. - don`t remember already). Also, choosing a russian font with setcolsolefont.
Update : the string was Line41 : $REPLY : ambiguous redirect.
I got to the roots of it : the folder /var/log/setup/tmp didn`t allow me to create files there, so the mktemp command gave an error and left REPLY empty. So, the dialog command got an emty string as a redirect (see 2> $REPLY). So I changed the permissions for /var/log/setup/tmp.

to SuShee : I didn`t find any .bashrc in my home folder. Should I make one? How does it have to look then? Also, if I`d like to use zsh and sh too, how to set everything for them?
 
Old 12-25-2008, 05:58 PM   #7
titopoquito
Senior Member
 
Registered: Jul 2004
Location: Ruhr Area, Germany
Distribution: Slackware64 14.0
Posts: 1,525

Rep: Reputation: 94
Quote:
Originally Posted by levantis View Post
to SuShee : I didn`t find any .bashrc in my home folder. Should I make one? How does it have to look then? Also, if I`d like to use zsh and sh too, how to set everything for them?
I cannot tell about zsh and sh, but for bash many use .bashrc and .bash_profile. I have found many recommendations for .bash_profile to just source .bashrc like this and do nothing more:

Code:
#!/bin/bash

if [ -f "$HOME/.bashrc" ] ; then
   source $HOME/.bashrc
fi
There is no rules how .bashrc has to be. You can put any command in it that bash should run, like any "autostart" or alias or whatever.

Code:
#!/bin/bash
alias ls="ls -al"
# do whatever you like :)
 
Old 12-25-2008, 06:22 PM   #8
gargamel
Senior Member
 
Registered: May 2003
Distribution: Slackware, SLAX, OpenSuSE
Posts: 1,629

Rep: Reputation: 142Reputation: 142
Internationlisation and Localisation are traditional differentiators of SuSE.
And it's the advantage of open source and Linux that the experience and groundwork
done by SuSE and many other supporters, is shared with the rest of the community.

So Slackware, as a "conservative" distribution, heavily benefits from the pioneer work
of others, "modern" or even "bleeding-edge" distributions.

So Slackware is a parasit. That's why I use it.

What I am going to say: OpenSuSE is great, IMHO, and in fact,
everything is documented there, too, but you can have almost
everything, but YaST, on Slackware, too. Things like
multi-language support just are preconfigured in a useful way
for most applications in OpenSuSE, and must be configured by
hand in Slackware. This may be a disadvantage. On the other hand,
I haven't seen another system that can be configured "by hand" so
quickly and easily as Slackware.

gargamel

Last edited by gargamel; 12-25-2008 at 06:26 PM.
 
Old 12-25-2008, 06:46 PM   #9
ErV
Senior Member
 
Registered: Mar 2007
Location: Russia
Distribution: Slackware 12.2
Posts: 1,202
Blog Entries: 3

Rep: Reputation: 62
Quote:
Originally Posted by levantis View Post
Editing files in /usr/share/kbd (as coosing locale, mapping, etc. - don`t remember already). Also, choosing a russian font with setcolsolefont.
You must also set system locale to tell the system which language is being used, and which encoding you want. It should be explained in links I gave before.
 
Old 12-28-2008, 02:27 PM   #10
levantis
LQ Newbie
 
Registered: Nov 2008
Posts: 9

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by Su-Shee View Post
In short, you have to do the following
Well, so here are some results :
1. In file managers on reiserfs (and, probably, all other unix FS) the filenames ARE displayed correctly. I`m happy (:
2. In "terminal", "gnome-terminal" and "xterm" I can normally read and type russian & japanese. I`m happy twice (:
3. In console, I didn`t find a font which would now display the name correctly. I`ve downloaded one which is said to include both cyrillic and japanese character sets. However, it`s extension is .bdf, and I don`t know where to put it. Sorry, can`t tell where i`ve downloaded it from - all bookmarks and history were in firefox.
4. The .bashrc runs EVERY time I run bash - xterm and others included. That`s : a) annoying messages and a delay till all`s set up b) not needed (I really hope) c) prone to bugs with scim
5. firefox now crashes with this : /usr/lib/firefox-2.0.0.17/run-mozilla.sh: line 131: 4044 Segmentation fault "$prog" ${1+"$@"}


About that iconv - it converts the files themselves. However, I need the NAMES to be displayed. Slackware pretends these files just aren`t there.

Last edited by levantis; 12-28-2008 at 03:29 PM.
 
Old 12-28-2008, 03:42 PM   #11
Su-Shee
Member
 
Registered: Sep 2007
Location: Berlin
Distribution: Slackware
Posts: 509

Rep: Reputation: 41
Yes. iconv is for everything _in_ the file and convmv for the filenames themselves.

Console I've never cared for - if I actually use console and not a shell within an xterm I'm doing some config stuff as root and root is funny-char-less in my system - just to be on the safe side.

Firefox seg fault I have no idea; but I'm already in the FF3-generation.
 
Old 12-28-2008, 03:46 PM   #12
ErV
Senior Member
 
Registered: Mar 2007
Location: Russia
Distribution: Slackware 12.2
Posts: 1,202
Blog Entries: 3

Rep: Reputation: 62
Quote:
Originally Posted by levantis View Post
Slackware pretends these files just aren`t there.
This happens when you mount partition with default ntfs driver (instead of ntfs-3g) and forget to specify iocharset (or whatever that option was called on default ntfs driver). You should use ntfs-3g driver which is included in slackware 12.2.

/etc/fstab line for mounting ntfs partition will look like this:
Code:
/dev/hdc1	/mnt/common	ntfs-3g		defaults,locale=ru_RU.UTF8,gid=users,fmask=113,dmask=003 1 0
If your locale is not ru_RU.UTF8, you should insert the one you are using instead.
 
Old 12-29-2008, 07:43 AM   #13
levantis
LQ Newbie
 
Registered: Nov 2008
Posts: 9

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by ErV View Post
This happens when you mount partition with default ntfs driver (instead of ntfs-3g) and forget to specify iocharset (or whatever that option was called on default ntfs driver). You should use ntfs-3g driver which is included in slackware 12.2.

/etc/fstab line for mounting ntfs partition will look like this:
Code:
/dev/hdc1	/mnt/common	ntfs-3g		defaults,locale=ru_RU.UTF8,gid=users,fmask=113,dmask=003 1 0
If your locale is not ru_RU.UTF8, you should insert the one you are using instead.
yep! it works! YAAY!



btw, a little riddle : before I made the changes, the line would look like that :
/dev/hdc1 /mnt/d ntfs-3g umask=000 1 0
non-english files were not there.

doing
umount /mnt/d
mount /mnt/d
would use fstab, right?
but it solved the problem till next reboot (:
 
Old 12-29-2008, 07:57 AM   #14
ErV
Senior Member
 
Registered: Mar 2007
Location: Russia
Distribution: Slackware 12.2
Posts: 1,202
Blog Entries: 3

Rep: Reputation: 62
Quote:
Originally Posted by levantis View Post
btw, a little riddle : before I made the changes, the line would look like that :
/dev/hdc1 /mnt/d ntfs-3g umask=000 1 0
non-english files were not there.
Yes, because you didn't specify locale, ntfs-3g didn't know how to convert filenames and simply dropped all non-english names.

I guess in previous post I forgot that such problem (disappearing files if no locale is specified) was happening with ntfs-3g as well, not only with ntfs driver (as I said before).
 
  


Reply

Tags
language, slackware, suse


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Fault-tolerant Web hosting on a shoestring LXer Syndicated Linux News 0 05-10-2007 01:16 PM
LXer: Fault-tolerant Linux can compete with Windows LXer Syndicated Linux News 0 03-02-2007 05:31 PM
Slackware second language mjjzf Slackware 6 08-10-2005 10:18 AM
Fault tolerant IMAP server setup mikenac Linux - Software 2 02-27-2005 11:52 AM
Fault tolerant boot? Power outages? KendersPlace Linux - General 8 07-27-2003 04:21 AM


All times are GMT -5. The time now is 08:23 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration