X-Git-Url: http://git.ozo.com/?a=blobdiff_plain;f=toolchain%2Fgcc%2Ffinal%2FMakefile;h=01fec380273752d01c10046f476f785ec34b92aa;hb=0d9f922230aa02821c538a87c1d10584cff6c61c;hp=e8c32f629dc77af1eeaae99df135cd54ca407905;hpb=348cae15d2934f07a6c584261c2bee49cc43bbbd;p=lede-git%2F.git diff --git a/toolchain/gcc/final/Makefile b/toolchain/gcc/final/Makefile index e8c32f629d..01fec38027 100644 --- a/toolchain/gcc/final/Makefile +++ b/toolchain/gcc/final/Makefile @@ -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),) @@ -46,7 +39,16 @@ define Host/Configure ); endef +ifeq ($(CONFIG_USE_GLIBC)$(CONFIG_INSTALL_GCCGO),yy) +define FixGogccCrt + # link crtX.o for gotools + mkdir -p $(GCC_BUILD_DIR)/gotools + $(foreach crt, i 1 n, ln -sf ../../glibc-dev/lib/crt$(crt).o $(GCC_BUILD_DIR)/gotools/ ; ) +endef +endif + define Host/Compile + $(FixGogccCrt) +$(GCC_MAKE) $(HOST_JOBS) -C $(GCC_BUILD_DIR) all endef @@ -77,6 +79,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