Cleaning CMake installed files

2019-02-06 16:02发布

问题:

I have some executables/libraries being placed into the system paths using CMake's "install" keyword. Is there a built-in mechanism to do something like a "distclean", where all installed files are removed?

Endless Google searches have repeatedly turned-up conversations where the responses always mention "rm -fr " if the question mentions "cmake" and "cleanup", without reading it more closely.

回答1:

There should be file "install_manifest.txt" after executing "make install". The following command should work:

cat install_manifest.txt | sudo xargs rm


标签: cmake