0
votes

For a uni course, I had to git clone a repo and build it (including monstrosities in the between) and then I had to install it. However, my teacher isn't very good, and the tool is pretty bad (or at least useless for my computer) and I want to revert make install. How do I do that ?

I forgot to do it in a virtual machine or in a docker container sadly :(

Thankies

2

2 Answers

2
votes

You should use the make uninstall command in the build directory. The cleaner way being make uninstall-recursiveif possible. Then do not forget to remove all sources with the rm -rf command.

0
votes

gmake helpfully can tell you what it would do for a given action. The result is text, which can be translated with sed/awk/perl into other commands. For example, if make install does multiple cp <files> <destdir>/ commands, then the following action deletes all those files from each destdir:

MAKEFLAGS= ${MAKE} -j1 -spinf $(word 1,${MAKEFILE_LIST}) install \ | awk '/^cp /{ for (i=NF; --i>0;){print $NF"/"$i} }' | xargs rm -f