[lldb-dev] [OS X]: building lldb with cmake
Pavel Labath via lldb-dev
lldb-dev at lists.llvm.org
Fri Sep 9 02:42:34 PDT 2016
Hi Rene,
building lldb on osx with cmake should work fine when you're doing it
as a part of llvm (our buildbot is doing it
<http://lab.llvm.org:8011/builders/lldb-x86_64-darwin-13.4>).
What you are asking for is called a "standalone" build of LLDB. I
don't think anyone has tried it on a mac, but other people are using
it, with varying levels of success. You should look at
lldb/cmake/modules/LLDBStandalone.cmake for how to set it up. As far
as I know, the main trick is pointing your build to the llvm-config
binary installed by the llvm package (you should just check out the
lldb repo, without llvm and clang sources).
good luck,
pl
On 9 September 2016 at 09:55, René J.V. Bertin via lldb-dev
<lldb-dev at lists.llvm.org> wrote:
> Hi,
>
> I've been working on a MacPorts port for lldb (MacPorts already provides ports for llvm and clang; cf. https://trac.macports.org/ticket/45251). Using the Xcode project isn't really an option here, so I've based my approach on the instructions for building using CMake on *n*x.
>
> In short:
>
> - unpack llvm sources
> - unpack lldb sources in the expected location in the llvm tree
> - call cmake from an out-of-tree build directory pointing it to the toplevel CMakeLists.txt (i.e. the one in llvm-src)
> - call make in the lldb subdir under the build directory (build/tools/lldb).
>
> The nice thing with CMake's Makefiles generator is that it is usually able to figure out what needs to be built from upstreams when make is called in a project subdirectory, and this works with lldb.
>
> Yet I've been asked to look into the possibility of building *just* lldb, using whatever dependencies it requires from the already installed llvm+clang directory.
>
> I'm presuming that there might be a benefit to that approach on other Unices too. Has anyone tried whether this is the case, assuming that it's actually possible?
>
> NB: MacPorts' port:lldb will depend on port:llvm and port:clang, so prebuilt dependencies will be available, as long as nothing is required that is omitted from a standard install.
>
> Thanks,
> René
> _______________________________________________
> lldb-dev mailing list
> lldb-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev
More information about the lldb-dev
mailing list