summaryrefslogtreecommitdiff
path: root/Rules.mak
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2016-04-21 01:25:29 +0200
committerWaldemar Brodkorb <wbx@uclibc-ng.org>2016-06-30 03:24:42 +0200
commitee92c0fe5c1b9d59508273916e2c9a75b68dbc13 (patch)
tree65a22258b12f84325910fc2ad47e2b02696ef593 /Rules.mak
parentdd46699e46decb7273f44dc2cbf307f096dc39e8 (diff)
nds32: add support for new architecture
Add support for Andes Technology NDS32 architecture. See here http://www.andestech.com/en/index/index.htm for more informaton. Verification of the port from an older uClibc port was done on a sponsored AG101p board. The testsuite only has 5 errors, three are related to an existing bug in dlclose() with LT.old, also happening on cris32 and m68k. Failures to fallocate/posix_fallocate are unresolved. Thanks to Andes Technology sponsoring the hardware and being very helpful while doing the uClibc-ng porting. Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
Diffstat (limited to 'Rules.mak')
-rw-r--r--Rules.mak9
1 files changed, 9 insertions, 0 deletions
diff --git a/Rules.mak b/Rules.mak
index 3e4e6c03c..894d4dc28 100644
--- a/Rules.mak
+++ b/Rules.mak
@@ -104,6 +104,7 @@ ifeq ($(TARGET_ARCH),)
ARCH ?= $(shell uname -m | $(SED) -e s/i.86/i386/ \
-e s/sun.*/sparc/ -e s/sparc.*/sparc/ \
-e s/arm.*/arm/ -e s/sa110/arm/ \
+ -e s/nds32.*/nds32/ \
-e s/sh.*/sh/ \
-e s/s390x/s390/ -e s/parisc.*/hppa/ \
-e s/ppc.*/powerpc/ -e s/mips.*/mips/ \
@@ -300,6 +301,7 @@ ifeq ($(UCLIBC_HAS_SOFT_FLOAT),y)
ifneq ($(TARGET_ARCH),bfin)
ifneq ($(TARGET_ARCH),lm32)
ifneq ($(TARGET_ARCH),nios2)
+ifneq ($(TARGET_ARCH),nds32)
ifneq ($(TARGET_ARCH),sh)
ifneq ($(TARGET_ARCH),c6x)
ifneq ($(TARGET_ARCH),h8300)
@@ -313,6 +315,7 @@ endif
endif
endif
endif
+endif
$(eval $(call check-gcc-var,-std=gnu99))
CPU_CFLAGS-y += $(CFLAG_-std=gnu99)
@@ -410,6 +413,12 @@ ifeq ($(TARGET_ARCH),mips)
CPU_LDFLAGS-y += $(CPU_CFLAGS)
endif
+ifeq ($(TARGET_ARCH),nds32)
+ CPU_CFLAGS-$(CONFIG_NDS32_ISA)+=-march=nds32
+ CFLAGS-.os+= -DPIC
+ CFLAGS-.oS+= -DPIC
+endif
+
ifeq ($(TARGET_ARCH),sh)
$(eval $(call check-gcc-var,-mprefergot))
OPTIMIZATION += $(CFLAG_-mprefergot)