To build vim from source on Ubuntu:
$ sudo apt-get build-dep vim-gnomeor similar.
$ ./configure. You can customize the build (and enable Perl, Python, etc. language integrations) by passing configuration options. See
src/INSTALLfor an overview.
$ 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
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.