summaryrefslogtreecommitdiff
path: root/toolchain
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2018-05-12 15:04:16 +0200
committerWaldemar Brodkorb <wbx@openadk.org>2018-05-12 15:04:30 +0200
commitc7aa35971feff8d26379ff63299219b129fcbe5b (patch)
tree35f60b34288f62254ac076f253f08b5209586aab /toolchain
parent44cbb78fa78eb2167290a2072e7815d405c8940b (diff)
nds32: use binutils/gcc from github
Diffstat (limited to 'toolchain')
-rw-r--r--toolchain/binutils/Makefile.inc6
-rw-r--r--toolchain/binutils/patches/nds32-binutils-2.30-branch-open/fls-internal.patch29
-rw-r--r--toolchain/binutils/patches/nds32-binutils-2.30-branch-open/remove-gnu-suffix.patch14
-rw-r--r--toolchain/gcc/Makefile.inc4
4 files changed, 48 insertions, 5 deletions
diff --git a/toolchain/binutils/Makefile.inc b/toolchain/binutils/Makefile.inc
index 1f72612a4..c2ad2076e 100644
--- a/toolchain/binutils/Makefile.inc
+++ b/toolchain/binutils/Makefile.inc
@@ -38,10 +38,10 @@ PKG_SITES:= https://github.com/c-sky/binutils-gdb.git
DISTFILES:= ${PKG_NAME}-${PKG_VERSION}.tar.xz
endif
ifeq ($(ADK_TOOLCHAIN_BINUTILS_NDS32),y)
-PKG_VERSION:= 2.24-nds32
+PKG_VERSION:= nds32-binutils-2.30-branch-open
+PKG_GIT:= branch
PKG_RELEASE:= 1
-PKG_HASH:= ab1c72aeed2d50403bdf67914e60d936279d065943d83d1c19c20462a7b82cda
-PKG_SITES:= http://distfiles.openadk.org/
+PKG_SITES:= https://github.com/andestech/binutils.git
DISTFILES:= ${PKG_NAME}-${PKG_VERSION}.tar.xz
endif
ifeq ($(ADK_TOOLCHAIN_BINUTILS_AVR32),y)
diff --git a/toolchain/binutils/patches/nds32-binutils-2.30-branch-open/fls-internal.patch b/toolchain/binutils/patches/nds32-binutils-2.30-branch-open/fls-internal.patch
new file mode 100644
index 000000000..33c78ac36
--- /dev/null
+++ b/toolchain/binutils/patches/nds32-binutils-2.30-branch-open/fls-internal.patch
@@ -0,0 +1,29 @@
+diff -Nur binutils-nds32-binutils-2.30-branch-open.orig/bfd/elf32-nds32.c binutils-nds32-binutils-2.30-branch-open/bfd/elf32-nds32.c
+--- binutils-nds32-binutils-2.30-branch-open.orig/bfd/elf32-nds32.c 2018-05-10 22:01:57.000000000 +0200
++++ binutils-nds32-binutils-2.30-branch-open/bfd/elf32-nds32.c 2018-05-12 09:01:10.000000000 +0200
+@@ -5286,7 +5286,7 @@
+ }
+
+ static unsigned int
+-fls (register unsigned int x)
++fls_internal (register unsigned int x)
+ {
+ return ffs (x & (-x));
+ }
+@@ -6189,14 +6189,14 @@
+
+ if (1 < ones32 (tls_type))
+ {
+- eff_tls_type = 1 << (fls (tls_type) - 1);
++ eff_tls_type = 1 << (fls_internal (tls_type) - 1);
+ /* TLS model shall be handled in nds32_elf_unify_tls_model () */
+
+ /* TLS model X -> LE is not implement yet!
+ * workaround here! */
+ if (eff_tls_type == GOT_TLS_LE)
+ {
+- eff_tls_type = 1 << (fls (tls_type ^ eff_tls_type) - 1);
++ eff_tls_type = 1 << (fls_internal (tls_type ^ eff_tls_type) - 1);
+ }
+ }
+
diff --git a/toolchain/binutils/patches/nds32-binutils-2.30-branch-open/remove-gnu-suffix.patch b/toolchain/binutils/patches/nds32-binutils-2.30-branch-open/remove-gnu-suffix.patch
new file mode 100644
index 000000000..3afa794c4
--- /dev/null
+++ b/toolchain/binutils/patches/nds32-binutils-2.30-branch-open/remove-gnu-suffix.patch
@@ -0,0 +1,14 @@
+diff -Nur binutils-nds32-binutils-2.30-branch-open.orig/ld/configure.tgt binutils-nds32-binutils-2.30-branch-open/ld/configure.tgt
+--- binutils-nds32-binutils-2.30-branch-open.orig/ld/configure.tgt 2018-05-10 22:03:15.000000000 +0200
++++ binutils-nds32-binutils-2.30-branch-open/ld/configure.tgt 2018-05-12 08:44:24.000000000 +0200
+@@ -583,8 +583,8 @@
+ nds32*be-*-elf*) targ_emul=nds32belf
+ targ_extra_emuls="nds32elf nds32elf16m nds32belf16m"
+ ;;
+-nds32*le-*-linux-gnu*) targ_emul=nds32elf_linux ;;
+-nds32*be-*-linux-gnu*) targ_emul=nds32belf_linux ;;
++nds32*le-*-linux*) targ_emul=nds32elf_linux ;;
++nds32*be-*-linux*) targ_emul=nds32belf_linux ;;
+ nios2*-*-linux*) targ_emul=nios2linux ;;
+ nios2*-*-*) targ_emul=nios2elf ;;
+ ns32k-pc532-mach* | ns32k-pc532-ux*) targ_emul=pc532macha ;;
diff --git a/toolchain/gcc/Makefile.inc b/toolchain/gcc/Makefile.inc
index e9c48aa9c..4c2f06db8 100644
--- a/toolchain/gcc/Makefile.inc
+++ b/toolchain/gcc/Makefile.inc
@@ -57,9 +57,9 @@ DISTFILES:= ${PKG_NAME}-${PKG_VERSION}.tar.gz
LIBSTDCXXVER:= 19
endif
ifeq ($(ADK_TOOLCHAIN_GCC_NDS32),y)
-PKG_VERSION:= 4.9.4-nds32
+PKG_VERSION:= nds32-6.3.0-open
PKG_HASH:= b23ce96df25dfdd5526496a3c2cd7ee1da4ed4094971a2e0c47c73ad7e1ad30a
-PKG_SITES:= http://distfiles.openadk.org/
+PKG_SITES:= https://github.com/andestech/gcc.git
PKG_RELEASE:= 1
DISTFILES:= ${PKG_NAME}-${PKG_VERSION}.tar.xz
endif