Post History
In Debian-based distributions, one can update the system with apt upgrade and cleanup unused dependencies with apt autoremove. Period. On Gentoo that is apparently not as straightforward. From G...
#2: Post edited
- In Debian-based distributions, one can update the system with `apt upgrade` and
- cleanup unused dependencies with `apt autoremove`. Period.
- On Gentoo that is apparently not as straightforward. From
- [Gentoo Cheat Sheet: Package removal][1]:
- > The recommended way to remove a package is by using `emerge --deselect`. This
- > removes the specified package from the @world set (i.e. says the package is no
- > longer wanted). To clean up the system afterwards, run depclean as given below.
- >
- > emerge --ask --depclean
- >
- > As a safety measure, depclean will not remove any packages unless all
- > required dependencies have been resolved. As a consequence of this, it often
- > becomes necessary to run:
- >
- > emerge --ask --verbose --update --newuse --deep @world
- I understand `emerge --deselect` and `emerge --depclean`; Together they work
- as `apt remove --autoremove`.
- I do not understand the last paragraph though. What does "depclean will not remove any
- packages unless all required dependencies have been resolved" mean exactly?
- Surely enough depclean won't remove dependencies currently in use. Why is it
- necessary to run the *update* command then? What does it have to do with
- package *removal*?
- [1]: https://wiki.gentoo.org/wiki/Gentoo_Cheat_Sheet#Package_removal
- In Debian-based distributions, one can update the system with `apt upgrade` and
- cleanup unused dependencies with `apt autoremove`. Period.
- On Gentoo that is apparently not as straightforward. From
- [Gentoo Cheat Sheet: Package removal][1]:
- > The recommended way to remove a package is by using `emerge --deselect`. This
- > removes the specified package from the @world set (i.e. says the package is no
- > longer wanted). To clean up the system afterwards, run depclean as given below.
- >
- > emerge --ask --depclean
- >
- > As a safety measure, depclean will not remove any packages unless all
- > required dependencies have been resolved. As a consequence of this, it often
- > becomes necessary to run:
- >
- > emerge --ask --verbose --update --newuse --deep @world
- I understand `emerge --deselect` and `emerge --depclean`; Together they work
- as `apt remove --autoremove`.
- I do not understand the last paragraph though. What does "depclean will not remove any
- packages unless all required dependencies have been resolved" mean exactly?
- Surely enough depclean won't remove dependencies currently in use. Why is it
- necessary to run the *update* command then? What does it have to do with
- package *removal*?
- The [Emerge manual][2] was not of much enlightening here; It actually employs the very same wording.
- [1]: https://wiki.gentoo.org/wiki/Gentoo_Cheat_Sheet#Package_removal
- [2]: https://dev.gentoo.org/~zmedico/portage/doc/man/emerge.1.html
#1: Initial revision
What does `emerge --update --newuse --deep @world` have to do with package removal?
In Debian-based distributions, one can update the system with `apt upgrade` and cleanup unused dependencies with `apt autoremove`. Period. On Gentoo that is apparently not as straightforward. From [Gentoo Cheat Sheet: Package removal][1]: > The recommended way to remove a package is by using `emerge --deselect`. This > removes the specified package from the @world set (i.e. says the package is no > longer wanted). To clean up the system afterwards, run depclean as given below. > > emerge --ask --depclean > > As a safety measure, depclean will not remove any packages unless all > required dependencies have been resolved. As a consequence of this, it often > becomes necessary to run: > > emerge --ask --verbose --update --newuse --deep @world I understand `emerge --deselect` and `emerge --depclean`; Together they work as `apt remove --autoremove`. I do not understand the last paragraph though. What does "depclean will not remove any packages unless all required dependencies have been resolved" mean exactly? Surely enough depclean won't remove dependencies currently in use. Why is it necessary to run the *update* command then? What does it have to do with package *removal*? [1]: https://wiki.gentoo.org/wiki/Gentoo_Cheat_Sheet#Package_removal