aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClinton Popetz <cpopetz@cpopetz.com>2000-04-26 15:09:44 +0000
committerClinton Popetz <cpopetz@cpopetz.com>2000-04-26 15:09:44 +0000
commit7f6d05e83efe70ae5a029ca9bf76ce10a32b3b40 (patch)
tree8e599c994d0b9951b1177309cd8c2aa6f21abb73
parentc13c43fdda3d022918e2ab2211caf52643eab25a (diff)
downloadgdb-7f6d05e83efe70ae5a029ca9bf76ce10a32b3b40.zip
gdb-7f6d05e83efe70ae5a029ca9bf76ce10a32b3b40.tar.gz
gdb-7f6d05e83efe70ae5a029ca9bf76ce10a32b3b40.tar.bz2
Add XCOFF64 support.
bfd: * Makefile.am (coff64-rs6000.lo): New rule. * Makefile.in: Regenerate. * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data, xcoff_is_local_label_name, xcoff_rtype2howto, xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p, xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap, xcoff_write_archive_contents): No longer static, and prefix with _bfd_. (NO_COFF_SYMBOLS): Define. (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in, xcoff64_swap_aux_out): New functions; handle xcoff symbol tables internally. (MINUS_ONE): New macro. (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS relocation. (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in, coff_SWAP_aux_out): Map to the new functions. * coff64-rs6000.c: New file. * libcoff.h (bfd_coff_backend_data): Add new fields _bfd_coff_force_symnames_in_strings and _bfd_coff_debug_string_prefix_length. (bfd_coff_force_symnames_in_strings, bfd_coff_debug_string_prefix_length): New macros for above fields. * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic. Set machine to 620 for XCOFF64. Use bfd_coff_swap_sym_in instead of using coff_swap_sym_in directly. (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64. (coff_set_flags) Set magic for XCOFF64. (coff_compute_section_file_positions): Add symbol name length to string section length if bfd_coff_debug_string_prefix_length is true. (coff_write_object_contents): Don't do reloc overflow for XCOFF64. (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of using coff_swap_lineno_in directly. (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings and _bfd_coff_debug_string_prefix_length fields. * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force symbol names into strings table when bfd_coff_force_symnames_in_strings is true. * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR, SET_RELOC_VADDR): New macros. (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros. (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C code. (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64 changes within RS6000COFF_C specific code. (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC, MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO. * reloc.c (bfd_perform_relocation, bfd_install_relocation): Extend existing hack on target name. * xcofflink.c (XCOFF_XVECP): Extend existing hack on target name. * coff-tic54x.c (ticof): Keep up to date with new fields in bfd_coff_backend_data. * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define targ_selvecs to include rs6000coff64_vec for rs6000. * configure.in: Add rs6000coff64_vec case. * cpu-powerpc.c: New bfd_arch_info_type. gas: * as.c (parse_args): Allow md_parse_option to override -a listing option. * config/obj-coff.c (add_lineno): Change type of offset parameter from "int" to "bfd_vma." * config/tc-ppc.c (md_pseudo_table): Add "llong" and "machine." (ppc_mach, ppc_subseg_align, ppc_target_format): New. (ppc_change_csect): Align correctly for XCOFF64. (ppc_machine): New function, which discards "ppc_machine" line. (ppc_tc): Cons for 8 when code is 64 bit. (md_apply_fix3): Don't check operand->insert. Handle 64 bit relocations. (md_parse_option): Handle -a64 and -a32. (ppc_xcoff64): New. * config/tc-ppc.h (TARGET_MACH): Define. (TARGET_FORMAT): Move to function. (SUB_SEGMENT_ALIGN): Use ppc_subseg_align. include: * include/coff/rs6k64.h: New file. opcodes: * configure.in: Add bfd_powerpc_64_arch. * disassemble.c (disassembler): Use print_insn_big_powerpc for 64 bit code.
-rw-r--r--bfd/ChangeLog60
-rw-r--r--bfd/Makefile.am3
-rw-r--r--bfd/Makefile.in3
-rw-r--r--bfd/coff-rs6000.c419
-rw-r--r--bfd/coff-tic54x.c20
-rw-r--r--bfd/coff64-rs6000.c479
-rw-r--r--bfd/coffcode.h46
-rw-r--r--bfd/coffgen.c41
-rw-r--r--bfd/coffswap.h95
-rw-r--r--bfd/config.bfd3
-rwxr-xr-xbfd/configure28
-rw-r--r--bfd/configure.in2
-rw-r--r--bfd/cpu-powerpc.c14
-rw-r--r--bfd/libcoff.h8
-rw-r--r--bfd/reloc.c2
-rw-r--r--bfd/targets.c2
-rw-r--r--bfd/xcofflink.c1
-rw-r--r--gas/ChangeLog19
-rw-r--r--gas/as.c3
-rw-r--r--gas/config/obj-coff.c2
-rw-r--r--gas/config/tc-ppc.c68
-rw-r--r--gas/config/tc-ppc.h26
-rw-r--r--include/ChangeLog4
-rw-r--r--include/coff/rs6k64.h236
-rw-r--r--opcodes/ChangeLog6
-rwxr-xr-xopcodes/configure320
-rw-r--r--opcodes/configure.in1
-rw-r--r--opcodes/disassemble.c5
28 files changed, 1587 insertions, 329 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index e6f92be..4190359 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,63 @@
+Mon Apr 24 15:20:35 2000 Clinton Popetz <cpopetz@cygnus.com>
+
+ * Makefile.am (coff64-rs6000.lo): New rule.
+ * Makefile.in: Regenerate.
+ * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data,
+ xcoff_is_local_label_name, xcoff_rtype2howto,
+ xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p,
+ xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap,
+ xcoff_write_archive_contents): No longer static, and prefix with _bfd_.
+ (NO_COFF_SYMBOLS): Define.
+ (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in,
+ xcoff64_swap_aux_out): New functions; handle xcoff symbol tables
+ internally.
+ (MINUS_ONE): New macro.
+ (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS
+ relocation.
+ (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in,
+ coff_SWAP_aux_out): Map to the new functions.
+ * coff64-rs6000.c: New file.
+ * libcoff.h (bfd_coff_backend_data): Add new fields
+ _bfd_coff_force_symnames_in_strings and
+ _bfd_coff_debug_string_prefix_length.
+ (bfd_coff_force_symnames_in_strings,
+ bfd_coff_debug_string_prefix_length): New macros for above fields.
+ * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic.
+ Set machine to 620 for XCOFF64. Use bfd_coff_swap_sym_in instead
+ of using coff_swap_sym_in directly.
+ (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64.
+ (coff_set_flags) Set magic for XCOFF64.
+ (coff_compute_section_file_positions): Add symbol name length to
+ string section length if bfd_coff_debug_string_prefix_length is
+ true.
+ (coff_write_object_contents): Don't do reloc overflow for XCOFF64.
+ (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of
+ using coff_swap_lineno_in directly.
+ (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings
+ and _bfd_coff_debug_string_prefix_length fields.
+ * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force
+ symbol names into strings table when
+ bfd_coff_force_symnames_in_strings is true.
+ * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR,
+ SET_RELOC_VADDR): New macros.
+ (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros.
+ (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C
+ code.
+ (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64
+ changes within RS6000COFF_C specific code.
+ (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC,
+ MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO.
+ * reloc.c (bfd_perform_relocation, bfd_install_relocation):
+ Extend existing hack on target name.
+ * xcofflink.c (XCOFF_XVECP): Extend existing hack on
+ target name.
+ * coff-tic54x.c (ticof): Keep up to date with new fields
+ in bfd_coff_backend_data.
+ * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define
+ targ_selvecs to include rs6000coff64_vec for rs6000.
+ * configure.in: Add rs6000coff64_vec case.
+ * cpu-powerpc.c: New bfd_arch_info_type.
+
Mon Apr 24 02:17:31 2000 Jeffrey A Law (law@cygnus.com)
* config.bfd: Only disable elf32-hppa vectors, not all of the
diff --git a/bfd/Makefile.am b/bfd/Makefile.am
index 83fd192..8a36f0e 100644
--- a/bfd/Makefile.am
+++ b/bfd/Makefile.am
@@ -818,6 +818,9 @@ coff-pmac.lo: coff-pmac.c coff-rs6000.c $(INCDIR)/coff/internal.h \
coff-rs6000.lo: coff-rs6000.c $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/rs6000.h libcoff.h $(INCDIR)/bfdlink.h \
coffcode.h coffswap.h
+coff64-rs6000.lo: coff64-rs6000.c coff-rs6000.c $(INCDIR)/coff/internal.h \
+ $(INCDIR)/coff/rs6000.h libcoff.h $(INCDIR)/bfdlink.h \
+ coffcode.h coffswap.h
coff-sh.lo: coff-sh.c $(INCDIR)/bfdlink.h $(INCDIR)/coff/sh.h \
$(INCDIR)/coff/internal.h libcoff.h coffcode.h coffswap.h
coff-sparc.lo: coff-sparc.c $(INCDIR)/coff/sparc.h \
diff --git a/bfd/Makefile.in b/bfd/Makefile.in
index 26692fa..329d22e 100644
--- a/bfd/Makefile.in
+++ b/bfd/Makefile.in
@@ -1346,6 +1346,9 @@ coff-pmac.lo: coff-pmac.c coff-rs6000.c $(INCDIR)/coff/internal.h \
coff-rs6000.lo: coff-rs6000.c $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/rs6000.h libcoff.h $(INCDIR)/bfdlink.h \
coffcode.h coffswap.h
+coff64-rs6000.lo: coff64-rs6000.c coff-rs6000.c $(INCDIR)/coff/internal.h \
+ $(INCDIR)/coff/rs6000.h libcoff.h $(INCDIR)/bfdlink.h \
+ coffcode.h coffswap.h
coff-sh.lo: coff-sh.c $(INCDIR)/bfdlink.h $(INCDIR)/coff/sh.h \
$(INCDIR)/coff/internal.h libcoff.h coffcode.h coffswap.h
coff-sparc.lo: coff-sparc.c $(INCDIR)/coff/sparc.h \
diff --git a/bfd/coff-rs6000.c b/bfd/coff-rs6000.c
index 6f8563f..b1384ed 100644
--- a/bfd/coff-rs6000.c
+++ b/bfd/coff-rs6000.c
@@ -38,29 +38,29 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* The main body of code is in coffcode.h. */
-static boolean xcoff_mkobject PARAMS ((bfd *));
-static boolean xcoff_copy_private_bfd_data PARAMS ((bfd *, bfd *));
-static boolean xcoff_is_local_label_name PARAMS ((bfd *, const char *));
-static void xcoff_rtype2howto
+boolean _bfd_xcoff_mkobject PARAMS ((bfd *));
+boolean _bfd_xcoff_copy_private_bfd_data PARAMS ((bfd *, bfd *));
+boolean _bfd_xcoff_is_local_label_name PARAMS ((bfd *, const char *));
+void _bfd_xcoff_rtype2howto
PARAMS ((arelent *, struct internal_reloc *));
-static reloc_howto_type *xcoff_reloc_type_lookup
+reloc_howto_type *_bfd_xcoff_reloc_type_lookup
PARAMS ((bfd *, bfd_reloc_code_real_type));
-static boolean xcoff_slurp_armap PARAMS ((bfd *));
-static const bfd_target *xcoff_archive_p PARAMS ((bfd *));
-static PTR xcoff_read_ar_hdr PARAMS ((bfd *));
-static bfd *xcoff_openr_next_archived_file PARAMS ((bfd *, bfd *));
-static int xcoff_generic_stat_arch_elt PARAMS ((bfd *, struct stat *));
+boolean _bfd_xcoff_slurp_armap PARAMS ((bfd *));
+const bfd_target *_bfd_xcoff_archive_p PARAMS ((bfd *));
+PTR _bfd_xcoff_read_ar_hdr PARAMS ((bfd *));
+bfd *_bfd_xcoff_openr_next_archived_file PARAMS ((bfd *, bfd *));
+int _bfd_xcoff_generic_stat_arch_elt PARAMS ((bfd *, struct stat *));
static const char *normalize_filename PARAMS ((bfd *));
-static boolean xcoff_write_armap
+boolean _bfd_xcoff_write_armap
PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
-static boolean xcoff_write_archive_contents PARAMS ((bfd *));
-static int _bfd_xcoff_sizeof_headers PARAMS ((bfd *, boolean));
+boolean _bfd_xcoff_write_archive_contents PARAMS ((bfd *));
+int _bfd_xcoff_sizeof_headers PARAMS ((bfd *, boolean));
/* We use our own tdata type. Its first field is the COFF tdata type,
so the COFF routines are compatible. */
-static boolean
-xcoff_mkobject (abfd)
+boolean
+_bfd_xcoff_mkobject (abfd)
bfd *abfd;
{
coff_data_type *coff;
@@ -90,8 +90,8 @@ xcoff_mkobject (abfd)
/* Copy XCOFF data from one BFD to another. */
-static boolean
-xcoff_copy_private_bfd_data (ibfd, obfd)
+boolean
+_bfd_xcoff_copy_private_bfd_data (ibfd, obfd)
bfd *ibfd;
bfd *obfd;
{
@@ -138,21 +138,310 @@ xcoff_copy_private_bfd_data (ibfd, obfd)
The AIX native linker does not have a -X option, and it ignores the
-x option. */
-static boolean
-xcoff_is_local_label_name (abfd, name)
+boolean
+_bfd_xcoff_is_local_label_name (abfd, name)
bfd *abfd ATTRIBUTE_UNUSED;
const char *name ATTRIBUTE_UNUSED;
{
return false;
}
+
+#define NO_COFF_SYMBOLS
+
+static void xcoff_swap_sym_in PARAMS ((bfd *, PTR, PTR));
+static unsigned int xcoff_swap_sym_out PARAMS ((bfd *, PTR, PTR));
+static void xcoff_swap_aux_in PARAMS ((bfd *, PTR, int, int, int, int, PTR));
+static unsigned int xcoff_swap_aux_out PARAMS ((bfd *, PTR, int, int, int, int, PTR));
+
+static void
+xcoff_swap_sym_in (abfd, ext1, in1)
+ bfd *abfd;
+ PTR ext1;
+ PTR in1;
+{
+ SYMENT *ext = (SYMENT *)ext1;
+ struct internal_syment *in = (struct internal_syment *)in1;
+
+
+ if(ext->e.e_name[0] != 0)
+ {
+ memcpy(in->_n._n_name, ext->e.e_name, SYMNMLEN);
+ }
+ else
+ {
+ in->_n._n_n._n_zeroes = 0;
+ in->_n._n_n._n_offset =
+ bfd_h_get_32(abfd, (bfd_byte *) ext->e.e.e_offset);
+ }
+
+ in->n_value = bfd_h_get_32(abfd, (bfd_byte *) ext->e_value);
+ in->n_scnum = bfd_h_get_16(abfd, (bfd_byte *) ext->e_scnum);
+ in->n_type = bfd_h_get_16(abfd, (bfd_byte *) ext->e_type);
+ in->n_sclass = bfd_h_get_8(abfd, ext->e_sclass);
+ in->n_numaux = bfd_h_get_8(abfd, ext->e_numaux);
+}
+
+static unsigned int
+xcoff_swap_sym_out (abfd, inp, extp)
+ bfd *abfd;
+ PTR inp;
+ PTR extp;
+{
+ struct internal_syment *in = (struct internal_syment *)inp;
+ SYMENT *ext =(SYMENT *)extp;
+
+ if(in->_n._n_name[0] != 0)
+ {
+ memcpy(ext->e.e_name, in->_n._n_name, SYMNMLEN);
+ }
+ else
+ {
+ bfd_h_put_32(abfd, 0, (bfd_byte *) ext->e.e.e_zeroes);
+ bfd_h_put_32(abfd, in->_n._n_n._n_offset,
+ (bfd_byte *) ext->e.e.e_offset);
+ }
+
+ bfd_h_put_32(abfd, in->n_value , (bfd_byte *) ext->e_value);
+ bfd_h_put_16(abfd, in->n_scnum , (bfd_byte *) ext->e_scnum);
+ bfd_h_put_16(abfd, in->n_type , (bfd_byte *) ext->e_type);
+ bfd_h_put_8(abfd, in->n_sclass , ext->e_sclass);
+ bfd_h_put_8(abfd, in->n_numaux , ext->e_numaux);
+ return bfd_coff_symesz (abfd);
+}
+
+#define PUTWORD bfd_h_put_32
+#define PUTHALF bfd_h_put_16
+#define PUTBYTE bfd_h_put_8
+#define GETWORD bfd_h_get_32
+#define GETHALF bfd_h_get_16
+#define GETBYTE bfd_h_get_8
+
+static void
+xcoff_swap_aux_in (abfd, ext1, type, class, indx, numaux, in1)
+ bfd *abfd;
+ PTR ext1;
+ int type;
+ int class;
+ int indx;
+ int numaux;
+ PTR in1;
+{
+ AUXENT *ext = (AUXENT *)ext1;
+ union internal_auxent *in = (union internal_auxent *)in1;
+
+ switch (class) {
+ case C_FILE:
+ if (ext->x_file.x_fname[0] == 0) {
+ in->x_file.x_n.x_zeroes = 0;
+ in->x_file.x_n.x_offset =
+ bfd_h_get_32(abfd, (bfd_byte *) ext->x_file.x_n.x_offset);
+ } else {
+ if (numaux > 1)
+ {
+ if (indx == 0)
+ memcpy (in->x_file.x_fname, ext->x_file.x_fname,
+ numaux * sizeof (AUXENT));
+ }
+ else
+ {
+ memcpy (in->x_file.x_fname, ext->x_file.x_fname, FILNMLEN);
+ }
+ }
+ goto end;
+
+ /* RS/6000 "csect" auxents */
+ case C_EXT:
+ case C_HIDEXT:
+ if (indx + 1 == numaux)
+ {
+ in->x_csect.x_scnlen.l =
+ bfd_h_get_32 (abfd, ext->x_csect.x_scnlen);
+ in->x_csect.x_parmhash = bfd_h_get_32 (abfd,
+ ext->x_csect.x_parmhash);
+ in->x_csect.x_snhash = bfd_h_get_16 (abfd, ext->x_csect.x_snhash);
+ /* We don't have to hack bitfields in x_smtyp because it's
+ defined by shifts-and-ands, which are equivalent on all
+ byte orders. */
+ in->x_csect.x_smtyp = bfd_h_get_8 (abfd, ext->x_csect.x_smtyp);
+ in->x_csect.x_smclas = bfd_h_get_8 (abfd, ext->x_csect.x_smclas);
+ in->x_csect.x_stab = bfd_h_get_32 (abfd, ext->x_csect.x_stab);
+ in->x_csect.x_snstab = bfd_h_get_16 (abfd, ext->x_csect.x_snstab);
+ goto end;
+ }
+ break;
+
+ case C_STAT:
+ case C_LEAFSTAT:
+ case C_HIDDEN:
+ if (type == T_NULL) {
+ in->x_scn.x_scnlen = bfd_h_get_32(abfd,
+ (bfd_byte *) ext->x_scn.x_scnlen);
+ in->x_scn.x_nreloc = bfd_h_get_16(abfd,
+ (bfd_byte *) ext->x_scn.x_nreloc);
+ in->x_scn.x_nlinno = bfd_h_get_16(abfd,
+ (bfd_byte *) ext->x_scn.x_nlinno);
+ /* PE defines some extra fields; we zero them out for
+ safety. */
+ in->x_scn.x_checksum = 0;
+ in->x_scn.x_associated = 0;
+ in->x_scn.x_comdat = 0;
+
+ goto end;
+ }
+ break;
+ }
+
+ in->x_sym.x_tagndx.l = bfd_h_get_32(abfd, (bfd_byte *) ext->x_sym.x_tagndx);
+ in->x_sym.x_tvndx = bfd_h_get_16(abfd, (bfd_byte *) ext->x_sym.x_tvndx);
+
+ if (class == C_BLOCK || class == C_FCN || ISFCN (type) || ISTAG (class))
+ {
+ in->x_sym.x_fcnary.x_fcn.x_lnnoptr = bfd_h_get_32(abfd, (bfd_byte *)
+ ext->x_sym.x_fcnary.x_fcn.x_lnnoptr);
+ in->x_sym.x_fcnary.x_fcn.x_endndx.l = bfd_h_get_32(abfd, (bfd_byte *)
+ ext->x_sym.x_fcnary.x_fcn.x_endndx);
+ }
+ else
+ {
+ in->x_sym.x_fcnary.x_ary.x_dimen[0] =
+ bfd_h_get_16 (abfd, (bfd_byte *) ext->x_sym.x_fcnary.x_ary.x_dimen[0]);
+ in->x_sym.x_fcnary.x_ary.x_dimen[1] =
+ bfd_h_get_16 (abfd, (bfd_byte *) ext->x_sym.x_fcnary.x_ary.x_dimen[1]);
+ in->x_sym.x_fcnary.x_ary.x_dimen[2] =
+ bfd_h_get_16 (abfd, (bfd_byte *) ext->x_sym.x_fcnary.x_ary.x_dimen[2]);
+ in->x_sym.x_fcnary.x_ary.x_dimen[3] =
+ bfd_h_get_16 (abfd, (bfd_byte *) ext->x_sym.x_fcnary.x_ary.x_dimen[3]);
+ }
+ if (ISFCN(type)) {
+ in->x_sym.x_misc.x_fsize = bfd_h_get_32(abfd, (bfd_byte *) ext->x_sym.x_misc.x_fsize);
+ }
+ else {
+ in->x_sym.x_misc.x_lnsz.x_lnno = bfd_h_get_16(abfd, (bfd_byte *)
+ ext->x_sym.x_misc.x_lnsz.x_lnno);
+ in->x_sym.x_misc.x_lnsz.x_size = bfd_h_get_16(abfd, (bfd_byte *)
+ ext->x_sym.x_misc.x_lnsz.x_size);
+ }
+
+end: ;
+ /* the semicolon is because MSVC doesn't like labels at
+ end of block. */
+
+}
+
+
+
+static unsigned int
+xcoff_swap_aux_out (abfd, inp, type, class, indx, numaux, extp)
+ bfd *abfd;
+ PTR inp;
+ int type;
+ int class;
+ int indx ATTRIBUTE_UNUSED;
+ int numaux ATTRIBUTE_UNUSED;
+ PTR extp;
+{
+ union internal_auxent *in = (union internal_auxent *)inp;
+ AUXENT *ext = (AUXENT *)extp;
+
+ memset((PTR)ext, 0, bfd_coff_auxesz (abfd));
+ switch (class)
+ {
+ case C_FILE:
+ if (in->x_file.x_fname[0] == 0)
+ {
+ PUTWORD(abfd, 0, (bfd_byte *) ext->x_file.x_n.x_zeroes);
+ PUTWORD(abfd,
+ in->x_file.x_n.x_offset,
+ (bfd_byte *) ext->x_file.x_n.x_offset);
+ }
+ else
+ {
+ memcpy (ext->x_file.x_fname, in->x_file.x_fname, FILNMLEN);
+ }
+ goto end;
+
+ /* RS/6000 "csect" auxents */
+ case C_EXT:
+ case C_HIDEXT:
+ if (indx + 1 == numaux)
+ {
+ PUTWORD (abfd, in->x_csect.x_scnlen.l,ext->x_csect.x_scnlen);
+ PUTWORD (abfd, in->x_csect.x_parmhash, ext->x_csect.x_parmhash);
+ PUTHALF (abfd, in->x_csect.x_snhash, ext->x_csect.x_snhash);
+ /* We don't have to hack bitfields in x_smtyp because it's
+ defined by shifts-and-ands, which are equivalent on all
+ byte orders. */
+ PUTBYTE (abfd, in->x_csect.x_smtyp, ext->x_csect.x_smtyp);
+ PUTBYTE (abfd, in->x_csect.x_smclas, ext->x_csect.x_smclas);
+ PUTWORD (abfd, in->x_csect.x_stab, ext->x_csect.x_stab);
+ PUTHALF (abfd, in->x_csect.x_snstab, ext->x_csect.x_snstab);
+ goto end;
+ }
+ break;
+
+ case C_STAT:
+ case C_LEAFSTAT:
+ case C_HIDDEN:
+ if (type == T_NULL) {
+ bfd_h_put_32(abfd, in->x_scn.x_scnlen, (bfd_byte *) ext->x_scn.x_scnlen);
+ bfd_h_put_16(abfd, in->x_scn.x_nreloc, (bfd_byte *) ext->x_scn.x_nreloc);
+ bfd_h_put_16(abfd, in->x_scn.x_nlinno, (bfd_byte *) ext->x_scn.x_nlinno);
+ goto end;
+ }
+ break;
+ }
+
+ PUTWORD(abfd, in->x_sym.x_tagndx.l, (bfd_byte *) ext->x_sym.x_tagndx);
+ PUTWORD(abfd, in->x_sym.x_tvndx , (bfd_byte *) ext->x_sym.x_tvndx);
+
+ if (class == C_BLOCK || class == C_FCN || ISFCN (type) || ISTAG (class))
+ {
+ bfd_h_put_32(abfd, in->x_sym.x_fcnary.x_fcn.x_lnnoptr,
+ (bfd_byte *) ext->x_sym.x_fcnary.x_fcn.x_lnnoptr);
+ PUTWORD(abfd, in->x_sym.x_fcnary.x_fcn.x_endndx.l,
+ (bfd_byte *) ext->x_sym.x_fcnary.x_fcn.x_endndx);
+ }
+ else
+ {
+ bfd_h_put_16 (abfd, in->x_sym.x_fcnary.x_ary.x_dimen[0],
+ (bfd_byte *) ext->x_sym.x_fcnary.x_ary.x_dimen[0]);
+ bfd_h_put_16 (abfd, in->x_sym.x_fcnary.x_ary.x_dimen[1],
+ (bfd_byte *) ext->x_sym.x_fcnary.x_ary.x_dimen[1]);
+ bfd_h_put_16 (abfd, in->x_sym.x_fcnary.x_ary.x_dimen[2],
+ (bfd_byte *) ext->x_sym.x_fcnary.x_ary.x_dimen[2]);
+ bfd_h_put_16 (abfd, in->x_sym.x_fcnary.x_ary.x_dimen[3],
+ (bfd_byte *) ext->x_sym.x_fcnary.x_ary.x_dimen[3]);
+ }
+
+ if (ISFCN (type))
+ PUTWORD (abfd, in->x_sym.x_misc.x_fsize,
+ (bfd_byte *) ext->x_sym.x_misc.x_fsize);
+ else
+ {
+ bfd_h_put_16(abfd, in->x_sym.x_misc.x_lnsz.x_lnno,
+ (bfd_byte *)ext->x_sym.x_misc.x_lnsz.x_lnno);
+ bfd_h_put_16(abfd, in->x_sym.x_misc.x_lnsz.x_size,
+ (bfd_byte *)ext->x_sym.x_misc.x_lnsz.x_size);
+ }
+
+end:
+ return bfd_coff_auxesz (abfd);
+}
+
+
+
/* The XCOFF reloc table. Actually, XCOFF relocations specify the
bitsize and whether they are signed or not, along with a
conventional type. This table is for the types, which are used for
different algorithms for putting in the reloc. Many of these
relocs need special_function entries, which I have not written. */
-static reloc_howto_type xcoff_howto_table[] =
+/* In case we're on a 32-bit machine, construct a 64-bit "-1" value
+ from smaller values. Start with zero, widen, *then* decrement. */
+#define MINUS_ONE (((bfd_vma)0) - 1)
+
+reloc_howto_type xcoff_howto_table[] =
{
/* Standard 32 bit relocation. */
HOWTO (0, /* type */
@@ -493,7 +782,21 @@ static reloc_howto_type xcoff_howto_table[] =
true, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+ HOWTO (0, /* type */
+ 0, /* rightshift */
+ 4, /* size (0 = byte, 1 = short, 2 = long) */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ 0, /* special_function */
+ "R_POS", /* name */
+ true, /* partial_inplace */
+ MINUS_ONE, /* src_mask */
+ MINUS_ONE, /* dst_mask */
false) /* pcrel_offset */
+
};
/* These are the first two like the above but for 16-bit relocs. */
@@ -542,11 +845,11 @@ static reloc_howto_type xcoff_howto_table_16[] =
true, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
-};
+ false) /* pcrel_offset */
+ };
-static void
-xcoff_rtype2howto (relent, internal)
+void
+_bfd_xcoff_rtype2howto (relent, internal)
arelent *relent;
struct internal_reloc *internal;
{
@@ -571,8 +874,8 @@ xcoff_rtype2howto (relent, internal)
#endif
}
-static reloc_howto_type *
-xcoff_reloc_type_lookup (abfd, code)
+reloc_howto_type *
+_bfd_xcoff_reloc_type_lookup (abfd, code)
bfd *abfd ATTRIBUTE_UNUSED;
bfd_reloc_code_real_type code;
{
@@ -587,6 +890,8 @@ xcoff_reloc_type_lookup (abfd, code)
case BFD_RELOC_32:
case BFD_RELOC_CTOR:
return &xcoff_howto_table[0];
+ case BFD_RELOC_64:
+ return &xcoff_howto_table[0x1c];
default:
return NULL;
}
@@ -606,12 +911,16 @@ xcoff_reloc_type_lookup (abfd, code)
#define COFF_LONG_FILENAMES
-#define RTYPE2HOWTO(cache_ptr, dst) xcoff_rtype2howto (cache_ptr, dst)
+#define RTYPE2HOWTO(cache_ptr, dst) _bfd_xcoff_rtype2howto (cache_ptr, dst)
-#define coff_mkobject xcoff_mkobject
-#define coff_bfd_copy_private_bfd_data xcoff_copy_private_bfd_data
-#define coff_bfd_is_local_label_name xcoff_is_local_label_name
-#define coff_bfd_reloc_type_lookup xcoff_reloc_type_lookup
+#define coff_SWAP_sym_in xcoff_swap_sym_in
+#define coff_SWAP_sym_out xcoff_swap_sym_out
+#define coff_SWAP_aux_in xcoff_swap_aux_in
+#define coff_SWAP_aux_out xcoff_swap_aux_out
+#define coff_mkobject _bfd_xcoff_mkobject
+#define coff_bfd_copy_private_bfd_data _bfd_xcoff_copy_private_bfd_data
+#define coff_bfd_is_local_label_name _bfd_xcoff_is_local_label_name
+#define coff_bfd_reloc_type_lookup _bfd_xcoff_reloc_type_lookup
#define coff_relocate_section _bfd_ppc_xcoff_relocate_section
#include "coffcode.h"
@@ -829,24 +1138,24 @@ struct xcoff_ar_hdr_big
/* XCOFF archives do not have anything which corresponds to an
extended name table. */
-#define xcoff_slurp_extended_name_table bfd_false
-#define xcoff_construct_extended_name_table \
+#define _bfd_xcoff_slurp_extended_name_table bfd_false
+#define _bfd_xcoff_construct_extended_name_table \
((boolean (*) PARAMS ((bfd *, char **, bfd_size_type *, const char **))) \
bfd_false)
-#define xcoff_truncate_arname bfd_dont_truncate_arname
+#define _bfd_xcoff_truncate_arname bfd_dont_truncate_arname
/* We can use the standard get_elt_at_index routine. */
-#define xcoff_get_elt_at_index _bfd_generic_get_elt_at_index
+#define _bfd_xcoff_get_elt_at_index _bfd_generic_get_elt_at_index
/* XCOFF archives do not have a timestamp. */
-#define xcoff_update_armap_timestamp bfd_true
+#define _bfd_xcoff_update_armap_timestamp bfd_true
/* Read in the armap of an XCOFF archive. */
-static boolean
-xcoff_slurp_armap (abfd)
+boolean
+_bfd_xcoff_slurp_armap (abfd)
bfd *abfd;
{
file_ptr off;
@@ -969,8 +1278,8 @@ xcoff_slurp_armap (abfd)
/* See if this is an XCOFF archive. */
-static const bfd_target *
-xcoff_archive_p (abfd)
+const bfd_target *
+_bfd_xcoff_archive_p (abfd)
bfd *abfd;
{
char magic[SXCOFFARMAG];
@@ -1060,7 +1369,7 @@ xcoff_archive_p (abfd)
memcpy (bfd_ardata (abfd)->tdata, &hdr, SIZEOF_AR_FILE_HDR_BIG);
}
- if (! xcoff_slurp_armap (abfd))
+ if (! _bfd_xcoff_slurp_armap (abfd))
{
bfd_release (abfd, bfd_ardata (abfd));
abfd->tdata.aout_ar_data = (struct artdata *) NULL;
@@ -1072,8 +1381,8 @@ xcoff_archive_p (abfd)
/* Read the archive header in an XCOFF archive. */
-static PTR
-xcoff_read_ar_hdr (abfd)
+PTR
+_bfd_xcoff_read_ar_hdr (abfd)
bfd *abfd;
{
size_t namlen;
@@ -1160,8 +1469,8 @@ xcoff_read_ar_hdr (abfd)
/* Open the next element in an XCOFF archive. */
-static bfd *
-xcoff_openr_next_archived_file (archive, last_file)
+bfd *
+_bfd_xcoff_openr_next_archived_file (archive, last_file)
bfd *archive;
bfd *last_file;
{
@@ -1221,8 +1530,8 @@ xcoff_openr_next_archived_file (archive, last_file)
/* Stat an element in an XCOFF archive. */
-static int
-xcoff_generic_stat_arch_elt (abfd, s)
+int
+_bfd_xcoff_generic_stat_arch_elt (abfd, s)
bfd *abfd;
struct stat *s;
{
@@ -1452,8 +1761,8 @@ xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
}
/*ARGSUSED*/
-static boolean
-xcoff_write_armap (abfd, elength, map, orl_count, stridx)
+boolean
+_bfd_xcoff_write_armap (abfd, elength, map, orl_count, stridx)
bfd *abfd;
unsigned int elength ATTRIBUTE_UNUSED;
struct orl *map;
@@ -1983,8 +2292,8 @@ xcoff_write_archive_contents_big (abfd)
return true;
}
-static boolean
-xcoff_write_archive_contents (abfd)
+boolean
+_bfd_xcoff_write_archive_contents (abfd)
bfd *abfd;
{
if (! xcoff_big_format_p (abfd))
@@ -1997,7 +2306,7 @@ xcoff_write_archive_contents (abfd)
always uses an a.out header. */
/*ARGSUSED*/
-static int
+int
_bfd_xcoff_sizeof_headers (abfd, reloc)
bfd *abfd;
boolean reloc ATTRIBUTE_UNUSED;
@@ -2105,16 +2414,16 @@ const bfd_target
bfd_getb16, bfd_getb_signed_16, bfd_putb16, /* hdrs */
{_bfd_dummy_target, coff_object_p, /* bfd_check_format */
- xcoff_archive_p, CORE_FILE_P},
+ _bfd_xcoff_archive_p, CORE_FILE_P},
{bfd_false, coff_mkobject, /* bfd_set_format */
_bfd_generic_mkarchive, bfd_false},
{bfd_false, coff_write_object_contents, /* bfd_write_contents */
- xcoff_write_archive_contents, bfd_false},
+ _bfd_xcoff_write_archive_contents, bfd_false},
BFD_JUMP_TABLE_GENERIC (coff),
BFD_JUMP_TABLE_COPY (coff),
BFD_JUMP_TABLE_CORE (coff),
- BFD_JUMP_TABLE_ARCHIVE (xcoff),
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_xcoff),
BFD_JUMP_TABLE_SYMBOLS (coff),
BFD_JUMP_TABLE_RELOCS (coff),
BFD_JUMP_TABLE_WRITE (coff),
diff --git a/bfd/coff-tic54x.c b/bfd/coff-tic54x.c
index 4cfa27e..4ae62e3 100644
--- a/bfd/coff-tic54x.c
+++ b/bfd/coff-tic54x.c
@@ -428,6 +428,16 @@ static CONST bfd_coff_backend_data ticoff0_swap_table =
#else
false,
#endif
+#ifdef COFF_FORCE_SYMBOLS_IN_STRINGS
+ true,
+#else
+ false,
+#endif
+#ifdef COFF_DEBUG_STRING_WIDE_PREFIX
+ 4,
+#else
+ 2,
+#endif
COFF_DEFAULT_SECTION_ALIGNMENT_POWER,
coff_SWAP_filehdr_in, coff_SWAP_aouthdr_in, coff_SWAP_scnhdr_in,
coff_SWAP_reloc_in, ticoff0_bad_format_hook, coff_set_arch_mach_hook,
@@ -460,6 +470,16 @@ static CONST bfd_coff_backend_data ticoff1_swap_table =
false,
#endif
COFF_DEFAULT_SECTION_ALIGNMENT_POWER,
+#ifdef COFF_FORCE_SYMBOLS_IN_STRINGS
+ true,
+#else
+ false,
+#endif
+#ifdef COFF_DEBUG_STRING_WIDE_PREFIX
+ 4,
+#else
+ 2,
+#endif
coff_SWAP_filehdr_in, coff_SWAP_aouthdr_in, coff_SWAP_scnhdr_in,
coff_SWAP_reloc_in, ticoff1_bad_format_hook, coff_set_arch_mach_hook,
coff_mkobject_hook, styp_to_sec_flags, coff_set_alignment_hook,
diff --git a/bfd/coff64-rs6000.c b/bfd/coff64-rs6000.c
new file mode 100644
index 0000000..a417039
--- /dev/null
+++ b/bfd/coff64-rs6000.c
@@ -0,0 +1,479 @@
+/* BFD back-end for IBM RS/6000 "XCOFF64" files.
+ Copyright 2000
+ Free Software Foundation, Inc.
+ Written Clinton Popetz.
+ Contributed by Cygnus Support.
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+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. */
+
+/* Internalcoff.h and coffcode.h modify themselves based on these flags. */
+#define XCOFF64
+#define RS6000COFF_C 1
+
+#include "bfd.h"
+#include "sysdep.h"
+#include "libbfd.h"
+#include "coff/internal.h"
+#include "coff/rs6k64.h"
+#include "libcoff.h"
+
+
+#define GET_FILEHDR_SYMPTR bfd_h_get_64
+#define PUT_FILEHDR_SYMPTR bfd_h_put_64
+#define GET_AOUTHDR_DATA_START bfd_h_get_64
+#define PUT_AOUTHDR_DATA_START bfd_h_put_64
+#define GET_AOUTHDR_TEXT_START bfd_h_get_64
+#define PUT_AOUTHDR_TEXT_START bfd_h_put_64
+#define GET_AOUTHDR_TSIZE bfd_h_get_64
+#define PUT_AOUTHDR_TSIZE bfd_h_put_64
+#define GET_AOUTHDR_DSIZE bfd_h_get_64
+#define PUT_AOUTHDR_DSIZE bfd_h_put_64
+#define GET_AOUTHDR_BSIZE bfd_h_get_64
+#define PUT_AOUTHDR_BSIZE bfd_h_put_64
+#define GET_AOUTHDR_ENTRY bfd_h_get_64
+#define PUT_AOUTHDR_ENTRY bfd_h_put_64
+#define GET_SCNHDR_PADDR bfd_h_get_64
+#define PUT_SCNHDR_PADDR bfd_h_put_64
+#define GET_SCNHDR_VADDR bfd_h_get_64
+#define PUT_SCNHDR_VADDR bfd_h_put_64
+#define GET_SCNHDR_SIZE bfd_h_get_64
+#define PUT_SCNHDR_SIZE bfd_h_put_64
+#define GET_SCNHDR_SCNPTR bfd_h_get_64
+#define PUT_SCNHDR_SCNPTR bfd_h_put_64
+#define GET_SCNHDR_RELPTR bfd_h_get_64
+#define PUT_SCNHDR_RELPTR bfd_h_put_64
+#define GET_SCNHDR_LNNOPTR bfd_h_get_64
+#define PUT_SCNHDR_LNNOPTR bfd_h_put_64
+#define GET_SCNHDR_NRELOC bfd_h_get_32
+#define MAX_SCNHDR_NRELOC 0xffffffff
+#define PUT_SCNHDR_NRELOC bfd_h_put_32
+#define GET_SCNHDR_NLNNO bfd_h_get_32
+#define MAX_SCNHDR_NLNNO 0xffffffff
+#define PUT_SCNHDR_NLNNO bfd_h_put_32
+#define GET_RELOC_VADDR bfd_h_get_64
+#define PUT_RELOC_VADDR bfd_h_put_64
+
+#define COFF_FORCE_SYMBOLS_IN_STRINGS
+#define COFF_DEBUG_STRING_WIDE_PREFIX
+
+#define TARGET_SYM rs6000coff64_vec
+#define TARGET_NAME "aixcoff64-rs6000"
+
+#define COFF_ADJUST_SCNHDR_OUT_POST(ABFD,INT,EXT) \
+do { \
+ memset (((SCNHDR *)EXT)->s_pad, 0, sizeof (((SCNHDR *)EXT)->s_pad));\
+} while(0)
+
+#define NO_COFF_LINENOS
+
+#define coff_SWAP_lineno_in xcoff64_swap_lineno_in
+#define coff_SWAP_lineno_out xcoff64_swap_lineno_out
+
+#define PUTWORD bfd_h_put_32
+#define PUTHALF bfd_h_put_16
+#define PUTBYTE bfd_h_put_8
+#define GETWORD bfd_h_get_32
+#define GETHALF bfd_h_get_16
+#define GETBYTE bfd_h_get_8
+
+
+/* For XCOFF64, the effective width of symndx changes depending on
+ whether we are the first entry. Sigh. */
+static void
+xcoff64_swap_lineno_in (abfd, ext1, in1)
+ bfd *abfd;
+ PTR ext1;
+ PTR in1;
+{
+ LINENO *ext = (LINENO *)ext1;
+ struct internal_lineno *in = (struct internal_lineno *)in1;
+
+ in->l_lnno = bfd_h_get_32(abfd, (bfd_byte *) (ext->l_lnno));
+ if (in->l_lnno == 0)
+ in->l_addr.l_symndx =
+ bfd_h_get_32(abfd, (bfd_byte *) ext->l_addr.l_symndx);
+ else
+ in->l_addr.l_symndx =
+ bfd_h_get_64(abfd, (bfd_byte *) ext->l_addr.l_symndx);
+}
+
+static unsigned int
+xcoff64_swap_lineno_out (abfd, inp, outp)
+ bfd *abfd;
+ PTR inp;
+ PTR outp;
+{
+ struct internal_lineno *in = (struct internal_lineno *)inp;
+ struct external_lineno *ext = (struct external_lineno *)outp;
+ PUTWORD(abfd, in->l_addr.l_symndx, (bfd_byte *)
+ ext->l_addr.l_symndx);
+
+ bfd_h_put_32 (abfd, in->l_lnno, (bfd_byte *) (ext->l_lnno));
+ if (in->l_lnno == 0)
+ bfd_h_put_32 (abfd, in->l_addr.l_symndx, (bfd_byte *)ext->l_addr.l_symndx);
+ else
+ bfd_h_put_64 (abfd, in->l_addr.l_symndx, (bfd_byte *)ext->l_addr.l_symndx);
+
+ return bfd_coff_linesz (abfd);
+}
+
+#define NO_COFF_SYMBOLS
+
+static void xcoff64_swap_sym_in PARAMS ((bfd *, PTR, PTR));
+static unsigned int xcoff64_swap_sym_out PARAMS ((bfd *, PTR, PTR));
+static void xcoff64_swap_aux_in PARAMS ((bfd *, PTR, int, int, int, int, PTR));
+static unsigned int xcoff64_swap_aux_out PARAMS ((bfd *, PTR, int, int, int, int, PTR));
+
+static void
+xcoff64_swap_sym_in (abfd, ext1, in1)
+ bfd *abfd;
+ PTR ext1;
+ PTR in1;
+{
+ SYMENT *ext = (SYMENT *)ext1;
+ struct internal_syment *in = (struct internal_syment *)in1;
+
+
+ in->_n._n_n._n_zeroes = 0;
+ in->_n._n_n._n_offset = bfd_h_get_32(abfd, (bfd_byte *) ext->e_offset);
+ in->n_value = bfd_h_get_64(abfd, (bfd_byte *) ext->e.e_value);
+ in->n_scnum = bfd_h_get_16(abfd, (bfd_byte *) ext->e_scnum);
+ in->n_type = bfd_h_get_16(abfd, (bfd_byte *) ext->e_type);
+ in->n_sclass = bfd_h_get_8(abfd, ext->e_sclass);
+ in->n_numaux = bfd_h_get_8(abfd, ext->e_numaux);
+}
+
+static unsigned int
+xcoff64_swap_sym_out (abfd, inp, extp)
+ bfd *abfd;
+ PTR inp;
+ PTR extp;
+{
+ struct internal_syment *in = (struct internal_syment *)inp;
+ SYMENT *ext =(SYMENT *)extp;
+
+ bfd_h_put_32(abfd, in->_n._n_n._n_offset, (bfd_byte *) ext->e_offset);
+ bfd_h_put_64(abfd, in->n_value , (bfd_byte *) ext->e.e_value);
+ bfd_h_put_16(abfd, in->n_scnum , (bfd_byte *) ext->e_scnum);
+ bfd_h_put_16(abfd, in->n_type , (bfd_byte *) ext->e_type);
+ bfd_h_put_8(abfd, in->n_sclass , ext->e_sclass);
+ bfd_h_put_8(abfd, in->n_numaux , ext->e_numaux);
+ return bfd_coff_symesz (abfd);
+}
+
+static void
+xcoff64_swap_aux_in (abfd, ext1, type, class, indx, numaux, in1)
+ bfd *abfd;
+ PTR ext1;
+ int type;
+ int class;
+ int indx;
+ int numaux;
+ PTR in1;
+{
+ AUXENT *ext = (AUXENT *)ext1;
+ union internal_auxent *in = (union internal_auxent *)in1;
+
+ switch (class) {
+ case C_FILE:
+ if (ext->x_file.x_fname[0] == 0) {
+ in->x_file.x_n.x_zeroes = 0;
+ in->x_file.x_n.x_offset =
+ bfd_h_get_32(abfd, (bfd_byte *) ext->x_file.x_n.x_offset);
+ } else {
+ if (numaux > 1)
+ {
+ if (indx == 0)
+ memcpy (in->x_file.x_fname, ext->x_file.x_fname,
+ numaux * sizeof (AUXENT));
+ }
+ else
+ {
+ memcpy (in->x_file.x_fname, ext->x_file.x_fname, FILNMLEN);
+ }
+ }
+ goto end;
+
+ /* RS/6000 "csect" auxents */
+ case C_EXT:
+ case C_HIDEXT:
+ if (indx + 1 == numaux)
+ {
+ in->x_csect.x_scnlen.l =
+ bfd_h_get_32(abfd, ext->x_csect.x_scnlen_lo);
+ /* FIXME: If we want section lengths larger than 32 bits, we need
+ to modify the internal coff structures to support it. */
+ in->x_csect.x_parmhash = bfd_h_get_32 (abfd,
+ ext->x_csect.x_parmhash);
+ in->x_csect.x_snhash = bfd_h_get_16 (abfd, ext->x_csect.x_snhash);
+ /* We don't have to hack bitfields in x_smtyp because it's
+ defined by shifts-and-ands, which are equivalent on all
+ byte orders. */
+ in->x_csect.x_smtyp = bfd_h_get_8 (abfd, ext->x_csect.x_smtyp);
+ in->x_csect.x_smclas = bfd_h_get_8 (abfd, ext->x_csect.x_smclas);
+ goto end;
+ }
+ break;
+
+ case C_STAT:
+ case C_LEAFSTAT:
+ case C_HIDDEN:
+ if (type == T_NULL) {
+ /* PE defines some extra fields; we zero them out for
+ safety. */
+ in->x_scn.x_checksum = 0;
+ in->x_scn.x_associated = 0;
+ in->x_scn.x_comdat = 0;
+
+ goto end;
+ }
+ break;
+ }
+
+ if (class == C_BLOCK || class == C_FCN || ISFCN (type) || ISTAG (class))
+ {
+ in->x_sym.x_fcnary.x_fcn.x_lnnoptr = bfd_h_get_64(abfd, (bfd_byte *)
+ ext->x_sym.x_fcnary.x_fcn.x_lnnoptr);
+ in->x_sym.x_fcnary.x_fcn.x_endndx.l = bfd_h_get_32(abfd, (bfd_byte *)
+ ext->x_sym.x_fcnary.x_fcn.x_endndx);
+ }
+ if (ISFCN(type)) {
+ in->x_sym.x_misc.x_fsize = bfd_h_get_32(abfd, (bfd_byte *) ext->x_sym.x_fcnary.x_fcn.x_fsize);
+ }
+ else {
+ in->x_sym.x_misc.x_lnsz.x_lnno = bfd_h_get_32(abfd, (bfd_byte *)
+ ext->x_sym.x_fcnary.x_lnsz.x_lnno);
+ in->x_sym.x_misc.x_lnsz.x_size = bfd_h_get_16(abfd, (bfd_byte *)
+ ext->x_sym.x_fcnary.x_lnsz.x_size);
+ }
+
+end: ;
+ /* the semicolon is because MSVC doesn't like labels at
+ end of block. */
+
+}
+
+
+
+static unsigned int
+xcoff64_swap_aux_out (abfd, inp, type, class, indx, numaux, extp)
+ bfd *abfd;
+ PTR inp;
+ int type;
+ int class;
+ int indx ATTRIBUTE_UNUSED;
+ int numaux ATTRIBUTE_UNUSED;
+ PTR extp;
+{
+ union internal_auxent *in = (union internal_auxent *)inp;
+ AUXENT *ext = (AUXENT *)extp;
+
+ memset((PTR)ext, 0, bfd_coff_auxesz (abfd));
+ switch (class)
+ {
+ case C_FILE:
+ if (in->x_file.x_fname[0] == 0)
+ {
+ PUTWORD(abfd, 0, (bfd_byte *) ext->x_file.x_n.x_zeroes);
+ PUTWORD(abfd,
+ in->x_file.x_n.x_offset,
+ (bfd_byte *) ext->x_file.x_n.x_offset);
+ }
+ else
+ {
+ memcpy (ext->x_file.x_fname, in->x_file.x_fname, FILNMLEN);
+ }
+ PUTBYTE (abfd, _AUX_FILE, (bfd_byte *) ext->x_auxtype.x_auxtype);
+ goto end;
+
+ /* RS/6000 "csect" auxents */
+ case C_EXT:
+ case C_HIDEXT:
+ if (indx + 1 == numaux)
+ {
+ PUTWORD (abfd, in->x_csect.x_scnlen.l, ext->x_csect.x_scnlen_lo);
+ PUTWORD (abfd, in->x_csect.x_parmhash, ext->x_csect.x_parmhash);
+ PUTHALF (abfd, in->x_csect.x_snhash, ext->x_csect.x_snhash);
+ /* We don't have to hack bitfields in x_smtyp because it's
+ defined by shifts-and-ands, which are equivalent on all
+ byte orders. */
+ PUTBYTE (abfd, in->x_csect.x_smtyp, ext->x_csect.x_smtyp);
+ PUTBYTE (abfd, in->x_csect.x_smclas, ext->x_csect.x_smclas);
+ PUTBYTE (abfd, _AUX_CSECT, (bfd_byte *) ext->x_auxtype.x_auxtype);
+ goto end;
+ }
+ break;
+
+ case C_STAT:
+ case C_LEAFSTAT:
+ case C_HIDDEN:
+ if (type == T_NULL) {
+ goto end;
+ }
+ break;
+ }
+
+ if (class == C_BLOCK || class == C_FCN || ISFCN (type) || ISTAG (class))
+ {
+ bfd_h_put_64(abfd, in->x_sym.x_fcnary.x_fcn.x_lnnoptr,
+ (bfd_byte *) ext->x_sym.x_fcnary.x_fcn.x_lnnoptr);
+ PUTBYTE (abfd, _AUX_FCN, (bfd_byte *) ext->x_auxtype.x_auxtype);
+ PUTWORD(abfd, in->x_sym.x_fcnary.x_fcn.x_endndx.l,
+ (bfd_byte *) ext->x_sym.x_fcnary.x_fcn.x_endndx);
+ }
+ if (ISFCN (type))
+ PUTWORD (abfd, in->x_sym.x_misc.x_fsize,
+ (bfd_byte *) ext->x_sym.x_fcnary.x_fcn.x_fsize);
+ else
+ {
+ bfd_h_put_32(abfd, in->x_sym.x_misc.x_lnsz.x_lnno,
+ (bfd_byte *)ext->x_sym.x_fcnary.x_lnsz.x_lnno);
+ bfd_h_put_16(abfd, in->x_sym.x_misc.x_lnsz.x_size,
+ (bfd_byte *)ext->x_sym.x_fcnary.x_lnsz.x_size);
+ }
+
+end:
+ return bfd_coff_auxesz (abfd);
+}
+
+#define SELECT_RELOC(internal, howto) \
+ { \
+ internal.r_type = howto->type; \
+ internal.r_size = \
+ ((howto->complain_on_overflow == complain_overflow_signed \
+ ? 0x80 \
+ : 0) \
+ | (howto->bitsize - 1)); \
+ }
+
+#define COFF_DEFAULT_SECTION_ALIGNMENT_POWER (3)
+
+#define COFF_LONG_FILENAMES
+
+#define RTYPE2HOWTO(cache_ptr, dst) _bfd_xcoff_rtype2howto (cache_ptr, dst)
+
+#define coff_SWAP_sym_in xcoff64_swap_sym_in
+#define coff_SWAP_sym_out xcoff64_swap_sym_out
+#define coff_SWAP_aux_in xcoff64_swap_aux_in
+#define coff_SWAP_aux_out xcoff64_swap_aux_out
+#define coff_mkobject _bfd_xcoff_mkobject
+#define coff_bfd_copy_private_bfd_data _bfd_xcoff_copy_private_bfd_data
+#define coff_bfd_is_local_label_name _bfd_xcoff_is_local_label_name
+#define coff_bfd_reloc_type_lookup _bfd_xcoff_reloc_type_lookup
+#define coff_relocate_section _bfd_ppc_xcoff_relocate_section
+
+extern boolean _bfd_xcoff_mkobject PARAMS ((bfd *));
+extern boolean _bfd_xcoff_copy_private_bfd_data PARAMS ((bfd *, bfd *));
+extern boolean _bfd_xcoff_is_local_label_name PARAMS ((bfd *, const char *));
+extern void _bfd_xcoff_rtype2howto
+ PARAMS ((arelent *, struct internal_reloc *));
+extern reloc_howto_type *_bfd_xcoff_reloc_type_lookup
+ PARAMS ((bfd *, bfd_reloc_code_real_type));
+extern boolean _bfd_xcoff_slurp_armap PARAMS ((bfd *));
+extern const bfd_target *_bfd_xcoff_archive_p PARAMS ((bfd *));
+extern PTR _bfd_xcoff_read_ar_hdr PARAMS ((bfd *));
+extern bfd *_bfd_xcoff_openr_next_archived_file PARAMS ((bfd *, bfd *));
+extern int _bfd_xcoff_generic_stat_arch_elt PARAMS ((bfd *, struct stat *));
+extern boolean _bfd_xcoff_write_armap
+ PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
+extern boolean _bfd_xcoff_write_archive_contents PARAMS ((bfd *));
+extern int _bfd_xcoff_sizeof_headers PARAMS ((bfd *, boolean));
+
+#define _bfd_xcoff_slurp_extended_name_table bfd_false
+#define _bfd_xcoff_construct_extended_name_table \
+ ((boolean (*) PARAMS ((bfd *, char **, bfd_size_type *, const char **))) \
+ bfd_false)
+#define _bfd_xcoff_truncate_arname bfd_dont_truncate_arname
+
+/* We can use the standard get_elt_at_index routine. */
+
+#define _bfd_xcoff_get_elt_at_index _bfd_generic_get_elt_at_index
+
+/* XCOFF archives do not have a timestamp. */
+
+#define _bfd_xcoff_update_armap_timestamp bfd_true
+
+#include "coffcode.h"
+
+#define CORE_FILE_P _bfd_dummy_target
+
+#define coff_core_file_failing_command _bfd_nocore_core_file_failing_command
+#define coff_core_file_failing_signal _bfd_nocore_core_file_failing_signal
+#define coff_core_file_matches_executable_p \
+ _bfd_nocore_core_file_matches_executable_p
+
+#define _bfd_xcoff_bfd_get_relocated_section_contents \
+ coff_bfd_get_relocated_section_contents
+#define _bfd_xcoff_bfd_relax_section coff_bfd_relax_section
+#define _bfd_xcoff_bfd_gc_sections coff_bfd_gc_sections
+#define _bfd_xcoff_bfd_link_split_section coff_bfd_link_split_section
+
+/* The transfer vector that leads the outside world to all of the above. */
+
+const bfd_target
+#ifdef TARGET_SYM
+ TARGET_SYM =
+#else
+ rs6000coff64_vec =
+#endif
+{
+#ifdef TARGET_NAME
+ TARGET_NAME,
+#else
+ "aixcoff64-rs6000", /* name */
+#endif
+ bfd_target_coff_flavour,
+ BFD_ENDIAN_BIG, /* data byte order is big */
+ BFD_ENDIAN_BIG, /* header byte order is big */
+
+ (HAS_RELOC | EXEC_P | /* object flags */
+ HAS_LINENO | HAS_DEBUG | DYNAMIC |
+ HAS_SYMS | HAS_LOCALS | WP_TEXT),
+
+ (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC), /* section flags */
+ 0, /* leading char */
+ '/', /* ar_pad_char */
+ 15, /* ar_max_namelen??? FIXMEmgo */
+
+ bfd_getb64, bfd_getb_signed_64, bfd_putb64,
+ bfd_getb32, bfd_getb_signed_32, bfd_putb32,
+ bfd_getb16, bfd_getb_signed_16, bfd_putb16, /* data */
+ bfd_getb64, bfd_getb_signed_64, bfd_putb64,
+ bfd_getb32, bfd_getb_signed_32, bfd_putb32,
+ bfd_getb16, bfd_getb_signed_16, bfd_putb16, /* hdrs */
+
+ {_bfd_dummy_target, coff_object_p, /* bfd_check_format */
+ _bfd_xcoff_archive_p, CORE_FILE_P},
+ {bfd_false, coff_mkobject, /* bfd_set_format */
+ _bfd_generic_mkarchive, bfd_false},
+ {bfd_false, coff_write_object_contents, /* bfd_write_contents */
+ _bfd_xcoff_write_archive_contents, bfd_false},
+
+ BFD_JUMP_TABLE_GENERIC (coff),
+ BFD_JUMP_TABLE_COPY (coff),
+ BFD_JUMP_TABLE_CORE (coff),
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_xcoff),
+ BFD_JUMP_TABLE_SYMBOLS (coff),
+ BFD_JUMP_TABLE_RELOCS (coff),
+ BFD_JUMP_TABLE_WRITE (coff),
+ BFD_JUMP_TABLE_LINK (_bfd_xcoff),
+ BFD_JUMP_TABLE_DYNAMIC (_bfd_xcoff),
+
+ NULL,
+
+ COFF_SWAP_TABLE
+};
diff --git a/bfd/coffcode.h b/bfd/coffcode.h
index 9474e93..08e99f6 100644
--- a/bfd/coffcode.h
+++ b/bfd/coffcode.h
@@ -1901,9 +1901,13 @@ coff_set_arch_mach_hook (abfd, filehdr)
#endif
#ifdef RS6000COFF_C
+#ifdef XCOFF64
+ case U802TOC64MAGIC:
+#else
case U802ROMAGIC:
case U802WRMAGIC:
case U802TOCMAGIC:
+#endif
{
int cputype;
@@ -1930,7 +1934,7 @@ coff_set_arch_mach_hook (abfd, filehdr)
free (buf);
return false;
}
- coff_swap_sym_in (abfd, (PTR) buf, (PTR) &sym);
+ bfd_coff_swap_sym_in (abfd, (PTR) buf, (PTR) &sym);
if (sym.n_sclass == C_FILE)
cputype = sym.n_type & 0xff;
else
@@ -1952,7 +1956,11 @@ coff_set_arch_mach_hook (abfd, filehdr)
machine = 0;
#else
arch = bfd_arch_rs6000;
+#ifdef XCOFF64
+ machine = 620;
+#else
machine = 6000;
+#endif
#endif /* POWERMAC */
break;
@@ -2125,6 +2133,10 @@ symname_in_debug_hook (abfd, sym)
#ifdef RS6000COFF_C
+#ifdef XCOFF64
+#define FORCE_SYMNAMES_IN_STRINGS
+#endif
+
/* Handle the csect auxent of a C_EXT or C_HIDEXT symbol. */
static boolean coff_pointerize_aux_hook
@@ -2667,12 +2679,18 @@ coff_set_flags (abfd, magicp, flagsp)
break;
#endif
-#ifdef U802TOCMAGIC
+#ifdef RS6000COFF_C
case bfd_arch_rs6000:
#ifndef PPCMAGIC
case bfd_arch_powerpc:
#endif
- *magicp = U802TOCMAGIC;
+#ifdef XCOFF64
+ if (bfd_get_mach (abfd) == 620 && !strncmp (abfd->xvec->name,"aix", 3))
+ *magicp = U802TOC64MAGIC;
+ else
+#else
+ *magicp = U802TOCMAGIC;
+#endif
return true;
break;
#endif
@@ -2780,8 +2798,8 @@ coff_compute_section_file_positions (abfd)
size_t len;
len = strlen (bfd_asymbol_name (*symp));
- if (len > SYMNMLEN)
- sz += len + 3;
+ if (len > SYMNMLEN || bfd_coff_force_symnames_in_strings (abfd))
+ sz += len + 1 + bfd_coff_debug_string_prefix_length (abfd);
}
}
if (sz > 0)
@@ -3309,7 +3327,8 @@ coff_write_object_contents (abfd)
&& ! is_reloc_section)
hasdebug = true;
-#ifdef RS6000COFF_C
+#ifdef RS6000COFF_C
+#ifndef XCOFF64
/* Indicate the use of an XCOFF overflow section header. */
if (current->reloc_count >= 0xffff || current->lineno_count >= 0xffff)
{
@@ -3317,6 +3336,7 @@ coff_write_object_contents (abfd)
section.s_nlnno = 0xffff;
}
#endif
+#endif
section.s_flags = sec_to_styp_flags (current->name, current->flags);
@@ -4068,7 +4088,7 @@ coff_slurp_line_table (abfd, asect)
while (counter < asect->lineno_count)
{
struct internal_lineno dst;
- coff_swap_lineno_in (abfd, src, &dst);
+ bfd_coff_swap_lineno_in (abfd, src, &dst);
cache_ptr->line_number = dst.l_lnno;
if (cache_ptr->line_number == 0)
@@ -5009,7 +5029,17 @@ static const bfd_coff_backend_data bfd_coff_std_swap_table =
#else
false,
#endif
- COFF_DEFAULT_SECTION_ALIGNMENT_POWER,
+ COFF_DEFAULT_SECTION_ALIGNMENT_POWER,
+#ifdef COFF_FORCE_SYMBOLS_IN_STRINGS
+ true,
+#else
+ false,
+#endif
+#ifdef COFF_DEBUG_STRING_WIDE_PREFIX
+ 4,
+#else
+ 2,
+#endif
coff_SWAP_filehdr_in, coff_SWAP_aouthdr_in, coff_SWAP_scnhdr_in,
coff_SWAP_reloc_in, coff_bad_format_hook, coff_set_arch_mach_hook,
coff_mkobject_hook, styp_to_sec_flags, coff_set_alignment_hook,
diff --git a/bfd/coffgen.c b/bfd/coffgen.c
index 47e5baa..bb7f862 100644
--- a/bfd/coffgen.c
+++ b/bfd/coffgen.c
@@ -819,7 +819,16 @@ coff_fix_symbol_name (abfd, symbol, native, string_size_p,
{
unsigned int filnmlen;
- strncpy (native->u.syment._n._n_name, ".file", SYMNMLEN);
+ if (bfd_coff_force_symnames_in_strings (abfd))
+ {
+ native->u.syment._n._n_n._n_offset =
+ (*string_size_p + STRING_SIZE_SIZE);
+ native->u.syment._n._n_n._n_zeroes = 0;
+ *string_size_p += 6; /* strlen(".file") + 1 */
+ }
+ else
+ strncpy (native->u.syment._n._n_name, ".file", SYMNMLEN);
+
auxent = &(native + 1)->u.auxent;
filnmlen = bfd_coff_filnmlen (abfd);
@@ -846,7 +855,7 @@ coff_fix_symbol_name (abfd, symbol, native, string_size_p,
}
else
{
- if (name_length <= SYMNMLEN)
+ if (name_length <= SYMNMLEN && !bfd_coff_force_symnames_in_strings (abfd))
{
/* This name will fit into the symbol neatly */
strncpy (native->u.syment._n._n_name, symbol->name, SYMNMLEN);
@@ -861,7 +870,8 @@ coff_fix_symbol_name (abfd, symbol, native, string_size_p,
else
{
long filepos;
- bfd_byte buf[2];
+ bfd_byte buf[4];
+ int prefix_len = bfd_coff_debug_string_prefix_length (abfd);
/* This name should be written into the .debug section. For
some reason each name is preceded by a two byte length
@@ -871,24 +881,29 @@ coff_fix_symbol_name (abfd, symbol, native, string_size_p,
if (*debug_string_section_p == (asection *) NULL)
*debug_string_section_p = bfd_get_section_by_name (abfd, ".debug");
filepos = bfd_tell (abfd);
- bfd_put_16 (abfd, name_length + 1, buf);
+ if (prefix_len == 4)
+ bfd_put_32 (abfd, name_length + 1, buf);
+ else
+ bfd_put_16 (abfd, name_length + 1, buf);
+
if (!bfd_set_section_contents (abfd,
*debug_string_section_p,
(PTR) buf,
(file_ptr) *debug_string_size_p,
- (bfd_size_type) 2)
+ (bfd_size_type) prefix_len)
|| !bfd_set_section_contents (abfd,
*debug_string_section_p,
(PTR) symbol->name,
((file_ptr) *debug_string_size_p
- + 2),
+ + prefix_len),
(bfd_size_type) name_length + 1))
abort ();
if (bfd_seek (abfd, filepos, SEEK_SET) != 0)
abort ();
- native->u.syment._n._n_n._n_offset = *debug_string_size_p + 2;
+ native->u.syment._n._n_n._n_offset =
+ *debug_string_size_p + prefix_len;
native->u.syment._n._n_n._n_zeroes = 0;
- *debug_string_size_p += name_length + 3;
+ *debug_string_size_p += name_length + 1 + prefix_len;
}
}
}
@@ -1244,7 +1259,7 @@ coff_write_symbols (abfd)
{
/* This is not a COFF symbol, so it certainly is not a
file name, nor does it go in the .debug section. */
- maxlen = SYMNMLEN;
+ maxlen = bfd_coff_force_symnames_in_strings (abfd) ? 0 : SYMNMLEN;
}
else if (bfd_coff_symname_in_debug (abfd,
&c_symbol->native->u.syment))
@@ -1255,9 +1270,13 @@ coff_write_symbols (abfd)
}
else if (c_symbol->native->u.syment.n_sclass == C_FILE
&& c_symbol->native->u.syment.n_numaux > 0)
- maxlen = bfd_coff_filnmlen (abfd);
+ {
+ if (bfd_coff_force_symnames_in_strings (abfd))
+ bfd_write (".file", 1, 6, abfd);
+ maxlen = bfd_coff_filnmlen (abfd);
+ }
else
- maxlen = SYMNMLEN;
+ maxlen = bfd_coff_force_symnames_in_strings (abfd) ? 0 : SYMNMLEN;
if (name_length > maxlen)
{
diff --git a/bfd/coffswap.h b/bfd/coffswap.h
index d7d090f..5bf011e 100644
--- a/bfd/coffswap.h
+++ b/bfd/coffswap.h
@@ -168,12 +168,18 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef GET_SCNHDR_NRELOC
#define GET_SCNHDR_NRELOC bfd_h_get_16
#endif
+#ifndef MAX_SCNHDR_NRELOC
+#define MAX_SCNHDR_NRELOC 0xffff
+#endif
#ifndef PUT_SCNHDR_NRELOC
#define PUT_SCNHDR_NRELOC bfd_h_put_16
#endif
#ifndef GET_SCNHDR_NLNNO
#define GET_SCNHDR_NLNNO bfd_h_get_16
#endif
+#ifndef MAX_SCNHDR_NLNNO
+#define MAX_SCNHDR_NLNNO 0xffff
+#endif
#ifndef PUT_SCNHDR_NLNNO
#define PUT_SCNHDR_NLNNO bfd_h_put_16
#endif
@@ -184,6 +190,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define PUT_SCNHDR_FLAGS bfd_h_put_32
#endif
+#ifndef GET_RELOC_VADDR
+#define GET_RELOC_VADDR bfd_h_get_32
+#endif
+#ifndef PUT_RELOC_VADDR
+#define PUT_RELOC_VADDR bfd_h_put_32
+#endif
static void coff_swap_aouthdr_in PARAMS ((bfd *, PTR, PTR));
static unsigned int coff_swap_aouthdr_out PARAMS ((bfd *, PTR, PTR));
@@ -217,7 +229,7 @@ coff_swap_reloc_in (abfd, src, dst)
RELOC *reloc_src = (RELOC *) src;
struct internal_reloc *reloc_dst = (struct internal_reloc *) dst;
- reloc_dst->r_vaddr = bfd_h_get_32(abfd, (bfd_byte *)reloc_src->r_vaddr);
+ reloc_dst->r_vaddr = GET_RELOC_VADDR (abfd, (bfd_byte *)reloc_src->r_vaddr);
reloc_dst->r_symndx = bfd_h_get_signed_32(abfd, (bfd_byte *) reloc_src->r_symndx);
#ifdef RS6000COFF_C
@@ -241,7 +253,7 @@ coff_swap_reloc_out (abfd, src, dst)
{
struct internal_reloc *reloc_src = (struct internal_reloc *)src;
struct external_reloc *reloc_dst = (struct external_reloc *)dst;
- bfd_h_put_32(abfd, reloc_src->r_vaddr, (bfd_byte *) reloc_dst->r_vaddr);
+ PUT_RELOC_VADDR (abfd, reloc_src->r_vaddr, (bfd_byte *) reloc_dst->r_vaddr);
bfd_h_put_32(abfd, reloc_src->r_symndx, (bfd_byte *) reloc_dst->r_symndx);
#ifdef RS6000COFF_C
@@ -439,28 +451,6 @@ coff_swap_aux_in (abfd, ext1, type, class, indx, numaux, in1)
}
goto end;
- /* RS/6000 "csect" auxents */
-#ifdef RS6000COFF_C
- case C_EXT:
- case C_HIDEXT:
- if (indx + 1 == numaux)
- {
- in->x_csect.x_scnlen.l = bfd_h_get_32 (abfd, ext->x_csect.x_scnlen);
- in->x_csect.x_parmhash = bfd_h_get_32 (abfd,
- ext->x_csect.x_parmhash);
- in->x_csect.x_snhash = bfd_h_get_16 (abfd, ext->x_csect.x_snhash);
- /* We don't have to hack bitfields in x_smtyp because it's
- defined by shifts-and-ands, which are equivalent on all
- byte orders. */
- in->x_csect.x_smtyp = bfd_h_get_8 (abfd, ext->x_csect.x_smtyp);
- in->x_csect.x_smclas = bfd_h_get_8 (abfd, ext->x_csect.x_smclas);
- in->x_csect.x_stab = bfd_h_get_32 (abfd, ext->x_csect.x_stab);
- in->x_csect.x_snstab = bfd_h_get_16 (abfd, ext->x_csect.x_snstab);
- goto end;
- }
- break;
-#endif
-
case C_STAT:
#ifdef C_LEAFSTAT
case C_LEAFSTAT:
@@ -558,27 +548,6 @@ coff_swap_aux_out (abfd, inp, type, class, indx, numaux, extp)
}
goto end;
-#ifdef RS6000COFF_C
- /* RS/6000 "csect" auxents */
- case C_EXT:
- case C_HIDEXT:
- if (indx + 1 == numaux)
- {
- PUTWORD (abfd, in->x_csect.x_scnlen.l, ext->x_csect.x_scnlen);
- PUTWORD (abfd, in->x_csect.x_parmhash, ext->x_csect.x_parmhash);
- PUTHALF (abfd, in->x_csect.x_snhash, ext->x_csect.x_snhash);
- /* We don't have to hack bitfields in x_smtyp because it's
- defined by shifts-and-ands, which are equivalent on all
- byte orders. */
- PUTBYTE (abfd, in->x_csect.x_smtyp, ext->x_csect.x_smtyp);
- PUTBYTE (abfd, in->x_csect.x_smclas, ext->x_csect.x_smclas);
- PUTWORD (abfd, in->x_csect.x_stab, ext->x_csect.x_stab);
- PUTHALF (abfd, in->x_csect.x_snstab, ext->x_csect.x_snstab);
- goto end;
- }
- break;
-#endif
-
case C_STAT:
#ifdef C_LEAFSTAT
case C_LEAFSTAT:
@@ -705,7 +674,11 @@ coff_swap_aouthdr_in (abfd, aouthdr_ext1, aouthdr_int1)
#ifdef RS6000COFF_C
+#ifdef XCOFF64
+ aouthdr_int->o_toc = bfd_h_get_64(abfd, aouthdr_ext->o_toc);
+#else
aouthdr_int->o_toc = bfd_h_get_32(abfd, aouthdr_ext->o_toc);
+#endif
aouthdr_int->o_snentry = bfd_h_get_16(abfd, aouthdr_ext->o_snentry);
aouthdr_int->o_sntext = bfd_h_get_16(abfd, aouthdr_ext->o_sntext);
aouthdr_int->o_sndata = bfd_h_get_16(abfd, aouthdr_ext->o_sndata);
@@ -716,9 +689,14 @@ coff_swap_aouthdr_in (abfd, aouthdr_ext1, aouthdr_int1)
aouthdr_int->o_algndata = bfd_h_get_16(abfd, aouthdr_ext->o_algndata);
aouthdr_int->o_modtype = bfd_h_get_16(abfd, aouthdr_ext->o_modtype);
aouthdr_int->o_cputype = bfd_h_get_16(abfd, aouthdr_ext->o_cputype);
+#ifdef XCOFF64
+ aouthdr_int->o_maxstack = bfd_h_get_64(abfd, aouthdr_ext->o_maxstack);
+ aouthdr_int->o_maxdata = bfd_h_get_64(abfd, aouthdr_ext->o_maxdata);
+#else
aouthdr_int->o_maxstack = bfd_h_get_32(abfd, aouthdr_ext->o_maxstack);
aouthdr_int->o_maxdata = bfd_h_get_32(abfd, aouthdr_ext->o_maxdata);
#endif
+#endif
#ifdef MIPSECOFF
aouthdr_int->bss_start = bfd_h_get_32(abfd, aouthdr_ext->bss_start);
@@ -763,7 +741,11 @@ coff_swap_aouthdr_out (abfd, in, out)
#endif
#ifdef RS6000COFF_C
+#ifdef XCOFF64
+ bfd_h_put_64 (abfd, aouthdr_in->o_toc, aouthdr_out->o_toc);
+#else
bfd_h_put_32 (abfd, aouthdr_in->o_toc, aouthdr_out->o_toc);
+#endif
bfd_h_put_16 (abfd, aouthdr_in->o_snentry, aouthdr_out->o_snentry);
bfd_h_put_16 (abfd, aouthdr_in->o_sntext, aouthdr_out->o_sntext);
bfd_h_put_16 (abfd, aouthdr_in->o_sndata, aouthdr_out->o_sndata);
@@ -774,9 +756,18 @@ coff_swap_aouthdr_out (abfd, in, out)
bfd_h_put_16 (abfd, aouthdr_in->o_algndata, aouthdr_out->o_algndata);
bfd_h_put_16 (abfd, aouthdr_in->o_modtype, aouthdr_out->o_modtype);
bfd_h_put_16 (abfd, aouthdr_in->o_cputype, aouthdr_out->o_cputype);
+#ifdef XCOFF64
+ bfd_h_put_64 (abfd, aouthdr_in->o_maxstack, aouthdr_out->o_maxstack);
+ bfd_h_put_64 (abfd, aouthdr_in->o_maxdata, aouthdr_out->o_maxdata);
+#else
bfd_h_put_32 (abfd, aouthdr_in->o_maxstack, aouthdr_out->o_maxstack);
bfd_h_put_32 (abfd, aouthdr_in->o_maxdata, aouthdr_out->o_maxdata);
+#endif
memset (aouthdr_out->o_resv2, 0, sizeof aouthdr_out->o_resv2);
+#ifdef XCOFF64
+ memset (aouthdr_out->o_debugger, 0, sizeof aouthdr_out->o_debugger);
+ memset (aouthdr_out->o_resv3, 0, sizeof aouthdr_out->o_resv3);
+#endif
#endif
#ifdef MIPSECOFF
@@ -879,8 +870,9 @@ coff_swap_scnhdr_out (abfd, in, out)
PUTWORD(abfd, scnhdr_int->s_nlnno, (bfd_byte *) scnhdr_ext->s_nlnno);
PUTWORD(abfd, scnhdr_int->s_nreloc, (bfd_byte *) scnhdr_ext->s_nreloc);
#else
- if (scnhdr_int->s_nlnno <= 0xffff)
- PUTHALF(abfd, scnhdr_int->s_nlnno, (bfd_byte *) scnhdr_ext->s_nlnno);
+ if (scnhdr_int->s_nlnno <= MAX_SCNHDR_NLNNO)
+ PUT_SCNHDR_NLNNO(abfd, scnhdr_int->s_nlnno,
+ (bfd_byte *) scnhdr_ext->s_nlnno);
else
{
char buf[sizeof (scnhdr_int->s_name) + 1];
@@ -891,10 +883,11 @@ coff_swap_scnhdr_out (abfd, in, out)
(_("%s: warning: %s: line number overflow: 0x%lx > 0xffff"),
bfd_get_filename (abfd),
buf, scnhdr_int->s_nlnno);
- PUTHALF (abfd, 0xffff, (bfd_byte *) scnhdr_ext->s_nlnno);
+ PUT_SCNHDR_NLNNO(abfd, 0xffff, (bfd_byte *) scnhdr_ext->s_nlnno);
}
- if (scnhdr_int->s_nreloc <= 0xffff)
- PUTHALF(abfd, scnhdr_int->s_nreloc, (bfd_byte *) scnhdr_ext->s_nreloc);
+ if (scnhdr_int->s_nreloc <= MAX_SCNHDR_NRELOC)
+ PUT_SCNHDR_NRELOC(abfd, scnhdr_int->s_nreloc,
+ (bfd_byte *) scnhdr_ext->s_nreloc);
else
{
char buf[sizeof (scnhdr_int->s_name) + 1];
@@ -905,7 +898,7 @@ coff_swap_scnhdr_out (abfd, in, out)
bfd_get_filename (abfd),
buf, scnhdr_int->s_nreloc);
bfd_set_error (bfd_error_file_truncated);
- PUTHALF (abfd, 0xffff, (bfd_byte *) scnhdr_ext->s_nreloc);
+ PUT_SCNHDR_NRELOC(abfd, 0xffff, (bfd_byte *) scnhdr_ext->s_nreloc);
ret = 0;
}
#endif
diff --git a/bfd/config.bfd b/bfd/config.bfd
index def3df0..cca93c8 100644
--- a/bfd/config.bfd
+++ b/bfd/config.bfd
@@ -42,7 +42,7 @@ m88*) targ_archs=bfd_m88k_arch ;;
mips*) targ_archs=bfd_mips_arch ;;
pj*) targ_archs="bfd_pj_arch bfd_i386_arch";;
powerpc*) targ_archs="bfd_rs6000_arch bfd_powerpc_arch" ;;
-rs6000) targ_archs="bfd_rs6000_arch bfd_powerpc_arch" ;;
+rs6000) targ_archs="bfd_rs6000_arch bfd_powerpc_64_arch bfd_powerpc_arch" ;;
sparc*) targ_archs=bfd_sparc_arch ;;
v850*) targ_archs=bfd_v850_arch ;;
z8k*) targ_archs=bfd_z8k_arch ;;
@@ -628,6 +628,7 @@ case "${targ}" in
powerpc-*-aix* | powerpc-*-beos*)
targ_defvec=rs6000coff_vec
+ targ_selvecs="rs6000coff64_vec"
;;
powerpc-*-*bsd* | powerpc-*-elf* | powerpc-*-sysv4* | powerpc-*-eabi* | \
powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-rtems* | \
diff --git a/bfd/configure b/bfd/configure
index 779e749..9f1425e 100755
--- a/bfd/configure
+++ b/bfd/configure
@@ -1845,7 +1845,7 @@ else
if { (eval echo configure:1846: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
+ *.c | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
@@ -5206,6 +5206,8 @@ do
mcore_pei_little_vec) tb="$tb pei-mcore.lo peigen.lo cofflink.lo" ;;
newsos3_vec) tb="$tb newsos3.lo aout32.lo" ;;
nlm32_i386_vec) tb="$tb nlm32-i386.lo nlm32.lo nlm.lo" ;;
+ rs6000coff64_vec) tb="$tb coff64-rs6000.lo xcofflink.lo"
+ target64=true ;;
nlm32_sparc_vec) tb="$tb nlm32-sparc.lo nlm32.lo nlm.lo" ;;
nlm32_alpha_vec) tb="$tb nlm32-alpha.lo nlm32.lo nlm.lo"
target64=true ;;
@@ -5334,17 +5336,17 @@ for ac_hdr in unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:5338: checking for $ac_hdr" >&5
+echo "configure:5340: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5343 "configure"
+#line 5345 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5348: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5350: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -5373,12 +5375,12 @@ done
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:5377: checking for $ac_func" >&5
+echo "configure:5379: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5382 "configure"
+#line 5384 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -5401,7 +5403,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:5405: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5407: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -5426,7 +5428,7 @@ fi
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:5430: checking for working mmap" >&5
+echo "configure:5432: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -5434,7 +5436,7 @@ else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 5438 "configure"
+#line 5440 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
@@ -5574,7 +5576,7 @@ main()
}
EOF
-if { (eval echo configure:5578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:5580: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
@@ -5599,12 +5601,12 @@ fi
for ac_func in madvise mprotect
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:5603: checking for $ac_func" >&5
+echo "configure:5605: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5608 "configure"
+#line 5610 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -5627,7 +5629,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:5631: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5633: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
diff --git a/bfd/configure.in b/bfd/configure.in
index 8dbd9bb..c87197d 100644
--- a/bfd/configure.in
+++ b/bfd/configure.in
@@ -574,6 +574,8 @@ do
mcore_pei_little_vec) tb="$tb pei-mcore.lo peigen.lo cofflink.lo" ;;
newsos3_vec) tb="$tb newsos3.lo aout32.lo" ;;
nlm32_i386_vec) tb="$tb nlm32-i386.lo nlm32.lo nlm.lo" ;;
+ rs6000coff64_vec) tb="$tb coff64-rs6000.lo xcofflink.lo"
+ target64=true ;;
nlm32_sparc_vec) tb="$tb nlm32-sparc.lo nlm32.lo nlm.lo" ;;
nlm32_alpha_vec) tb="$tb nlm32-alpha.lo nlm32.lo nlm.lo"
target64=true ;;
diff --git a/bfd/cpu-powerpc.c b/bfd/cpu-powerpc.c
index 11f0f80..a2c8f59 100644
--- a/bfd/cpu-powerpc.c
+++ b/bfd/cpu-powerpc.c
@@ -103,6 +103,20 @@ static const bfd_arch_info_type arch_info_struct[] =
false, /* not the default */
powerpc_compatible,
bfd_default_scan,
+ &arch_info_struct[4]
+ },
+ {
+ 32, /* 32 bits in a word */
+ 64, /* 64 bits in an address */
+ 8, /* 8 bits in a byte */
+ bfd_arch_powerpc,
+ 620, /* for the mpc620 */
+ "powerpc",
+ "powerpc:620",
+ 3,
+ false, /* not the default */
+ powerpc_compatible,
+ bfd_default_scan,
0
}
};
diff --git a/bfd/libcoff.h b/bfd/libcoff.h
index bee4ce9..a81fe68 100644
--- a/bfd/libcoff.h
+++ b/bfd/libcoff.h
@@ -713,6 +713,8 @@ typedef struct
boolean _bfd_coff_long_filenames;
boolean _bfd_coff_long_section_names;
unsigned int _bfd_coff_default_section_alignment_power;
+ boolean _bfd_coff_force_symnames_in_strings;
+ unsigned int _bfd_coff_debug_string_prefix_length;
void (*_bfd_coff_swap_filehdr_in) PARAMS ((
bfd *abfd,
PTR ext,
@@ -910,6 +912,12 @@ typedef struct
#define bfd_coff_symname_in_debug(abfd, sym)\
((coff_backend_info (abfd)->_bfd_coff_symname_in_debug) (abfd, sym))
+#define bfd_coff_force_symnames_in_strings(abfd)\
+ (coff_backend_info (abfd)->_bfd_coff_force_symnames_in_strings)
+
+#define bfd_coff_debug_string_prefix_length(abfd)\
+ (coff_backend_info (abfd)->_bfd_coff_debug_string_prefix_length)
+
#define bfd_coff_print_aux(abfd, file, base, symbol, aux, indaux)\
((coff_backend_info (abfd)->_bfd_coff_print_aux)\
(abfd, file, base, symbol, aux, indaux))
diff --git a/bfd/reloc.c b/bfd/reloc.c
index 12f07b6..7e1dd87 100644
--- a/bfd/reloc.c
+++ b/bfd/reloc.c
@@ -729,6 +729,7 @@ bfd_perform_relocation (abfd, reloc_entry, data, input_section, output_bfd,
/* WTF?? */
if (abfd->xvec->flavour == bfd_target_coff_flavour
&& strcmp (abfd->xvec->name, "aixcoff-rs6000") != 0
+ && strcmp (abfd->xvec->name, "aixcoff64-rs6000") != 0
&& strcmp (abfd->xvec->name, "xcoff-powermac") != 0
&& strcmp (abfd->xvec->name, "coff-Intel-little") != 0
&& strcmp (abfd->xvec->name, "coff-Intel-big") != 0)
@@ -1125,6 +1126,7 @@ bfd_install_relocation (abfd, reloc_entry, data_start, data_start_offset,
/* WTF?? */
if (abfd->xvec->flavour == bfd_target_coff_flavour
&& strcmp (abfd->xvec->name, "aixcoff-rs6000") != 0
+ && strcmp (abfd->xvec->name, "aixcoff64-rs6000") != 0
&& strcmp (abfd->xvec->name, "xcoff-powermac") != 0
&& strcmp (abfd->xvec->name, "coff-Intel-little") != 0
&& strcmp (abfd->xvec->name, "coff-Intel-big") != 0)
diff --git a/bfd/targets.c b/bfd/targets.c
index 8b3a0e1..c481b2b 100644
--- a/bfd/targets.c
+++ b/bfd/targets.c
@@ -614,6 +614,7 @@ extern const bfd_target ppcboot_vec;
extern const bfd_target riscix_vec;
extern const bfd_target pmac_xcoff_vec;
extern const bfd_target rs6000coff_vec;
+extern const bfd_target rs6000coff64_vec;
extern const bfd_target shcoff_vec;
extern const bfd_target shlcoff_vec;
extern const bfd_target shcoff_small_vec;
@@ -867,6 +868,7 @@ const bfd_target * const bfd_target_vector[] = {
&pmac_xcoff_vec,
#endif
&rs6000coff_vec,
+ &rs6000coff64_vec,
&ppcboot_vec,
&shcoff_vec,
&shlcoff_vec,
diff --git a/bfd/xcofflink.c b/bfd/xcofflink.c
index 3f488d7..17517b0 100644
--- a/bfd/xcofflink.c
+++ b/bfd/xcofflink.c
@@ -35,6 +35,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
whole approach. */
#define XCOFF_XVECP(xv) \
(strcmp ((xv)->name, "aixcoff-rs6000") == 0 \
+ || strcmp ((xv)->name, "aixcoff64-rs6000") == 0 \
|| strcmp ((xv)->name, "xcoff-powermac") == 0)
/* Get the XCOFF hash table entries for a BFD. */
diff --git a/gas/ChangeLog b/gas/ChangeLog
index a8acd9a..7d6e2b9 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,22 @@
+Mon Apr 24 15:21:11 2000 Clinton Popetz <cpopetz@cygnus.com>
+
+ * as.c (parse_args): Allow md_parse_option to override -a listing
+ option.
+ * config/obj-coff.c (add_lineno): Change type of offset parameter
+ from "int" to "bfd_vma."
+ * config/tc-ppc.c (md_pseudo_table): Add "llong" and "machine."
+ (ppc_mach, ppc_subseg_align, ppc_target_format): New.
+ (ppc_change_csect): Align correctly for XCOFF64.
+ (ppc_machine): New function, which discards "ppc_machine" line.
+ (ppc_tc): Cons for 8 when code is 64 bit.
+ (md_apply_fix3): Don't check operand->insert. Handle 64 bit
+ relocations.
+ (md_parse_option): Handle -a64 and -a32.
+ (ppc_xcoff64): New.
+ * config/tc-ppc.h (TARGET_MACH): Define.
+ (TARGET_FORMAT): Move to function.
+ (SUB_SEGMENT_ALIGN): Use ppc_subseg_align.
+
2000-04-26 David O'Brien <obrien@FreeBSD.org>
* doc/as.1: Fix unbalanced brackets.
diff --git a/gas/as.c b/gas/as.c
index 9bac61d..e34807b 100644
--- a/gas/as.c
+++ b/gas/as.c
@@ -672,6 +672,9 @@ the GNU General Public License. This program has absolutely no warranty.\n"));
case 'a':
if (optarg)
{
+ if (md_parse_option (optc, optarg) != 0)
+ break;
+
while (*optarg)
{
switch (*optarg)
diff --git a/gas/config/obj-coff.c b/gas/config/obj-coff.c
index d750868..11648b9 100644
--- a/gas/config/obj-coff.c
+++ b/gas/config/obj-coff.c
@@ -429,7 +429,7 @@ int coff_n_line_nos;
static void
add_lineno (frag, offset, num)
fragS *frag;
- int offset;
+ addressT offset;
int num;
{
struct line_no *new_line =
diff --git a/gas/config/tc-ppc.c b/gas/config/tc-ppc.c
index 365a535..cac5d6a 100644
--- a/gas/config/tc-ppc.c
+++ b/gas/config/tc-ppc.c
@@ -86,6 +86,7 @@ static void ppc_stabx PARAMS ((int));
static void ppc_rename PARAMS ((int));
static void ppc_toc PARAMS ((int));
static void ppc_xcoff_cons PARAMS ((int));
+static void ppc_machine PARAMS ((int));
static void ppc_vbyte PARAMS ((int));
#endif
@@ -182,9 +183,11 @@ const pseudo_typeS md_pseudo_table[] =
{ "text", ppc_section, 't' },
{ "toc", ppc_toc, 0 },
{ "long", ppc_xcoff_cons, 2 },
+ { "llong", ppc_xcoff_cons, 3 },
{ "word", ppc_xcoff_cons, 1 },
{ "short", ppc_xcoff_cons, 1 },
{ "vbyte", ppc_vbyte, 0 },
+ { "machine", ppc_machine, 0 },
#endif
#ifdef OBJ_ELF
@@ -591,6 +594,9 @@ static int ppc_cpu = 0;
PPC_OPCODE_32 or PPC_OPCODE_64. */
static unsigned long ppc_size = PPC_OPCODE_32;
+/* Whether to target xcoff64 */
+static int ppc_xcoff64 = 0;
+
/* Opcode hash table. */
static struct hash_control *ppc_hash;
@@ -740,6 +746,16 @@ md_parse_option (c, arg)
break;
#endif
+ /* a64 and a32 determine whether to use XCOFF64 or XCOFF32. */
+ case 'a':
+ if (strcmp (arg, "64") == 0)
+ ppc_xcoff64 = 1;
+ else if (strcmp (arg, "32") == 0)
+ ppc_xcoff64 = 0;
+ else
+ return 0;
+ break;
+
case 'm':
/* -mpwrx and -mpwr2 mean to assemble for the IBM POWER/2
(RIOS2). */
@@ -948,6 +964,37 @@ ppc_arch ()
return bfd_arch_unknown;
}
+unsigned long
+ppc_mach ()
+{
+ return (ppc_size == PPC_OPCODE_64) ? 620 : 0;
+}
+
+int
+ppc_subseg_align()
+{
+ return (ppc_xcoff64) ? 3 : 2;
+}
+
+extern char*
+ppc_target_format()
+{
+#ifdef OBJ_COFF
+#ifdef TE_PE
+ return (target_big_endian ? "pe-powerpc" : "pe-powerpcle");
+#elif TE_POWERMAC
+#else
+ return (ppc_xcoff64 ? "aixcoff64-rs6000" : "aixcoff-rs6000");
+#endif
+#ifdef TE_POWERMAC
+ return "xcoff-powermac";
+#endif
+#endif
+#ifdef OBJ_ELF
+ return (target_big_endian ? "elf32-powerpc" : "elf32-powerpcle");
+#endif
+}
+
/* This function is called when the assembler starts up. It is called
after the options have been parsed and the output file has been
opened. */
@@ -2478,7 +2525,7 @@ ppc_change_csect (sym)
symbol_set_frag (sym, frag_now);
S_SET_VALUE (sym, (valueT) frag_now_fix ());
- symbol_get_tc (sym)->align = 2;
+ symbol_get_tc (sym)->align = (ppc_xcoff64) ? 3 : 2;
symbol_get_tc (sym)->output = 1;
symbol_get_tc (sym)->within = sym;
@@ -3150,6 +3197,14 @@ ppc_xcoff_cons (log_size)
}
static void
+ppc_machine(dummy)
+ int dummy;
+{
+ discard_rest_of_line();
+ /* What does aix use this for? */
+}
+
+static void
ppc_vbyte (dummy)
int dummy;
{
@@ -3269,7 +3324,7 @@ ppc_tc (ignore)
else
{
++input_line_pointer;
- cons (4);
+ cons ((ppc_size == PPC_OPCODE_64) ? 8 : 4);
}
}
@@ -4802,7 +4857,6 @@ md_apply_fix3 (fixp, valuep, seg)
else if ((operand->flags & PPC_OPERAND_PARENS) != 0
&& operand->bits == 16
&& operand->shift == 0
- && operand->insert == NULL
&& fixp->fx_addsy != NULL
&& ppc_is_toc_sym (fixp->fx_addsy))
{
@@ -4849,6 +4903,14 @@ md_apply_fix3 (fixp, valuep, seg)
value, 4);
break;
+ case BFD_RELOC_64:
+ if (fixp->fx_pcrel)
+ fixp->fx_r_type = BFD_RELOC_64_PCREL;
+ /* fall through */
+ case BFD_RELOC_64_PCREL:
+ md_number_to_chars (fixp->fx_frag->fr_literal + fixp->fx_where,
+ value, 8);
+ break;
case BFD_RELOC_LO16:
case BFD_RELOC_16:
case BFD_RELOC_GPREL16:
diff --git a/gas/config/tc-ppc.h b/gas/config/tc-ppc.h
index 783a215..8409c79 100644
--- a/gas/config/tc-ppc.h
+++ b/gas/config/tc-ppc.h
@@ -47,31 +47,16 @@ struct fix;
/* The target BFD architecture. */
#define TARGET_ARCH (ppc_arch ())
+#define TARGET_MACH (ppc_mach ())
extern enum bfd_architecture ppc_arch PARAMS ((void));
+extern unsigned long ppc_mach PARAMS ((void));
/* Whether or not the target is big endian */
extern int target_big_endian;
/* The target BFD format. */
-#ifdef OBJ_COFF
-#ifdef TE_PE
-#define TARGET_FORMAT (target_big_endian ? "pe-powerpc" : "pe-powerpcle")
-#else
-#define TARGET_FORMAT "aixcoff-rs6000"
-#endif
-#endif
-
-/* PowerMac has a BFD slightly different from AIX's. */
-#ifdef TE_POWERMAC
-#ifdef TARGET_FORMAT
-#undef TARGET_FORMAT
-#endif
-#define TARGET_FORMAT "xcoff-powermac"
-#endif
-
-#ifdef OBJ_ELF
-#define TARGET_FORMAT (target_big_endian ? "elf32-powerpc" : "elf32-powerpcle")
-#endif
+#define TARGET_FORMAT (ppc_target_format ())
+extern char* ppc_target_format ();
/* Permit temporary numeric labels. */
#define LOCAL_LABELS_FB 1
@@ -186,7 +171,8 @@ extern int ppc_frob_symbol PARAMS ((symbolS *));
extern void ppc_adjust_symtab PARAMS ((void));
/* Niclas Andersson <nican@ida.liu.se> says this is needed. */
-#define SUB_SEGMENT_ALIGN(SEG) 2
+extern int ppc_subseg_align PARAMS ((void));
+#define SUB_SEGMENT_ALIGN(SEG) ppc_subseg_align()
/* We also need to copy, in particular, the class of the symbol,
over what obj-coff would otherwise have copied. */
diff --git a/include/ChangeLog b/include/ChangeLog
index 82ad23f..59559ca 100644
--- a/include/ChangeLog
+++ b/include/ChangeLog
@@ -1,3 +1,7 @@
+Mon Apr 24 15:20:51 2000 Clinton Popetz <cpopetz@cygnus.com>
+
+ * include/coff/rs6k64.h: New file.
+
Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
David Mosberger <davidm@hpl.hp.com>
diff --git a/include/coff/rs6k64.h b/include/coff/rs6k64.h
new file mode 100644
index 0000000..86d739c
--- /dev/null
+++ b/include/coff/rs6k64.h
@@ -0,0 +1,236 @@
+/* IBM RS/6000 "XCOFF64" file definitions for BFD.
+ Copyright (C) 2000 Free Software Foundation, Inc. */
+
+/********************** FILE HEADER **********************/
+
+struct external_filehdr {
+ char f_magic[2]; /* magic number */
+ char f_nscns[2]; /* number of sections */
+ char f_timdat[4]; /* time & date stamp */
+ char f_symptr[8];/* file pointer to symtab */
+ char f_opthdr[2]; /* sizeof(optional hdr) */
+ char f_flags[2]; /* flags */
+ char f_nsyms[4]; /* number of symtab entries */
+};
+
+ /* IBM RS/6000 */
+#define U802TOC64MAGIC 0757 /* readonly text segments and TOC, XCOFF64 */
+
+#define BADMAG(x) ((x).f_magic != U802TOC64MAGIC)
+
+#define FILHDR struct external_filehdr
+#define FILHSZ 24
+
+/********************** AOUT "OPTIONAL HEADER" **********************/
+
+
+typedef struct
+{
+ unsigned char magic[2]; /* type of file */
+ unsigned char vstamp[2]; /* version stamp */
+ unsigned char o_debugger[4]; /* reserved */
+ unsigned char text_start[8]; /* base of text used for this file */
+ unsigned char data_start[8]; /* base of data used for this file */
+ unsigned char o_toc[8]; /* address of TOC */
+ unsigned char o_snentry[2]; /* section number of entry point */
+ unsigned char o_sntext[2]; /* section number of .text section */
+ unsigned char o_sndata[2]; /* section number of .data section */
+ unsigned char o_sntoc[2]; /* section number of TOC */
+ unsigned char o_snloader[2]; /* section number of .loader section */
+ unsigned char o_snbss[2]; /* section number of .bss section */
+ unsigned char o_algntext[2]; /* .text alignment */
+ unsigned char o_algndata[2]; /* .data alignment */
+ unsigned char o_modtype[2]; /* module type (??) */
+ unsigned char o_cputype[2]; /* cpu type */
+ unsigned char o_resv2[4]; /* reserved */
+ unsigned char tsize[8]; /* text size bytes, padded to FW bdry */
+ unsigned char dsize[8]; /* initialized data " " */
+ unsigned char bsize[8]; /* uninitialized data " " */
+ unsigned char entry[8]; /* entry pt. */
+ unsigned char o_maxstack[8]; /* max stack size (??) */
+ unsigned char o_maxdata[8]; /* max data size (??) */
+ unsigned char o_resv3[116]; /* reserved */
+}
+AOUTHDR;
+
+#define AOUTSZ 220
+#define SMALL_AOUTSZ (0)
+#define AOUTHDRSZ 72
+
+#define RS6K_AOUTHDR_OMAGIC 0x0107 /* old: text & data writeable */
+#define RS6K_AOUTHDR_NMAGIC 0x0108 /* new: text r/o, data r/w */
+#define RS6K_AOUTHDR_ZMAGIC 0x010B /* paged: text r/o, both page-aligned */
+
+
+/********************** SECTION HEADER **********************/
+
+
+struct external_scnhdr {
+ char s_name[8]; /* section name */
+ char s_paddr[8]; /* physical address, aliased s_nlib */
+ char s_vaddr[8]; /* virtual address */
+ char s_size[8]; /* section size */
+ char s_scnptr[8]; /* file ptr to raw data for section */
+ char s_relptr[8]; /* file ptr to relocation */
+ char s_lnnoptr[8]; /* file ptr to line numbers */
+ char s_nreloc[4]; /* number of relocation entries */
+ char s_nlnno[4]; /* number of line number entries*/
+ char s_flags[4]; /* flags */
+ char s_pad[4]; /* padding */
+};
+
+/*
+ * names of "special" sections
+ */
+#define _TEXT ".text"
+#define _DATA ".data"
+#define _BSS ".bss"
+#define _PAD ".pad"
+#define _LOADER ".loader"
+
+#define SCNHDR struct external_scnhdr
+
+#define SCNHSZ 72
+
+/* XCOFF uses a special .loader section with type STYP_LOADER. */
+#define STYP_LOADER 0x1000
+
+/* XCOFF uses a special .debug section with type STYP_DEBUG. */
+#define STYP_DEBUG 0x2000
+
+/* XCOFF handles line number or relocation overflow by creating
+ another section header with STYP_OVRFLO set. */
+#define STYP_OVRFLO 0x8000
+
+/********************** LINE NUMBERS **********************/
+
+/* 1 line number entry for every "breakpointable" source line in a section.
+ * Line numbers are grouped on a per function basis; first entry in a function
+ * grouping will have l_lnno = 0 and in place of physical address will be the
+ * symbol table index of the function name.
+ */
+struct external_lineno {
+ union {
+ char l_symndx[8];/* function name symbol index, iff l_lnno == 0*/
+ char l_paddr[8]; /* (physical) address of line number */
+ } l_addr;
+ char l_lnno[4]; /* line number */
+};
+
+
+#define LINENO struct external_lineno
+
+#define LINESZ 12
+
+
+/********************** SYMBOLS **********************/
+
+#define E_SYMNMLEN 8 /* # characters in a symbol name */
+#define E_FILNMLEN 14 /* # characters in a file name */
+#define E_DIMNUM 4 /* # array dimensions in auxiliary entry */
+
+struct external_syment
+{
+ union {
+ char e_value[8];
+ } e;
+ char e_offset[4];
+ char e_scnum[2];
+ char e_type[2];
+ char e_sclass[1];
+ char e_numaux[1];
+};
+
+
+
+#define N_BTMASK (017)
+#define N_TMASK (060)
+#define N_BTSHFT (4)
+#define N_TSHIFT (2)
+
+
+union external_auxent {
+
+ struct {
+ union {
+ struct {
+ char x_lnno[4]; /* declaration line number */
+ char x_size[2]; /* str/union/array size */
+ } x_lnsz;
+ struct {
+ char x_lnnoptr[8];/* ptr to fcn line */
+ char x_fsize[4]; /* size of function */
+ char x_endndx[4]; /* entry ndx past block end */
+ } x_fcn;
+ } x_fcnary;
+ } x_sym;
+
+ union {
+ char x_fname[E_FILNMLEN];
+ struct {
+ char x_zeroes[4];
+ char x_offset[4];
+ char x_pad[6];
+ unsigned char x_ftype[1];
+ unsigned char x_resv[2];
+ } x_n;
+ } x_file;
+
+ struct {
+ char x_exptr[8];
+ char x_fsize[4];
+ char x_endndx[4];
+ char x_pad[1];
+ } x_except;
+
+ struct {
+ unsigned char x_scnlen_lo[4];
+ unsigned char x_parmhash[4];
+ unsigned char x_snhash[2];
+ unsigned char x_smtyp[1];
+ unsigned char x_smclas[1];
+ unsigned char x_scnlen_hi[4];
+ unsigned char x_pad[1];
+ } x_csect;
+
+ struct {
+ char x_pad[17];
+ char x_auxtype[1];
+ } x_auxtype;
+};
+
+#define SYMENT struct external_syment
+#define SYMESZ 18
+#define AUXENT union external_auxent
+#define AUXESZ 18
+#define DBXMASK 0x80 /* for dbx storage mask */
+#define SYMNAME_IN_DEBUG(symptr) ((symptr)->n_sclass & DBXMASK)
+
+/* Values for auxtype field in XCOFF64, taken from AIX 4.3 sym.h */
+#define _AUX_EXCEPT 255
+#define _AUX_FCN 254
+#define _AUX_SYM 253
+#define _AUX_FILE 252
+#define _AUX_CSECT 251
+
+
+
+/********************** RELOCATION DIRECTIVES **********************/
+
+
+struct external_reloc {
+ char r_vaddr[8];
+ char r_symndx[4];
+ char r_size[1];
+ char r_type[1];
+};
+
+
+#define RELOC struct external_reloc
+#define RELSZ 14
+
+#define DEFAULT_DATA_SECTION_ALIGNMENT 4
+#define DEFAULT_BSS_SECTION_ALIGNMENT 4
+#define DEFAULT_TEXT_SECTION_ALIGNMENT 4
+/* For new sections we havn't heard of before */
+#define DEFAULT_SECTION_ALIGNMENT 4
diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog
index fe86f74..647f929 100644
--- a/opcodes/ChangeLog
+++ b/opcodes/ChangeLog
@@ -1,3 +1,9 @@
+Mon Apr 24 15:21:35 2000 Clinton Popetz <cpopetz@cygnus.com>
+
+ * configure.in: Add bfd_powerpc_64_arch.
+ * disassemble.c (disassembler): Use print_insn_big_powerpc for
+ 64 bit code.
+
2000-04-24 Nick Clifton <nickc@cygnus.com>
* fr30-desc.c (fr30_cgen_cpu_open): Initialise signed_overflow
diff --git a/opcodes/configure b/opcodes/configure
index 99a7d20..c6caa7b 100755
--- a/opcodes/configure
+++ b/opcodes/configure
@@ -51,7 +51,6 @@ program_suffix=NONE
program_transform_name=s,x,x,
silent=
site=
-sitefile=
srcdir=
target=NONE
verbose=
@@ -166,7 +165,6 @@ Configuration:
--help print this message
--no-create do not create output files
--quiet, --silent do not print \`checking...' messages
- --site-file=FILE use FILE as the site file
--version print the version of autoconf that created configure
Directory and file names:
--prefix=PREFIX install architecture-independent files in PREFIX
@@ -337,11 +335,6 @@ EOF
-site=* | --site=* | --sit=*)
site="$ac_optarg" ;;
- -site-file | --site-file | --site-fil | --site-fi | --site-f)
- ac_prev=sitefile ;;
- -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
- sitefile="$ac_optarg" ;;
-
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
ac_prev=srcdir ;;
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
@@ -507,16 +500,12 @@ fi
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
# Prefer explicitly selected file to automatically selected ones.
-if test -z "$sitefile"; then
- if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
- fi
+if test -z "$CONFIG_SITE"; then
+ if test "x$prefix" != xNONE; then
+ CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+ else
+ CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
fi
-else
- CONFIG_SITE="$sitefile"
fi
for ac_site_file in $CONFIG_SITE; do
if test -r "$ac_site_file"; then
@@ -603,7 +592,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:607: checking host system type" >&5
+echo "configure:596: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -624,7 +613,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:628: checking target system type" >&5
+echo "configure:617: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -642,7 +631,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:646: checking build system type" >&5
+echo "configure:635: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -667,7 +656,7 @@ test "$host_alias" != "$target_alias" &&
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:671: checking for $ac_word" >&5
+echo "configure:660: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -697,7 +686,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:701: checking for $ac_word" >&5
+echo "configure:690: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -748,7 +737,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:752: checking for $ac_word" >&5
+echo "configure:741: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -780,7 +769,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:784: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:773: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -791,12 +780,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 795 "configure"
+#line 784 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:800: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:789: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -822,12 +811,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:826: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:815: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:831: checking whether we are using GNU C" >&5
+echo "configure:820: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -836,7 +825,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:840: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:829: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -855,7 +844,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:859: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:848: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -887,7 +876,7 @@ else
fi
echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:891: checking for POSIXized ISC" >&5
+echo "configure:880: checking for POSIXized ISC" >&5
if test -d /etc/conf/kconfig.d &&
grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
then
@@ -925,7 +914,7 @@ BFD_VERSION=`grep INIT_AUTOMAKE ${srcdir}/../bfd/configure.in | sed -n -e 's/[
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:929: checking for a BSD compatible install" >&5
+echo "configure:918: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -978,7 +967,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:982: checking whether build environment is sane" >&5
+echo "configure:971: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -1035,7 +1024,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:1039: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:1028: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1081,7 +1070,7 @@ EOF
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:1085: checking for working aclocal" >&5
+echo "configure:1074: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1094,7 +1083,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:1098: checking for working autoconf" >&5
+echo "configure:1087: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1107,7 +1096,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:1111: checking for working automake" >&5
+echo "configure:1100: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1120,7 +1109,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:1124: checking for working autoheader" >&5
+echo "configure:1113: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1133,7 +1122,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:1137: checking for working makeinfo" >&5
+echo "configure:1126: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1156,7 +1145,7 @@ fi
# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
set dummy ${ac_tool_prefix}ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1160: checking for $ac_word" >&5
+echo "configure:1149: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1188,7 +1177,7 @@ fi
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1192: checking for $ac_word" >&5
+echo "configure:1181: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1220,7 +1209,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1224: checking for $ac_word" >&5
+echo "configure:1213: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1326,7 +1315,7 @@ fi
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1330: checking for $ac_word" >&5
+echo "configure:1319: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1365,7 +1354,7 @@ ac_prog=ld
if test "$ac_cv_prog_gcc" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
-echo "configure:1369: checking for ld used by GCC" >&5
+echo "configure:1358: checking for ld used by GCC" >&5
ac_prog=`($CC -print-prog-name=ld) 2>&5`
case "$ac_prog" in
# Accept absolute paths.
@@ -1389,10 +1378,10 @@ echo "configure:1369: checking for ld used by GCC" >&5
esac
elif test "$with_gnu_ld" = yes; then
echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
-echo "configure:1393: checking for GNU ld" >&5
+echo "configure:1382: checking for GNU ld" >&5
else
echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
-echo "configure:1396: checking for non-GNU ld" >&5
+echo "configure:1385: checking for non-GNU ld" >&5
fi
if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1427,7 +1416,7 @@ else
fi
test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:1431: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:1420: checking if the linker ($LD) is GNU ld" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1443,7 +1432,7 @@ echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
-echo "configure:1447: checking for BSD-compatible nm" >&5
+echo "configure:1436: checking for BSD-compatible nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1479,7 +1468,7 @@ NM="$ac_cv_path_NM"
echo "$ac_t""$NM" 1>&6
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1483: checking whether ln -s works" >&5
+echo "configure:1472: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1528,8 +1517,8 @@ test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
case "$lt_target" in
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 1532 "configure"' > conftest.$ac_ext
- if { (eval echo configure:1533: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ echo '#line 1521 "configure"' > conftest.$ac_ext
+ if { (eval echo configure:1522: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
case "`/usr/bin/file conftest.o`" in
*32-bit*)
LD="${LD-ld} -32"
@@ -1550,19 +1539,19 @@ case "$lt_target" in
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -belf"
echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
-echo "configure:1554: checking whether the C compiler needs -belf" >&5
+echo "configure:1543: checking whether the C compiler needs -belf" >&5
if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1559 "configure"
+#line 1548 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:1566: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1555: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
lt_cv_cc_needs_belf=yes
else
@@ -1735,7 +1724,7 @@ test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:1739: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:1728: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -1758,12 +1747,12 @@ fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:1762: checking for Cygwin environment" >&5
+echo "configure:1751: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1767 "configure"
+#line 1756 "configure"
#include "confdefs.h"
int main() {
@@ -1774,7 +1763,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:1778: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1767: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -1791,19 +1780,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:1795: checking for mingw32 environment" >&5
+echo "configure:1784: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1800 "configure"
+#line 1789 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:1807: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1796: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -1822,7 +1811,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1826: checking for executable suffix" >&5
+echo "configure:1815: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1832,10 +1821,10 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1836: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1825: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
+ *.c | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
@@ -1858,7 +1847,7 @@ ac_exeext=$EXEEXT
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1862: checking for $ac_word" >&5
+echo "configure:1851: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1888,7 +1877,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1892: checking for $ac_word" >&5
+echo "configure:1881: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1939,7 +1928,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1943: checking for $ac_word" >&5
+echo "configure:1932: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1971,7 +1960,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1975: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1964: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1982,12 +1971,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1986 "configure"
+#line 1975 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1980: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -2013,12 +2002,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2017: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2006: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:2022: checking whether we are using GNU C" >&5
+echo "configure:2011: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2027,7 +2016,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2020: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -2046,7 +2035,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:2050: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:2039: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2080,7 +2069,7 @@ fi
ALL_LINGUAS=
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2084: checking how to run the C preprocessor" >&5
+echo "configure:2073: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@@ -2095,13 +2084,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 2099 "configure"
+#line 2088 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2105: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2094: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2112,13 +2101,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 2116 "configure"
+#line 2105 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2122: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2111: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2129,13 +2118,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 2133 "configure"
+#line 2122 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2139: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2128: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2160,12 +2149,12 @@ fi
echo "$ac_t""$CPP" 1>&6
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:2164: checking for ANSI C header files" >&5
+echo "configure:2153: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2169 "configure"
+#line 2158 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@@ -2173,7 +2162,7 @@ else
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2177: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2166: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2190,7 +2179,7 @@ rm -f conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2194 "configure"
+#line 2183 "configure"
#include "confdefs.h"
#include <string.h>
EOF
@@ -2208,7 +2197,7 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2212 "configure"
+#line 2201 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
@@ -2229,7 +2218,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
-#line 2233 "configure"
+#line 2222 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -2240,7 +2229,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }
EOF
-if { (eval echo configure:2244: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2233: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
@@ -2264,12 +2253,12 @@ EOF
fi
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:2268: checking for working const" >&5
+echo "configure:2257: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2273 "configure"
+#line 2262 "configure"
#include "confdefs.h"
int main() {
@@ -2318,7 +2307,7 @@ ccp = (char const *const *) p;
; return 0; }
EOF
-if { (eval echo configure:2322: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2311: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
@@ -2339,21 +2328,21 @@ EOF
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:2343: checking for inline" >&5
+echo "configure:2332: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 2350 "configure"
+#line 2339 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:2357: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2346: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
@@ -2379,12 +2368,12 @@ EOF
esac
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:2383: checking for off_t" >&5
+echo "configure:2372: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2388 "configure"
+#line 2377 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2412,12 +2401,12 @@ EOF
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:2416: checking for size_t" >&5
+echo "configure:2405: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2421 "configure"
+#line 2410 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2447,19 +2436,19 @@ fi
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:2451: checking for working alloca.h" >&5
+echo "configure:2440: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2456 "configure"
+#line 2445 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:2463: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2452: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
@@ -2480,12 +2469,12 @@ EOF
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:2484: checking for alloca" >&5
+echo "configure:2473: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2489 "configure"
+#line 2478 "configure"
#include "confdefs.h"
#ifdef __GNUC__
@@ -2513,7 +2502,7 @@ int main() {
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:2517: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2506: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
@@ -2545,12 +2534,12 @@ EOF
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:2549: checking whether alloca needs Cray hooks" >&5
+echo "configure:2538: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2554 "configure"
+#line 2543 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
@@ -2575,12 +2564,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2579: checking for $ac_func" >&5
+echo "configure:2568: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2584 "configure"
+#line 2573 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -2603,7 +2592,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:2607: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2596: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -2630,7 +2619,7 @@ done
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:2634: checking stack direction for C alloca" >&5
+echo "configure:2623: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2638,7 +2627,7 @@ else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 2642 "configure"
+#line 2631 "configure"
#include "confdefs.h"
find_stack_direction ()
{
@@ -2657,7 +2646,7 @@ main ()
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:2661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2650: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
@@ -2682,17 +2671,17 @@ for ac_hdr in unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2686: checking for $ac_hdr" >&5
+echo "configure:2675: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2691 "configure"
+#line 2680 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2696: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2685: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2721,12 +2710,12 @@ done
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2725: checking for $ac_func" >&5
+echo "configure:2714: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2730 "configure"
+#line 2719 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -2749,7 +2738,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:2753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2742: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -2774,7 +2763,7 @@ fi
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:2778: checking for working mmap" >&5
+echo "configure:2767: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2782,7 +2771,7 @@ else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 2786 "configure"
+#line 2775 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
@@ -2922,7 +2911,7 @@ main()
}
EOF
-if { (eval echo configure:2926: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2915: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
@@ -2950,17 +2939,17 @@ unistd.h values.h sys/param.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2954: checking for $ac_hdr" >&5
+echo "configure:2943: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2959 "configure"
+#line 2948 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2964: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2953: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2990,12 +2979,12 @@ done
__argz_count __argz_stringify __argz_next
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2994: checking for $ac_func" >&5
+echo "configure:2983: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2999 "configure"
+#line 2988 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3018,7 +3007,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3022: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3047,12 +3036,12 @@ done
for ac_func in stpcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3051: checking for $ac_func" >&5
+echo "configure:3040: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3056 "configure"
+#line 3045 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3075,7 +3064,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3079: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3068: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3109,19 +3098,19 @@ EOF
if test $ac_cv_header_locale_h = yes; then
echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:3113: checking for LC_MESSAGES" >&5
+echo "configure:3102: checking for LC_MESSAGES" >&5
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3118 "configure"
+#line 3107 "configure"
#include "confdefs.h"
#include <locale.h>
int main() {
return LC_MESSAGES
; return 0; }
EOF
-if { (eval echo configure:3125: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3114: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
am_cv_val_LC_MESSAGES=yes
else
@@ -3142,7 +3131,7 @@ EOF
fi
fi
echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:3146: checking whether NLS is requested" >&5
+echo "configure:3135: checking whether NLS is requested" >&5
# Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
enableval="$enable_nls"
@@ -3162,7 +3151,7 @@ fi
EOF
echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:3166: checking whether included gettext is requested" >&5
+echo "configure:3155: checking whether included gettext is requested" >&5
# Check whether --with-included-gettext or --without-included-gettext was given.
if test "${with_included_gettext+set}" = set; then
withval="$with_included_gettext"
@@ -3181,17 +3170,17 @@ fi
ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:3185: checking for libintl.h" >&5
+echo "configure:3174: checking for libintl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3190 "configure"
+#line 3179 "configure"
#include "confdefs.h"
#include <libintl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3195: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3184: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3208,19 +3197,19 @@ fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:3212: checking for gettext in libc" >&5
+echo "configure:3201: checking for gettext in libc" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3217 "configure"
+#line 3206 "configure"
#include "confdefs.h"
#include <libintl.h>
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3224: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3213: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libc=yes
else
@@ -3236,7 +3225,7 @@ echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
if test "$gt_cv_func_gettext_libc" != "yes"; then
echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:3240: checking for bindtextdomain in -lintl" >&5
+echo "configure:3229: checking for bindtextdomain in -lintl" >&5
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -3244,7 +3233,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3248 "configure"
+#line 3237 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -3255,7 +3244,7 @@ int main() {
bindtextdomain()
; return 0; }
EOF
-if { (eval echo configure:3259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3248: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -3271,19 +3260,19 @@ fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:3275: checking for gettext in libintl" >&5
+echo "configure:3264: checking for gettext in libintl" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3280 "configure"
+#line 3269 "configure"
#include "confdefs.h"
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3287: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3276: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libintl=yes
else
@@ -3311,7 +3300,7 @@ EOF
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3315: checking for $ac_word" >&5
+echo "configure:3304: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3345,12 +3334,12 @@ fi
for ac_func in dcgettext
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3349: checking for $ac_func" >&5
+echo "configure:3338: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3354 "configure"
+#line 3343 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3373,7 +3362,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3400,7 +3389,7 @@ done
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3404: checking for $ac_word" >&5
+echo "configure:3393: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3436,7 +3425,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3440: checking for $ac_word" >&5
+echo "configure:3429: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3468,7 +3457,7 @@ else
fi
cat > conftest.$ac_ext <<EOF
-#line 3472 "configure"
+#line 3461 "configure"
#include "confdefs.h"
int main() {
@@ -3476,7 +3465,7 @@ extern int _nl_msg_cat_cntr;
return _nl_msg_cat_cntr
; return 0; }
EOF
-if { (eval echo configure:3480: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3469: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
CATOBJEXT=.gmo
DATADIRNAME=share
@@ -3508,7 +3497,7 @@ fi
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3512: checking for $ac_word" >&5
+echo "configure:3501: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3542,7 +3531,7 @@ fi
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3546: checking for $ac_word" >&5
+echo "configure:3535: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3578,7 +3567,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3582: checking for $ac_word" >&5
+echo "configure:3571: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3668,7 +3657,7 @@ fi
LINGUAS=
else
echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:3672: checking for catalogs to be installed" >&5
+echo "configure:3661: checking for catalogs to be installed" >&5
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
@@ -3696,17 +3685,17 @@ echo "configure:3672: checking for catalogs to be installed" >&5
if test "$CATOBJEXT" = ".cat"; then
ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:3700: checking for linux/version.h" >&5
+echo "configure:3689: checking for linux/version.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3705 "configure"
+#line 3694 "configure"
#include "confdefs.h"
#include <linux/version.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3710: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3699: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3783,7 +3772,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:3787: checking for a BSD compatible install" >&5
+echo "configure:3776: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -3840,17 +3829,17 @@ for ac_hdr in string.h strings.h stdlib.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3844: checking for $ac_hdr" >&5
+echo "configure:3833: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3849 "configure"
+#line 3838 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3854: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3843: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3969,6 +3958,7 @@ if test x${all_targets} = xfalse ; then
bfd_pyramid_arch) ;;
bfd_romp_arch) ;;
bfd_rs6000_arch) ta="$ta ppc-dis.lo ppc-opc.lo" ;;
+ bfd_powerpc_64_arch) ta="$ta ppc-dis.lo ppc-opc.lo" ;;
bfd_sh_arch) ta="$ta sh-dis.lo" ;;
bfd_sparc_arch) ta="$ta sparc-dis.lo sparc-opc.lo" ;;
bfd_tahoe_arch) ;;
diff --git a/opcodes/configure.in b/opcodes/configure.in
index 847897b..039ef65 100644
--- a/opcodes/configure.in
+++ b/opcodes/configure.in
@@ -180,6 +180,7 @@ if test x${all_targets} = xfalse ; then
bfd_pyramid_arch) ;;
bfd_romp_arch) ;;
bfd_rs6000_arch) ta="$ta ppc-dis.lo ppc-opc.lo" ;;
+ bfd_powerpc_64_arch) ta="$ta ppc-dis.lo ppc-opc.lo" ;;
bfd_sh_arch) ta="$ta sh-dis.lo" ;;
bfd_sparc_arch) ta="$ta sparc-dis.lo sparc-opc.lo" ;;
bfd_tahoe_arch) ;;
diff --git a/opcodes/disassemble.c b/opcodes/disassemble.c
index 479e9e7..c4e2cad 100644
--- a/opcodes/disassemble.c
+++ b/opcodes/disassemble.c
@@ -216,7 +216,10 @@ disassembler (abfd)
#endif
#ifdef ARCH_rs6000
case bfd_arch_rs6000:
- disassemble = print_insn_rs6000;
+ if (bfd_get_mach (abfd) == 620)
+ disassemble = print_insn_big_powerpc;
+ else
+ disassemble = print_insn_rs6000;
break;
#endif
#ifdef ARCH_sh