command-t vim "无法加载 C 扩展"

Pet*_*ete 11 installation vim extension

当我点击 \t 在 VIM 中使用 Command-T 扩展时,出现错误

command-t.vim could not load the C extension
Run Code Online (Sandbox Code Playgroud)

我不知道如何解决这个问题......有什么建议吗?

谢谢


我正在使用 git-repository 安装方法。以下是我“rake make”时发生的情况:

~/.vim/bundle/command-t$ rake make
(in /home/petef/.vim/bundle/command-t)
/usr/bin/ruby1.8 extconf.rb
extconf.rb:24:in `require': no such file to load -- mkmf (LoadError)
    from extconf.rb:24
rake aborted!
Command failed with status (1): [/usr/bin/ruby1.8 extconf.rb...]
/home/petef/.vim/bundle/command-t/Rakefile:136
(See full trace by running task with --trace)
Run Code Online (Sandbox Code Playgroud)

小智 13

Pete,您必须在调用“rake make”命令之前安装 ruby​​-dev 包。


Ben*_*ams 5

Command-T 需要编译的 C 扩展才能工作。以下是Command-T 主页中有关如何编译扩展的相关部分:

The C extension must also be then compiled; for instance, if Vimball installs
your plugin files in ~/.vim, then you would do this: 

  cd ~/.vim/ruby/command-t 
  ruby extconf.rb 
  make 

Note that Command-T requires a version of VIM with Ruby support enabled, and 
it must be compiled using the same version of Ruby that Vim itself links 
against. For more details see the documentation: 

    http://git.wincent.com/command-t.git/blob_plain/HEAD:/README.txt
Run Code Online (Sandbox Code Playgroud)