Building libc++

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Building libc++

Toralf Niebuhr
Hi

When I try to build libc++ on the current trunk, I get the error below.
I set these variables for the build.
$ echo $CXX
clang++ -v
$TRIPLE
x86_64-apple-darwin10


+ clang++ -v -c -g -Os -arch i386 -arch ppc -arch x86_64 -nostdinc++ -I../include ../src/exception.cpp
clang version 2.0 (trunk 106826)
Target: x86_64-apple-darwin10
Thread model: posix
 "/usr/local/bin/clang" -cc1 -triple i386-apple-darwin10.0.0 -emit-obj -disable-free -main-file-name exception.cpp -pic-level 1 -mdisable-fp-elim -masm-verbose -target-cpu yonah -v -g -nostdinc++ -resource-dir /usr/local/lib/clang/2.0 -I ../include -Os -ferror-limit 19 -fmessage-length 148 -stack-protector 1 -fblocks -fexceptions -fdiagnostics-show-option -fcolor-diagnostics -o /var/folders/3C/3Cjb8XqLGZ4CudBSDgvEJE+++TI/-Tmp-/cc-Io6oCq.o -x c++ ../src/exception.cpp
clang -cc1 version 2.0 based upon llvm 2.8svn hosted on x86_64-apple-darwin10
#include "..." search starts here:
#include <...> search starts here:
 ../include
 /usr/local/include
 /usr/local/lib/clang/2.0/include
 /usr/include
 /System/Library/Frameworks (framework directory)
 /Library/Frameworks (framework directory)
End of search list.
../src/exception.cpp:14:12: fatal error: 'cxxabi.h' file not found
  #include <cxxabi.h>
           ^
1 error generated.


As the standard headers are not included, I suspect that cxxabi.h should be in the libc++ project?


Toralf Niebuhr
_______________________________________________
cfe-dev mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
Reply | Threaded
Open this post in threaded view
|

Re: Building libc++

रजनीश
On Jun 29, 2009, at 6:30 PM, Toralf Niebuhr wrote:
> As the standard headers are not included, I suspect that cxxabi.h  
> should be in the libc++ project?
>

http://lists.cs.uiuc.edu/pipermail/cfe-dev/2010-May/009112.html
_______________________________________________
cfe-dev mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
Reply | Threaded
Open this post in threaded view
|

Re: Building libc++

Toralf Niebuhr
In reply to this post by Toralf Niebuhr
Am 29.06.2010 um 15:41 schrieb रजनीश:

On Jun 29, 2009, at 6:30 PM, Toralf Niebuhr wrote:
As the standard headers are not included, I suspect that cxxabi.h should be in the libc++ project?


http://lists.cs.uiuc.edu/pipermail/cfe-dev/2010-May/009112.html

This is still not compiling for me. I didn't install the headers, but instead modified the build script so that the libc++abi includes are found too. Still the code is not compiling through.
Is there some quick start documentation somewhere online?
Thread model: posix
"/usr/local/bin/clang" -cc1 -triple i386-apple-darwin10.0.0 -emit-obj -disable-free -main-file-name exception.cpp -pic-level 1 -mdisable-fp-elim -masm-verbose -target-cpu yonah -v -g -nostdinc++ -resource-dir /usr/local/lib/clang/2.8 -I ../include -I /Users/gmthor85/Downloads/libcppabi/include -Os -ferror-limit 19 -fmessage-length 148 -stack-protector 1 -fblocks -fexceptions -fdiagnostics-show-option -fcolor-diagnostics -o /var/folders/3C/3Cjb8XqLGZ4CudBSDgvEJE+++TI/-Tmp-/cc-0M3mY3.o -x c++ ../src/exception.cpp
clang -cc1 version 2.8 based upon llvm 2.8svn hosted on x86_64-apple-darwin10
#include "..." search starts here:
#include <...> search starts here:
../include
/Users/gmthor85/Downloads/libcppabi/include
/usr/local/include
/usr/local/lib/clang/2.8/include
/usr/include
/System/Library/Frameworks (framework directory)
/Library/Frameworks (framework directory)
End of search list.
In file included from ../src/exception.cpp:14:
/Users/gmthor85/Downloads/libcppabi/include/cxxabi.h:30:62: error: no struct named 'type_info' in namespace 'std'
extern void __cxa_throw(void * thrown_exception, struct std::type_info * tinfo, 
                                                       ~~~~~^
/Users/gmthor85/Downloads/libcppabi/include/cxxabi.h:37:13: error: no type named 'type_info' in namespace 'std'
extern std::type_info * __cxa_current_exception_type();
      ~~~~~^

Toralf
_______________________________________________
cfe-dev mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
Reply | Threaded
Open this post in threaded view
|

Re: Building libc++

Howard Hinnant
On Jun 30, 2010, at 1:44 AM, Toralf Niebuhr wrote:

> /Users/gmthor85/Downloads/libcppabi/include/cxxabi.h:30:62: error: no struct named 'type_info' in namespace 'std'
> extern void __cxa_throw(void * thrown_exception, struct std::type_info * tinfo,
>                                                        ~~~~~^
> /Users/gmthor85/Downloads/libcppabi/include/cxxabi.h:37:13: error: no type named 'type_info' in namespace 'std'
> extern std::type_info * __cxa_current_exception_type();
>       ~~~~~^

I've seen this error before and could've sworn I fixed it.  I've fixed it (again I think).  If you could re-download:

http://home.roadrunner.com/~hinnant/libcppabi.zip

The cxxabi.h has been patched to forward declare std::type_info.

-Howard




_______________________________________________
cfe-dev mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev