CVS: packaging/patches binutils-2.18-430X.patch, 1.4.2.1, 1.4.2.2
"Sergey A. Borshch" <[email protected]> Thu, 12 Feb 2009 13:50:35 +0000
| Newsgroups | gmane.comp.hardware.texas-instruments.msp430.gcc.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/mspgcc/packaging/patches
In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv9142/patches
Modified Files:
Tag: MSP430X
binutils-2.18-430X.patch
Log Message:
$(PREFIX) fixed for windows build
Index: binutils-2.18-430X.patch
===================================================================
RCS file: /cvsroot/mspgcc/packaging/patches/binutils-2.18-430X.patch,v
retrieving revision 1.4.2.1
retrieving revision 1.4.2.2
diff -u -w -d -r1.4.2.1 -r1.4.2.2
--- binutils-2.18-430X.patch 26 Jan 2009 15:57:17 -0000 1.4.2.1
+++ binutils-2.18-430X.patch 12 Feb 2009 13:50:33 -0000 1.4.2.2
@@ -1,6 +1,6 @@
diff -ru binutils-2.18.orig/bfd/archures.c binutils-2.18/bfd/archures.c
--- binutils-2.18.orig/bfd/archures.c Sun Aug 10 11:37:28 2008
-+++ binutils-2.18/bfd/archures.c Mon Dec 8 04:20:39 2008
++++ binutils-2.18/bfd/archures.c Fri Jan 23 02:04:37 2009
@@ -377,6 +377,7 @@
.#define bfd_mach_msp20 20
.#define bfd_mach_msp21 21
@@ -21,7 +21,7 @@
.#define bfd_mach_xc16xl 2
diff -ru binutils-2.18.orig/bfd/bfd-in2.h binutils-2.18/bfd/bfd-in2.h
--- binutils-2.18.orig/bfd/bfd-in2.h Sun Aug 10 11:37:28 2008
-+++ binutils-2.18/bfd/bfd-in2.h Mon Dec 8 04:28:36 2008
++++ binutils-2.18/bfd/bfd-in2.h Fri Jan 23 02:04:37 2009
@@ -2048,6 +2048,7 @@
#define bfd_mach_msp20 20
#define bfd_mach_msp21 21
@@ -68,7 +68,7 @@
BFD_RELOC_IQ2000_OFFSET_16,
diff -ru binutils-2.18.orig/bfd/cpu-msp430.c binutils-2.18/bfd/cpu-msp430.c
--- binutils-2.18.orig/bfd/cpu-msp430.c Sun Aug 10 11:37:28 2008
-+++ binutils-2.18/bfd/cpu-msp430.c Mon Dec 8 03:34:19 2008
++++ binutils-2.18/bfd/cpu-msp430.c Fri Jan 23 02:04:37 2009
@@ -74,38 +74,51 @@
/* msp430x22x. */
N (16, bfd_mach_msp22, "msp:22", FALSE, & arch_info_struct[10]),
@@ -132,9 +132,8 @@
};
const bfd_arch_info_type bfd_msp430_arch =
-diff -ru binutils-2.18.orig/bfd/elf32-msp430.c binutils-2.18/bfd/elf32-msp430.c
--- binutils-2.18.orig/bfd/elf32-msp430.c Sun Aug 10 11:37:28 2008
-+++ binutils-2.18/bfd/elf32-msp430.c Mon Dec 8 04:18:32 2008
++++ binutils-2.18/bfd/elf32-msp430.c Sun Jan 25 03:31:34 2009
@@ -90,7 +90,7 @@
0xffff, /* dst_mask */
FALSE), /* pcrel_offset */
@@ -569,7 +568,7 @@
if (srel & 1)
return bfd_reloc_outofrange;
-@@ -360,35 +678,138 @@
+@@ -360,33 +678,141 @@
break;
case R_MSP430_16_PCREL_BYTE:
@@ -588,6 +587,10 @@
- contents += rel->r_offset;
- srel = (bfd_signed_vma) relocation;
- srel += rel->r_addend;
++ /* Check for an overflow. */
++ if (srel < -32768 || srel > 65535)
++ return bfd_reloc_overflow;
++
bfd_put_16 (input_bfd, srel & 0xffff, contents);
break;
@@ -595,13 +598,14 @@
- contents += rel->r_offset;
- srel = (bfd_signed_vma) relocation;
- srel += rel->r_addend;
--
- if (srel & 1)
- return bfd_reloc_notsupported;
-
- bfd_put_16 (input_bfd, srel & 0xffff, contents);
- break;
++ /* Check for an overflow. */
++ if (srel & 1 || srel < -32768 || srel > 65535)
++ return bfd_reloc_overflow;
+- if (srel & 1)
++ bfd_put_16 (input_bfd, srel & 0xffff, contents);
++ break;
++
+ case R_MSP430X_SRC: // address operand
+ case R_MSP430X_PCREL_SRC: // PC-relative address operand
+
@@ -711,17 +715,16 @@
+ case R_MSP430X_PCREL_INDXD: // 16-bit idx in mova/bra instruction PC relative (symbolic) mode operand
+
+ if (srel & 1) //odd address
-+ return bfd_reloc_notsupported;
+ return bfd_reloc_notsupported;
+ case R_MSP430X_INDXD: // 16-bit idx in calla/mova/bra instruction
-+
+
+- bfd_put_16 (input_bfd, srel & 0xffff, contents);
+ x = srel & 0xffff;
+ bfd_put_16 (input_bfd, x, contents + 2); //16 least-significant bits
-+ break;
-+
+ break;
+
default:
- r = _bfd_final_link_relocate (howto, input_bfd, input_section,
- contents, rel->r_offset,
-@@ -576,6 +997,10 @@
+@@ -576,6 +1002,10 @@
val = E_MSP430_MACH_MSP430x22;
break;
@@ -732,7 +735,7 @@
case bfd_mach_msp24:
val = E_MSP430_MACH_MSP430x24;
break;
-@@ -619,6 +1044,18 @@
+@@ -619,6 +1049,18 @@
case bfd_mach_msp46:
val = E_MSP430_MACH_MSP430x46;
break;
@@ -751,7 +754,7 @@
}
elf_elfheader (abfd)->e_machine = EM_MSP430;
-@@ -681,6 +1118,10 @@
+@@ -681,6 +1123,10 @@
e_set = bfd_mach_msp22;
break;
@@ -762,7 +765,7 @@
case E_MSP430_MACH_MSP430x24:
e_set = bfd_mach_msp24;
break;
-@@ -723,6 +1164,18 @@
+@@ -723,6 +1169,18 @@
case E_MSP430_MACH_MSP430x46:
e_set = bfd_mach_msp46;
@@ -783,7 +786,7 @@
}
diff -ru binutils-2.18.orig/bfd/libbfd.h binutils-2.18/bfd/libbfd.h
--- binutils-2.18.orig/bfd/libbfd.h Mon Aug 6 22:59:38 2007
-+++ binutils-2.18/bfd/libbfd.h Sun Dec 7 21:50:56 2008
++++ binutils-2.18/bfd/libbfd.h Fri Jan 23 02:04:37 2009
@@ -1939,6 +1939,25 @@
"BFD_RELOC_MSP430_16_BYTE",
"BFD_RELOC_MSP430_2X_PCREL",
@@ -812,7 +815,7 @@
"BFD_RELOC_IQ2000_UHI16",
diff -ru binutils-2.18.orig/bfd/reloc.c binutils-2.18/bfd/reloc.c
--- binutils-2.18.orig/bfd/reloc.c Mon Aug 6 22:59:40 2007
-+++ binutils-2.18/bfd/reloc.c Sun Dec 7 21:50:56 2008
++++ binutils-2.18/bfd/reloc.c Fri Jan 23 02:04:37 2009
@@ -4841,6 +4841,44 @@
BFD_RELOC_MSP430_2X_PCREL
ENUMX
@@ -860,7 +863,7 @@
diff -ru binutils-2.18.orig/binutils/objdump.c binutils-2.18/binutils/objdump.c
--- binutils-2.18.orig/binutils/objdump.c Mon Aug 6 22:56:14 2007
-+++ binutils-2.18/binutils/objdump.c Sun Dec 7 21:50:56 2008
++++ binutils-2.18/binutils/objdump.c Fri Jan 23 02:04:37 2009
@@ -961,7 +961,12 @@
#endif
const char *map;
@@ -2640,7 +2643,7 @@
default:
diff -ru binutils-2.18.orig/include/elf/msp430.h binutils-2.18/include/elf/msp430.h
--- binutils-2.18.orig/include/elf/msp430.h Sun Aug 10 11:37:28 2008
-+++ binutils-2.18/include/elf/msp430.h Mon Dec 8 03:44:55 2008
++++ binutils-2.18/include/elf/msp430.h Fri Jan 23 02:04:37 2009
@@ -36,6 +36,7 @@
#define E_MSP430_MACH_MSP430x20 20
#define E_MSP430_MACH_MSP430x21 21
@@ -2687,7 +2690,7 @@
diff -ru binutils-2.18.orig/include/opcode/msp430.h binutils-2.18/include/opcode/msp430.h
--- binutils-2.18.orig/include/opcode/msp430.h Tue May 10 13:21:14 2005
-+++ binutils-2.18/include/opcode/msp430.h Sun Dec 7 21:50:56 2008
++++ binutils-2.18/include/opcode/msp430.h Fri Jan 23 02:04:37 2009
@@ -25,7 +25,7 @@
int ol; /* Operand length words. */
int am; /* Addr mode. */
@@ -3015,7 +3018,7 @@
};
diff -ru binutils-2.18.orig/ld/Makefile.am binutils-2.18/ld/Makefile.am
--- binutils-2.18.orig/ld/Makefile.am Sun Aug 10 11:37:28 2008
-+++ binutils-2.18/ld/Makefile.am Mon Dec 8 03:50:34 2008
++++ binutils-2.18/ld/Makefile.am Fri Jan 23 02:04:37 2009
@@ -316,11 +316,22 @@
emsp430x2014.o \
emsp430x2101.o \
@@ -3303,7 +3306,7 @@
${GENSCRIPTS} news "$(tdir_news)"
diff -ru binutils-2.18.orig/ld/Makefile.in binutils-2.18/ld/Makefile.in
--- binutils-2.18.orig/ld/Makefile.in Sun Aug 10 11:37:28 2008
-+++ binutils-2.18/ld/Makefile.in Mon Dec 8 03:52:22 2008
++++ binutils-2.18/ld/Makefile.in Fri Jan 23 02:04:38 2009
@@ -560,14 +560,25 @@
emsp430x2002.o \
emsp430x2012.o \
@@ -3595,7 +3598,7 @@
${GENSCRIPTS} news "$(tdir_news)"
diff -ru binutils-2.18.orig/ld/configure.tgt binutils-2.18/ld/configure.tgt
--- binutils-2.18.orig/ld/configure.tgt Sun Aug 10 11:37:28 2008
-+++ binutils-2.18/ld/configure.tgt Mon Dec 8 03:53:59 2008
++++ binutils-2.18/ld/configure.tgt Fri Jan 23 02:04:38 2009
@@ -407,7 +407,7 @@
mt-*elf) targ_emul=elf32mt
;;
@@ -3607,7 +3610,7 @@
ns32k-*-netbsd* | ns32k-pc532-lites*) targ_emul=ns32knbsd
diff -ru binutils-2.18.orig/ld/emulparams/msp430all.sh binutils-2.18/ld/emulparams/msp430all.sh
--- binutils-2.18.orig/ld/emulparams/msp430all.sh Sun Aug 10 11:37:28 2008
-+++ binutils-2.18/ld/emulparams/msp430all.sh Mon Dec 8 04:09:01 2008
++++ binutils-2.18/ld/emulparams/msp430all.sh Fri Jan 23 02:04:38 2009
@@ -19,8 +19,6 @@
RAM_START=0x0200
RAM_SIZE=128
@@ -5146,7 +5149,7 @@
} ${RELOCATING+ > vectors}
diff -ru binutils-2.18.orig/opcodes/msp430-dis.c binutils-2.18/opcodes/msp430-dis.c
--- binutils-2.18.orig/opcodes/msp430-dis.c Sun Aug 10 11:37:28 2008
-+++ binutils-2.18/opcodes/msp430-dis.c Mon Dec 8 04:12:26 2008
++++ binutils-2.18/opcodes/msp430-dis.c Fri Jan 23 02:04:38 2009
@@ -51,12 +51,153 @@
return bfd_getl16 (buffer);
}
------------------------------------------------------------------------------
Create and Deploy Rich Internet Apps outside the browser with Adobe(R)AIR(TM)
software. With Adobe AIR, Ajax developers can use existing skills and code to
build responsive, highly engaging applications that combine the power of local
resources and data with the reach of the web. Download the Adobe AIR SDK and
Ajax docs to start building applications today-http://p.sf.net/sfu/adobe-com