To build vim from source on Ubuntu:
$ sudo apt-get build-dep vim-gnome or similar.cd vim/src$ ./configure. You can customize the build (and enable Perl, Python, etc. language integrations) by passing configuration options. See src/INSTALL for an overview.$ make.$ sudo make install. As your self-compiled Vim is not managed by the package manager, it will be placed in /usr/local/bin/vim, instead of /usr/bin/vim. So, to run it, you either need to specify the full path, or ensure that /usr/local/bin is before /usr/bin in your PATH (it usually is).$ sudo apt-get remove vim vim-runtime gvim.To verify the installation, you can run $ which vim which should return something like /usr/local/bin/vim if the installation was successful.