-diff -urNbB binutils-2.16.91.0.2.org/gas/Makefile.am binutils-2.16.91.0.2/gas/Makefile.am
---- binutils-2.16.91.0.2.org/gas/Makefile.am 2005-07-20 19:27:27.000000000 +0000
-+++ binutils-2.16.91.0.2/gas/Makefile.am 2005-07-21 18:35:02.000000000 +0000
-@@ -204,7 +204,7 @@
+--- binutils-2.17.50.0.3/gas/Makefile.am.orig 2006-07-15 20:23:50.000000000 +0200
++++ binutils-2.17.50.0.3/gas/Makefile.am 2006-07-17 10:44:29.524440000 +0200
+@@ -192,7 +192,7 @@
symbols.c \
write.c
HFILES = \
as.h \
-@@ -466,7 +466,8 @@
+@@ -441,7 +441,8 @@
# Note: GASP is now deprecated and has been removed. It is still
# available in the CVS archive or older binutils releases if it is needed.
noinst_SCRIPTS = $(GDBINIT)
EXTRA_SCRIPTS = .gdbinit
-@@ -530,6 +531,10 @@
+@@ -498,6 +499,10 @@
as.h asintl.h bignum.h bit_fix.h config.h emul.h expr.h flonum.h \
frags.h hash.h listing.h obj.h read.h symbols.h tc.h write.h
EXPECT = expect
RUNTEST = runtest
RUNTESTFLAGS=
-@@ -2508,6 +2513,8 @@
- $(INCDIR)/obstack.h subsegs.h struc-symbol.h
- write.o: write.c $(INCDIR)/symcat.h subsegs.h $(INCDIR)/obstack.h \
- output-file.h dwarf2dbg.h
+@@ -2048,6 +2053,8 @@
+ subsegs.h struc-symbol.h
+ write.o: write.c subsegs.h $(INCDIR)/obstack.h output-file.h \
+ dwarf2dbg.h
+gasp.o: gasp.c $(INCDIR)/getopt.h $(INCDIR)/safe-ctype.h \
+ sb.h macro.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h
- itbl-ops.o: itbl-ops.c itbl-ops.h $(INCDIR)/symcat.h
- e-crisaout.o: $(srcdir)/config/e-crisaout.c $(INCDIR)/symcat.h \
- emul-target.h
+ itbl-ops.o: itbl-ops.c itbl-ops.h
+ e-crisaout.o: $(srcdir)/config/e-crisaout.c emul-target.h
+ e-criself.o: $(srcdir)/config/e-criself.c emul-target.h
diff -urNbB binutils-2.16.91.0.2.org/gas/doc/Makefile.am binutils-2.16.91.0.2/gas/doc/Makefile.am
--- binutils-2.16.91.0.2.org/gas/doc/Makefile.am 2005-07-20 19:27:27.000000000 +0000
+++ binutils-2.16.91.0.2/gas/doc/Makefile.am 2005-07-21 18:31:04.000000000 +0000
+ (tc_gen_reloc): Put back pc rel handling.
+ * config/tc-mips.h: Defines DIFF_EXPR_OK.
+
---- gas/config/tc-mips.c.orig 2005-12-20 23:43:56.000000000 +0100
-+++ gas/config/tc-mips.c 2005-12-21 22:47:56.000000000 +0100
-@@ -11401,8 +11401,6 @@
+--- gas/config/tc-mips.c.orig 2006-07-15 20:23:51.000000000 +0200
++++ gas/config/tc-mips.c 2006-07-17 10:51:06.164440000 +0200
+@@ -11736,8 +11736,6 @@
buf = (bfd_byte *) (fixP->fx_frag->fr_literal + fixP->fx_where);
-- assert (! fixP->fx_pcrel || fixP->fx_r_type == BFD_RELOC_16_PCREL_S2);
+- assert (!fixP->fx_pcrel || fixP->fx_r_type == BFD_RELOC_16_PCREL_S2);
-
/* Don't treat parts of a composite relocation as done. There are two
reasons for this:
-@@ -13247,8 +13245,6 @@
+@@ -13562,8 +13560,6 @@
if (fixp->fx_pcrel)
{
/* At this point, fx_addnumber is "symbol offset - pcrel address".
Relocations want only the symbol offset. */
reloc->addend = fixp->fx_addnumber + reloc->address;
-@@ -13273,6 +13269,34 @@
+@@ -13588,6 +13584,34 @@
}
code = fixp->fx_r_type;
/* Symbol version definitions in external objects. */
Elf_Internal_Verdef *verdef;
---- binutils-2.16.91.0.7/bfd/elf.c.orig 2006-03-18 02:13:54.000000000 +0100
-+++ binutils-2.16.91.0.7/bfd/elf.c 2006-03-21 20:15:01.658432000 +0100
-@@ -1085,6 +1085,7 @@
+--- binutils-2.17.50.0.3/bfd/elf.c.orig 2006-07-15 20:23:49.000000000 +0200
++++ binutils-2.17.50.0.3/bfd/elf.c 2006-07-17 10:47:54.374440000 +0200
+@@ -1101,6 +1101,7 @@
case PT_GNU_EH_FRAME: pt = "EH_FRAME"; break;
case PT_GNU_STACK: pt = "STACK"; break;
case PT_GNU_RELRO: pt = "RELRO"; break;
default: pt = NULL; break;
}
return pt;
-@@ -2606,6 +2607,9 @@
+@@ -2662,6 +2663,9 @@
case PT_GNU_RELRO:
return _bfd_elf_make_section_from_phdr (abfd, hdr, index, "relro");
default:
/* Check for any processor-specific program segment types. */
bed = get_elf_backend_data (abfd);
-@@ -3933,6 +3937,20 @@
- pm = &m->next;
- }
-
-+ {
-+ amt = sizeof (struct elf_segment_map);
-+ m = bfd_zalloc (abfd, amt);
-+ if (m == NULL)
-+ goto error_return;
-+ m->next = NULL;
-+ m->p_type = PT_PAX_FLAGS;
-+ m->p_flags = elf_tdata (abfd)->pax_flags;
-+ m->p_flags_valid = 1;
-+
-+ *pm = m;
-+ pm = &m->next;
-+ }
-+
- free (sections);
- sections = NULL;
-
-@@ -4665,6 +4683,11 @@
+@@ -3633,6 +3637,11 @@
++segs;
}
for (s = abfd->sections; s != NULL; s = s->next)
{
if ((s->flags & SEC_LOAD) != 0
-@@ -5181,7 +5204,8 @@
+@@ -4116,6 +4125,20 @@
+ pm = &m->next;
+ }
+
++ {
++ amt = sizeof (struct elf_segment_map);
++ m = bfd_zalloc (abfd, amt);
++ if (m == NULL)
++ goto error_return;
++ m->next = NULL;
++ m->p_type = PT_PAX_FLAGS;
++ m->p_flags = elf_tdata (abfd)->pax_flags;
++ m->p_flags_valid = 1;
++
++ *pm = m;
++ pm = &m->next;
++ }
++
+ free (sections);
+ elf_tdata (abfd)->segment_map = mfirst;
+ }
+@@ -5228,7 +5251,8 @@
5. PT_GNU_STACK segments do not include any sections.
6. PT_TLS segment includes only SHF_TLS sections.
7. SHF_TLS sections are only in PT_TLS or PT_LOAD segments.
(with the possible exception of .dynamic). */
#define INCLUDE_SECTION_IN_SEGMENT(section, segment, bed) \
((((segment->p_paddr \
-@@ -5191,6 +5215,7 @@
+@@ -5238,6 +5262,7 @@
|| IS_COREFILE_NOTE (segment, section)) \
&& section->output_section != NULL \
&& segment->p_type != PT_GNU_STACK \