OSDN Git Service

* coff-pe-read.c: New file - support reading of minimal symbols from a portable
[pf3gnuchains/pf3gnuchains3x.git] / gdb / coffread.c
index c2f140b..912943c 100644 (file)
@@ -46,6 +46,8 @@
 #include "gdb_assert.h"
 #include "block.h"
 
+#include "coff-pe-read.h"
+
 extern void _initialize_coffread (void);
 
 struct coff_symfile_info
@@ -1087,6 +1089,13 @@ coff_symtab_read (long symtab_offset, unsigned int nsyms,
        }
     }
 
+  if ((nsyms == 0) && (pe_file))
+    {
+      /* We've got no debugging symbols, but it's is a portable
+        executable, so try to read the export table */
+      read_pe_exported_syms (objfile);
+    }
+
   if (last_source_file)
     coff_end_symtab (objfile);