Index: BOOK/patches.ent
===================================================================
--- BOOK/patches.ent	(revision 73fbec103d54b50645952ecf61ac1ca711bf8bc1)
+++ BOOK/patches.ent	(revision d33f80cdeca950bfab540312ace5e8ae899457c7)
@@ -26,5 +26,5 @@
 
 <!ENTITY coreutils-i18n-patch "coreutils-&coreutils-version;-i18n-1.patch">
-<!ENTITY coreutils-i18n-patch-md5 "e50af44aea772a6ad3e16938cc03f74c">
+<!ENTITY coreutils-i18n-patch-md5 "cc19ae40783df5015893bebcffbd398b">
 <!ENTITY coreutils-i18n-patch-size "108 KB">
 
Index: patches/coreutils-6.12-i18n-1.patch
===================================================================
--- patches/coreutils-6.12-i18n-1.patch	(revision 73fbec103d54b50645952ecf61ac1ca711bf8bc1)
+++ patches/coreutils-6.12-i18n-1.patch	(revision d33f80cdeca950bfab540312ace5e8ae899457c7)
@@ -3,10 +3,10 @@
 Initial Package Version: 6.12
 Upstream Status: Unkown
-Origin: Fedora and Bryan Kadzban
+Origin: Mandriva
 Description: i18n Updates
 
 diff -Naur coreutils-6.12.orig/lib/linebuffer.h coreutils-6.12/lib/linebuffer.h
 --- coreutils-6.12.orig/lib/linebuffer.h	2007-10-17 06:47:26.000000000 -0700
-+++ coreutils-6.12/lib/linebuffer.h	2009-01-08 12:56:49.000000000 -0800
++++ coreutils-6.12/lib/linebuffer.h	2009-01-08 20:14:37.000000000 -0800
 @@ -21,6 +21,11 @@
  
@@ -33,5 +33,5 @@
 diff -Naur coreutils-6.12.orig/src/cut.c coreutils-6.12/src/cut.c
 --- coreutils-6.12.orig/src/cut.c	2008-05-25 23:40:33.000000000 -0700
-+++ coreutils-6.12/src/cut.c	2009-01-08 12:56:49.000000000 -0800
++++ coreutils-6.12/src/cut.c	2009-01-08 20:14:37.000000000 -0800
 @@ -28,6 +28,11 @@
  #include <assert.h>
@@ -627,5 +627,5 @@
 diff -Naur coreutils-6.12.orig/src/expand.c coreutils-6.12/src/expand.c
 --- coreutils-6.12.orig/src/expand.c	2008-05-25 23:40:33.000000000 -0700
-+++ coreutils-6.12/src/expand.c	2009-01-08 12:56:49.000000000 -0800
++++ coreutils-6.12/src/expand.c	2009-01-08 20:14:37.000000000 -0800
 @@ -37,11 +37,28 @@
  #include <stdio.h>
@@ -824,5 +824,5 @@
 diff -Naur coreutils-6.12.orig/src/fold.c coreutils-6.12/src/fold.c
 --- coreutils-6.12.orig/src/fold.c	2008-05-25 23:40:33.000000000 -0700
-+++ coreutils-6.12/src/fold.c	2009-01-08 12:56:49.000000000 -0800
++++ coreutils-6.12/src/fold.c	2009-01-08 20:14:37.000000000 -0800
 @@ -22,11 +22,33 @@
  #include <getopt.h>
@@ -1230,5 +1230,5 @@
 diff -Naur coreutils-6.12.orig/src/join.c coreutils-6.12/src/join.c
 --- coreutils-6.12.orig/src/join.c	2008-05-25 23:40:32.000000000 -0700
-+++ coreutils-6.12/src/join.c	2009-01-08 12:56:49.000000000 -0800
++++ coreutils-6.12/src/join.c	2009-01-08 20:14:37.000000000 -0800
 @@ -22,17 +22,31 @@
  #include <sys/types.h>
@@ -1281,5 +1281,14 @@
  /* If nonzero, check that the input is correctly ordered. */
  static enum
-@@ -230,10 +246,11 @@
+@@ -221,6 +237,8 @@
+ 
+ /* Fill in the `fields' structure in LINE.  */
+ 
++/* Fill in the `fields' structure in LINE.  */
++
+ static void
+ xfields (struct line *line)
+ {
+@@ -230,10 +248,11 @@
    if (ptr == lim)
      return;
@@ -1295,154 +1304,5 @@
      }
    else
-@@ -260,6 +277,148 @@
-   extract_field (line, ptr, lim - ptr);
- }
- 
-+#if HAVE_MBRTOWC
-+static void
-+xfields_multibyte (struct line *line)
-+{
-+  char *ptr = line->buf.buffer;
-+  char const *lim = ptr + line->buf.length - 1;
-+  wchar_t wc = 0;
-+  size_t mblength = 1;
-+  mbstate_t state, state_bak;
-+
-+  memset (&state, 0, sizeof (mbstate_t));
-+
-+  if (ptr == lim)
-+    return;
-+
-+  if (tab != NULL)
-+    {
-+      unsigned char t = tab[0];
-+      char *sep = ptr;
-+      for (; ptr < lim; ptr = sep + mblength)
-+	{
-+	  sep = ptr;
-+	  while (sep < lim)
-+	    {
-+	      state_bak = state;
-+	      mblength = mbrtowc (&wc, sep, lim - sep + 1, &state);
-+
-+	      if (mblength == (size_t)-1 || mblength == (size_t)-2)
-+		{
-+		  mblength = 1;
-+		  state = state_bak;
-+		}
-+	      mblength = (mblength < 1) ? 1 : mblength;
-+
-+	      if (mblength == tablen && !memcmp (sep, tab, mblength))
-+		break;
-+	      else
-+		{
-+		  sep += mblength;
-+		  continue;
-+		}
-+	    }
-+
-+	  if (sep == lim)
-+	    break;
-+
-+	  extract_field (line, ptr, sep - ptr);
-+	}
-+    }
-+  else
-+    {
-+      /* Skip leading blanks before the first field.  */
-+      while(ptr < lim)
-+      {
-+        state_bak = state;
-+        mblength = mbrtowc (&wc, ptr, lim - ptr + 1, &state);
-+
-+        if (mblength == (size_t)-1 || mblength == (size_t)-2)
-+          {
-+            mblength = 1;
-+            state = state_bak;
-+            break;
-+          }
-+        mblength = (mblength < 1) ? 1 : mblength;
-+
-+        if (!iswblank(wc))
-+          break;
-+        ptr += mblength;
-+      }
-+
-+      do
-+	{
-+	  char *sep;
-+	  state_bak = state;
-+	  mblength = mbrtowc (&wc, ptr, lim - ptr + 1, &state);
-+	  if (mblength == (size_t)-1 || mblength == (size_t)-2)
-+	    {
-+	      mblength = 1;
-+	      state = state_bak;
-+	      break;
-+	    }
-+	  mblength = (mblength < 1) ? 1 : mblength;
-+
-+	  sep = ptr + mblength;
-+	  while (sep != lim)
-+	    {
-+	      state_bak = state;
-+	      mblength = mbrtowc (&wc, sep, lim - sep + 1, &state);
-+	      if (mblength == (size_t)-1 || mblength == (size_t)-2)
-+		{
-+		  mblength = 1;
-+		  state = state_bak;
-+		  break;
-+		}
-+	      mblength = (mblength < 1) ? 1 : mblength;
-+
-+	      if (iswblank (wc))
-+		break;
-+
-+	      sep += mblength;
-+	    }
-+
-+	  extract_field (line, ptr, sep - ptr);
-+	  if (sep == lim)
-+	    return;
-+
-+	  state_bak = state;
-+	  mblength = mbrtowc (&wc, sep, lim - sep + 1, &state);
-+	  if (mblength == (size_t)-1 || mblength == (size_t)-2)
-+	    {
-+	      mblength = 1;
-+	      state = state_bak;
-+	      break;
-+	    }
-+	  mblength = (mblength < 1) ? 1 : mblength;
-+
-+	  ptr = sep + mblength;
-+	  while (ptr != lim)
-+	    {
-+	      state_bak = state;
-+	      mblength = mbrtowc (&wc, ptr, lim - ptr + 1, &state);
-+	      if (mblength == (size_t)-1 || mblength == (size_t)-2)
-+		{
-+		  mblength = 1;
-+		  state = state_bak;
-+		  break;
-+		}
-+	      mblength = (mblength < 1) ? 1 : mblength;
-+
-+	      if (!iswblank (wc))
-+		break;
-+
-+	      ptr += mblength;
-+	    }
-+	}
-+      while (ptr != lim);
-+    }
-+
-+  extract_field (line, ptr, lim - ptr);
-+}
-+#endif
-+ 
- static struct line *
- dup_line (const struct line *old)
- {
-@@ -305,56 +464,115 @@
+@@ -305,56 +324,115 @@
  	size_t jf_1, size_t jf_2)
  {
@@ -1455,5 +1315,5 @@
 +  char *beg[2];
 +  char *copy[2];
-+  size_t len[2]; 	/* Length of fields to compare.  */
++  size_t len[2]; /* Length of fields to compare.  */
    int diff;
 +  int i, j;
@@ -1583,5 +1443,154 @@
  
  /* Check that successive input lines PREV and CURRENT from input file
-@@ -413,6 +631,11 @@
+@@ -393,6 +471,148 @@
+     }
+ }
+ 
++#if HAVE_MBRTOWC
++static void
++xfields_multibyte (struct line *line)
++{
++  char *ptr = line->buf.buffer;
++  char const *lim = ptr + line->buf.length - 1;
++  wchar_t wc = 0;
++  size_t mblength = 1;
++  mbstate_t state, state_bak;
++
++  memset (&state, 0, sizeof (mbstate_t));
++
++  if (ptr == lim)
++    return;
++
++  if (tab != NULL)
++    {
++      unsigned char t = tab[0];
++      char *sep = ptr;
++      for (; ptr < lim; ptr = sep + mblength)
++	{
++	  sep = ptr;
++	  while (sep < lim)
++	    {
++	      state_bak = state;
++	      mblength = mbrtowc (&wc, sep, lim - sep + 1, &state);
++
++	      if (mblength == (size_t)-1 || mblength == (size_t)-2)
++		{
++		  mblength = 1;
++		  state = state_bak;
++		}
++	      mblength = (mblength < 1) ? 1 : mblength;
++
++	      if (mblength == tablen && !memcmp (sep, tab, mblength))
++		break;
++	      else
++		{
++		  sep += mblength;
++		  continue;
++		}
++	    }
++
++	  if (sep == lim)
++	    break;
++
++	  extract_field (line, ptr, sep - ptr);
++	}
++    }
++  else
++    {
++      /* Skip leading blanks before the first field.  */
++      while(ptr < lim)
++      {
++        state_bak = state;
++        mblength = mbrtowc (&wc, ptr, lim - ptr + 1, &state);
++
++        if (mblength == (size_t)-1 || mblength == (size_t)-2)
++          {
++            mblength = 1;
++            state = state_bak;
++            break;
++          }
++        mblength = (mblength < 1) ? 1 : mblength;
++
++        if (!iswblank(wc))
++          break;
++        ptr += mblength;
++      }
++
++      do
++	{
++	  char *sep;
++	  state_bak = state;
++	  mblength = mbrtowc (&wc, ptr, lim - ptr + 1, &state);
++	  if (mblength == (size_t)-1 || mblength == (size_t)-2)
++	    {
++	      mblength = 1;
++	      state = state_bak;
++	      break;
++	    }
++	  mblength = (mblength < 1) ? 1 : mblength;
++
++	  sep = ptr + mblength;
++	  while (sep != lim)
++	    {
++	      state_bak = state;
++	      mblength = mbrtowc (&wc, sep, lim - sep + 1, &state);
++	      if (mblength == (size_t)-1 || mblength == (size_t)-2)
++		{
++		  mblength = 1;
++		  state = state_bak;
++		  break;
++		}
++	      mblength = (mblength < 1) ? 1 : mblength;
++
++	      if (iswblank (wc))
++		break;
++
++	      sep += mblength;
++	    }
++
++	  extract_field (line, ptr, sep - ptr);
++	  if (sep == lim)
++	    return;
++
++	  state_bak = state;
++	  mblength = mbrtowc (&wc, sep, lim - sep + 1, &state);
++	  if (mblength == (size_t)-1 || mblength == (size_t)-2)
++	    {
++	      mblength = 1;
++	      state = state_bak;
++	      break;
++	    }
++	  mblength = (mblength < 1) ? 1 : mblength;
++
++	  ptr = sep + mblength;
++	  while (ptr != lim)
++	    {
++	      state_bak = state;
++	      mblength = mbrtowc (&wc, ptr, lim - ptr + 1, &state);
++	      if (mblength == (size_t)-1 || mblength == (size_t)-2)
++		{
++		  mblength = 1;
++		  state = state_bak;
++		  break;
++		}
++	      mblength = (mblength < 1) ? 1 : mblength;
++
++	      if (!iswblank (wc))
++		break;
++
++	      ptr += mblength;
++	    }
++	}
++      while (ptr != lim);
++    }
++
++  extract_field (line, ptr, lim - ptr);
++}
++#endif
++
+ /* Read a line from FP into LINE and split it into fields.
+    Return true if successful.  */
+ 
+@@ -413,6 +633,11 @@
    line->nfields_allocated = 0;
    line->nfields = 0;
@@ -1595,5 +1604,5 @@
  
    if (prevline[which - 1])
-@@ -509,11 +732,18 @@
+@@ -509,11 +734,18 @@
  
  /* Print the join of LINE1 and LINE2.  */
@@ -1615,5 +1624,5 @@
    outlist = outlist_head.next;
    if (outlist)
-@@ -529,12 +759,12 @@
+@@ -529,12 +761,12 @@
  	  if (o->file == 0)
  	    {
@@ -1630,5 +1639,5 @@
  		  field = join_field_1;
  		}
-@@ -548,7 +778,7 @@
+@@ -548,7 +780,7 @@
  	  o = o->next;
  	  if (o == NULL)
@@ -1639,5 +1648,5 @@
        putchar ('\n');
      }
-@@ -566,23 +796,23 @@
+@@ -566,23 +798,23 @@
        prfield (join_field_1, line1);
        for (i = 0; i < join_field_1 && i < line1->nfields; ++i)
@@ -1667,5 +1676,5 @@
  	}
        putchar ('\n');
-@@ -1016,20 +1246,41 @@
+@@ -1016,20 +1248,41 @@
  
  	case 't':
@@ -1721,5 +1730,5 @@
 diff -Naur coreutils-6.12.orig/src/pr.c coreutils-6.12/src/pr.c
 --- coreutils-6.12.orig/src/pr.c	2008-05-25 23:40:32.000000000 -0700
-+++ coreutils-6.12/src/pr.c	2009-01-08 12:56:50.000000000 -0800
++++ coreutils-6.12/src/pr.c	2009-01-08 20:14:37.000000000 -0800
 @@ -312,6 +312,32 @@
  
@@ -2446,5 +2455,5 @@
 diff -Naur coreutils-6.12.orig/src/sort.c coreutils-6.12/src/sort.c
 --- coreutils-6.12.orig/src/sort.c	2008-05-25 23:40:32.000000000 -0700
-+++ coreutils-6.12/src/sort.c	2009-01-08 12:56:50.000000000 -0800
++++ coreutils-6.12/src/sort.c	2009-01-08 20:14:37.000000000 -0800
 @@ -22,10 +22,19 @@
  
@@ -3315,5 +3324,5 @@
 diff -Naur coreutils-6.12.orig/src/unexpand.c coreutils-6.12/src/unexpand.c
 --- coreutils-6.12.orig/src/unexpand.c	2008-05-25 23:40:33.000000000 -0700
-+++ coreutils-6.12/src/unexpand.c	2009-01-08 12:56:50.000000000 -0800
++++ coreutils-6.12/src/unexpand.c	2009-01-08 20:14:37.000000000 -0800
 @@ -38,11 +38,28 @@
  #include <stdio.h>
@@ -3570,5 +3579,5 @@
 diff -Naur coreutils-6.12.orig/src/uniq.c coreutils-6.12/src/uniq.c
 --- coreutils-6.12.orig/src/uniq.c	2008-05-25 23:40:32.000000000 -0700
-+++ coreutils-6.12/src/uniq.c	2009-01-08 12:56:50.000000000 -0800
++++ coreutils-6.12/src/uniq.c	2009-01-08 20:14:37.000000000 -0800
 @@ -22,6 +22,16 @@
  #include <getopt.h>
@@ -3939,5 +3948,5 @@
 diff -Naur coreutils-6.12.orig/tests/Makefile.am coreutils-6.12/tests/Makefile.am
 --- coreutils-6.12.orig/tests/Makefile.am	2008-05-27 04:47:53.000000000 -0700
-+++ coreutils-6.12/tests/Makefile.am	2009-01-08 12:56:50.000000000 -0800
++++ coreutils-6.12/tests/Makefile.am	2009-01-08 20:14:37.000000000 -0800
 @@ -191,6 +191,7 @@
    misc/shuf					\
@@ -3959,60 +3968,39 @@
    pr/0FF					\
    pr/0FFnt					\
-diff -Naur coreutils-6.12.orig/tests/misc/cut coreutils-6.12/tests/misc/cut
---- coreutils-6.12.orig/tests/misc/cut	2008-05-16 23:41:11.000000000 -0700
-+++ coreutils-6.12/tests/misc/cut	2009-01-08 12:56:50.000000000 -0800
-@@ -26,7 +26,7 @@
- my $prog = 'cut';
- my $try = "Try \`$prog --help' for more information.\n";
- my $from_1 = "$prog: fields and positions are numbered from 1\n$try";
--my $inval = "$prog: invalid byte or field list\n$try";
-+my $inval = "$prog: invalid byte, character or field list\n$try";
- my $no_endpoint = "$prog: invalid range with no endpoint: -\n$try";
- 
- my @Tests =
-@@ -141,7 +141,7 @@
- 
-   # None of the following invalid ranges provoked an error up to coreutils-6.9.
-   ['inval1', qw(-f 2-0), {IN=>''}, {OUT=>''}, {EXIT=>1},
--   {ERR=>"$prog: invalid decreasing range\n$try"}],
-+   {ERR=>"$inval"}],
-   ['inval2', qw(-f -), {IN=>''}, {OUT=>''}, {EXIT=>1}, {ERR=>$no_endpoint}],
-   ['inval3', '-f', '4,-', {IN=>''}, {OUT=>''}, {EXIT=>1}, {ERR=>$no_endpoint}],
-   ['inval4', '-f', '1-2,-', {IN=>''}, {OUT=>''}, {EXIT=>1}, {ERR=>$no_endpoint}],
 diff -Naur coreutils-6.12.orig/tests/misc/mb1.I coreutils-6.12/tests/misc/mb1.I
 --- coreutils-6.12.orig/tests/misc/mb1.I	1969-12-31 16:00:00.000000000 -0800
-+++ coreutils-6.12/tests/misc/mb1.I	2009-01-08 12:56:50.000000000 -0800
++++ coreutils-6.12/tests/misc/mb1.I	2009-01-08 20:14:37.000000000 -0800
 @@ -0,0 +1,4 @@
-+AppleïŒ 10
-+BananaïŒ 5
-+CitrusïŒ 20
-+CherryïŒ 30
++AppleïŒ 10
++BananaïŒ 5
++CitrusïŒ 20
++CherryïŒ 30
 diff -Naur coreutils-6.12.orig/tests/misc/mb1.X coreutils-6.12/tests/misc/mb1.X
 --- coreutils-6.12.orig/tests/misc/mb1.X	1969-12-31 16:00:00.000000000 -0800
-+++ coreutils-6.12/tests/misc/mb1.X	2009-01-08 12:56:50.000000000 -0800
++++ coreutils-6.12/tests/misc/mb1.X	2009-01-08 20:14:37.000000000 -0800
 @@ -0,0 +1,4 @@
-+BananaïŒ 5
-+AppleïŒ 10
-+CitrusïŒ 20
-+CherryïŒ 30
++BananaïŒ 5
++AppleïŒ 10
++CitrusïŒ 20
++CherryïŒ 30
 diff -Naur coreutils-6.12.orig/tests/misc/mb2.I coreutils-6.12/tests/misc/mb2.I
 --- coreutils-6.12.orig/tests/misc/mb2.I	1969-12-31 16:00:00.000000000 -0800
-+++ coreutils-6.12/tests/misc/mb2.I	2009-01-08 12:56:50.000000000 -0800
++++ coreutils-6.12/tests/misc/mb2.I	2009-01-08 20:14:37.000000000 -0800
 @@ -0,0 +1,4 @@
-+AppleïŒ ïŒ¡ïŒ¡10ïŒ ïŒ 20
-+BananaïŒ ïŒ¡ïŒ¡5ïŒ ïŒ 30
-+CitrusïŒ ïŒ¡ïŒ¡20ïŒ ïŒ 5
-+CherryïŒ ïŒ¡ïŒ¡30ïŒ ïŒ 10
++AppleïŒ ïŒ¡ïŒ¡10ïŒ ïŒ 20
++BananaïŒ ïŒ¡ïŒ¡5ïŒ ïŒ 30
++CitrusïŒ ïŒ¡ïŒ¡20ïŒ ïŒ 5
++CherryïŒ ïŒ¡ïŒ¡30ïŒ ïŒ 10
 diff -Naur coreutils-6.12.orig/tests/misc/mb2.X coreutils-6.12/tests/misc/mb2.X
 --- coreutils-6.12.orig/tests/misc/mb2.X	1969-12-31 16:00:00.000000000 -0800
-+++ coreutils-6.12/tests/misc/mb2.X	2009-01-08 12:56:50.000000000 -0800
++++ coreutils-6.12/tests/misc/mb2.X	2009-01-08 20:14:37.000000000 -0800
 @@ -0,0 +1,4 @@
-+CitrusïŒ ïŒ¡ïŒ¡20ïŒ ïŒ 5
-+CherryïŒ ïŒ¡ïŒ¡30ïŒ ïŒ 10
-+AppleïŒ ïŒ¡ïŒ¡10ïŒ ïŒ 20
-+BananaïŒ ïŒ¡ïŒ¡5ïŒ ïŒ 30
++CitrusïŒ ïŒ¡ïŒ¡20ïŒ ïŒ 5
++CherryïŒ ïŒ¡ïŒ¡30ïŒ ïŒ 10
++AppleïŒ ïŒ¡ïŒ¡10ïŒ ïŒ 20
++BananaïŒ ïŒ¡ïŒ¡5ïŒ ïŒ 30
 diff -Naur coreutils-6.12.orig/tests/misc/sort-mb-tests coreutils-6.12/tests/misc/sort-mb-tests
 --- coreutils-6.12.orig/tests/misc/sort-mb-tests	1969-12-31 16:00:00.000000000 -0800
-+++ coreutils-6.12/tests/misc/sort-mb-tests	2009-01-08 12:56:50.000000000 -0800
++++ coreutils-6.12/tests/misc/sort-mb-tests	2009-01-08 20:14:37.000000000 -0800
 @@ -0,0 +1,58 @@
 +#! /bin/sh
@@ -4031,5 +4019,5 @@
 +errors=0
 +
-+$xx -t ïŒ  -k2 -n misc/mb1.I > misc/mb1.O
++$xx -t ïŒ  -k2 -n misc/mb1.I > misc/mb1.O
 +code=$?
 +if test $code != 0; then
@@ -4049,5 +4037,5 @@
 +fi
 +
-+$xx -t ïŒ  -k4 -n misc/mb2.I > misc/mb2.O
++$xx -t ïŒ  -k4 -n misc/mb2.I > misc/mb2.O
 +code=$?
 +if test $code != 0; then
