unable to build lldb 3.8

Hi to all,

quick disclaimer: if this is the wrong mailing list, please let me know and accept my apologies. But I am not sure, if this is a bug or just me taking the wrong steps to build lldb. Feel free to suggest redirection.

I wanted to build the entire llvm 3.8 suite to explore some parallel goodies (OpenMP, CUDA). I downloaded a handful of llvm projects and packages:
cfe-3.8.0.src.tar.xz compiler-rt-3.8.0.src.tar.xz libcxxabi-3.8.0.src.tar.xz lld-3.8.0.src.tar.xz llvm-3.8.0.src.tar.xz polly-3.8.0.src.tar.xz
clang-tools-extra-3.8.0.src.tar.xz libcxx-3.8.0.src.tar.xz libunwind-3.8.0.src.tar.xz lldb-3.8.0.src.tar.xz openmp-3.8.0.src.tar.xz test-suite-3.8.0.src.tar.xz
and put them in the right place I hope (see tree output attached).

I then went:
$ cmake -DCMAKE_INSTALL_PREFIX=/foo/bar /path/to/llvm/source
$ make -jXX
#all goes well until here
$ make -jXX install
...
- Up-to-date: /home/steinbac/software/llvm/3.8/include/lldb/DataFormatters/FormattersContainer.h
-- Up-to-date: /home/steinbac/software/llvm/3.8/include/lldb/DataFormatters/TypeCategory.h
CMake Error at tools/lldb/scripts/cmake_install.cmake:36 (file):
   file INSTALL cannot find
   "/data/steinbac/llvm/llvm-3.8.0.build/lib/python2.7".
Call Stack (most recent call first):
   tools/lldb/cmake_install.cmake:42 (include)
   tools/cmake_install.cmake:43 (include)
   cmake_install.cmake:61 (include)

make: *** [install] Error 1

What am I missing?

Best,
Peter

PS. My system details:
$ lsb_release -a
LSB Version: :core-4.1-amd64:core-4.1-noarch:cxx-4.1-amd64:cxx-4.1-noarch:desktop-4.1-amd64:desktop-4.1-noarch:languages-4.1-amd64:languages-4.1-noarch:printing-4.1-amd64:printing-4.1-noarch
Distributor ID: CentOS
Description: CentOS Linux release 7.1.1503 (Core)
Release: 7.1.1503
Codename: Core
$ uname -a
Linux islay.mpi-cbg.de 3.10.0-229.20.1.el7.x86_64 #1 SMP Tue Nov 3 19:10:07 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
$ gcc --version
gcc (GCC) 4.8.3 20140911 (Red Hat 4.8.3-9)
Copyright (C) 2013 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

llvm_srctree_3levels.log (11.8 KB)

Hi Peter,

thank you for the report, you are writing to the right list.

Unfortunately, I am not aware of anyone in LLDB, who actually uses the
"make install" functionality, so it's very well possible that it's
broken. I can take a look at it, but I won't be able to do that for a
couple of weeks now. If you have some cmake experience you can try
digging around the lldb install scripts. I don't think the fix should
be difficult.

Until then, as a workaround I can recommend the following:
- if you just want to try out lldb, don't do a "make install", it
should run just fine from the build directory
- if you must do an "install", I guess you'll have to avoid checking
out lldb for now... :confused:

BTW, could you also send me the "tree diagram" of your build directory
as well? It might help me track the problem down when I get around to
it.

cheers,
pl

Hi Pavel,

thank you for jumping on this thread and giving this honest answer. I had a look at the build tree and indeed all binaries appear to be where they should be, i.e. build/bin, build/lib* and build/lib64/python2.7 etc. I'll do as you suggest and copy them to their final destination for now. I attached a 3 level tree dump to this mail of the build directory for completeness.

I am relying on "make install" as we do a homogeneous provisioning of custom packages on our cluster (through a parallel FS) and workstation infrastructure (through network mounts) for now.

If "make install" is not supported for now, I'd appreciate it if that would be documented somewhere.

Thanks -
Peter

llvm_buildtree_3levels.log (15.2 KB)

This is just a wild guess, but could you try running cmake with
-DLLVM_LIBDIR_SUFFIX=64. I remember we've had a need for that in the
past for systems which store libraries in lib64. Some provisions were
put in place to autodetect it, but i'm not sure if they completely
work.

-DLLVM_LIBDIR_SUFFIX=64 did the trick!
great -
Peter

Dear all,

as a follow-up, are there any plans to make lldb support CUDA, OpenCL or SPIR-V based platforms in the near future?

Best,
P