On Sat, 15 Aug 2009 10:23:14 -0600, Matthew Burgess 
<matt...@linuxfromscratch.org> wrote:
> On Sat, 15 Aug 2009 09:04:44 -0700, Dan Nicholson <dbn.li...@gmail.com>
> wrote:
>> On Sat, Aug 15, 2009 at 8:54 AM, Matthew
>> Burgess<matt...@linuxfromscratch.org> wrote:
>>>
>>> Ah, it does, but only on an earlier invocation of sort!  So, I guess,
>>> for now, BLFS could have a patch to dash to add LC_COLLATE=C to the
> other
>>> call to sort in src/mkbuiltins.
>> 
>> Yeah, I'd send that upstream and cc Herbert Xu.
> 
> Only one problem, it still doesn't help!  The problem is that LANG, which
> is set in my /etc/profile, doesn't appear to be overridden by the LC_COLLATE
> setting.

OK, figured this out and it was indeed respecting LC_COLLATE, but that's not the
issue in this case.  It turns out that it's LC_CTYPE that needs to bet set in
this case:

$ sort -u -k 3,3 builtins
     0  .       -s      dotcmd

$ LC_CTYPE=C ./sort -u -k 3,3 builtins
    21  local   -a      localcmd
    14  export  -as     exportcmd
     3  alias   -au     aliascmd
     7  chdir   cdcmd
    10  echo    echocmd
    18  hash    hashcmd
    22  printf  printfcmd
    23  pwd     pwdcmd
     0  .       -s      dotcmd
     2  [       testcmd
    33  type    typecmd
     4  bg      -u      bgcmd
    34  ulimit  ulimitcmd

I'll send the patch up to Herbert now.

Regards,

Matt.

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to