Simple. Just change DEPEND to RDEPEND so emerge --depclean works properly. Otherwise, it tries to uninstall all the packages.
which portage version ?
from portage manpage RDEPEND This should contain a list of all packages that are required for this program to run (aka runtime depend). If this is not set, then it defaults to the value of DEPEND.
i dont see your bug ... dep-clean removes everything that is not needed by packages in the world/system for runtime ...
err nm, i didnt see the summary change
I'll try to clarify. If you emerge xfce4-base it installs all of the basic components of XFCE4. However these are installed as depend not rdepend. Therefore if you do emerge --depclean, portage tries to remove all the packages including the window manager. Since it is a base package it should be RDEPEND.
How did you notice they are not installed as RDEPEND (they are listed as such in /var/db/pkg for me) ? I can confirm the bug but not the solution.
I just ran --depclean and it tried to remove them, so I took a look at the ebuild. I figured that was the problem so I changed it in my directory and it solved the problem. I also have a habit of editing the wrapper ebuilds.
see bug #30998. same issue
xfce4-base: Change DEPEND to RDEPEND so emerge --depclean works
*** Bug 30998 has been marked as a duplicate of this bug. ***
ok, so rdiff also shows this
Hmm, adding RDEPEND="${DEPEND}" didn't work here (I didn't re-emerge xfce4-base as RDEPEND in /var/db/pkg was already correct), neither did changing DEPEND to RDEPEND. I tried it with the ebuild in PORTDIR and the one in /var/db/pkg, emerge --depclean -p always shows the xfce4-base dependencies. Also bug 30998 seems unrelated to this bug for me. And DEPEND="${RDEPEND}" would be the reverse of the current description, so I assume this was a typo. As I said, I can confirm the problem, but not the cause/solution.
The fix no longer works on my system (the original reporter). In /var/db/pkg all deps are listed as RDEPEND.
2.0.49-r16 seems to fix this
This (or something vaguely resembling this) was fixed a while back.