LoginSignup
27
28

More than 5 years have passed since last update.

vim7.4をソースからインストール

Last updated at Posted at 2013-11-08

最新版を取得

wget http://ftp.vim.org/pub/vim/unix/vim-7.4.tar.bz2
tar jxvf vim-7.4.tar.bz2
cd vim74/

パッチ用のディレクトリを作成

mkdir patches
cd patches/

パッチを取得(2013/10/16時点)

seq -f http://ftp.vim.org/pub/vim/patches/7.4/7.4.%03g 052 | xargs wget
cd ..

パッチをあてる

cat patches/7.4.* | patch -p0

src/Makfileを修正

これをやらないとsedが戻らなくなる
http://www40.atwiki.jp/hirukiyo/m/pages/18.html

インストール

# インストール先を/usr/local/vim74にして、古いvimも共存させる。
# リモートホストのvimを使う想定。
./configure --prefix=/usr/local/vim74 --disable-selinux --enable-multibyte --with-features=huge --enable-pythoninterp --disable-netbeans --enable-perlinterp --disable-xsmp-interact --disable-xsmp --without-x --disable-gui

# コンパイル
make

# makeでperl関連のエラーが出たら以下
yum -y install perl-ExtUtils-Embed

# インストール
make install

古いvimと入れ替え

※ コメントでiwaimさんが言っているように環境変数変えたほうが良いと思う。

prefix指定なしでconfigureしていればこの手順はいらないと思う。

# 古いvimをmv
mv /usr/bin/vim /usr/bin/vim72

# 新しいvimをパスに入れる
ln -s /usr/local/vim74/bin/vim /usr/bin/vim
27
28
3

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
27
28