I searched an answer to this question: How to uninstall a package that is not tracked by pacman. Probably an incorrectly installed package. But despite studying a lot of posts on various forums could not figure out how to solve it exactly.
So there is the following package called calibre which is not recognized by pacman:
pacman -Q --info calibre
error: package 'calibre' was not found
Since I don’t remember how it was installed, it seems the only way to remove it would be delete it manually?
Is it possible to remove it from the system by running a command that deletes all files and folders that contain the string “calibre”, then use pacman to delete resulting orphan packages?
For example using the command:
rm *\calibre*
we can delete the package calibre, right? Is this ok?
If so, uninstall instructions are documented there as well:
You can uninstall calibre by running sudo calibre-uninstall. Alternately, simply deleting the installation folder will remove 99% of the installed files.
It is quite likely that you ran an isolation install. As in you installed calibre by running this command:
wget -nv -O- https://download.calibre-ebook.com/linux-installer.sh | sh /dev/stdin install_dir=~/calibre-bin isolated=y
Yes. An isolated install is a self-contained installation, which means every binary and library file required for calibre to run is packaged inside that directory.
This directory is simply to store files related to your calibre library (all your books will be kept inside this directory).
There is no correct way to globally remove a package that wasn’t installed with pacman. You have to use the method you installed it with to remove it if possible. If not then other methods of removing it such as removing the directory that it resides in.
So, after deleting the calibre-bin folder in home/user/ directory I ran
pacman -Qtdq
and it returned no orphans. But it seems there should be a lot of extra packages tied to calibre, that wre installed because calibre depended on them? How to remove them now?
Maybe not. If you removed the folders containing the calibre-bin and calibre library i don’t think i would be that concerned about some left over files. If you don’t know where they reside and the computer is functioning properly then i don’t see a reason to be worried.
There seems to be some kind of misunderstanding here. Why would you run this command to check for leftovers when you never installed calibre with pacman to begin with?
Like I mentioned earlier, if you did an isolated installation (see the comment above), the installer script will just jam everything (binary executables and the required .so files inside the calibre-bin directory. Once you’ve deleted that directory, the calibre package is gone, and that’s it.