what compiler do you use? Could you try to build LLDB with clang 3.5 specifying it via DCMAKE_C_COMPILER and DCMAKE_CXX_COMPILER flags?
It might be a problem with sysroot setup since some headers are not found - you can try to pass a custom sysroot with -DCMAKE_CXX_FLAGS=“–sysroot=…”
Using gcc 4.8 from devtoolset2. Clang builds fine so might try building with that tomorrow.
I fixed several RHEL-derived distribution-related issues in top of tree LLDB a few weeks back. It was for RHEL 7-derived builds, so quite a bit newer. If you are building your lldb off of top-of-tree, hopefully this will mostly become an exercise of:
Do you have a new-enough python. (I believe at this point you really want a 2.7, but with CentOS 5 you might be far back enough to be 2.4 or 2.6. We probably limp along with 2.6 since that was our baseline for a while). Worst case here you can download a newer python and build from source, then specify it to cmake via the right python cmake variables.
Do you have a new-enough c++ compiler. Since you’re able to build a clang, that should take care of that issue.
Other libs you’ll need. I needed to install these:
yum install libedit-devel
yum install python-devel
yum install ncurses-devel
yum install swig
yum install libxml2-devel
* cmake - you'll need cmake 184.108.40.206 or later. This one I'm pretty sure you're going to need to build this from scratch.
* ninja - you're going to want to build the ninja build tool to optimize your build speed and use -GNinja with your cmake command line.
It'll be interesting to hear what else you find.
For My Centos 5 build:
Using python 2.7 (From devtoolset 2)
Using gcc 4.8 (From devtoolset 2)
disabled libedit and python bindings
Built cmake from source
Make is fine so didnt bother with ninja
Applying the patch then gives me a working liblldb.so.
Also want to say that its refreshing seeing such a good api. The interface is easy to understand and is standalone without pulling in a bunch of complex types from other libraries. Well done lldb team!
Great, glad to hear, Mark!