How to remove dependencies installed from .deb files?
I am unable to remove dependencies installed from .deb files. For example, I downloaded the .deb files for vlc and its dependencies with the command 'sudo apt --download-only install vlc'. I can install vlc and its dependencies with 'sudo dpkg -i *.deb', and i can remove vlc with 'sudo dpkg -r vlc', but this doesn't remove its dependencies. And 'sudo apt autoremove' doesn't remove them also.
|
If you can verify that they are no longer needed (see deborphan) you can remove them by name.
Why install from the deb file rather than directly using apt? Why do you WANT to remove them? |
Quote:
Yes, this can happen with optional dependencies, called "Install Recommends" in Debian-speak. It is possible to tell apt to not install recommends at all. What dependencies did vlc pull in? BTW, don't use dpkg unless absolutely necessary. Why couldn't you just 'apt install vlc'? |
Quote:
Code:
vlc-plugin-notify_3.0.11-0+deb10u1_amd64.deb I don't want to have residual packages on my system. |
Quote:
|
How did you install these dependencies?
If manually, then apt doesn't see them as dependencies at all because you installed them yourself. You have to then equally manually uninstall them. It's possible to install offline with apt, too. Recommended, less chance to break your system. |
Quote:
Code:
sudo dpkg --remove vlc-plugin-notify_3.0.11-0+deb10u1_amd64.deb libixml10_1%3a1.8.4-2_amd64.deb libxcb-xv0_1.13.1-2_amd64.deb libupnp13_1%3a1.8.4-2_amd64.deb vlc-l10n_3.0.11-0+deb10u1_all.deb libgroupsock8_2018.11.26-1.1_amd64.deb vlc-data_3.0.11-0+deb10u1_all.deb libvlc5_3.0.11-0+deb10u1_amd64.deb vlc-plugin-video-splitter_3.0.11-0+deb10u1_amd64.deb vlc-plugin-visualization_3.0.11-0+deb10u1_amd64.deb libsidplay2_2.1.1-15_amd64.deb libaribb24-0_1.0.3-2_amd64.deb libresid builder0c2a_2.1.1-15_amd64.deb libdvbpsi10_1.3.2-1_amd64.deb libproxy-tools_0.4.15-5_amd64.deb vlc-plugin-qt_3.0.11-0+deb10u1_amd64.deb vlc_3.0.11-0+deb10u1_amd64.deb libmatroska6v5_1.4.9-1+deb10u1_amd64.deb liblirc-client0_0.10.1-5.2_amd64.deb vlc-plugin-skins2_3.0.11-0+deb10u1_amd64.deb |
Quote:
|
Quote:
But i think i found how to install dependency automatically when i am offline. I tested that with other application - geany, because i can't do that with vlc anymore. If i run 'sudo apt install geany' it installs only two packages - geany and geany-common. So, i downloaded the packages with 'sudo apt --download-only geany', then disconnected from internet and run 'sudo apt install geany' and this installed the application. After that i removed geany with 'sudo apt remove geany' and when i run 'sudo apt autoremove' it removed geany-common also. So, i guess if i am offline and want to install deb packages i better copy them to /var/cache/apt/archive and run 'sudo apt install packname'. This way the dependencies will be installed automatically and after that can be removed with 'apt autoremove'. |
Quote:
This doesn't work, i already tried it. It's probably because the packages are installed with different names. |
Quote:
Code:
fcitx-frontend-qt5 |
Those packages are not dependencies of anything else. You should know better than us if you need them. If you don't know what they are then you probably can remove them.
|
Quote:
It has the advantage that you allow apt to take full care of your package management which is highly recommended on a Debian system. |
All times are GMT -5. The time now is 01:23 AM. |