toolchain: gcc: enable sanitizers for glibc toolchain

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
This commit is contained in:
Yousong Zhou
2019-10-19 12:00:43 +00:00
parent ed6ba2801c
commit 69b9f0161e
2 changed files with 176 additions and 1 deletions

View File

@@ -4,7 +4,6 @@ include ../common.mk
GCC_CONFIGURE += \
--with-headers=$(TOOLCHAIN_DIR)/include \
--disable-libsanitizer \
--enable-languages=$(TARGET_LANGUAGES) \
--enable-shared \
--enable-threads \
@@ -12,6 +11,10 @@ GCC_CONFIGURE += \
--enable-lto \
--with-libelf=$(TOPDIR)/staging_dir/host
ifndef CONFIG_USE_GLIBC
GCC_CONFIGURE += --disable-libsanitizer
endif
ifdef CONFIG_USE_MUSL
GCC_MAKE += gcc_cv_libc_provides_ssp=yes
endif