Blame SOURCES/a2ps-4.13b-encoding.patch

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