toolchain: add support of ARCv2 architecture
[openwrt/staging/chunkeey.git] / toolchain / gcc / final / Makefile
index e8c32f629dc77af1eeaae99df135cd54ca407905..3434d894a2b501ba9545c99d47066fc43a7b5480 100644 (file)
@@ -4,23 +4,16 @@ include ../common.mk
 
 GCC_CONFIGURE += \
        --with-headers=$(TOOLCHAIN_DIR)/include \
+       --disable-libsanitizer \
        --enable-languages=$(TARGET_LANGUAGES) \
        --enable-shared \
        --enable-threads \
-       --with-slibdir=$(TOOLCHAIN_DIR)/lib
-
-ifneq ($(CONFIG_GCC_VERSION_4_5)$(CONFIG_GCC_VERSION_4_6),)
-  GCC_CONFIGURE += \
+       --with-slibdir=$(TOOLCHAIN_DIR)/lib \
        --enable-lto \
        --with-libelf=$(TOPDIR)/staging_dir/host
-endif
 
-ifneq ($(CONFIG_TLS_SUPPORT),)
-  GCC_CONFIGURE += \
-       --enable-tls
-else
-  GCC_CONFIGURE += \
-       --disable-tls
+ifdef CONFIG_USE_MUSL
+  GCC_MAKE += gcc_cv_libc_provides_ssp=yes
 endif
 
 ifneq ($(CONFIG_SJLJ_EXCEPTIONS),)
@@ -77,6 +70,7 @@ define Host/Install
                done; \
        );
        $(if $(CONFIG_EXTRA_TARGET_ARCH),$(call SetupExtraArch))
+       $(RM) $(TOOLCHAIN_DIR)/lib/libiberty.a
        $(SCRIPT_DIR)/patch-specs.sh "$(TOOLCHAIN_DIR)"
 endef