On Saturday 25 August 2001 15:32, J. Craig Woods wrote: > Sorry to be so blatant. > > But you may be the only one, other than Chmouel (whom we see little of), > I know of for this issue. I have posted this before with no results. It > may be unknown to most. You (Mandrakesoft) have done an excellent job > with even your beta releases. MandrakeFreg-3 is more stable than some of > your final releases in the "old days". In those earlier time, I "cut my > teeth" on Linux by fixing so many of the "bugs" in those releases. Hell, > I just installed Freq-3, and, other than some corrupted packages, it is > ready to go. But (ah, the inevitable "but") I have one issue that has > perplexed the hell out of me. Are the LC variables set up during the > kernel compile? They must be. I have looked at all of the files that set > up environment varibles, such as ".bashrc", "/etc/profile", and > "/etc/bashrc" but the LC varible is not to be found. I can see that most > of these varibles are setup (env | grep LC). With Freq-3, one of these > variable is missing, LC_ALL=?. What is the value of this varible, and > since the kernel came pre-compiled for Freq-3, can I just export this > varible to the environment? > > Any help in this matter would be most appreciated. I have looked high > and low to no avail. I can not believe that, with all the books I have > at my disposal, not one of them has an entry for LC. > > Thanks, > drjung try this url: file:/usr/share/locale (pauses to file a bug report about FHS--should be in /usr/share/doc) or man locale AFAICDetermine, LC_ALL is one of those infamous reserved variables Some of the variables have a _huge_ effect on the operation of programs, and these variables are usually set up at install time when you are asked what ketboard and what language(s) you have and want to use. How huge? Watch: [tester@civileme tester]$ echo B | grep "[a-z]" B [tester@civileme tester]$ locale LANG=en LC_CTYPE=en_US LC_NUMERIC=en_US LC_TIME=en_US LC_COLLATE=en_US LC_MONETARY=en_US LC_MESSAGES=en_US LC_PAPER="en" LC_NAME="en" LC_ADDRESS="en" LC_TELEPHONE="en" LC_MEASUREMENT="en" LC_IDENTIFICATION="en" LC_ALL= [tester@civileme tester]$ Last login: Sat Aug 11 10:05:39 2001 from 192.168.1.133 [civileme@ke civileme]$ echo B | grep "[a-z]" [civileme@ke civileme]$ locale LANG=POSIX LC_CTYPE="POSIX" LC_NUMERIC="POSIX" LC_TIME="POSIX" LC_COLLATE="POSIX" LC_MONETARY="POSIX" LC_MESSAGES="POSIX" LC_PAPER="POSIX" LC_NAME="POSIX" LC_ADDRESS="POSIX" LC_TELEPHONE="POSIX" LC_MEASUREMENT="POSIX" LC_IDENTIFICATION="POSIX" LC_ALL= [civileme@ke civileme]$ You see, the English collating sequence by POSIX standards is aAbBcC... so [a-z] means all the alphabet, upper and lower case except "Z" There are warnings in the regular expressions manual that such constructs might not be portable or might be locale-dependent, but most script writers seem to have blithely ignored these and used the [a-z] constrict instead of the more correct (and less flexible) [[:lower:]] (note the double brackets are required) of course if you encounter a flaky script counter it with another flaky one =============================== #!/bin/bash export LC_COLLATE="POSIX" =============================== then the flaky script should run... Some folks even claimed sed was broken in their bug reports because behavior now changes with locale settings. Anyway, I am unable to determine the current use of the LC_ALL variable. If it is in fact reserved, then it should be left strictly alone or things may not be portable when we implement even more of the POSIX standrads. With us in beta, my research time for such questions is coming out of my sleep, so please feel free to out-research me with the POSIX folks and the unicode consortium. Civileme
Want to buy your Pack or Services from MandrakeSoft? Go to http://wwww.mandrakestore.com
