Add a checkbox for libmpx build.

Disable libmpx for musl builds.

Signed-off-by: Alexey Neyman <stilor@att.net>
This commit is contained in:
Alexey Neyman 2016-09-22 17:01:43 -07:00
parent 531eab4c56
commit 651567ff90
3 changed files with 24 additions and 0 deletions

View File

@ -160,6 +160,7 @@ config CC_GCC_5
select CC_GCC_HAS_LNK_HASH_STYLE
select CC_GCC_HAS_LIBQUADMATH
select CC_GCC_HAS_LIBSANITIZER
select CC_GCC_HAS_LIBMPX
select CC_SUPPORT_GOLANG
config CC_GCC_5_or_later
@ -178,6 +179,7 @@ config CC_GCC_6
select CC_GCC_HAS_LNK_HASH_STYLE
select CC_GCC_HAS_LIBQUADMATH
select CC_GCC_HAS_LIBSANITIZER
select CC_GCC_HAS_LIBMPX
select CC_SUPPORT_GOLANG
config CC_GCC_6_or_later
@ -276,6 +278,9 @@ config CC_GCC_HAS_LIBQUADMATH
config CC_GCC_HAS_LIBSANITIZER
bool
config CC_GCC_HAS_LIBMPX
bool
if ! CC_GCC_CUSTOM
config CC_GCC_VERSION

View File

@ -182,6 +182,16 @@ config CC_GCC_LIBSANITIZER
The default is 'N'. Say 'Y' if you need it, and report success/failure.
config CC_GCC_LIBMPX
bool
default y
prompt "Compile libmpx"
depends on CC_GCC_HAS_LIBMPX
depends on ARCH_x86
depends on !LIBC_musl # MUSL does not define libc types that GCC requires
help
Enable GCC support for Intel Memory Protection Extensions (MPX).
#-----------------------------------------------------------------------------
comment "Misc. obscure options."

View File

@ -436,6 +436,7 @@ do_gcc_core_backend() {
extra_config+=(--disable-libgomp)
extra_config+=(--disable-libmudflap)
extra_config+=(--disable-libmpx)
if [ "${CT_CC_GCC_LIBSSP}" = "y" ]; then
extra_config+=(--enable-libssp)
@ -904,6 +905,14 @@ do_gcc_backend() {
fi
fi
if [ "${CT_CC_GCC_HAS_LIBMPX}" = "y" ]; then
if [ "${CT_CC_GCC_LIBMPX}" = "y" ]; then
extra_config+=(--enable-libmpx)
else
extra_config+=(--disable-libmpx)
fi
fi
final_LDFLAGS+=("${ldflags}")
# *** WARNING ! ***