summaryrefslogtreecommitdiff
path: root/toolchain/gcc/Makefile
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2024-05-17 18:37:22 +0200
committerWaldemar Brodkorb <wbx@openadk.org>2024-05-18 04:51:20 +0200
commitf5c67bc4f3f14de3a4261f21565cb4658a9ef3bd (patch)
tree1f18bf997eaa72769f73fb4eb812f88477527cd1 /toolchain/gcc/Makefile
parent6d77c8668e4e557924f8883fa5d6ab6e5af58f2e (diff)
nds32: add back support for old toolchain and Linux, working on ag101p with latest uClibc-ng
fix
Diffstat (limited to 'toolchain/gcc/Makefile')
-rw-r--r--toolchain/gcc/Makefile8
1 files changed, 6 insertions, 2 deletions
diff --git a/toolchain/gcc/Makefile b/toolchain/gcc/Makefile
index 2b2f7e03c..8798b06d2 100644
--- a/toolchain/gcc/Makefile
+++ b/toolchain/gcc/Makefile
@@ -259,6 +259,10 @@ ifneq ($(ADK_TARGET_ABI_RISCV),)
GCC_CONFOPTS+= --with-abi=${ADK_TARGET_ABI_RISCV}
endif
+ifeq ($(ADK_TOOLCHAIN_GCC_NDS32),y)
+EXTRA_CXXFLAGS:= --std=c++03
+endif
+
ifeq (${ADK_MAKE_PARALLEL},y)
GCC_MAKEOPTS+= -j${ADK_MAKE_JOBS}
endif
@@ -332,7 +336,7 @@ endif
CC='$(HOST_CC)' \
CXX='$(HOST_CXX)' \
CFLAGS="-O0 -g0 -fomit-frame-pointer" \
- CXXFLAGS="-O0 -g0 -fomit-frame-pointer" \
+ CXXFLAGS="-O0 -g0 -fomit-frame-pointer $(EXTRA_CXXFLAGS)" \
$(WRKBUILD)/configure \
${GCC_INITIAL_CONFOPTS} \
${GCC_CONFOPTS} \
@@ -373,7 +377,7 @@ $(WRKBUILD)/.compiled:
cd $(GCC_BUILD_DIR_FINAL); \
PATH='$(TARGET_PATH)' \
CC='$(HOST_CC)' \
- CXX='$(HOST_CXX)' \
+ CXX='$(HOST_CXX) $(EXTRA_CXXFLAGS)' \
CFLAGS_FOR_TARGET='$(TARGET_CFLAGS)' \
CXXFLAGS_FOR_TARGET='$(TARGET_CXXFLAGS)' \
$(WRKBUILD)/configure \