summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--target/config/Config.in.binutils2
-rw-r--r--target/config/Config.in.compiler5
-rw-r--r--toolchain/gcc/Makefile.inc8
-rw-r--r--toolchain/gcc/patches/4.5.4/gcc.lm322
4 files changed, 16 insertions, 1 deletions
diff --git a/target/config/Config.in.binutils b/target/config/Config.in.binutils
index ac25afb9c..680ba671d 100644
--- a/target/config/Config.in.binutils
+++ b/target/config/Config.in.binutils
@@ -7,6 +7,7 @@ default ADK_TOOLCHAIN_BINUTILS_AVR32 if ADK_TARGET_ARCH_AVR32
default ADK_TOOLCHAIN_BINUTILS_KVX if ADK_TARGET_ARCH_KVX
default ADK_TOOLCHAIN_BINUTILS_2_28 if ADK_TARGET_CPU_SH_J2
default ADK_TOOLCHAIN_BINUTILS_2_38 if ADK_TARGET_ARCH_NDS32
+default ADK_TOOLCHAIN_BINUTILS_2_40 if ADK_TARGET_ARCH_LM32
default ADK_TOOLCHAIN_BINUTILS_2_41
config ADK_TOOLCHAIN_BINUTILS_GIT
@@ -17,6 +18,7 @@ config ADK_TOOLCHAIN_BINUTILS_GIT
config ADK_TOOLCHAIN_BINUTILS_2_41
bool "2.41"
depends on !ADK_TARGET_ARCH_AVR32
+ depends on !ADK_TARGET_ARCH_LM32
depends on !ADK_TARGET_ARCH_KVX
config ADK_TOOLCHAIN_BINUTILS_2_40
diff --git a/target/config/Config.in.compiler b/target/config/Config.in.compiler
index da3c10f7e..a8f501044 100644
--- a/target/config/Config.in.compiler
+++ b/target/config/Config.in.compiler
@@ -14,6 +14,7 @@ prompt "GCC version"
depends on ADK_BUILD_COMPILER_GCC
default ADK_TOOLCHAIN_GCC_AVR32 if ADK_TARGET_ARCH_AVR32
default ADK_TOOLCHAIN_GCC_KVX if ADK_TARGET_ARCH_KVX
+default ADK_TOOLCHAIN_GCC_LM32 if ADK_TARGET_ARCH_LM32
default ADK_TOOLCHAIN_GCC_METAG if ADK_TARGET_ARCH_METAG
default ADK_TOOLCHAIN_GCC_7 if ADK_TARGET_ARCH_C6X # ICE with newer GCC
default ADK_TOOLCHAIN_GCC_9 if ADK_TARGET_ARCH_BFIN && ADK_TARGET_BINFMT_FDPIC
@@ -93,6 +94,10 @@ config ADK_TOOLCHAIN_GCC_AVR32
bool "4.4.7-avr32"
depends on ADK_TARGET_ARCH_AVR32
+config ADK_TOOLCHAIN_GCC_LM32
+ bool "4.5.4-lm32"
+ depends on ADK_TARGET_ARCH_LM32
+
config ADK_TOOLCHAIN_GCC_METAG
bool "4.2.4-metag"
depends on ADK_TARGET_ARCH_METAG
diff --git a/toolchain/gcc/Makefile.inc b/toolchain/gcc/Makefile.inc
index 1fddb6ed3..2fbfc6077 100644
--- a/toolchain/gcc/Makefile.inc
+++ b/toolchain/gcc/Makefile.inc
@@ -66,6 +66,14 @@ PKG_RELEASE:= 1
DISTFILES:= ${PKG_NAME}-${PKG_VERSION}.tar.gz
LIBSTDCXXVER:= 19
endif
+ifeq ($(ADK_TOOLCHAIN_GCC_LM32),y)
+PKG_VERSION:= 4.5.4
+PKG_HASH:= 33fb968907ef7b6c528f6395ba049eb34c4df859bf5aa6c2bc3856268801e078
+PKG_SITES:= https://ftp.gnu.org/gnu/gcc/gcc-$(PKG_VERSION)/
+PKG_RELEASE:= 1
+DISTFILES:= ${PKG_NAME}-${PKG_VERSION}.tar.gz
+LIBSTDCXXVER:= 19
+endif
ifeq ($(ADK_TOOLCHAIN_GCC_METAG),y)
PKG_VERSION:= 4.2.4
PKG_HASH:= 7cb75c5183bd18f415860084440377016dc78feeee2852227b831f2e4fcaa5d6
diff --git a/toolchain/gcc/patches/4.5.4/gcc.lm32 b/toolchain/gcc/patches/4.5.4/gcc.lm32
index f32fb0dbd..df77ddf83 100644
--- a/toolchain/gcc/patches/4.5.4/gcc.lm32
+++ b/toolchain/gcc/patches/4.5.4/gcc.lm32
@@ -114,7 +114,7 @@ diff -Nur gcc-4.5.4.orig/libgcc/config.host gcc-4.5.4/libgcc/config.host
tmake_file="lm32/t-lm32 lm32/t-elf t-softfp"
;;
-lm32-*-uclinux*)
-+lm32-*-linux*)
++lm32-*-*linux*)
extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o"
- tmake_file="lm32/t-lm32 lm32/t-uclinux t-softfp"
+ tmake_file="lm32/t-lm32 t-softfp"