Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 793866

Summary: dev-util/lldb-12.0.0 automagic dependency on dev-lang/lua
Product: Gentoo Linux Reporter: Alessandro Barbieri <lssndrbarbieri>
Component: Current packagesAssignee: LLVM support project <llvm>
Status: RESOLVED FIXED    
Severity: normal CC: ionen
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 879535    
Attachments: lldblink
info
lldb REQUIRES

Description Alessandro Barbieri 2021-06-02 10:37:16 UTC
lldb doesn't have dev-lang/lua as dependency but it link to liblua5.3.so.0
Comment 1 Alessandro Barbieri 2021-06-02 10:37:57 UTC
Created attachment 713274 [details]
lldblink

ldd output
Comment 2 Alessandro Barbieri 2021-06-02 10:39:17 UTC
Created attachment 713277 [details]
info

emerge --info
Comment 3 Ionen Wolkens gentoo-dev 2021-06-03 01:10:05 UTC
(In reply to Alessandro Barbieri from comment #1)
> Created attachment 713274 [details]
> lldblink
> 
> ldd output
Don't use ldd for this given it'll also show libraries linked with dependencies (e.g. not directly used by this), use `scanelf -n`, or even read /var/db/pkg/<cat>/<pkg>/REQUIRES for all files installed by a package.

Is lua still there then?

You may like "lddtree" to see which library is using what too.
Comment 4 Alessandro Barbieri 2021-06-03 09:27:50 UTC
Created attachment 713409 [details]
lldb REQUIRES
Comment 5 Alessandro Barbieri 2021-06-03 09:28:58 UTC
lddtree (which lldb)
/usr/bin/lldb (interpreter => /lib64/ld-linux-x86-64.so.2)
    libpthread.so.0 => /lib64/libpthread.so.0
    liblldb.so.12 => /usr/lib64/liblldb.so.12
        libpython3.8.so.1.0 => /usr/lib64/libpython3.8.so.1.0
            libutil.so.1 => /lib64/libutil.so.1
        liblua5.3.so.0 => /usr/lib64/liblua5.3.so.0
        libncurses.so.6 => /lib64/libncurses.so.6
        libtinfo.so.6 => /lib64/libtinfo.so.6
        libpanel.so.6 => /usr/lib64/libpanel.so.6
        libxml2.so.2 => /usr/lib64/libxml2.so.2
            libicuuc.so.69 => /usr/lib64/libicuuc.so.69
                libicudata.so.69 => /usr/lib64/libicudata.so.69
            libz.so.1 => /lib64/libz.so.1
        liblzma.so.5 => /lib64/liblzma.so.5
        libedit.so.0 => /lib64/libedit.so.0
        libdl.so.2 => /lib64/libdl.so.2
        libclang-cpp.so.12 => /usr/lib/llvm/12/lib64/libclang-cpp.so.12
        libm.so.6 => /lib64/libm.so.6
    libLLVM-12.so => /usr/lib/llvm/12/lib64/libLLVM-12.so
        libffi.so.7 => /usr/lib64/libffi.so.7
        libz3.so.4.8 => /usr/lib64/libz3.so.4.8
            libgmp.so.10 => /usr/lib64/libgmp.so.10
    libstdc++.so.6 => /usr/lib/gcc/x86_64-pc-linux-gnu/10.2.0/libstdc++.so.6
    libgcc_s.so.1 => /usr/lib/gcc/x86_64-pc-linux-gnu/10.2.0/libgcc_s.so.1
    libc.so.6 => /lib64/libc.so.6
Comment 6 Eugene Shalygin 2022-06-14 13:54:24 UTC
Same with dev-util/lldb-14.0.5
Comment 7 ayuayuayu 2022-06-15 07:58:20 UTC
from https://lldb.llvm.org/resources/build.html
> Optional Dependencies
> [...]
> By default they are auto-detected: if CMake can find the dependency
> it will be used. It is possible to override this behavior by setting
> the corresponding CMake flag to On or Off to force the dependency
> to be enabled or disabled. When a dependency is set to On and
> can’t be found it will cause a CMake configuration error.
among the optional dependencies listed is LLDB_ENABLE_LUA .

from what i can tell, lua support began in 10.0.0 .

at a minimum, one could add "LUA_COMPAT=( lua5-3 )", inherit lua-single, "-DLLDB_ENABLE_LUA=$(usex lua)" to src_configure, and something like "${LUA_DEPS} lua? ( >=dev-lang/swig-3.0.11 )" to BDEPEND .
i do not feel i am familiar enough with portage's lua eclasses and lldb's lua-related cmake knobs to provide a proper ebuild diff/patch.
(for example, src_configure has "-DPython3_EXECUTABLE=\"${PYTHON}\"", but i am not sure what the lua analogue is, or if it even exists.)
Comment 8 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-11-18 07:31:35 UTC
Fixed in bug 879535.