minor formatting changes
[deliverable/binutils-gdb.git] / binutils / nm.c
index 204c6a2f0cc0e949918fa42d2a0a8df0b3f9f65e..3e2ee12f492d1e71553813043fb2c6c2df1054f9 100644 (file)
@@ -1,5 +1,6 @@
 /* nm.c -- Describe symbol table of a rel file.
-   Copyright 1991, 92, 93, 94, 95, 96, 97, 1998 Free Software Foundation, Inc.
+   Copyright 1991, 92, 93, 94, 95, 96, 97, 98, 1999
+   Free Software Foundation, Inc.
 
    This file is part of GNU Binutils.
 
@@ -15,7 +16,8 @@
 
    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+   02111-1307, USA.  */
 
 #include "bfd.h"
 #include "progress.h"
@@ -372,6 +374,12 @@ main (argc, argv)
   int c;
   int retval;
 
+#if defined (HAVE_SETLOCALE) && defined (HAVE_LC_MESSAGES)
+  setlocale (LC_MESSAGES, "");
+#endif
+  bindtextdomain (PACKAGE, LOCALEDIR);
+  textdomain (PACKAGE);
+
   program_name = *argv;
   xmalloc_set_program_name (program_name);
 
@@ -477,7 +485,6 @@ main (argc, argv)
 #ifdef HAVE_SBRK
   if (show_stats)
     {
-      extern char **environ;
       char *lim = (char *) sbrk (0);
 
       fprintf (stderr, _("%s: data size %ld\n"), program_name,
@@ -892,7 +899,7 @@ display_rel_file (abfd, archive_bfd)
     {
       if (!(bfd_get_file_flags (abfd) & HAS_SYMS))
        {
-         printf (_("No symbols in \"%s\".\n"), bfd_get_filename (abfd));
+         fprintf (stderr, _("%s: no symbols\n"), bfd_get_filename (abfd));
          return;
        }
     }
@@ -1298,13 +1305,13 @@ print_archive_filename_bsd (filename)
 
 static void
 print_archive_filename_sysv (filename)
-     char *filename;
+     char *filename ATTRIBUTE_UNUSED;
 {
 }
 
 static void
 print_archive_filename_posix (filename)
-     char *filename;
+     char *filename ATTRIBUTE_UNUSED;
 {
 }
 \f
@@ -1312,7 +1319,7 @@ print_archive_filename_posix (filename)
 
 static void
 print_archive_member_bsd (archive, filename)
-     char *archive;
+     char *archive ATTRIBUTE_UNUSED;
      CONST char *filename;
 {
   if (!filename_per_symbol)
@@ -1420,7 +1427,7 @@ print_symbol_info_bsd (info, abfd)
      symbol_info *info;
      bfd *abfd;
 {
-  if (info->type == 'U')
+  if (info->type == 'U' || info->type == 'w')
     {
       printf ("%*s",
 #ifdef BFD64
@@ -1451,7 +1458,7 @@ print_symbol_info_sysv (info, abfd)
      bfd *abfd;
 {
   print_symname ("%-20s|", info->name, abfd);  /* Name */
-  if (info->type == 'U')
+  if (info->type == 'U' || info->type == 'w')
     printf ("        ");       /* Value */
   else
     print_value (info->value);
@@ -1474,7 +1481,7 @@ print_symbol_info_posix (info, abfd)
 {
   print_symname ("%s ", info->name, abfd);
   printf ("%c ", info->type);
-  if (info->type == 'U')
+  if (info->type == 'U' || info->type == 'w')
     printf ("        ");
   else
     print_value (info->value);
This page took 0.023823 seconds and 4 git commands to generate.