[cfe-dev] libcxx install location?

Larry Evans cppljevans at suddenlink.net
Sat Feb 5 05:26:25 PST 2011

On 02/05/11 05:56, Larry Evans wrote:
> On 02/05/11 05:39, Jean-Daniel Dupas wrote:
>> Le 5 févr. 2011 à 11:51, Larry Evans a écrit :
> [snip]
>>> Also, that libcxx page makes no mention of:
>>>  http://llvm.org/svn/llvm-project/cfe/trunk/runtime/libcxx/Makefile
>>> However, seeing:
>>>  LIBCXX_SRC_ROOT := $(LLVM_SRC_ROOT)/projects/libcxx
>>>  CPP.Flags := -nostdinc++ -I$(LIBCXX_SRC_ROOT)/include
> [snip]
>> Did you had a look at this thread:
>> http://lists.cs.uiuc.edu/pipermail/cfe-dev/2011-January/013017.html
> Yes, but I'd rather not mess with /usr/lib or /usr/include if it
> can be avoided, and the mentioned trunk/runtime/libcxx/Makefile
> suggested maybe there's another way which avoids messing with /usr.
> -Larry
I went ahead and did as:


and added symlinks from /usr/lib and /usr/include/c++.  It compiled OK;
however, the link failed with:

make compile
ls -ld /usr/lib/libc++*
lrwxrwxrwx 1 root root 69 Feb  5 07:09 /usr/lib/libc++.so ->
ls -ld /usr/include/c++/v1
lrwxrwxrwx 1 root root 59 Feb  5 07:14 /usr/include/c++/v1 ->
-stdlib=libc++ move.cpp -o move.exe
undefined reference to `__cxa_free_exception'
undefined reference to `__cxa_begin_catch'
undefined reference to `__cxa_guard_release'

I didn't link to path-to-libcxx/lib/libc++.1.dylib
because there was no such file.  Instead, I figured
that was a MacOS convention for shared libs; so,
I substituted the only likely file in the target


Now I did *not* do the download and install of:


because the webpage:



  To build on Mac OS X 10.6, you need a helper library and header found
  here. cp cxxabi.h to /usr/include, and cp libc++abi.dylib to

and I'm on ubuntu, not Mac OS X.

Am I missing something?



More information about the cfe-dev mailing list