[cfe-dev] libc++abi on linux

Richard Smith richard at metafoo.co.uk
Mon Jul 9 00:42:44 PDT 2012


On Sun, Jul 8, 2012 at 10:52 PM, soaliap <soaliap at 126.com> wrote:

>
> "C. Bergström"-3 wrote
> >
> > libcxxrt + libunwind is the way to go imho
> > https://github.com/pathscale/libcxxrt
> > https://github.com/pathscale/libunwind
> >
> > These have been tested to work with clang - Admittedly the build process
> > may not be straight forward, but if enough interest maybe we solve that
> >
>
> Does this mean that if I want to build libcxxabi with clang++ or other
> compiler on linux, I must build libcxxrt and libunwind first? I have tried
> simply copying a file unwind.h from ${libunwind-path}/include to
> ${libcxxabi-path}/include, and it can compile success. But I'm not sure
> whether that works right.


I believe that should be fine; all unwind.h implementations should be
essentially equivalent. The problem which libc++abi + Clang faces seems to
be that the unwind.h provided by Clang is simply missing a bunch of the
declarations that libc++abi expects it to contain. It tries to
#include_next some other unwind.h to solve that problem, but that doesn't
work so well if there's no system unwind.h and libunwind isn't installed. I
don't know if there's a good reason why Clang's header is missing
things which libc++abi uses, like _Unwind_Exception.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20120709/fc647fb0/attachment.html>


More information about the cfe-dev mailing list