[PATCH] D56836: [mips] Include whole lpthread when using both -pthread and -static
Aleksandar Beserminji via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Jan 18 05:03:39 PST 2019
abeserminji added a comment.
@atanasyan That looks good. I tried to make an equivalent for the Makefile
--- SingleSource/UnitTests/C++11/Makefile (revision 351547)
+++ SingleSource/UnitTests/C++11/Makefile (working copy)
@@ -4,6 +4,11 @@
CPPFLAGS += -std=c++11 -pthread
+ifeq (-static, $(findstring -static, $(TARGET_FLAGS)))
+#PROGRAMS_TO_SKIP += stdthreadbug
+LDFLAGS += -Wl,--whole-archive -lpthread -Wl,--no-whole-archive
+endif
+
ifdef BENCHMARKING_ONLY
PROGRAMS_TO_SKIP += stdthreadbug
endif
As an option, we can provide necessary flags for the test to finish successfully instead of not testing it.
Repository:
rC Clang
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D56836/new/
https://reviews.llvm.org/D56836
More information about the cfe-commits
mailing list