On Thu, 20 Jul 2017 18:48:20 -0400 "Isaac D. Cohen" <icohen2...@zoho.com> wrote:
> But then I decided to try, just to make sure, and redo the second pass > of gcc with --enable-threads. After doing that I redid the compilation of > glibc and got the same error. So that doesn't seem to be the problem. Isaac, That first URL: https://www.mail-archive.com/gcc@gcc.gnu.org/msg81240.html gives a test program for gcc's threads ability. Create a file, thread.cc, which contains #include <thread> int main(int, char **){ std::thread tt; } and then try compiling it with: g++ -std=c++11 thread.cc -lpthread -o x which should work without error and produce the executable "x". If that fails, then your gcc (or should I say, libstdc++) does not have the proper thread support. I note that in section 5.8 for Libstdc++-7.1.0 there is: "--disable-libstdcxx-threads Since we have not yet built the C threads library, the C++ one cannot be built either." Also, note the "--with-gxx-include-dir" This initial version of libstdc++ will/must be overwritten later by a full version from gcc. If that does not happen and your gcc is still using this earlier limited version of libstdc++, then it will not have thread support from the libstdc++ library no matter how gcc itself was configured and compiled. And watch out that in GCC pass 2 you started with a fresh unpacking of the gcc tarball. (We have to do this, right?) After all, in the Libstdc++-7.1.0 a ../libstdc++-v3/configure --disable-libstdcxx-threads had been done in the pass 1 tarball's libstdc++-v3 subdirectory. Does anyone know if those libstdc++ configure settings will remain or be properly overridden if gcc's main directory configure is run - e.g., what if the LFS builder attempts to start gcc pass 2 with the existing unpacked gcc tar ball from pass 1? A question I now have is: At what point in the build process can the LFS system (i.e., gcc) be expected to be able to compile the thread.cc test above? Is it after GCC-7.1.0 Pass 2, or is it only after the final build of GCC? If the former is true, then how can GCC-7.1.0 Pass 2 have thread support when Glibc-2.25+adc7e06 has not yet been rebuilt (since just after Pass 1, and libstdc++ could not be enabled with thread support under that glibc)? And if the latter is true, how can the final build of glibc be expected to pass make check if doing so requires thread support in gcc/libstdc++ ? Cheers, Mike -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style