daily update
[deliverable/binutils-gdb.git] / bfd / mmo.c
index 03b4e2e0b91d1875960f9085bf25c441cb24483f..091b341810be3d5b9d2b147ef7616c8a13ae3d87 100644 (file)
--- a/bfd/mmo.c
+++ b/bfd/mmo.c
@@ -1,5 +1,5 @@
 /* BFD back-end for mmo objects (MMIX-specific object-format).
-   Copyright 2001, 2002, 2003, 2004
+   Copyright 2001, 2002, 2003, 2004, 2005
    Free Software Foundation, Inc.
    Written by Hans-Peter Nilsson (hp@bitrange.com).
    Infrastructure and other bits originally copied from srec.c and
@@ -19,7 +19,7 @@ GNU General Public License for more details.
 
 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., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.  */
 
 /*
 SECTION
@@ -424,7 +424,7 @@ static bfd_boolean mmo_has_leading_or_trailing_zero_tetra_p (bfd *,
    particular input or caller; put such things into the bfd or elsewhere.
    Look ma, no static per-invocation data!  */
 
-static unsigned
+static
 char valid_mmo_symbol_character_set[/* A-Z a-z (we assume consecutive
                                       codes; sorry EBCDIC:ers!).  */
                                    + 'Z' - 'A' + 1 + 'z' - 'a' + 1
@@ -947,7 +947,7 @@ mmo_get_generic_spec_data_section (bfd *abfd, int spec_data_number)
 static asection *
 mmo_get_spec_section (bfd *abfd, int spec_data_number)
 {
-  bfd_byte *secname;
+  char *secname;
   asection *sec;
   bfd_byte buf[4];
   unsigned int secname_length;
@@ -996,7 +996,7 @@ mmo_get_spec_section (bfd *abfd, int spec_data_number)
       if (bfd_bread (secname + i * 4, 4, abfd) != 4)
        goto format_error_free;
 
-      if (secname[i * 4] == LOP)
+      if (secname[i * 4] == (char) LOP)
        {
          /* A bit of overkill, but we handle char 0x98 in a section name,
             and recognize misparsing.  */
@@ -1853,6 +1853,7 @@ mmo_scan (bfd *abfd)
                    rsec
                      = bfd_make_section_old_way (abfd,
                                                  MMIX_REG_CONTENTS_SECTION_NAME);
+                   rsec->flags |= SEC_LINKER_CREATED;
                    rsec->vma = z * 8;
                    loc = mmo_get_loc (rsec, z * 8, (255 - z) * 8);
                    bfd_put_64 (abfd, first_octa, loc);
@@ -2146,6 +2147,7 @@ mmo_canonicalize_symtab (bfd *abfd, asymbol **alocation)
            {
              c->section
                = bfd_make_section_old_way (abfd, MMIX_REG_SECTION_NAME);
+             c->section->flags |= SEC_LINKER_CREATED;
            }
          else
            {
@@ -2547,7 +2549,7 @@ EXAMPLE
 
   mmo_write_tetra_raw (abfd, LOP_SPEC_SECTION);
   mmo_write_tetra (abfd, (strlen (sec->name) + 3) / 4);
-  mmo_write_chunk (abfd, sec->name, strlen (sec->name));
+  mmo_write_chunk (abfd, (bfd_byte *) sec->name, strlen (sec->name));
   mmo_flush_chunk (abfd);
   /* FIXME: We can get debug sections (.debug_line & Co.) with a section
      flag still having SEC_RELOC set.  Investigate.  This might be true
@@ -3202,6 +3204,7 @@ mmo_canonicalize_reloc (bfd *abfd ATTRIBUTE_UNUSED,
 /* FIXME: We can do better on this one, if we have a dwarf2 .debug_line
    section or if MMO line numbers are implemented.  */
 #define mmo_find_nearest_line _bfd_nosymbols_find_nearest_line
+#define mmo_find_inliner_info _bfd_nosymbols_find_inliner_info
 #define mmo_make_empty_symbol _bfd_generic_make_empty_symbol
 #define mmo_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
 #define mmo_read_minisymbols _bfd_generic_read_minisymbols
This page took 0.024888 seconds and 4 git commands to generate.