1999-09-06 Donn Terry <donn@interix.com>
authorIan Lance Taylor <ian@airs.com>
Mon, 6 Sep 1999 18:44:56 +0000 (18:44 +0000)
committerIan Lance Taylor <ian@airs.com>
Mon, 6 Sep 1999 18:44:56 +0000 (18:44 +0000)
* syms.c (stt): Add some PE/PEI section names.
(bfd_decode_symclass): Return 'w', not 'U', for a weak undefined
symbol.
(bfd_symbol_info): Check for 'w'.

bfd/ChangeLog
bfd/syms.c

index d5d95dac0a403e38ddef73886c6ad3686607bf24..8a4fa9509c8347a1ebce0a439eb7a0b9df210133 100644 (file)
@@ -1,5 +1,10 @@
 1999-09-06  Donn Terry  <donn@interix.com>
 
+       * syms.c (stt): Add some PE/PEI section names.
+       (bfd_decode_symclass): Return 'w', not 'U', for a weak undefined
+       symbol.
+       (bfd_symbol_info): Check for 'w'.
+
        * section.c (struct bfd_comdat_info): Define.
        (asection): Add comdat field.
        (STD_SECTION): Initialize comdat field.
index 108e3eac27ba7faf338806dbceeebd02526c2c71..86dc66cbffce1c6f29a4a7cb0881f23ded8fe8ca 100644 (file)
@@ -523,6 +523,11 @@ static CONST struct section_to_type stt[] =
   {".sdata", 'g'},             /* Small initialized data.  */
   {".text", 't'},
   {"code", 't'},               /* MRI .text */
+  {".drectve", 'i'},            /* MSVC's .drective section */
+  {".idata", 'i'},              /* MSVC's .idata (import) section */
+  {".edata", 'e'},              /* MSVC's .edata (export) section */
+  {".pdata", 'p'},              /* MSVC's .pdata (stack unwind) section */
+  {".debug", 'N'},              /* MSVC's .debug (non-standard debug syms) */
   {0, 0}
 };
 
@@ -572,7 +577,12 @@ bfd_decode_symclass (symbol)
   if (bfd_is_com_section (symbol->section))
     return 'C';
   if (bfd_is_und_section (symbol->section))
-    return 'U';
+    {
+      if (symbol->flags & BSF_WEAK)
+       return 'w';
+      else
+       return 'U';
+    }
   if (bfd_is_ind_section (symbol->section))
     return 'I';
   if (symbol->flags & BSF_WEAK)
@@ -619,7 +629,7 @@ bfd_symbol_info (symbol, ret)
      symbol_info *ret;
 {
   ret->type = bfd_decode_symclass (symbol);
-  if (ret->type != 'U')
+  if (ret->type != 'U' && ret->type != 'w')
     ret->value = symbol->value + symbol->section->vma;
   else
     ret->value = 0;
This page took 0.030755 seconds and 4 git commands to generate.