When building libc++ on a clean Linux system (through cmake), it
complains that it can't find cxxabi.h. This is sensible because
cxxabi.h lives at /usr/include/c++/4.6/cxxabi.h, right next to all the
other C++ library headers, and the libc++ build passes -nostdinc++ to
avoid accidentally including those.
What's the right way to fix this? Options include:
1) Document that linux users should copy or symlink cxxabi.h from
their c++ include directory into /usr/include
2) Teach clang to find cxxabi.h in the C++ library directories even
with -nostdinc++
3) Have the libc++ build process find cxxabi.h and copy it into the
libc++ include directory as part of the build.
4) ???
5) Profit!
When building libc++ on a clean Linux system (through cmake), it
complains that it can't find cxxabi.h. This is sensible because
cxxabi.h lives at /usr/include/c++/4.6/cxxabi.h, right next to all the
other C++ library headers, and the libc++ build passes -nostdinc++ to
avoid accidentally including those.
What's the right way to fix this? Options include:
1) Document that linux users should copy or symlink cxxabi.h from
their c++ include directory into /usr/include
In practice, the commands to do this on Ubuntu 11.10 are:
I had to tweak this work-around a bit for Debian Squeeze with GCC 4.4.
(Aside from changing 4.6 to 4.4, of course.)
Namely, “cxxabi_forced.h” is spelled with a dash instead of an underscore,
aka “cxxabi-forced.h” and resides in the toplevel include directory.
With that change, the last line looks like this for me: