-diff -uNdr binutils-2.21-orig.0/bfd/Makefile.am binutils-2.21/bfd/Makefile.am
---- binutils-2.21-orig.0/bfd/Makefile.am 2010-12-08 09:37:33.000000000 +0100
-+++ binutils-2.21/bfd/Makefile.am 2011-06-17 18:17:52.000000000 +0200
-@@ -232,6 +232,8 @@
+diff -ruwN bfd/Makefile.am bfd/Makefile.am
+--- bfd/Makefile.am 2009-10-16 17:17:44.000000000 +0530
++++ bfd/Makefile.am 2010-03-11 12:13:23.069283600 +0530
+@@ -228,6 +228,8 @@
coff-apollo.lo \
coff-arm.lo \
coff-aux.lo \
coff-go32.lo \
coff-h8300.lo \
coff-h8500.lo \
-@@ -413,6 +415,8 @@
+@@ -411,6 +413,8 @@
coff-apollo.c \
coff-arm.c \
coff-aux.c \
coff-go32.c \
coff-h8300.c \
coff-h8500.c \
-diff -uNdr binutils-2.21-orig.0/bfd/Makefile.in binutils-2.21/bfd/Makefile.in
---- binutils-2.21-orig.0/bfd/Makefile.in 2010-12-08 09:37:36.000000000 +0100
-+++ binutils-2.21/bfd/Makefile.in 2011-06-17 18:17:52.000000000 +0200
-@@ -532,6 +532,8 @@
+diff -ruwN bfd/Makefile.in bfd/Makefile.in
+--- bfd/Makefile.in 2009-10-16 17:17:48.000000000 +0530
++++ bfd/Makefile.in 2010-03-11 12:13:23.084906900 +0530
+@@ -524,6 +524,8 @@
coff-apollo.lo \
coff-arm.lo \
coff-aux.lo \
coff-go32.lo \
coff-h8300.lo \
coff-h8500.lo \
-@@ -713,6 +715,8 @@
+@@ -707,6 +709,8 @@
coff-apollo.c \
coff-arm.c \
coff-aux.c \
coff-go32.c \
coff-h8300.c \
coff-h8500.c \
-diff -uNdr binutils-2.21-orig.0/bfd/coff-avr.c binutils-2.21/bfd/coff-avr.c
---- binutils-2.21-orig.0/bfd/coff-avr.c 1970-01-01 01:00:00.000000000 +0100
-+++ binutils-2.21/bfd/coff-avr.c 2011-06-17 18:17:52.000000000 +0200
+diff -ruwN bfd/coff-avr.c bfd/coff-avr.c
+--- bfd/coff-avr.c 1970-01-01 05:30:00.000000000 +0530
++++ bfd/coff-avr.c 2010-03-11 12:13:23.100530200 +0530
@@ -0,0 +1,613 @@
+/* BFD back-end for Atmel AVR COFF files.
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1999, 2000, 2001, 2003
+
+ COFF_SWAP_TABLE
+};
-diff -uNdr binutils-2.21-orig.0/bfd/coff-ext-avr.c binutils-2.21/bfd/coff-ext-avr.c
---- binutils-2.21-orig.0/bfd/coff-ext-avr.c 1970-01-01 01:00:00.000000000 +0100
-+++ binutils-2.21/bfd/coff-ext-avr.c 2011-06-17 18:17:52.000000000 +0200
+diff -ruwN bfd/coff-ext-avr.c bfd/coff-ext-avr.c
+--- bfd/coff-ext-avr.c 1970-01-01 05:30:00.000000000 +0530
++++ bfd/coff-ext-avr.c 2010-03-11 12:13:23.131776800 +0530
@@ -0,0 +1,428 @@
+/* BFD back-end for Atmel AVR "extended" COFF files.
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1999, 2000, 2001, 2003
+
+ COFF_SWAP_TABLE
+};
-diff -uNdr binutils-2.21-orig.0/bfd/coffcode.h binutils-2.21/bfd/coffcode.h
---- binutils-2.21-orig.0/bfd/coffcode.h 2010-11-04 17:03:22.000000000 +0100
-+++ binutils-2.21/bfd/coffcode.h 2011-06-17 18:17:52.000000000 +0200
+diff -ruwN bfd/coffcode.h bfd/coffcode.h
+--- bfd/coffcode.h 2009-09-10 17:17:12.000000000 +0530
++++ bfd/coffcode.h 2010-03-11 12:13:23.147400100 +0530
@@ -1,3 +1,4 @@
+
/* Support for the generic parts of most COFF variants, for BFD.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
-@@ -1934,6 +1935,17 @@
+ 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
+@@ -1910,6 +1911,17 @@
coff->relocbase = 0;
coff->local_toc_sym_map = 0;
/* make_abs_section(abfd);*/
return TRUE;
-@@ -1958,17 +1970,6 @@
+@@ -1934,17 +1946,6 @@
coff->sym_filepos = internal_f->f_symptr;
coff->timestamp = internal_f->f_timdat;
obj_raw_syment_count (abfd) =
-@@ -2100,6 +2101,11 @@
+@@ -2076,6 +2077,11 @@
}
break;
#endif
#ifdef MC68MAGIC
case MC68MAGIC:
case M68MAGIC:
-@@ -2879,6 +2885,13 @@
+@@ -2871,6 +2877,13 @@
return TRUE;
#endif
#ifdef PPCMAGIC
case bfd_arch_powerpc:
*magicp = PPCMAGIC;
-@@ -3705,6 +3718,11 @@
+@@ -3698,6 +3711,11 @@
section.s_page = 0;
#endif
#ifdef COFF_WITH_PE
section.s_paddr = 0;
#endif
-@@ -4051,6 +4069,17 @@
+@@ -4042,6 +4060,17 @@
internal_a.magic = ZMAGIC;
#endif
#if defined(PPC_PE)
#define __A_MAGIC_SET__
internal_a.magic = IMAGE_NT_OPTIONAL_HDR_MAGIC;
-@@ -4113,8 +4142,16 @@
+@@ -4109,8 +4138,16 @@
#endif
}
/* Now should write relocs, strings, syms. */
obj_sym_filepos (abfd) = sym_base;
-@@ -4672,6 +4709,10 @@
+@@ -4668,6 +4705,10 @@
/* In PE, 0x69 (105) denotes a weak external symbol. */
case C_NT_WEAK:
#endif
switch (coff_classify_symbol (abfd, &src->u.syment))
{
case COFF_SYMBOL_GLOBAL:
-@@ -4895,7 +4936,9 @@
+@@ -4891,7 +4932,9 @@
&& src->u.syment.n_scnum == 0)
break;
/* Fall through. */
case C_ULABEL: /* Undefined label. */
case C_USTATIC: /* Undefined static. */
#ifndef COFF_WITH_PE
-diff -uNdr binutils-2.21-orig.0/bfd/coffgen.c binutils-2.21/bfd/coffgen.c
---- binutils-2.21-orig.0/bfd/coffgen.c 2010-04-27 16:42:50.000000000 +0200
-+++ binutils-2.21/bfd/coffgen.c 2011-06-17 18:17:52.000000000 +0200
+diff -ruwN bfd/coffgen.c bfd/coffgen.c
+--- bfd/coffgen.c 2009-09-10 17:17:12.000000000 +0530
++++ bfd/coffgen.c 2010-03-11 12:13:23.163023400 +0530
@@ -699,6 +699,20 @@
if (last_file != NULL)
last_file->n_value = native_index;
new_symbol->native = (combined_entry_type *) bfd_zalloc (abfd, amt);
if (!new_symbol->native)
return NULL;
-diff -uNdr binutils-2.21-orig.0/bfd/coffswap.h binutils-2.21/bfd/coffswap.h
---- binutils-2.21-orig.0/bfd/coffswap.h 2009-09-05 09:56:22.000000000 +0200
-+++ binutils-2.21/bfd/coffswap.h 2011-06-17 18:17:52.000000000 +0200
+diff -ruwN bfd/coffswap.h bfd/coffswap.h
+--- bfd/coffswap.h 2009-09-07 13:45:15.000000000 +0530
++++ bfd/coffswap.h 2010-03-11 12:13:23.178646700 +0530
@@ -383,7 +383,11 @@
void * ext1,
int type,
}
else
memcpy (in->x_file.x_fname, ext->x_file.x_fname, FILNMLEN);
-diff -uNdr binutils-2.21-orig.0/bfd/config.bfd binutils-2.21/bfd/config.bfd
---- binutils-2.21-orig.0/bfd/config.bfd 2010-12-01 12:03:10.000000000 +0100
-+++ binutils-2.21/bfd/config.bfd 2011-06-17 18:17:52.000000000 +0200
-@@ -338,6 +338,7 @@
+diff -ruwN bfd/config.bfd bfd/config.bfd
+--- bfd/config.bfd 2009-08-06 23:08:00.000000000 +0530
++++ bfd/config.bfd 2010-03-11 12:13:23.178646700 +0530
+@@ -339,6 +339,7 @@
avr-*-*)
targ_defvec=bfd_elf32_avr_vec
;;
bfin-*-*)
-diff -uNdr binutils-2.21-orig.0/bfd/configure binutils-2.21/bfd/configure
---- binutils-2.21-orig.0/bfd/configure 2010-12-08 09:37:34.000000000 +0100
-+++ binutils-2.21/bfd/configure 2011-06-17 18:17:52.000000000 +0200
-@@ -15035,6 +15035,8 @@
+diff -ruwN bfd/configure bfd/configure
+--- bfd/configure 2009-10-16 17:17:47.000000000 +0530
++++ bfd/configure 2010-03-11 12:13:23.209893300 +0530
+@@ -14782,6 +14782,8 @@
armpe_little_vec) tb="$tb pe-arm.lo peigen.lo cofflink.lo " ;;
armpei_big_vec) tb="$tb pei-arm.lo peigen.lo cofflink.lo " ;;
armpei_little_vec) tb="$tb pei-arm.lo peigen.lo cofflink.lo " ;;
b_out_vec_big_host) tb="$tb bout.lo aout32.lo" ;;
b_out_vec_little_host) tb="$tb bout.lo aout32.lo" ;;
bfd_pei_ia64_vec) tb="$tb pei-ia64.lo pepigen.lo cofflink.lo"; target_size=64 ;;
-diff -uNdr binutils-2.21-orig.0/bfd/configure.in binutils-2.21/bfd/configure.in
---- binutils-2.21-orig.0/bfd/configure.in 2010-12-08 09:37:33.000000000 +0100
-+++ binutils-2.21/bfd/configure.in 2011-06-17 18:17:52.000000000 +0200
+diff -ruwN bfd/configure.in bfd/configure.in
+--- bfd/configure.in 2009-10-16 17:17:44.000000000 +0530
++++ bfd/configure.in 2010-03-11 12:13:23.209893300 +0530
@@ -670,6 +670,8 @@
armpe_little_vec) tb="$tb pe-arm.lo peigen.lo cofflink.lo " ;;
armpei_big_vec) tb="$tb pei-arm.lo peigen.lo cofflink.lo " ;;
b_out_vec_big_host) tb="$tb bout.lo aout32.lo" ;;
b_out_vec_little_host) tb="$tb bout.lo aout32.lo" ;;
bfd_pei_ia64_vec) tb="$tb pei-ia64.lo pepigen.lo cofflink.lo"; target_size=64 ;;
-diff -uNdr binutils-2.21-orig.0/bfd/targets.c binutils-2.21/bfd/targets.c
---- binutils-2.21-orig.0/bfd/targets.c 2010-10-22 14:08:28.000000000 +0200
-+++ binutils-2.21/bfd/targets.c 2011-06-17 18:17:52.000000000 +0200
-@@ -575,6 +575,8 @@
+diff -ruwN bfd/targets.c bfd/targets.c
+--- bfd/targets.c 2009-09-10 17:17:13.000000000 +0530
++++ bfd/targets.c 2010-03-11 12:13:23.225516600 +0530
+@@ -564,6 +564,8 @@
extern const bfd_target armpe_little_vec;
extern const bfd_target armpei_big_vec;
extern const bfd_target armpei_little_vec;
extern const bfd_target b_out_vec_big_host;
extern const bfd_target b_out_vec_little_host;
extern const bfd_target bfd_pei_ia64_vec;
-@@ -911,6 +913,8 @@
+@@ -890,6 +892,8 @@
&armpe_little_vec,
&armpei_big_vec,
&armpei_little_vec,
&b_out_vec_big_host,
&b_out_vec_little_host,
#ifdef BFD64
-diff -uNdr binutils-2.21-orig.0/binutils/Makefile.am binutils-2.21/binutils/Makefile.am
---- binutils-2.21-orig.0/binutils/Makefile.am 2010-11-05 14:23:02.000000000 +0100
-+++ binutils-2.21/binutils/Makefile.am 2011-06-17 18:20:09.000000000 +0200
-@@ -103,7 +103,7 @@
+diff -ruwN binutils/Makefile.am binutils/Makefile.am
+--- binutils/Makefile.am 2009-09-09 13:43:23.000000000 +0530
++++ binutils/Makefile.am 2010-03-11 12:13:23.241139900 +0530
+@@ -101,7 +101,7 @@
resbin.c rescoff.c resrc.c resres.c \
size.c srconv.c stabs.c strings.c sysdump.c \
- unwind-ia64.c elfedit.c version.c \
+ unwind-ia64.c version.c \
- windres.c winduni.c wrstabs.c \
+ windres.c winduni.c wrcoff.c wrstabs.c \
windmc.c mclex.c
GENERATED_CFILES = \
-@@ -111,7 +111,7 @@
+@@ -109,7 +109,7 @@
defparse.c deflex.c nlmheader.c rcparse.c mcparse.c
DEBUG_SRCS = rddbg.c debug.c stabs.c ieee.c rdcoff.c
# Code shared by all the binutils.
BULIBS = bucomm.c version.c filemode.c
-diff -uNdr binutils-2.21-orig.0/binutils/Makefile.in binutils-2.21/binutils/Makefile.in
---- binutils-2.21-orig.0/binutils/Makefile.in 2010-11-05 14:23:02.000000000 +0100
-+++ binutils-2.21/binutils/Makefile.in 2011-06-17 18:20:34.000000000 +0200
-@@ -131,7 +131,7 @@
+diff -ruwN binutils/Makefile.in binutils/Makefile.in
+--- binutils/Makefile.in 2009-09-09 13:43:23.000000000 +0530
++++ binutils/Makefile.in 2010-03-11 12:13:23.241139900 +0530
+@@ -126,7 +126,7 @@
nm_new_OBJECTS = $(am_nm_new_OBJECTS)
nm_new_LDADD = $(LDADD)
am__objects_2 = rddbg.$(OBJEXT) debug.$(OBJEXT) stabs.$(OBJEXT) \
am__objects_3 = $(am__objects_2) wrstabs.$(OBJEXT)
am_objcopy_OBJECTS = objcopy.$(OBJEXT) not-strip.$(OBJEXT) \
rename.$(OBJEXT) $(am__objects_3) $(am__objects_1)
-@@ -444,7 +444,7 @@
+@@ -439,7 +439,7 @@
resbin.c rescoff.c resrc.c resres.c \
size.c srconv.c stabs.c strings.c sysdump.c \
- unwind-ia64.c elfedit.c version.c \
+ unwind-ia64.c version.c \
- windres.c winduni.c wrstabs.c \
+ windres.c winduni.c wrcoff.c wrstabs.c \
windmc.c mclex.c
GENERATED_CFILES = \
-@@ -452,7 +452,7 @@
+@@ -447,7 +447,7 @@
defparse.c deflex.c nlmheader.c rcparse.c mcparse.c
DEBUG_SRCS = rddbg.c debug.c stabs.c ieee.c rdcoff.c
# Code shared by all the binutils.
BULIBS = bucomm.c version.c filemode.c
-diff -uNdr binutils-2.21-orig.0/binutils/bucomm.c binutils-2.21/binutils/bucomm.c
---- binutils-2.21-orig.0/binutils/bucomm.c 2010-10-06 00:48:34.000000000 +0200
-+++ binutils-2.21/binutils/bucomm.c 2011-06-17 18:17:52.000000000 +0200
-@@ -558,6 +558,32 @@
+diff -ruwN binutils/bucomm.c binutils/bucomm.c
+--- binutils/bucomm.c 2009-09-14 17:13:26.000000000 +0530
++++ binutils/bucomm.c 2010-03-11 12:13:23.256763200 +0530
+@@ -550,6 +550,32 @@
return ret;
}
+
/* Returns the size of the named file. If the file does not
exist, or if it is not a real file, then a suitable non-fatal
- error message is printed and (off_t) -1 is returned. */
-diff -uNdr binutils-2.21-orig.0/binutils/bucomm.h binutils-2.21/binutils/bucomm.h
---- binutils-2.21-orig.0/binutils/bucomm.h 2009-09-02 09:22:31.000000000 +0200
-+++ binutils-2.21/binutils/bucomm.h 2011-06-17 18:17:52.000000000 +0200
+ error message is printed and zero is returned. */
+diff -ruwN binutils/bucomm.h binutils/bucomm.h
+--- binutils/bucomm.h 2009-09-02 12:52:31.000000000 +0530
++++ binutils/bucomm.h 2010-03-11 12:13:23.272386500 +0530
@@ -58,6 +58,8 @@
off_t get_file_size (const char *);
extern char *program_name;
/* filemode.c */
-diff -uNdr binutils-2.21-orig.0/binutils/budbg.h binutils-2.21/binutils/budbg.h
---- binutils-2.21-orig.0/binutils/budbg.h 2009-09-02 09:22:31.000000000 +0200
-+++ binutils-2.21/binutils/budbg.h 2011-06-17 18:17:52.000000000 +0200
+diff -ruwN binutils/budbg.h binutils/budbg.h
+--- binutils/budbg.h 2009-09-02 12:52:31.000000000 +0530
++++ binutils/budbg.h 2010-03-11 12:13:23.272386500 +0530
@@ -52,8 +52,11 @@
extern bfd_boolean write_ieee_debugging_info (bfd *, void *);
+ (bfd *abfd, void *, long *symcountp, asymbol ***);
+
#endif
-diff -uNdr binutils-2.21-orig.0/binutils/debug.c binutils-2.21/binutils/debug.c
---- binutils-2.21-orig.0/binutils/debug.c 2009-09-10 15:40:44.000000000 +0200
-+++ binutils-2.21/binutils/debug.c 2011-06-17 18:17:52.000000000 +0200
+diff -ruwN binutils/debug.c binutils/debug.c
+--- binutils/debug.c 2009-09-14 17:13:26.000000000 +0530
++++ binutils/debug.c 2010-03-11 12:13:23.288009800 +0530
@@ -31,6 +31,7 @@
#include <assert.h>
#include "bfd.h"
+ /* Not found, pass the original name on. */
+ return oname;
+}
-diff -uNdr binutils-2.21-orig.0/binutils/debug.h binutils-2.21/binutils/debug.h
---- binutils-2.21-orig.0/binutils/debug.h 2009-09-10 15:40:44.000000000 +0200
-+++ binutils-2.21/binutils/debug.h 2011-06-17 18:17:52.000000000 +0200
-@@ -441,6 +441,12 @@
+diff -ruwN binutils/debug.h binutils/debug.h
+--- binutils/debug.h 2009-09-14 17:13:26.000000000 +0530
++++ binutils/debug.h 2010-03-11 12:13:23.288009800 +0530
+@@ -440,6 +440,12 @@
extern bfd_boolean debug_start_source (void *, const char *);
/* Record a function definition. This implicitly starts a function
block. The debug_type argument is the type of the return value.
The bfd_boolean indicates whether the function is globally visible.
-diff -uNdr binutils-2.21-orig.0/binutils/doc/objcopy.1 binutils-2.21/binutils/doc/objcopy.1
---- binutils-2.21-orig.0/binutils/doc/objcopy.1 2010-12-08 09:39:12.000000000 +0100
-+++ binutils-2.21/binutils/doc/objcopy.1 2011-06-17 18:24:32.000000000 +0200
-@@ -203,6 +203,8 @@
+diff -ruwN binutils/doc/objcopy.1 binutils/doc/objcopy.1
+--- binutils/doc/objcopy.1 2009-10-16 17:22:19.000000000 +0530
++++ binutils/doc/objcopy.1 2010-03-11 12:13:23.303633100 +0530
+@@ -202,6 +202,8 @@
[\fB\-\-readonly\-text\fR]
[\fB\-\-pure\fR]
[\fB\-\-impure\fR]
[\fB\-\-file\-alignment=\fR\fInum\fR]
[\fB\-\-heap=\fR\fIsize\fR]
[\fB\-\-image\-base=\fR\fIaddress\fR]
-@@ -911,6 +913,23 @@
+@@ -885,6 +887,23 @@
It can also be a useful way of reducing the size of a \fB\-\-just\-symbols\fR
linker input file.
.RE
+takes precedence over any \fB\-\-change\-pathname\fR option. For some
+debugging formats that cannot handle long filenames, this options is
+implied (notably, some COFF debugging formats).
- .IP "\fB\-\-compress\-debug\-sections\fR" 4
- .IX Item "--compress-debug-sections"
- Compress \s-1DWARF\s0 debug sections using zlib.
-diff -uNdr binutils-2.21-orig.0/binutils/objcopy.c binutils-2.21/binutils/objcopy.c
---- binutils-2.21-orig.0/binutils/objcopy.c 2010-10-29 14:10:25.000000000 +0200
-+++ binutils-2.21/binutils/objcopy.c 2011-06-17 18:17:52.000000000 +0200
+ .IP "\fB\-V\fR" 4
+ .IX Item "-V"
+ .PD 0
+diff -ruwN binutils/objcopy.c binutils/objcopy.c
+--- binutils/objcopy.c 2009-09-14 17:13:26.000000000 +0530
++++ binutils/objcopy.c 2010-03-11 12:13:23.319256400 +0530
@@ -32,6 +32,7 @@
#include "elf-bfd.h"
#include <sys/stat.h>
#include "coff/internal.h"
#include "libcoff.h"
-@@ -308,6 +309,8 @@
+@@ -297,6 +298,8 @@
OPTION_IMPURE,
OPTION_EXTRACT_SYMBOL,
OPTION_REVERSE_BYTES,
OPTION_FILE_ALIGNMENT,
OPTION_HEAP,
OPTION_IMAGE_BASE,
-@@ -358,10 +361,12 @@
+@@ -346,10 +349,12 @@
{"adjust-section-vma", required_argument, 0, OPTION_CHANGE_SECTION_ADDRESS},
{"adjust-warnings", no_argument, 0, OPTION_CHANGE_WARNINGS},
{"alt-machine-code", required_argument, 0, OPTION_ALT_MACH_CODE},
{"change-section-address", required_argument, 0, OPTION_CHANGE_SECTION_ADDRESS},
{"change-section-lma", required_argument, 0, OPTION_CHANGE_SECTION_LMA},
{"change-section-vma", required_argument, 0, OPTION_CHANGE_SECTION_VMA},
-@@ -554,6 +559,8 @@
+@@ -543,6 +548,8 @@
--prefix-alloc-sections <prefix>\n\
Add <prefix> to start of every allocatable\n\
section name\n\
--file-alignment <num> Set PE file alignment to <num>\n\
--heap <reserve>[,<commit>] Set PE reserve/commit heap to <reserve>/\n\
<commit>\n\
-@@ -1006,6 +1013,8 @@
+@@ -999,6 +1006,8 @@
asymbol **from = isyms, **to = osyms;
long src_count = 0, dst_count = 0;
int relocatable = (abfd->flags & (EXEC_P | DYNAMIC)) == 0;
for (; src_count < symcount; src_count++)
{
-@@ -1106,7 +1115,8 @@
+@@ -1099,7 +1108,8 @@
|| bfd_is_com_section (bfd_get_section (sym)))
keep = strip_symbols != STRIP_UNNEEDED;
else if ((flags & BSF_DEBUGGING) != 0) /* Debugging symbol. */
&& strip_symbols != STRIP_UNNEEDED
&& ! convert_debugging);
else if (bfd_coff_get_comdat_section (abfd, bfd_get_section (sym)))
-@@ -2857,6 +2867,10 @@
+@@ -2817,6 +2827,10 @@
return write_ieee_debugging_info (obfd, dhandle);
if (bfd_get_flavour (obfd) == bfd_target_coff_flavour
|| bfd_get_flavour (obfd) == bfd_target_elf_flavour)
{
bfd_byte *syms, *strings;
-@@ -3707,6 +3721,30 @@
+@@ -3641,6 +3655,30 @@
prefix_alloc_sections_string = optarg;
break;
case OPTION_READONLY_TEXT:
bfd_flags_to_set |= WP_TEXT;
bfd_flags_to_clear &= ~WP_TEXT;
-diff -uNdr binutils-2.21-orig.0/binutils/rdcoff.c binutils-2.21/binutils/rdcoff.c
---- binutils-2.21-orig.0/binutils/rdcoff.c 2009-09-02 09:22:32.000000000 +0200
-+++ binutils-2.21/binutils/rdcoff.c 2011-06-17 18:17:52.000000000 +0200
+diff -ruwN binutils/rdcoff.c binutils/rdcoff.c
+--- binutils/rdcoff.c 2009-09-02 12:52:32.000000000 +0530
++++ binutils/rdcoff.c 2010-03-11 12:13:23.334879700 +0530
@@ -82,6 +82,9 @@
struct coff_slots *slots;
/* Basic types. */
if (ISFCN (syment.n_type))
{
fnname = name;
-diff -uNdr binutils-2.21-orig.0/binutils/wrcoff.c binutils-2.21/binutils/wrcoff.c
---- binutils-2.21-orig.0/binutils/wrcoff.c 1970-01-01 01:00:00.000000000 +0100
-+++ binutils-2.21/binutils/wrcoff.c 2011-06-17 18:17:52.000000000 +0200
-@@ -0,0 +1,3412 @@
+diff -ruwN binutils/wrcoff.c binutils/wrcoff.c
+--- binutils/wrcoff.c 1970-01-01 05:30:00.000000000 +0530
++++ binutils/wrcoff.c 2010-03-11 12:13:23.366126300 +0530
+@@ -0,0 +1,3410 @@
+/* wrcoff.c -- Generate (AVR) COFF debugging information
+ Copyright 2003 Free Software Foundation, Inc.
+
+ struct coff_struct_hash_entry *shash;
+ struct coff_enum_hash_entry *ehash;
+ struct coff_private_symdata *priv;
-+ unsigned int type, numaux, arydim, size, nele, nderived;
++ unsigned int type, numaux, arydim, size, i, nele, nderived;
+ const char *name;
+ bfd_boolean oldavrcoff = (info->flags & (COFF_FL_AVR | COFF_FL_EXT_AVR))
+ == COFF_FL_AVR;
+
+ if (ISARY (type))
+ {
-+ unsigned i;
-+
+ /* Compute size of entire array. */
+ for (i = 0, nele = 1; i < arydim; i++)
+ nele *= aux->x_sym.x_fcnary.x_ary.x_dimen[i];
+
+ return TRUE;
+}
-diff -uNdr binutils-2.21-orig.0/include/coff/avr.h binutils-2.21/include/coff/avr.h
---- binutils-2.21-orig.0/include/coff/avr.h 1970-01-01 01:00:00.000000000 +0100
-+++ binutils-2.21/include/coff/avr.h 2011-06-17 18:17:52.000000000 +0200
+diff -ruwN include/coff/avr.h include/coff/avr.h
+--- include/coff/avr.h 1970-01-01 05:30:00.000000000 +0530
++++ include/coff/avr.h 2010-03-11 12:13:23.381749600 +0530
@@ -0,0 +1,110 @@
+/* coff information for Atmel AVR.
+
+
+#define RELOC struct external_reloc
+#define RELSZ 10
-diff -uNdr binutils-2.21-orig.0/include/coff/internal.h binutils-2.21/include/coff/internal.h
---- binutils-2.21-orig.0/include/coff/internal.h 2010-04-15 12:26:07.000000000 +0200
-+++ binutils-2.21/include/coff/internal.h 2011-06-17 18:17:52.000000000 +0200
-@@ -647,6 +647,8 @@
+diff -ruwN include/coff/internal.h include/coff/internal.h
+--- include/coff/internal.h 2009-09-02 12:51:39.000000000 +0530
++++ include/coff/internal.h 2010-03-11 12:13:23.381749600 +0530
+@@ -646,6 +646,8 @@
};