[cfe-dev] Anyone who has built lldb successfully on RHEL 6.x?

Zack Perry zack.perry at sbcglobal.net
Tue Jul 30 13:30:44 PDT 2013


I have been trying to build lldbwith the following two approaches:

(I) using llvm/clang 3.3 together with libc++/libc++abi so the build is free of libstdc++:

This is what I used to configure the build:

../llvm/configure --prefix=/usr --enable-optimized --disable-assertions --enable-targets=host-only --enable-cxx11=yes --enable-libcpp=yes --with-extra-ld-options="-lc++abi"

The resulting Release/bin/lldb crashes even for simple things like help x-(

(II) using the bundled GCC 4.4.7

This is what I used to configure the build:

CC=gcc CXX=g++ CXXFLAGS=-std=c++0x ../llvm/configure --prefix=/usr --enable-optimized --disable-assertions --enable-targets=host-only 


$ make DEBUG_SYMBOLS=0 -j 4
make[1]: Entering directory `/home/zackp/clang3.3/build/lib/Support'
llvm[1]: Compiling APFloat.cpp for Release+Debug build
llvm[1]: Compiling APInt.cpp for Release+Debug build
llvm[1]: Compiling APSInt.cpp for Release+Debug build
llvm[1]: Compiling BlockFrequency.cpp for Release+Debug build
llvm[1]: Compiling BranchProbability.cpp for Release+Debug build
In file included from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/memory:83,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/SmallVector.h:27,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/ArrayRef.h:14,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/APInt.h:18,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/APSInt.h:18,
                 from /home/zackp/clang3.3/llvm/lib/Support/APSInt.cpp:15:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In member function ‘virtual void* std::_Sp_counted_deleter<_Ptr, _Deleter, _Alloc, _Lp>::_M_get_deleter(const std::type_info&)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:146: error: cannot use typeid with -fno-rtti
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In member function ‘virtual void* std::_Sp_counted_ptr_inplace<_Tp, _Alloc, _Lp>::_M_get_deleter(const std::type_info&)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:204: error: cannot use typeid with -fno-rtti
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In constructor ‘std::__shared_ptr<_Tp, _Lp>::__shared_ptr(std::_Sp_make_shared_tag, _Alloc, _Args&& ...)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:861: error: cannot use typeid with -fno-rtti
In file included from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/memory:83,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/SmallVector.h:27,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/ArrayRef.h:14,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/APInt.h:18,
                 from /home/zackp/clang3.3/llvm/lib/Support/APInt.cpp:16:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In member function ‘virtual void* std::_Sp_counted_deleter<_Ptr, _Deleter, _Alloc, _Lp>::_M_get_deleter(const std::type_info&)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:146: error: cannot use typeid with -fno-rtti
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In function ‘_Del* std::get_deleter(const std::__shared_ptr<_Tp2, _Lp>&)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:1005: error: cannot use typeid with -fno-rtti
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In member function ‘virtual void* std::_Sp_counted_ptr_inplace<_Tp, _Alloc, _Lp>::_M_get_deleter(const std::type_info&)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:204: error: cannot use typeid with -fno-rtti
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In constructor ‘std::__shared_ptr<_Tp, _Lp>::__shared_ptr(std::_Sp_make_shared_tag, _Alloc, _Args&& ...)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:861: error: cannot use typeid with -fno-rtti
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In function ‘_Del* std::get_deleter(const std::__shared_ptr<_Tp2, _Lp>&)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:1005: error: cannot use typeid with -fno-rtti
In file included from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/memory:83,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/SmallVector.h:27,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/ArrayRef.h:14,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/APInt.h:18,
                 from /home/zackp/clang3.3/llvm/include/llvm/ADT/APFloat.h:104,
                 from /home/zackp/clang3.3/llvm/lib/Support/APFloat.cpp:15:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In member function ‘virtual void* std::_Sp_counted_deleter<_Ptr, _Deleter, _Alloc, _Lp>::_M_get_deleter(const std::type_info&)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:146: error: cannot use typeid with -fno-rtti
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In member function ‘virtual void* std::_Sp_counted_ptr_inplace<_Tp, _Alloc, _Lp>::_M_get_deleter(const std::type_info&)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:204: error: cannot use typeid with -fno-rtti
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In constructor ‘std::__shared_ptr<_Tp, _Lp>::__shared_ptr(std::_Sp_make_shared_tag, _Alloc, _Args&& ...)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:861: error: cannot use typeid with -fno-rtti
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h: In function ‘_Del* std::get_deleter(const std::__shared_ptr<_Tp2, _Lp>&)’:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/shared_ptr.h:1005: error: cannot use typeid with -fno-rtti
make[1]: *** [/home/zackp/clang3.3/build/lib/Support/Release+Debug/APSInt.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: *** [/home/zackp/clang3.3/build/lib/Support/Release+Debug/APInt.o] Error 1
make[1]: *** [/home/zackp/clang3.3/build/lib/Support/Release+Debug/APFloat.o] Error 1
make[1]: Leaving directory `/home/zackp/clang3.3/build/lib/Support'
make: *** [all] Error 1

As a result, the current llvm/clang based C++11 environment on this test machine doesn't have the lldbdebugger ;-( Although so far I have been able to build even the full Boost libraries on this host, not having a matching debugger just doesn't install good feeling.

Any tips are appreciated!

-- Zack
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20130730/71cb0f67/attachment.html>


More information about the cfe-dev mailing list