[cfe-dev] Clang 3.4 --with-gcc-toolchain question

DbdM Tbt spin.x2k at gmail.com
Thu May 8 05:56:29 PDT 2014


Good day,
I would like to ask about the behavior of '--with-gcc-toolchain'
configuration option.
I am currently trying out clang 3.4 with gcc 4.7 and for this, I used the
centos devtools repo.
GCC 4.7 is installed into /opt/centos/devtoolset-1.0/.
I configured clang 3.4 like below:
CC=/opt/centos/devtoolset-1.0/root/usr/bin/gcc
CXX=/opt/centos/devtoolset-1.0/root/usr/bin/g++ <configure>
--with-gcc-toolchain=/opt/centos/devtoolset-1.0/root/usr/

Make is ok but when I try clang-check it doesn't seem to find 'iostream'.
I thought with the option --with-gcc-toolchain, clang and its tools will
automatically be pointed the gcc 4.7 directories.
Perhaps I am missing something here or my assumptions are flawed. Can
someone share some insights?.

Using the -v option on clang-check, the "Selected GCC installation:" is
blank and the list of include directories don't include the 4.7 directories.
Explicitly specifying the include directories (-I option) in the
clang-check invocation will work but is there another workaround?
I would prefer to resolve such issues in the 'environment setup' aspect and
not during 'application usage'.

Thank you very much,
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20140508/655668df/attachment.html>


More information about the cfe-dev mailing list