source: npl/system/klibc/patches/dash-mkbuiltins-fix-sort-order-harder.patch

Last change on this file was c5c522c, checked in by Edwin Eefting <edwin@datux.nl>, 8 years ago

initial commit, transferred from cleaned syn3 svn tree

  • Property mode set to 100644
File size: 677 bytes
  • usr/dash/mkbuiltins

    From: Ben Hutchings <ben@decadent.org.uk>
    Date: Wed, 09 Sep 2015 02:12:40 +0100
    Subject: dash: mkbuiltins: Fix sort order harder
    Forwarded: http://www.zytor.com/pipermail/klibc/2016-January/003890.html
    
    LC_COLLATE can be overriden by LC_ALL, so set LC_ALL instead when
    running sort.
    
    Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
    ---
    a b awk '{ for (i = 2 ; i <= NF ; i++) { 
    7878                if ($i ~ /^-/)
    7979                        line = $(++i) "\t" line
    8080                print line
    81         }}' $temp | LC_COLLATE=C sort -k 1,1 | tee $temp2 | awk '{
     81        }}' $temp | LC_ALL=C sort -k 1,1 | tee $temp2 | awk '{
    8282                opt = ""
    8383                if (NF > 2) {
    8484                        opt = substr($2, 2)
Note: See TracBrowser for help on using the repository browser.