aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorStan Shebs <shebs@codesourcery.com>1995-06-16 00:07:45 +0000
committerStan Shebs <shebs@codesourcery.com>1995-06-16 00:07:45 +0000
commitd21041b3e20375ba2139d2c21a5e4d44ecdf26f2 (patch)
tree9069fcd01de5cd061f563566843f087d679fe82d /gas
parente33c359dcbac4cc48ee4e9facde3bd02ae29905c (diff)
downloadgdb-d21041b3e20375ba2139d2c21a5e4d44ecdf26f2.zip
gdb-d21041b3e20375ba2139d2c21a5e4d44ecdf26f2.tar.gz
gdb-d21041b3e20375ba2139d2c21a5e4d44ecdf26f2.tar.bz2
* config/obj-coff.c: Don't use "bfd/" when including libbfd.h
and libcoff.h. (fill_section): Call PROGRESS. * Makefile.in (INCLUDES): Add bfd srcdir. * mpw-config.in: Add bfd_gas flag and set for each config. (i386-unknown-go32, m68k-unknown-coff): Recognize. * mpw-make.in (HACK_O_RAMA, OBJ_COFF_OMIT_TIMESTAMP): Add to config.h.
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog12
-rw-r--r--gas/config/obj-coff.c18
-rw-r--r--gas/mpw-config.in20
-rw-r--r--gas/mpw-make.in4
4 files changed, 45 insertions, 9 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index 3f48191..8a74c24 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,15 @@
+Thu Jun 15 16:53:37 1995 Stan Shebs <shebs@andros.cygnus.com>
+
+ * config/obj-coff.c: Don't use "bfd/" when including libbfd.h
+ and libcoff.h.
+ (fill_section): Call PROGRESS.
+ * Makefile.in (INCLUDES): Add bfd srcdir.
+
+ * mpw-config.in: Add bfd_gas flag and set for each config.
+ (i386-unknown-go32, m68k-unknown-coff): Recognize.
+ * mpw-make.in (HACK_O_RAMA, OBJ_COFF_OMIT_TIMESTAMP): Add to
+ config.h.
+
Thu Jun 15 10:04:26 1995 Doug Evans <dje@canuck.cygnus.com>
* config/tc-arm.h (LOCAL_LABEL): Prepend '.' if not OBJ_AOUT.
diff --git a/gas/config/obj-coff.c b/gas/config/obj-coff.c
index 1c9f9cd..82b5e96 100644
--- a/gas/config/obj-coff.c
+++ b/gas/config/obj-coff.c
@@ -1306,8 +1306,9 @@ symbol_dump ()
#include "frags.h"
/* This is needed because we include internal bfd things. */
#include <time.h>
-#include "bfd/libbfd.h"
-#include "bfd/libcoff.h"
+
+#include "libbfd.h"
+#include "libcoff.h"
/* The NOP_OPCODE is for the alignment fill value. Fill with nop so
that we can stick sections together without causing trouble. */
@@ -1681,9 +1682,10 @@ fill_section (abfd, h, file_cursor)
for (i = SEG_E0; i < SEG_UNKNOWN; i++)
{
unsigned int offset = 0;
-
struct internal_scnhdr *s = &(segment_info[i].scnhdr);
+ PROGRESS (1);
+
if (s->s_name[0])
{
fragS *frag = segment_info[i].frchainP->frch_root;
@@ -2949,13 +2951,11 @@ write_object_file ()
H_SET_STRING_SIZE (&headers, string_byte_count);
-#if !defined(TC_H8300) && !defined(TC_Z8K)
for (i = SEG_E0; i < SEG_UNKNOWN; i++)
{
fixup_mdeps (segment_info[i].frchainP->frch_root, &headers, i);
fixup_segment (&segment_info[i], i);
}
-#endif
/* Look for ".stab" segments and fill in their initial symbols
correctly. */
@@ -3489,6 +3489,9 @@ fixup_segment (segP, this_segment_type)
register fragS *fragP;
register segT add_symbol_segment = absolute_section;
+ if (linkrelax)
+ return;
+
for (fixP = segP->fix_root; fixP; fixP = fixP->fx_next)
{
fragP = fixP->fx_frag;
@@ -3644,7 +3647,8 @@ fixup_segment (segP, this_segment_type)
break;
default:
-#ifdef TC_A29K
+
+#if defined(TC_A29K) || (defined(TE_PE) && defined(TC_I386))
/* This really should be handled in the linker, but
backward compatibility forbids. */
add_number += S_GET_VALUE (add_symbolP);
@@ -3687,7 +3691,7 @@ fixup_segment (segP, this_segment_type)
if (pcrel)
{
-#ifndef TC_M88K
+#if !defined(TC_M88K) && !(defined(TE_PE) && defined(TC_I386))
/* This adjustment is not correct on the m88k, for which the
linker does all the computation. */
add_number -= md_pcrel_from (fixP);
diff --git a/gas/mpw-config.in b/gas/mpw-config.in
index 4005dc3..320daac 100644
--- a/gas/mpw-config.in
+++ b/gas/mpw-config.in
@@ -6,16 +6,27 @@ Set target_arch `echo {target_canonical} | sed -e 's/-.*-.*//'`
Set obj_format `echo {target_canonical} | sed -e 's/.*-.*-//'`
+Set bfd_gas no
+
Set TDEFINES ""
If "{target_canonical}" =~ /m68k-apple-macos/
Set obj_format "coff"
+ Set TDEFINES '-d M68KCOFF'
Else If "{target_canonical}" =~ /ppc-apple-macos/
Set obj_format "xcoff"
-Else If "{target_canonical}" =~ /sh-hitachi-hms/
+ Set bfd_gas yes
+Else If "{target_canonical}" =~ /i386-unknown-go32/
Set obj_format "coff"
+ Set TDEFINES '-d I386COFF'
+Else If "{target_canonical}" =~ /m68k-unknown-coff/
+ Set TDEFINES '-d M68KCOFF'
Else If "{target_canonical}" =~ /mips-idt-ecoff/
+ Set bfd_gas yes
Set TDEFINES '-d TARGET_BYTES_BIG_ENDIAN'
+Else If "{target_canonical}" =~ /sh-hitachi-hms/
+ Set obj_format "coff"
+ forward-include "{srcroot}"opcodes:sh-opc.h 'opcodes/sh-opc.h'
End If
forward-include "{srcdir}"config:tc-{target_arch}.c targ-cpu.c
@@ -44,6 +55,13 @@ End If
Echo '# From mpw-config.in' > "{o}"mk.tmp
Echo 'VERSION = ' `Search 'VERSION=' "{srcdir}"Makefile.in | sed -e 's/.*VERSION=\(.*\)/\1/'` >> "{o}"mk.tmp
+
+If "{bfd_gas}" =~ /yes/
+ Echo "HACK_O_RAMA = BFD_ASSEMBLER" >> "{o}"mk.tmp
+Else
+ Echo "HACK_O_RAMA = MANY_SEGMENTS" >> "{o}"mk.tmp
+End If
+
Echo "TDEFINES = " {TDEFINES} >> "{o}"mk.tmp
Echo '# End from mpw-config.in' >> "{o}"mk.tmp
diff --git a/gas/mpw-make.in b/gas/mpw-make.in
index 7dc5789..f7e9760 100644
--- a/gas/mpw-make.in
+++ b/gas/mpw-make.in
@@ -103,11 +103,13 @@ as.new \Option-f\Option-f {OBJECTS} {TARG_OBJECTS} {CLIBS} "{o}"Version.r
Echo '#define WANT_FOPEN_BIN' >> "{o}"config.new
Echo '#define HAVE_ERRNO_H' >> "{o}"config.new
Echo '#define HAVE_STDARG_H' >> "{o}"config.new
- Echo '#define BFD_ASSEMBLER' >> "{o}"config.new
+ Echo '#define ' {HACK_O_RAMA} >> "{o}"config.new
+ Echo '#define OBJ_COFF_OMIT_TIMESTAMP' >> "{o}"config.new
Echo '#endif /* GAS_VERSION */' >> "{o}"config.new
MoveIfChange "{o}"config.new "{o}"config.h
Echo ' ' >"{o}"config-stamp
+
"{o}"Version.r \Option-f "{o}"version-stamp
"{o}"version-stamp \Option-f Makefile