Locale changes from Bruno Haible <haible@clisp.cons.org>.
[deliverable/binutils-gdb.git] / binutils / coffdump.c
index 5cd75cb75f3eedcca1fc30b4149f44a660d2f142..0bd39f40d9ff2d91db16963ee86868e0e346b6c4 100644 (file)
@@ -1,5 +1,5 @@
 /* Coff file dumper.
-   Copyright (C) 1994, 1998 Free Software Foundation, Inc.
+   Copyright 1994, 1995, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
 
 This file is part of GNU Binutils.
 
@@ -33,7 +33,21 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define PROGRAM_VERSION "1.0"
 
 static int atnl;
-static void dump_coff_scope ();
+
+static void tab PARAMS ((int));
+static void nl PARAMS ((void));
+static void dump_coff_lines PARAMS ((struct coff_line *));
+static void dump_coff_type PARAMS ((struct coff_type *));
+static void dump_coff_where PARAMS ((struct coff_where *));
+static void dump_coff_visible PARAMS ((struct coff_visible *));
+extern void dump_coff_symbol PARAMS ((struct coff_symbol *));
+static void dump_coff_scope PARAMS ((struct coff_scope *));
+static void dump_coff_sfile PARAMS ((struct coff_sfile *));
+static void dump_coff_section PARAMS ((struct coff_section *));
+extern void coff_dump PARAMS ((struct coff_ofile *));
+static void show_usage PARAMS ((FILE *, int));
+static void show_help PARAMS ((void));
+extern int main PARAMS ((int, char **));
 
 static void
 tab (x)
@@ -476,8 +490,11 @@ main (ac, av)
       { NULL, no_argument, 0, 0 }
     };
 
-#ifdef HAVE_SETLOCALE
+#if defined (HAVE_SETLOCALE) && defined (HAVE_LC_MESSAGES)
   setlocale (LC_MESSAGES, "");
+#endif
+#if defined (HAVE_SETLOCALE)
+  setlocale (LC_CTYPE, "");
 #endif
   bindtextdomain (PACKAGE, LOCALEDIR);
   textdomain (PACKAGE);
@@ -513,9 +530,7 @@ main (ac, av)
 
   if (!input_file)
     {
-      fprintf (stderr,_("%s: no input file specified\n"),
-              program_name);
-      exit(1);
+      fatal (_("no input file specified"));
     }
   abfd = bfd_openr (input_file, 0);
 
This page took 0.024612 seconds and 4 git commands to generate.