checkinstall后手动删除vim

checkinstall后手动删除vim

我下载了这个 Vim发布并在 Ubuntu 16.04 上解压缩 tarball。然后我切换到 vim 目录并运行sudo checkinstall,程序最终为:

Makefile:2412: recipe for target 'installpack' failed
make[1]: *** [installpack] Error 1
make[1]: Leaving directory '/home/mudde/Downloads/vim-8.0.0326/src'
Makefile:36: recipe for target 'install' failed
make: *** [install] Error 2

****  Installation failed. Aborting package creation.

Restoring overwritten files from backup...OK

Cleaning up...OK

Bye.

它提到有错误,但我可以开始/usr/local/bin/vim

vim --version
VIM - Vi IMproved 8.0 (2016 Sep 12, compiled Feb 12 2017 19:18:51)
Included patches: 1-326

现在我想删除它,但使用包管理器不起作用

sudo apt-get remove vim
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package 'vim' is not installed, so not removed
The following packages were automatically installed and are no longer required:
  feh libexif12 libjpeg-progs libjpeg9 linux-headers-4.4.0-57 linux-headers-4.4.0-57-generic
  linux-image-4.4.0-57-generic linux-image-extra-4.4.0-57-generic lua-lgi menu rlwrap
  vim-gui-common vim-runtime
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 62 not upgraded.

如何手动删除vim?我可以删除所有文件和目录,还是应该排除一些文件和目录,或者另一方面,我是否错过了某些内容?

$ sudo find /etc /usr /lib /var -name "*vim*" -prune
/etc/vim
/usr/share/man/man5/apparmor.vim.5.gz
/usr/share/man/man5/vim-registry.5.gz
/usr/share/man/it/man1/vimdiff.1.gz
/usr/share/man/it/man1/vim.1.gz
/usr/share/man/it/man1/rvim.1.gz
/usr/share/man/it/man1/gvim.1.gz
/usr/share/man/it/man1/gvimtutor.1.gz
/usr/share/man/it/man1/evim.1.gz
/usr/share/man/it/man1/gvimdiff.1.gz
/usr/share/man/it/man1/rgvim.1.gz
/usr/share/man/it/man1/vimtutor.1.gz
/usr/share/man/fr/man1/vimdiff.1.gz
/usr/share/man/fr/man1/vim.1.gz
/usr/share/man/fr/man1/rvim.1.gz
/usr/share/man/fr/man1/gvim.1.gz
/usr/share/man/fr/man1/gvimtutor.1.gz
/usr/share/man/fr/man1/evim.1.gz
/usr/share/man/fr/man1/gvimdiff.1.gz
/usr/share/man/fr/man1/rgvim.1.gz
/usr/share/man/fr/man1/vimtutor.1.gz
/usr/share/man/pl/man1/vimdiff.1.gz
/usr/share/man/pl/man1/vim.1.gz
/usr/share/man/pl/man1/rvim.1.gz
/usr/share/man/pl/man1/gvim.1.gz
/usr/share/man/pl/man1/gvimtutor.1.gz
/usr/share/man/pl/man1/evim.1.gz
/usr/share/man/pl/man1/gvimdiff.1.gz
/usr/share/man/pl/man1/rgvim.1.gz
/usr/share/man/pl/man1/vimtutor.1.gz
/usr/share/man/ru/man1/vimdiff.1.gz
/usr/share/man/ru/man1/vim.1.gz
/usr/share/man/ru/man1/rvim.1.gz
/usr/share/man/ru/man1/gvim.1.gz
/usr/share/man/ru/man1/gvimtutor.1.gz
/usr/share/man/ru/man1/evim.1.gz
/usr/share/man/ru/man1/gvimdiff.1.gz
/usr/share/man/ru/man1/rgvim.1.gz
/usr/share/man/ru/man1/vimtutor.1.gz
/usr/share/man/ja/man1/vimdiff.1.gz
/usr/share/man/ja/man1/vim.1.gz
/usr/share/man/ja/man1/rvim.1.gz
/usr/share/man/ja/man1/gvim.1.gz
/usr/share/man/ja/man1/gvimtutor.1.gz
/usr/share/man/ja/man1/evim.1.gz
/usr/share/man/ja/man1/gvimdiff.1.gz
/usr/share/man/ja/man1/rgvim.1.gz
/usr/share/man/ja/man1/vimtutor.1.gz
/usr/share/man/man1/vimdiff.1.gz
/usr/share/man/man1/vim.1.gz
/usr/share/man/man1/rvim.1.gz
/usr/share/man/man1/vim-addon-manager.1.gz
/usr/share/man/man1/vim-addons.1.gz
/usr/share/man/man1/vimdot.1.gz
/usr/share/man/man1/gvim.1.gz
/usr/share/man/man1/gvimtutor.1.gz
/usr/share/man/man1/evim.1.gz
/usr/share/man/man1/gvimdiff.1.gz
/usr/share/man/man1/rgvim.1.gz
/usr/share/man/man1/vimtutor.1.gz
/usr/share/lintian/overrides/vim-common
/usr/share/lintian/overrides/vim-gui-common
/usr/share/doc/vim-common
/usr/share/doc/vim-addon-manager
/usr/share/doc/vim-gui-common
/usr/share/doc/vim-runtime
/usr/share/doc/mercurial-common/examples/vim
/usr/share/bash-completion/completions/vim-addon-manager
/usr/share/pixmaps/vim-32.xpm
/usr/share/pixmaps/vim-16.xpm
/usr/share/pixmaps/vim-48.xpm
/usr/share/pixmaps/gvim.svg
/usr/share/applications/vim.desktop
/usr/share/applications/gvim.desktop
/usr/share/icons/hicolor/48x48/apps/gvim.png
/usr/share/icons/hicolor/scalable/apps/gvim.svg
/usr/share/icons/locolor/32x32/apps/gvim.png
/usr/share/icons/locolor/16x16/apps/gvim.png
/usr/share/vim
/usr/share/rubygems-integration/all/specifications/vim-addon-manager-0.5.3.gemspec
/usr/share/cmake-3.5/editors/vim
/usr/share/gettext/styles/po-vim.css
/usr/bin/vim-addon-manager
/usr/bin/vim-addons
/usr/bin/vimdot
/usr/bin/gvimtutor
/usr/bin/vimtutor
/usr/lib/mime/packages/vim-common
/usr/lib/mime/packages/vim-gui-common
/usr/lib/ruby/vendor_ruby/vim
/usr/lib/git-core/mergetools/vimdiff2
/usr/lib/git-core/mergetools/vimdiff
/usr/lib/git-core/mergetools/vimdiff3
/usr/lib/git-core/mergetools/gvimdiff
/usr/lib/git-core/mergetools/gvimdiff2
/usr/lib/git-core/mergetools/gvimdiff3
/usr/src/linux-headers-4.4.0-57-generic/include/config/video/vim2m.h
/usr/src/linux-headers-4.4.0-59-generic/include/config/video/vim2m.h
/usr/src/linux-headers-4.4.0-62-generic/include/config/video/vim2m.h
/usr/local/share/awesome/lib/awful/hotkeys_popup/keys/vim.lua
/usr/local/share/man/man1/vim.1
/usr/local/share/man/man1/vimtutor.1
/usr/local/share/man/man1/vimdiff.1
/usr/local/share/man/man1/evim.1
/usr/local/share/doc/awesome/doc/libraries/awful.hotkeys_popup.keys.vim.html
/usr/local/share/vim
/usr/local/bin/vim
/usr/local/bin/vim.rm
/usr/local/bin/vimtutor
/lib/modules/4.4.0-57-generic/kernel/drivers/media/platform/vim2m.ko
/lib/modules/4.4.0-59-generic/kernel/drivers/media/platform/vim2m.ko
/lib/modules/4.4.0-62-generic/kernel/drivers/media/platform/vim2m.ko
/var/lib/dpkg/info/vim-common.list
/var/lib/dpkg/info/vim-common.conffiles
/var/lib/dpkg/info/vim-common.preinst
/var/lib/dpkg/info/vim-common.md5sums
/var/lib/dpkg/info/vim-addon-manager.list
/var/lib/dpkg/info/vim-addon-manager.prerm
/var/lib/dpkg/info/vim-addon-manager.md5sums
/var/lib/dpkg/info/vim-addon-manager.preinst
/var/lib/dpkg/info/vim-addon-manager.postinst
/var/lib/dpkg/info/vim-addon-manager.postrm
/var/lib/dpkg/info/vim-latexsuite.postrm
/var/lib/dpkg/info/vim-latexsuite.list
/var/lib/dpkg/info/vim-gui-common.list
/var/lib/dpkg/info/vim-gui-common.conffiles
/var/lib/dpkg/info/vim-gui-common.md5sums
/var/lib/dpkg/info/vim-runtime.list
/var/lib/dpkg/info/vim-runtime.postrm
/var/lib/dpkg/info/vim-runtime.postinst
/var/lib/dpkg/info/vim-runtime.preinst
/var/lib/dpkg/info/vim-runtime.md5sums
/var/lib/dpkg/info/vim-tiny.list
/var/lib/vim
/var/cache/apt/archives/vim-runtime_2%3a7.4.1689-3ubuntu1.2_all.deb
/var/cache/apt/archives/vim_2%3a7.4.1689-3ubuntu1.2_amd64.deb
/var/cache/apt/archives/vim-addon-manager_0.5.5_all.deb
/var/cache/apt/archives/vim-latexsuite_20141116.812-2_all.deb
/var/cache/apt/archives/vim-gui-common_2%3a7.4.1689-3ubuntu1.2_all.deb
/var/cache/apt/archives/vim-gtk_2%3a7.4.1689-3ubuntu1.2_amd64.deb

答案1

checkinstallDebian 方式使 Debian 软件包管理器了解您可以通过configure和构建的软件包make && make install。显然,安装过程中出现了问题checkinstall,并且您的构建未正确注册为已安装的软件包。

您可以通过多种方式卸载该软件。有些软件包提供目标uninstall(即make uninstall)。如果没有,您必须手动删除相应的文件。使用find和寻找合适的-mtime-mmin可能是最有前途的。如果没有,您可以将 vim 安装到临时基目录中,并使用结果作为模式来搜索要删除的文件。

答案2

您没有通过包管理器安装 vim,因此您将无法通过这种方式卸载它。查找/usr/local会让您变得简单,因为vim不会安装很多文件。

相关内容