vim7

UnixやLinuxでは定番とも言えるテキストエディタである「vi(vim)」の最新版「vim7」がリリースされた。(と言っても、リリースされて結構経つんだけど・・・)
色々と新機能が追加されたみたいなので、一度使ってみようと思い、サーバにインストール。・・・してみようとしたがエラーが出てしまい、インストールできない。試しにvim6.4も試してみたが同じエラーが出る。下記はmake時に出たエラー。(vim6.4をmakeした時のもの)

[root@localhost]# make
Starting make in the src directory.
If there are problems, cd to the src directory and run make there
cd src && make first
make[1]: Entering directory `/root/vim64/src'
mkdir objects
CC="gcc -Iproto -DHAVE_CONFIG_H     -g -O2       " srcdir=. sh ./osdef.sh
gcc -c -I. -Iproto -DHAVE_CONFIG_H     -g -O2        -o objects/buffer.o buffer.c
In file included from buffer.c:29:
vim.h:40: parse error before `:'
In file included from /usr/include/bits/types.h:143,
                 from /usr/include/stdio.h:36,
                 from os_unix.h:21,
                 from vim.h:195,
                 from buffer.c:29:
/usr/include/bits/pthreadtypes.h:48: parse error before `size_t'
/usr/include/bits/pthreadtypes.h:48: warning: no semicolon at end of struct or union
/usr/include/bits/pthreadtypes.h:51: parse error before `__stacksize'
/usr/include/bits/pthreadtypes.h:51: warning: data definition has no type or storage class
/usr/include/bits/pthreadtypes.h:52: warning: data definition has no type or storage class
In file included from /usr/include/_G_config.h:44,
                 from /usr/include/libio.h:32,
                 from /usr/include/stdio.h:65,
                 from os_unix.h:21,
                 from vim.h:195,
                 from buffer.c:29:
/usr/include/gconv.h:72: parse error before `size_t'
/usr/include/gconv.h:85: parse error before `size_t'
/usr/include/gconv.h:94: parse error before `size_t'
/usr/include/gconv.h:170: parse error before `size_t'
/usr/include/gconv.h:170: warning: no semicolon at end of struct or union
/usr/include/gconv.h:173: parse error before `}'
/usr/include/gconv.h:173: warning: data definition has no type or storage class
In file included from /usr/include/libio.h:32,
                 from /usr/include/stdio.h:65,
                 from os_unix.h:21,
                 from vim.h:195,
                 from buffer.c:29:
/usr/include/_G_config.h:47: field `__cd' has incomplete type
/usr/include/_G_config.h:50: field `__cd' has incomplete type
/usr/include/_G_config.h:53: confused by earlier errors, bailing out
make[1]: *** [objects/buffer.o] Error 1
make[1]: Leaving directory `/root/vim64/src'
make: *** [first] Error 2

ウェブで原因を調べていると、同じようなエラーが出てインストールできない人はいるんだが、解決策は見つからず。いろいろと自分で調べているうちに「Canna-libs-3.5b2-50.i386.rpm」をインストールすることで、vim7をmake、make installすることに成功した。

ちなみに自分の試した環境はredhat7.2。同じようなエラーで悩んでる人は是非。

タイトルとURLをコピーしました