Update RISC-V XCC toolchain
[akaros.git] / tools / compilers / gcc-glibc / binutils-2.21.1-ros.patch
1 diff -ruN orig-src/binutils-2.21.1/bfd/config.bfd binutils-2.21.1/bfd/config.bfd
2 --- orig-src/binutils-2.21.1/bfd/config.bfd     2011-04-01 05:02:42.000000000 -0700
3 +++ binutils-2.21.1/bfd/config.bfd      2011-11-11 04:05:38.000000000 -0800
4 @@ -519,6 +519,12 @@
5    i[3-7]86-*-aros*)
6      targ_defvec=bfd_elf32_i386_vec
7      ;;
8 +  i[3-7]86-*-ros*)
9 +    targ_defvec=bfd_elf32_i386_vec
10 +    ;;
11 +  sparc-*-ros*) 
12 +    targ_defvec=bfd_elf32_sparc_vec
13 +    ;;
14    i[3-7]86-*-chorus*)
15      targ_defvec=bfd_elf32_i386_vec
16      ;;
17 diff -ruN orig-src/binutils-2.21.1/config.sub binutils-2.21.1/config.sub
18 --- orig-src/binutils-2.21.1/config.sub 2010-06-01 10:53:40.000000000 -0700
19 +++ binutils-2.21.1/config.sub  2011-11-11 04:05:38.000000000 -0800
20 @@ -1297,7 +1297,7 @@
21               | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \
22               | -sym* | -kopensolaris* \
23               | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
24 -             | -aos* | -aros* \
25 +             | -aos* | -aros* | -ros* \
26               | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
27               | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
28               | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
29 diff -ruN orig-src/binutils-2.21.1/configure binutils-2.21.1/configure
30 --- orig-src/binutils-2.21.1/configure  2011-06-27 00:39:00.000000000 -0700
31 +++ binutils-2.21.1/configure   2011-12-15 09:57:17.000000000 -0800
32 @@ -6701,6 +6701,10 @@
33    *-*-mingw* | *-*-cygwin ) RPATH_ENVVAR=PATH ;;
34    *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
35  esac
36 +# Override RPATH_ENVVAR, courtesy of Gentoo.  See this thread for more info:
37 +# http://www.cygwin.com/ml/binutils/2010-02/msg00266.html
38 +# http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo/src/patchsets/binutils/2.20/08_all_binutils-RPATH_ENVVAR-smack.patch?view=markup&revision=1.1
39 +RPATH_ENVVAR="cant_touch_this_nah_nah_nah"
40  
41  # On systems where the dynamic library environment variable is PATH,
42  # gcc/ will put dynamic libraries into a subdirectory to avoid adding
43 diff -ruN orig-src/binutils-2.21.1/gas/configure.tgt binutils-2.21.1/gas/configure.tgt
44 --- orig-src/binutils-2.21.1/gas/configure.tgt  2011-04-01 05:02:42.000000000 -0700
45 +++ binutils-2.21.1/gas/configure.tgt   2011-11-11 04:05:38.000000000 -0800
46 @@ -180,6 +180,8 @@
47    i386-*-beos*)                                fmt=elf ;;
48    i386-*-coff)                         fmt=coff ;;
49    i386-*-elf)                          fmt=elf ;;
50 +  i386-*-ros)                          fmt=elf ;;
51 +  sparc-*-ros)                         fmt=elf ;;
52    i386-*-kaos*)                                fmt=elf ;;
53    i386-*-bsd*)                         fmt=aout em=386bsd ;;
54    i386-*-netbsd0.8)                    fmt=aout em=386bsd ;;
55 diff -ruN orig-src/binutils-2.21.1/ld/configure.tgt binutils-2.21.1/ld/configure.tgt
56 --- orig-src/binutils-2.21.1/ld/configure.tgt   2011-04-01 05:03:54.000000000 -0700
57 +++ binutils-2.21.1/ld/configure.tgt    2011-11-11 04:05:38.000000000 -0800
58 @@ -242,6 +242,8 @@
59                         esac ;;
60  i[3-7]86-*-netware)    targ_emul=i386nw ;;
61  i[3-7]86-*-elf*)       targ_emul=elf_i386 ;;
62 +i[3-7]86-*-ros)        targ_emul=elf_i386 ;;
63 +sparc*-*-ros)          targ_emul=elf32_sparc ;;
64  x86_64-*-elf*)         targ_emul=elf_x86_64
65                         targ_extra_emuls="elf_i386 elf_l1om"
66                         ;;