This has led to a bit of debate on IRC, so I would like to start by proposing my two base assumptions: 1. I understand that `emerge -uD world` means > "Update (-u) all installed (-D world) packages." 2. Implicitly, a package manager should respect > "Only compile/install things which are needed." If we take these two assumptions, then `emerge -uD --with-bdeps=y world` does the wrong thing, whenever there are bdeps of installed packages which are absent from the system (possible reasons include: a package has been installed as binpkg, the bdeps have been depcleaned for diskspace reasons, etc.). `emerge -uD --with-bdeps=y` will not only update currently installed bdeps (as the command implies), but also newly install all bdeps which are currently not installed, even if their dependees are not being compiled. That can lead to whole toolchains being compiled needlessly (in my example the buildtime chain of firefox with nodejs and clang).
Created attachment 891311 [details] emerge -uDpqt --with-bdeps=y world As a concrete example of this, take www-client/firefox-125.0.1 with all its bdeps missing (reason: installed from a binpkg), installed. Attached is the output of `emerge -uD --with-bdeps=y`, the clang toolchain is pulled in without need. Also attached is the "attempted workaround" `emerge -uD --with-deps=n` (skips the update of dev-python/hatchling).
Created attachment 891312 [details] emerge -uDpqt --with-bdeps=n world
> 1. I understand that `emerge -uD world` means > "Update (-u) all installed (-D world) packages." Incorrect. A more precise definition. Update (-u) all members of the @world set, along with any direct or indirect dependencies (-D). Updating dependencies of the @world set does not mean all installed packages. There may be packages installed which are not included in @world and which would be removed by emerge --depclean. Also, there may be packages in @world which are not currently installed. The --with-bdeps flag controls which dependency classes are included by -D. That's it. > 2. Implicitly, a package manager should respect > "Only compile/install things which are needed." This assumption doesn't really mean anything without defining "needed". The --with-bdeps flag alters the definition of "needed" in this context.