(1): Before installing the new version of Vim, you need to uninstall the old version of Vim, and then execute the following commands under Terminal:
sudo apt-get remove vim sudo apt-get remove vim-runtime sudo apt-get remove gvim sudo apt-get remove vim-tiny sudo apt-get Remove vim-common sudo apt-get Remove Vim-gui-common
(2): Download the installation package:
TAR-XJVF vim-7.4. tar.bz2
(3): Set the Vim source code compilation properties
CD./vim74/src
./configure--prefix=/usr/local/--with-features=--enable-pythoninterp--enable--- Enable-rubyinterp--enable---enable-multibyte--enable-sniff--enable---with-features= --enable---enable---enable---enable---enable---enable- --enable-cscope
You need to reconfigure the input make distclean
#清理一下上一次编译生成的所有文件
The parameters are described as follows:
--prefix=/usr/local/Vim74: compiling the installation path
- --with-features=huge: Supports maximum features
- --ENABLE-PYTHONINTERP: Enable vim for Python-written plug-in support
- --enable-perlinterp: Enable VIM to support Perl-written plugins
- --enable-rubyinterp: Enable VIM to support Ruby-written plugins
- --ENABLE-LUAINTERP: Enable VIM for LUA-written plug-in support
- --enable-multibyte: Multi-byte support can input Chinese in vim
--
enable
-sniff:Vim状态提示 提示Vim当前处于INSERT、NORMAL、VISUAL哪种模式
- --enable-cscope:vim Support for Cscope
- --ENABLE-GUI=GTK2:GTK2 support, you can also use GNOME to represent the build Gvim
Make && make instal
(4): Add search Path
Add the path to/etc/profile or ~/.bash_profile, and in path plus the command search path, you will need to log out after adding.
nano/etc/ Profile4 if["' Id-u '"-eq0 ]; Then5Path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/vim74/bin" 6 Else 7Path="/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games:/usr/local/vim74/bin" 8fi9Export PATH
.
Vim 7.4 Compilation installation