From 0291cc44eee410270a97efb6258394c1f1f8352a Mon Sep 17 00:00:00 2001 From: Rich Felker Date: Fri, 6 May 2016 18:37:09 +0000 Subject: [PATCH] litecross: add some gcc options that should always be used with musl libmpx is broken in all gcc versions that have it (not supported yet by mcm/litecross, but will be). ifunc is not supported by musl and won't be unless/until the contract for resolvers can be specified clearly in a way that real-world usage is safe and does not require lazy binding; having it enabled at gcc level reportedly produces a broken libatomic. explicitly enabling libstdcxx-time is needed to get libc clock_gettime (with vdso support) to be used in libstdc++; it's disabled by default because of glibc legacy practice of having clock_gettime in librt, which depends on glibc's libpthread and undermines libstdc++'s (invalid use of) weak references to pthread symbols. --- litecross/Makefile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/litecross/Makefile b/litecross/Makefile index 8fec20a..adbeedb 100644 --- a/litecross/Makefile +++ b/litecross/Makefile @@ -25,7 +25,10 @@ FULL_TOOLCHAIN_CONFIG = $(TOOLCHAIN_CONFIG) \ --with-sysroot=$(SYSROOT) \ --with-build-sysroot='$$(LC_ROOT)/obj_sysroot' \ --enable-tls \ - --disable-libmudflap --disable-libsanitizer + --disable-libmudflap --disable-libsanitizer \ + --disable-gnu-indirect-function \ + --disable-libmpx \ + --enable-libstdcxx-time FULL_MUSL_CONFIG = $(MUSL_CONFIG) \ --prefix= --host=$(TARGET)