LLDB doesn't link on OS X: lldbPluginOSDarwinKernel not found

Hi all,

Title says all, I'm trying to build lldb on OS X, using cmake, and it
complains about lldbPluginOSDarwinKernel missing when linking
liblldb.3.4.

I've grepped around, and it doesn't seem to be defined anywhere , only
used since r180243.

Is it available on another repo, or should it be removed from the
CMakeLists.txt?

Thanks!

-- Ahmed Bougacha

That was my bad, I just updated the CMakeLists.txt file (it had a wrong name).
But there's another problem: For now we're not running the
scripts/generate-vers.pl to create a small C file to link against lldb
(for the _liblldb_coreVersionString function).
Because of that, even after my fix, the CMake build won't work. I
don't know that much CMake, so I'm waiting for some spare time to try
to fix it. If you know how to fix it, or want to try, please go ahead
and send a patch.

Regards,

  Filipe

That was my bad, I just updated the CMakeLists.txt file (it had a wrong name).
But there's another problem: For now we're not running the
scripts/generate-vers.pl to create a small C file to link against lldb
(for the _liblldb_coreVersionString function).
Because of that, even after my fix, the CMake build won't work. I
don't know that much CMake, so I'm waiting for some spare time to try
to fix it. If you know how to fix it, or want to try, please go ahead
and send a patch.

Yep, that's exactly what I just noticed. I'll see what I can do about it.

Thanks!

-- Ahmed Bougacha

With the attached patch the file is generated, and it links fine.
Now it says it can't locate debugserver when I try to actually run
something, I'll look into that later.
-- Ahmed Bougacha

lldb-osx-cmake.diff (1.42 KB)

Patch LGTM. Tried it out and can confirm it fixes the missing symbol error pertaining to version.

Ahmed, I'm not sure there is CMake support for building debugserver, though it's probably not too bad to add the target definition in a similar manner to the "lldb" target.

Dan

PS. In the future please send patches to LLDB-commits list :slight_smile:

Committed in r182751.

Thanks Ahmed!

Cheers,
Dan