Blame SOURCES/a2ps-4.13b-encoding.patch

8f1c6e
--- a2ps-4.13/etc/a2ps-site.cfg.in.encoding	2000-01-15 23:39:36.000000000 +0000
8f1c6e
+++ a2ps-4.13/etc/a2ps-site.cfg.in	2002-08-05 10:22:20.000000000 +0100
8f1c6e
@@ -11,7 +11,7 @@
8f1c6e
 #################################################################
8f1c6e
 
8f1c6e
 # Default encoding
8f1c6e
-Options: --encoding=@ENCODING@
8f1c6e
+#Options: --encoding=@ENCODING@
8f1c6e
 
8f1c6e
 # Default medium
8f1c6e
 Options: --medium=@MEDIUM@
8f1c6e
--- a2ps-4.13/src/main.c.encoding	2002-08-05 10:22:20.000000000 +0100
8f1c6e
+++ a2ps-4.13/src/main.c	2002-08-05 10:22:20.000000000 +0100
8f1c6e
@@ -32,6 +32,7 @@
8f1c6e
 /************************************************************************/
8f1c6e
 #include <assert.h>
8f1c6e
 #include <string.h>
8f1c6e
+#include <langinfo.h>
8f1c6e
 #include <locale.h>
8f1c6e
 
8f1c6e
 #include "a2ps.h"
8f1c6e
@@ -1021,9 +1022,8 @@
8f1c6e
   sheets_map = sheets_map_new ();
8f1c6e
   style_sheets = new_style_sheets ();
8f1c6e
 
8f1c6e
-  /* Process special case: Japanese Document */
8f1c6e
-  if (! strncmp (locale, "ja", 2) )
8f1c6e
-    job->requested_encoding_name = xstrdup ("euc-jp");
8f1c6e
+  /* Use locale to set default encoding. */
8f1c6e
+  job->requested_encoding_name = xstrdup (nl_langinfo (CODESET));
8f1c6e
 
8f1c6e
   /* Process the command line options. */
8f1c6e
   argn = a2ps_handle_options (job, argc, argv);
8f1c6e
--- a2ps-4.13/encoding/encoding.map.encoding	2002-08-05 10:22:20.000000000 +0100
8f1c6e
+++ a2ps-4.13/encoding/encoding.map	2002-08-05 10:38:55.000000000 +0100
8f1c6e
@@ -45,6 +45,7 @@
8f1c6e
 latin1			iso1
8f1c6e
 iso1			iso1
8f1c6e
 iso-8859-1		iso1
8f1c6e
+ansi_x3.4-1968		iso1
8f1c6e
 
8f1c6e
 latin2			iso2
8f1c6e
 iso2			iso2
8f1c6e
@@ -128,3 +129,6 @@
8f1c6e
 # Apple' Macintosh
8f1c6e
 mac			mac
8f1c6e
 macintosh		mac
8f1c6e
+
8f1c6e
+# We don't handle UTF-8 at all yet.  Sometimes latin1 will work...
8f1c6e
+utf-8			iso1