How do I remove a program that I have compiled from source using the ./configure; make; make install method? Does it matter whether I have kept the original directory that the source was stored in or not?
Answers:
Thank you for visiting the Q&A section on Magenaut. Please note that all the answers may not help you solve the issue immediately. So please treat them as advisements. If you found the post helpful (or not), leave a comment & I’ll get back to you as soon as possible.
Method 1
There are a couple of approaches that you can pursue.
- Re-run
./configurewith the same options you originally passed to it and then runmake uninstall. If you no longer have the original files, re-download the tarball of the corresponding version and use that. - Use
findorlocateto track down the relevant files (only really practicable for smaller programmes) and remove them manually.
To avoid this scenario again, you could always look at a tool like checkinstall for building from source and tracking the installed files; it was developed for precisely this reason:
A lot of people has asked me how can they remove from their boxes a program they compiled and installed from source. Some times -very few- the program’s author adds an uninstall rule to their Makefile, but that’s not usually the case. This is my primary reason to write CheckInstall. After you ./configure; make your program, CheckInstall will run make install (or whatever you tell it to run) and keep track of every file modified by this installation.
All methods was sourced from stackoverflow.com or stackexchange.com, is licensed under cc by-sa 2.5, cc by-sa 3.0 and cc by-sa 4.0