Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[solved] depclean wants to remove sys-devel/lld
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
jagdpanther
l33t
l33t


Joined: 22 Nov 2003
Posts: 756

PostPosted: Fri Nov 01, 2024 8:54 pm    Post subject: [solved] depclean wants to remove sys-devel/lld Reply with quote

As of yesterday 'emerge --depclean -p' states that it wants to remove sys-devel/lld:
Code:
>>> These are the packages that would be unmerged:

 app-doc/python-docs
    selected: 3.12.6
   protected: none
     omitted: 3.13.0

 sys-devel/lld-toolchain-symlinks
    selected: 18
   protected: none
     omitted: none

 sys-devel/lld
    selected: 18.1.8
   protected: none
     omitted: none


However it appears that my system still needs sys-devel/lld ...

Code:
$ equery depends sys-devel/lld
 * These packages depend on sys-devel/lld:
app-emulation/wine-vanilla-9.0 (sys-devel/lld)
app-office/libreoffice-24.2.6.2 (clang ? =sys-devel/lld-18*)
                                (=sys-devel/lld-17*)
                                (=sys-devel/lld-16*)
                                (=sys-devel/lld-15*)
dev-lang/rust-1.81.0 (wasm ? sys-devel/lld:18)
...
mail-client/thunderbird-128.4.0 (clang ? sys-devel/lld:17)
                                (clang ? sys-devel/lld:18)
                                (clang ? sys-devel/lld:19)
sys-apps/pciutils-3.13.0 (sys-devel/lld)
sys-devel/clang-18.1.8 (test ? ~sys-devel/lld-18.1.8)
sys-devel/clang-common-18.1.8-r3 (default-lld ? >=sys-devel/lld-18.1.8)
sys-devel/lld-toolchain-symlinks-18 (sys-devel/lld:18)
www-client/firefox-128.4.0 (clang ? sys-devel/lld:17)
                           (clang ? sys-devel/lld:18)
                           (clang ? sys-devel/lld:19)



Why does 'emerge --depclean' want to remove sys-devel/lld?


Last edited by jagdpanther on Fri Nov 01, 2024 10:38 pm; edited 1 time in total
Back to top
View user's profile Send private message
Hu
Administrator
Administrator


Joined: 06 Mar 2007
Posts: 22586

PostPosted: Fri Nov 01, 2024 9:55 pm    Post subject: Reply with quote

emerge --depclean wants to remove lld because nothing in @world needs (even recursively) lld to be installed. As we have been telling people a lot lately, don't trust equery, because it does not resolve conditional dependencies. It shows that you could need lld with the right USE flags or the right other conditional relations satisfied.
Back to top
View user's profile Send private message
eschwartz
Developer
Developer


Joined: 29 Oct 2023
Posts: 214

PostPosted: Fri Nov 01, 2024 9:57 pm    Post subject: Reply with quote

equery depends is inaccurate and returns inaccurate information.

Code:

# wine-vanilla

BDEPEND="
        || (
                sys-devel/binutils
                sys-devel/lld
        )


Code:

# libreoffice

BDEPEND="

        clang? (
                || (
                        (       sys-devel/clang:18
                                sys-devel/llvm:18
                                =sys-devel/lld-18*      )
                        (       sys-devel/clang:17
                                sys-devel/llvm:17
                                =sys-devel/lld-17*      )
                        (       sys-devel/clang:16
                                sys-devel/llvm:16
                                =sys-devel/lld-16*      )
                        (       sys-devel/clang:15
                                sys-devel/llvm:15
                                =sys-devel/lld-15*      )
                )


Code:

# thunderbird

BDEPEND="${PYTHON_DEPS}
        $(llvm_gen_dep '
                sys-devel/clang:${LLVM_SLOT}
                sys-devel/llvm:${LLVM_SLOT}
                clang? (
                        sys-devel/lld:${LLVM_SLOT}
                        virtual/rust:0/llvm-${LLVM_SLOT}
                        pgo? ( sys-libs/compiler-rt-sanitizers:${LLVM_SLOT}[profile] )
                )
        ')


Code:

# pciutils

# See bug #847133 re binutils check
BDEPEND="
        || ( >=sys-devel/binutils-2.37:* sys-devel/lld sys-devel/native-cctools )


As you can see, in all these cases lld is not required as it is either conditional on USE flag, exists in an "any-of" group, or both.

I haven't checked all your examples -- all I did was check and explain a sample of them -- but I am sure you will find the rest have the same pattern.

emerge --depclean removes packages if it is possible to do so, it is possible in these cases, so there you have it. But in some cases if you had built with USE=clang it might have kept lld. ;)
Back to top
View user's profile Send private message
jagdpanther
l33t
l33t


Joined: 22 Nov 2003
Posts: 756

PostPosted: Fri Nov 01, 2024 10:37 pm    Post subject: Reply with quote

Thank you.

I let 'emerge --depclean' remove sys-devel/lld and those listed apps in my original post still work without issue.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum