<p dir="ltr">Try using GCC_INSTALL_PREFIX when you invoke cmake.</p>
<div class="gmail_quote">On Dec 10, 2015 11:34 AM, "Rocco Moretti via cfe-dev" <<a href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div><div>Hello,<br><br></div>I'm having difficulties compiling the Clang 3.7.0 release. For this I'm attempting to use gcc 5.2.0 installed in a non-standard location (as the system compiler is gcc 4.4, and not something I have authorization to update).<br><br></div>I'm using the --with-gcc-toolchain option to the cmake command to point to the directory of the gcc 5.2.0 install, and I do get the "The CXX compiler identification is GNU 5.2.0" messages. (But it does this even when I omit the --with-gcc-toolchain option, as I've set the CC and CXX environment variables.) <br><br>However, when I attempt to use the compiler, I'm apparently getting the system gcc 4.4 include search paths for the standard library, rather than the 5.2.0 paths:<br><br>$ bin/clang++ -E -x c++ - -v < /dev/null<br>...<br>#include "..." search starts here:<br>#include <...> search starts here:<br> /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7<br> /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/x86_64-redhat-linux<br> /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/backward<br> /usr/local/include<br> /path/to/clang/3.7.0/build2/bin/../lib/clang/3.7.0/include<br> /usr/include<br>End of search list.<br>...<br><br></div>Am I correct that my compile was unable to find the gcc 5.2.0 C++ standard library, or am I thinking about this in the wrong fashion?<br><br></div>My Google searching and different compilation attempts haven't been very successful. The --with-gcc-toolchain option isn't documented all that well, specifying just that it's "where gcc is installed", but not saying anything about what, exactly, is expected from that directory (I presume it's the same as the install prefix passed to the GCC compile; the directory which contains the bin/ lib/ include/, etc. directories where the gcc version is), or what will happen if the C++ stdlib is not found in that directory (is there any error message?).<br><br></div>Thanks.<br><div><br><br><div><div><div><br></div></div></div></div></div>
<br>_______________________________________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a><br>
<br></blockquote></div>