aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorJohn Gilmore <gnu@cygnus>1991-11-22 23:02:29 +0000
committerJohn Gilmore <gnu@cygnus>1991-11-22 23:02:29 +0000
commit853f0a703050ce2022ae9946d168d13289929ccb (patch)
tree24d614620a0cb95ec76f587aae196d388e47ef7f /bfd
parent2dd074f42164525862ce3f9dd831e1f5e4982f7f (diff)
downloadgdb-853f0a703050ce2022ae9946d168d13289929ccb.zip
gdb-853f0a703050ce2022ae9946d168d13289929ccb.tar.gz
gdb-853f0a703050ce2022ae9946d168d13289929ccb.tar.bz2
* coff-mips.c, coffcode.h: Peter Schauer's patch to kludge in
nonstandard MIPS sections (.rdata, .sdata, etc).
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog3
-rw-r--r--bfd/coff-mips.c8
-rw-r--r--bfd/coffcode.h4
3 files changed, 13 insertions, 2 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 797d75d8..397597b 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,5 +1,8 @@
Fri Nov 22 08:11:42 1991 John Gilmore (gnu at cygnus.com)
+ * coff-mips.c, coffcode.h: Peter Schauer's patch to kludge in
+ nonstandard MIPS sections (.rdata, .sdata, etc).
+
* aoutx.h, bfd.c, coffcode.h, ieee.c, oasys.c, targets.c: CONST lint.
* libbfd-in.h, libbfd.h, aoutx.h, coffcode.h, elf.c, libaout.h:
Rename ALIGN to BFD_ALIGN to avoid conflict with BSD <sys/param.h>.
diff --git a/bfd/coff-mips.c b/bfd/coff-mips.c
index 6db7df8..342cadf 100644
--- a/bfd/coff-mips.c
+++ b/bfd/coff-mips.c
@@ -21,7 +21,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
#include "bfd.h"
#include "sysdep.h"
#include "libbfd.h"
-#include "ecoff.h"
+#include "coff-mips.h"
#include "internalcoff.h"
#include "libcoff.h" /* to allow easier abstraction-breaking */
#include "trad-core.h"
@@ -34,6 +34,8 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
#define NO_COFF_LINENOS
/* Define MIPS to get MIPS magic numbers and such */
#define MIPS 1
+/* Define additional MIPS section types */
+#define STYP_OTHER_LOAD 0x98000300
#include "coffcode.h"
/* We do not implement symbols for ecoff. */
@@ -43,12 +45,14 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
(PROTO(void,(*),(bfd *, PTR, asymbol *, enum bfd_print_symbol))) bfd_void
#define coff_swap_sym_in (PROTO(void,(*),(bfd *,PTR,PTR))) bfd_void
#define coff_swap_aux_in (PROTO(void,(*),(bfd *,PTR,int,int,PTR))) bfd_void
+#define coff_swap_sym_out (PROTO(unsigned,(*),(bfd *,PTR,PTR))) bfd_void
+#define coff_swap_aux_out (PROTO(unsigned,(*),(bfd *,PTR,int,int,PTR))) bfd_void
/* We do not implement linenos for ecoff. */
#define coff_get_lineno (struct lineno_cache_entry *(*)()) bfd_nullvoidptr
#define coff_swap_lineno_in (PROTO(void,(*),(bfd *,PTR,PTR))) bfd_void
#define coff_find_nearest_line (PROTO(boolean, (*),(bfd*,asection*,asymbol**,bfd_vma, CONST char**, CONST char**, unsigned int *))) bfd_false
-
+#define coff_swap_lineno_out (PROTO(unsigned,(*),(bfd *,PTR,PTR))) bfd_void
bfd_target ecoff_little_vec =
{"ecoff-littlemips", /* name */
bfd_target_coff_flavour,
diff --git a/bfd/coffcode.h b/bfd/coffcode.h
index 0410c00..636ac61 100644
--- a/bfd/coffcode.h
+++ b/bfd/coffcode.h
@@ -369,6 +369,10 @@ DEFUN(styp_to_sec_flags, (styp_flags),
if ((styp_flags & STYP_LIT) == STYP_LIT)
sec_flags = (SEC_LOAD | SEC_ALLOC | SEC_READONLY);
#endif /* STYP_LIT */
+#ifdef STYP_OTHER_LOAD /* Other loaded sections */
+ if (styp_flags & STYP_OTHER_LOAD)
+ sec_flags = (SEC_LOAD | SEC_ALLOC);
+#endif /* STYP_SDATA */
return(sec_flags);
}