X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=bfd%2Fcoffswap.h;h=60a04d432a2ff10b2badb0f6a1c87de306e37467;hb=8aaaf7577f070c91086533d959ac36a15d1d604f;hp=674fdc7791d6385400e5578f42dbcec951411b41;hpb=96d56e9f9150298df80355ce22ba007fe67f07ed;p=deliverable%2Fbinutils-gdb.git diff --git a/bfd/coffswap.h b/bfd/coffswap.h index 674fdc7791..60a04d432a 100644 --- a/bfd/coffswap.h +++ b/bfd/coffswap.h @@ -1,7 +1,5 @@ /* Generic COFF swapping routines, for BFD. - Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1999, 2000, - 2001, 2002, 2004, 2005, 2007 - Free Software Foundation, Inc. + Copyright (C) 1990-2019 Free Software Foundation, Inc. Written by Cygnus Support. This file is part of BFD, the Binary File Descriptor library. @@ -324,7 +322,7 @@ coff_swap_sym_in (bfd * abfd, void * ext1, void * in1) } in->n_value = H_GET_32 (abfd, ext->e_value); - in->n_scnum = H_GET_16 (abfd, ext->e_scnum); + in->n_scnum = (short) H_GET_16 (abfd, ext->e_scnum); if (sizeof (ext->e_type) == 2) in->n_type = H_GET_16 (abfd, ext->e_type); else @@ -431,7 +429,7 @@ coff_swap_aux_in (bfd *abfd, in->x_scn.x_nlinno = GET_SCN_NLINNO (abfd, ext); /* PE defines some extra fields; we zero them out for - safety. */ + safety. */ in->x_scn.x_checksum = 0; in->x_scn.x_associated = 0; in->x_scn.x_comdat = 0; @@ -620,17 +618,6 @@ coff_swap_aouthdr_in (bfd * abfd, void * aouthdr_ext1, void * aouthdr_int1) aouthdr_int->data_start = GET_AOUTHDR_DATA_START (abfd, aouthdr_ext->data_start); -#ifdef I960 - aouthdr_int->tagentries = H_GET_32 (abfd, aouthdr_ext->tagentries); -#endif - -#ifdef APOLLO_M68 - H_PUT_32 (abfd, aouthdr_int->o_inlib, aouthdr_ext->o_inlib); - H_PUT_32 (abfd, aouthdr_int->o_sri, aouthdr_ext->o_sri); - H_PUT_32 (abfd, aouthdr_int->vid[0], aouthdr_ext->vid); - H_PUT_32 (abfd, aouthdr_int->vid[1], aouthdr_ext->vid + 4); -#endif - #ifdef RS6000COFF_C #ifdef XCOFF64 aouthdr_int->o_toc = H_GET_64 (abfd, aouthdr_ext->o_toc); @@ -691,10 +678,6 @@ coff_swap_aouthdr_out (bfd * abfd, void * in, void * out) PUT_AOUTHDR_DATA_START (abfd, aouthdr_in->data_start, aouthdr_out->data_start); -#ifdef I960 - H_PUT_32 (abfd, aouthdr_in->tagentries, aouthdr_out->tagentries); -#endif - #ifdef RS6000COFF_C #ifdef XCOFF64 H_PUT_64 (abfd, aouthdr_in->o_toc, aouthdr_out->o_toc); @@ -769,9 +752,6 @@ coff_swap_scnhdr_in (bfd * abfd, void * ext, void * in) scnhdr_int->s_flags = GET_SCNHDR_FLAGS (abfd, scnhdr_ext->s_flags); scnhdr_int->s_nreloc = GET_SCNHDR_NRELOC (abfd, scnhdr_ext->s_nreloc); scnhdr_int->s_nlnno = GET_SCNHDR_NLNNO (abfd, scnhdr_ext->s_nlnno); -#ifdef I960 - scnhdr_int->s_align = GET_SCNHDR_ALIGN (abfd, scnhdr_ext->s_align); -#endif #ifdef COFF_ADJUST_SCNHDR_IN_POST COFF_ADJUST_SCNHDR_IN_POST (abfd, ext, in); #endif @@ -796,10 +776,6 @@ coff_swap_scnhdr_out (bfd * abfd, void * in, void * out) PUT_SCNHDR_RELPTR (abfd, scnhdr_int->s_relptr, scnhdr_ext->s_relptr); PUT_SCNHDR_LNNOPTR (abfd, scnhdr_int->s_lnnoptr, scnhdr_ext->s_lnnoptr); PUT_SCNHDR_FLAGS (abfd, scnhdr_int->s_flags, scnhdr_ext->s_flags); -#if defined(M88) - H_PUT_32 (abfd, scnhdr_int->s_nlnno, scnhdr_ext->s_nlnno); - H_PUT_32 (abfd, scnhdr_int->s_nreloc, scnhdr_ext->s_nreloc); -#else if (scnhdr_int->s_nlnno <= MAX_SCNHDR_NLNNO) PUT_SCNHDR_NLNNO (abfd, scnhdr_int->s_nlnno, scnhdr_ext->s_nlnno); else @@ -808,10 +784,10 @@ coff_swap_scnhdr_out (bfd * abfd, void * in, void * out) memcpy (buf, scnhdr_int->s_name, sizeof (scnhdr_int->s_name)); buf[sizeof (scnhdr_int->s_name)] = '\0'; - (*_bfd_error_handler) - (_("%s: warning: %s: line number overflow: 0x%lx > 0xffff"), - bfd_get_filename (abfd), - buf, scnhdr_int->s_nlnno); + _bfd_error_handler + /* xgettext:c-format */ + (_("%pB: warning: %s: line number overflow: 0x%lx > 0xffff"), + abfd, buf, scnhdr_int->s_nlnno); PUT_SCNHDR_NLNNO (abfd, 0xffff, scnhdr_ext->s_nlnno); } @@ -823,18 +799,14 @@ coff_swap_scnhdr_out (bfd * abfd, void * in, void * out) memcpy (buf, scnhdr_int->s_name, sizeof (scnhdr_int->s_name)); buf[sizeof (scnhdr_int->s_name)] = '\0'; - (*_bfd_error_handler) (_("%s: %s: reloc overflow: 0x%lx > 0xffff"), - bfd_get_filename (abfd), - buf, scnhdr_int->s_nreloc); + /* xgettext:c-format */ + _bfd_error_handler (_("%pB: %s: reloc overflow: 0x%lx > 0xffff"), + abfd, buf, scnhdr_int->s_nreloc); bfd_set_error (bfd_error_file_truncated); PUT_SCNHDR_NRELOC (abfd, 0xffff, scnhdr_ext->s_nreloc); ret = 0; } -#endif -#ifdef I960 - PUT_SCNHDR_ALIGN (abfd, scnhdr_int->s_align, scnhdr_ext->s_align); -#endif #ifdef COFF_ADJUST_SCNHDR_OUT_POST COFF_ADJUST_SCNHDR_OUT_POST (abfd, in, out); #endif