<div dir="ltr">> <span style="font-family:arial,sans-serif;font-size:13px">What do you think about an ENABLE_STD_THREADS := YES for these </span><div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">That seems like a reasonable way to go.  And we just work out in the Makefile.rules what that needs to translate into.</span></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Oct 17, 2014 at 5:53 AM, Ed Maste <span dir="ltr"><<a href="mailto:emaste@freebsd.org" target="_blank">emaste@freebsd.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On FreeBSD the test fails to link without `-lpthread`:<br>
```<br>
os command: gmake clean LD_EXTRAS='-L/tank/emaste/src/llvm/build-nodebug/bin/../lib/python2.7/site-packages/../.. -llldb' EXE='test_listener_event_description' CFLAGS_EXTRAS='-std=c++11 -stdlib=libc++ -I/tank/emaste/src/llvm/tools/lldb/test/../include' CXX_SOURCES='driver.cpp listener_test.cpp test_listener_event_description.cpp'; gmake ARCH=amd64 CC="/usr/bin/clang" LD_EXTRAS='-L/tank/emaste/src/llvm/build-nodebug/bin/../lib/python2.7/site-packages/../.. -llldb' EXE='test_listener_event_description' CFLAGS_EXTRAS='-std=c++11 -stdlib=libc++ -I/tank/emaste/src/llvm/tools/lldb/test/../include' CXX_SOURCES='driver.cpp listener_test.cpp test_listener_event_description.cpp'<br>
with pid: 92054<br>
stdout: rm -f "test_listener_event_description"  driver.o listener_test.o test_listener_event_description.o driver.d listener_test.d test_listener_event_description.d<br>
rm -f -r<br>
rm -rf *.o *.d *.dSYM<br>
/usr/bin/clang++ -std=c++11 -g -O0 -m64  -std=c++11 -stdlib=libc++ -I/tank/emaste/src/llvm/tools/lldb/test/../include -I/tank/emaste/src/llvm/tools/lldb/test/make/../../include   -c -o driver.o driver.cpp<br>
/usr/bin/clang++ -std=c++11 -g -O0 -m64  -std=c++11 -stdlib=libc++ -I/tank/emaste/src/llvm/tools/lldb/test/../include -I/tank/emaste/src/llvm/tools/lldb/test/make/../../include   -c -o listener_test.o listener_test.cpp<br>
/usr/bin/clang++ -std=c++11 -g -O0 -m64  -std=c++11 -stdlib=libc++ -I/tank/emaste/src/llvm/tools/lldb/test/../include -I/tank/emaste/src/llvm/tools/lldb/test/make/../../include   -c -o test_listener_event_description.o test_listener_event_description.cpp<br>
/usr/bin/clang++  driver.o listener_test.o test_listener_event_description.o -g -O0 -m64  -std=c++11 -stdlib=libc++ -I/tank/emaste/src/llvm/tools/lldb/test/../include -I/tank/emaste/src/llvm/tools/lldb/test/make/../../include -L/tank/emaste/src/llvm/build-nodebug/bin/../lib/python2.7/site-packages/../.. -llldb  -o "test_listener_event_description"<br>
<br>
stderr: /usr/bin/ld: G: invalid DSO for symbol `pthread_create@@FBSD_1.0' definition<br>
//lib/libthr.so.3: could not read symbols: Bad value<br>
clang++: error: linker command failed with exit code 1 (use -v to see invocation)<br>
```<br>
<br>
What do you think about an ENABLE_STD_THREADS := YES for these tests, and then a system-dependent library addition?  My quick Google search suggests linking requirements for std::thread are quite system-dependent; AFAICT some Linuxes also need -lpthread -- perhaps a combination of the specific libc, libpthread, and libc++.<br>
<br>
<a href="http://reviews.llvm.org/D5838" target="_blank">http://reviews.llvm.org/D5838</a><br>
<br>
<br>
<br>
_______________________________________________<br>
lldb-commits mailing list<br>
<a href="mailto:lldb-commits@cs.uiuc.edu">lldb-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><table cellspacing="0" cellpadding="0" style="color:rgb(136,136,136);font-family:'Times New Roman'"><tbody><tr style="color:rgb(85,85,85);font-family:sans-serif;font-size:small"><td nowrap style="border-top-style:solid;border-top-color:rgb(213,15,37);border-top-width:2px">Todd Fiala |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(51,105,232);border-top-width:2px"> Software Engineer |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(0,153,57);border-top-width:2px"> <a href="mailto:tfiala@google.com" style="color:rgb(17,85,204)" target="_blank"><span style="background-color:rgb(255,255,204);color:rgb(34,34,34);background-repeat:initial initial">tfiala@google.com</span></a></td><td nowrap style="border-top-style:solid;border-top-color:rgb(238,178,17);border-top-width:2px"><br></td></tr></tbody></table><br></div>
</div>