Rev 3022 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3022 | Rev 4055 | ||
---|---|---|---|
Line 13... | Line 13... | ||
13 | echo "Script failed: $2" |
13 | echo "Script failed: $2" |
14 | exit |
14 | exit |
15 | fi |
15 | fi |
16 | } |
16 | } |
17 | 17 | ||
- | 18 | if [ -z "${CROSS_PREFIX}" ] ; then |
|
- | 19 | CROSS_PREFIX="/usr/local" |
|
- | 20 | fi |
|
- | 21 | ||
18 | BINUTILS_VERSION="2.18" |
22 | BINUTILS_VERSION="2.19" |
19 | GCC_VERSION="4.2.2" |
23 | GCC_VERSION="4.3.2" |
20 | 24 | ||
21 | BINUTILS="binutils-${BINUTILS_VERSION}.tar.gz" |
25 | BINUTILS="binutils-${BINUTILS_VERSION}.tar.gz" |
22 | GCC_CORE="gcc-core-${GCC_VERSION}.tar.bz2" |
26 | GCC_CORE="gcc-core-${GCC_VERSION}.tar.bz2" |
23 | GCC_OBJC="gcc-objc-${GCC_VERSION}.tar.bz2" |
27 | GCC_OBJC="gcc-objc-${GCC_VERSION}.tar.bz2" |
24 | GCC_CPP="gcc-g++-${GCC_VERSION}.tar.bz2" |
28 | GCC_CPP="gcc-g++-${GCC_VERSION}.tar.bz2" |
Line 27... | Line 31... | ||
27 | GCC_SOURCE="ftp://ftp.gnu.org/gnu/gcc/gcc-${GCC_VERSION}/" |
31 | GCC_SOURCE="ftp://ftp.gnu.org/gnu/gcc/gcc-${GCC_VERSION}/" |
28 | 32 | ||
29 | PLATFORM="mips" |
33 | PLATFORM="mips" |
30 | WORKDIR=`pwd` |
34 | WORKDIR=`pwd` |
31 | TARGET="${PLATFORM}-sgi-irix5" |
35 | TARGET="${PLATFORM}-sgi-irix5" |
32 | PREFIX="/usr/local/${PLATFORM}" |
36 | PREFIX="${CROSS_PREFIX}/${PLATFORM}" |
33 | BINUTILSDIR="${WORKDIR}/binutils-${BINUTILS_VERSION}" |
37 | BINUTILSDIR="${WORKDIR}/binutils-${BINUTILS_VERSION}" |
34 | GCCDIR="${WORKDIR}/gcc-${GCC_VERSION}" |
38 | GCCDIR="${WORKDIR}/gcc-${GCC_VERSION}" |
35 | OBJDIR="${WORKDIR}/gcc-obj" |
39 | OBJDIR="${WORKDIR}/gcc-obj" |
36 | 40 | ||
37 | echo ">>> Downloading tarballs" |
41 | echo ">>> Downloading tarballs" |
Line 78... | Line 82... | ||
78 | check_error $? "Error unpacking GCC C++." |
82 | check_error $? "Error unpacking GCC C++." |
79 | 83 | ||
80 | echo ">>> Compiling and installing binutils" |
84 | echo ">>> Compiling and installing binutils" |
81 | cd "${BINUTILSDIR}" |
85 | cd "${BINUTILSDIR}" |
82 | check_error $? "Change directory failed." |
86 | check_error $? "Change directory failed." |
- | 87 | patch -p1 <<EOF |
|
- | 88 | diff -Naur binutils-2.19.orig/bfd/elfxx-mips.c binutils-2.19/bfd/elfxx-mips.c |
|
- | 89 | --- binutils-2.19.orig/bfd/elfxx-mips.c 2008-08-18 20:14:04.000000000 +0200 |
|
- | 90 | +++ binutils-2.19/bfd/elfxx-mips.c 2009-01-18 18:14:47.292011299 +0100 |
|
- | 91 | @@ -1409,7 +1409,7 @@ |
|
- | 92 | function, or 0 if we can't decide which function that is. */ |
|
- | 93 | |
|
- | 94 | static unsigned long |
|
- | 95 | -mips16_stub_symndx (asection *sec, const Elf_Internal_Rela *relocs, |
|
- | 96 | +mips16_stub_symndx (asection *sec __attribute__((unused)), const Elf_Internal_Rela *relocs, |
|
- | 97 | const Elf_Internal_Rela *relend) |
|
- | 98 | { |
|
- | 99 | const Elf_Internal_Rela *rel; |
|
- | 100 | EOF |
|
- | 101 | check_error $? "Error patching binutils" |
|
83 | ./configure "--target=${TARGET}" "--prefix=${PREFIX}" "--program-prefix=${TARGET}-" "--disable-nls" |
102 | ./configure "--target=${TARGET}" "--prefix=${PREFIX}" "--program-prefix=${TARGET}-" "--disable-nls" |
84 | check_error $? "Error configuring binutils." |
103 | check_error $? "Error configuring binutils." |
85 | make all install |
104 | make all install |
86 | check_error $? "Error compiling/installing binutils." |
105 | check_error $? "Error compiling/installing binutils." |
87 | 106 |