下载 Vim,Lua,LuaJIT
wget ftp://ftp.vim.org/pub/vim/unix/vim-8.0.tar.bz2
wget http://www.lua.org/ftp/lua-5.3.3.tar.gz
wget http://luajit.org/download/LuaJIT-2.0.4.tar.gz
解压
tar jxvf xxx.tar.bz2
tar zxvf xxx.tar.gz
编译安装 Lua
cd lua-5.3.3
make linux test
sudo make install
编译安装 LuaJIT
cd luajit-2.0.4
make
sudo make install
查看 Lua 与 LuaJIT 所在文件夹
默认安装文件夹为/usr/local
编译安装 Vim
cd vim-8.0
./configure --with-features=huge \
--without-x \
--disable-nls \
--enable-gui=no \
--enable-cscope \
--enable-largefile \
--disable-netbeans \
--enable-multibyte \
--with-tlib=ncurses \
--enable-pythoninterp \
--with-python-config-dir=/usr/lib64/python2.7/config \
--enable-rubyinterp \
--enable-luainterp \
--with-lua-prefix=/usr/local \
--with-luajit=yes \
--enable-fail-if-missing
make
sudo make install
指定 LD_LIBRARY_PATH
export LD_LIBRARY_PATH=/usr/local/lib:${LD_LIBRARY_PATH}
为新安装的 Vim 创建别名
alias vim='/usr/local/bin/vim'
alias vi='/usr/local/bin/vim'