2003-06-23 H.J. Lu <hongjiu.lu@intel.com>
authorH.J. Lu <hjl.tools@gmail.com>
Mon, 23 Jun 2003 23:39:39 +0000 (23:39 +0000)
committerH.J. Lu <hjl.tools@gmail.com>
Mon, 23 Jun 2003 23:39:39 +0000 (23:39 +0000)
* elflink.h (elf_link_input_bfd): Check raw size when using
kept_section to preserve debug information discarded by
linkonce.

bfd/ChangeLog
bfd/elflink.h

index 2e1a2a391db438e99e57de868e09fb698ebe2376..1e81fd7bb681f43c9876fce515580b6cd72a65eb 100644 (file)
@@ -1,3 +1,9 @@
+2003-06-23  H.J. Lu <hongjiu.lu@intel.com>
+
+       * elflink.h (elf_link_input_bfd): Check raw size when using
+       kept_section to preserve debug information discarded by
+       linkonce.
+
 2003-06-20  Alan Modra  <amodra@bigpond.net.au>
 
        * elf64-ppc.c (struct ppc_link_hash_table): Add top_id.
index 4a7d27def1eebfc68259e3df4fc104b400b3d9a1..75689466bea8ffa79a29618c171c7023d3bf375e 100644 (file)
@@ -5042,7 +5042,7 @@ elf_link_input_bfd (finfo, input_bfd)
                              /* Try to preserve debug information.  */
                              if ((o->flags & SEC_DEBUGGING) != 0
                                  && sec->kept_section != NULL
-                                 && sec->_cooked_size == sec->kept_section->_cooked_size)
+                                 && sec->_raw_size == sec->kept_section->_raw_size)
                                h->root.u.def.section
                                  = sec->kept_section;
                              else
@@ -5071,7 +5071,7 @@ elf_link_input_bfd (finfo, input_bfd)
                              /* Try to preserve debug information.  */
                              if ((o->flags & SEC_DEBUGGING) != 0
                                  && sec->kept_section != NULL
-                                 && sec->_cooked_size == sec->kept_section->_cooked_size)
+                                 && sec->_raw_size == sec->kept_section->_raw_size)
                                finfo->sections[r_symndx]
                                  = sec->kept_section;
                              else