Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/vim/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
自编vim在Fedora 21上找不到syntax.vim_Vim - Fatal编程技术网

自编vim在Fedora 21上找不到syntax.vim

自编vim在Fedora 21上找不到syntax.vim,vim,Vim,我刚刚在本地目录中构建了vim,因此它是自包含的。 一切正常,我可以启动vim/gvim等 但当我启动vim时,我得到以下信息: [statquant@localhost BuildFromSources]$ ./myOwnVim/usr/bin/vim Error detected while processing /home/statquant/.vimrc: line 85: E484: Can't open file /usr/share/vim/syntax/syntax.vim

我刚刚在本地目录中构建了vim,因此它是自包含的。 一切正常,我可以启动vim/gvim等

但当我启动vim时,我得到以下信息:

[statquant@localhost BuildFromSources]$ ./myOwnVim/usr/bin/vim
Error detected while processing /home/statquant/.vimrc:
line   85:
E484: Can't open file /usr/share/vim/syntax/syntax.vim
Press ENTER or type command to continue
出于某种原因,我认为它不知道什么是
$VIM

事实上,即使在设定之后

$VIM=$HOME/BuildFromSources/myOwnVim/usr/share/vim
.bashrc
和寻源中,它不会拾取它(在vim中执行
:echo
会给出
/usr/share/vim
,这是回退)


如何正确设置它?

运行
/configure
时,需要包含参数
--prefix=path/to/install/location
。编译后,运行
makeinstall
,将所有文件放置在所需位置。 这将允许您进行自定义vim安装

总之:

  • /configure--prefix=path/to/install/location
  • make
  • 进行安装

  • 运行
    /configure
    时,需要包含参数
    --prefix=path/to/install/location
    。编译后,运行
    makeinstall
    ,将所有文件放置在所需位置。 这将允许您进行自定义vim安装

    总之:

  • /configure--prefix=path/to/install/location
  • make
  • 进行安装

  • 运行
    /configure
    时,需要包含参数
    --prefix=path/to/install/location
    。编译后,运行
    makeinstall
    ,将所有文件放置在所需位置。 这将允许您进行自定义vim安装

    总之:

  • /configure--prefix=path/to/install/location
  • make
  • 进行安装

  • 运行
    /configure
    时,需要包含参数
    --prefix=path/to/install/location
    。编译后,运行
    makeinstall
    ,将所有文件放置在所需位置。 这将允许您进行自定义vim安装

    总之:

  • /configure--prefix=path/to/install/location
  • make
  • 进行安装

  • 这是完整的说明

    #install all packages
    sudo yum install -y ruby ruby-devel \
        lua lua-devel luajit luajit-devel \
        ctags mercurial tcl-devel \
        python python-devel python3 python3-devel \
        perl perl-devel perl-ExtUtils-ParseXS \
        perl-ExtUtils-XSpp perl-ExtUtils-CBuilder \
        perl-ExtUtils-Embed
    
    需要此步骤来纠正Fedora 20如何安装XSubPP的问题

    #symlink xsubpp (perl) from /usr/bin to the perl dir
    sudo ln -s /usr/bin/xsubpp /usr/share/perl5/ExtUtils/xsubpp 
    
    来源可通过mercurial获得

    #download the sources in $HOME/Sources
    mkdir $HOME/Sources
    cd $HOME/Sources
    hg clone https://code.google.com/p/vim/
    cd vim
    
    我们构建的vim应该具有所有功能

    #configure the install, vim will be located at $HOME/Build/vim 
    mkdir $HOME/Build/vim
    ./configure --with-features=huge \
                --enable-fail-if-missing \
                --enable-luainterp=yes \
                --enable-mzschemeinterp \
                --enable-perlinterp \
                --enable-pythoninterp=yes \
                --with-python-config-dir=/usr/lib64/python2.7/config \
                --enable-python3interp=yes \
                --enable-tclinterp=yes \
                --enable-rubyinterp=yes \
                --enable-cscope \
                --enable-multibyte \
                --enable-gui=gtk2 \
                --prefix=$HOME/Build/vim \
                --with-compiledby=YOU
    
    然后是安装

    #install 
    make install
    
    应该是这样的

    #check the install
    [statquant@localhost vim]$ tree -L 3 $HOME/Build/vim/
    home/statquant/Build/vim
    ├── bin
    │   ├── eview -> vim
    │   ├── evim -> vim
    │   ├── ex -> vim
    │   ├── gview -> vim
    │   ├── gvim -> vim
    │   ├── gvimdiff -> vim
    │   ├── gvimtutor
    │   ├── rgview -> vim
    │   ├── rgvim -> vim
    │   ├── rview -> vim
    │   ├── rvim -> vim
    │   ├── view -> vim
    │   ├── vim
    │   ├── vimdiff -> vim
    │   ├── vimtutor
    │   └── xxd
    └── share
        ├── man
        │   ├── fr
        │   ├── fr.ISO8859-1
        │   ├── fr.UTF-8
        │   ├── it
        │   ├── it.ISO8859-1
        │   ├── it.UTF-8
        │   ├── ja
        │   ├── man1
        │   ├── pl
        │   ├── pl.ISO8859-2
        │   ├── pl.UTF-8
        │   ├── ru.KOI8-R
        │   └── ru.UTF-8
        └── vim
            └── vim74
    
    最后:

    #change ~/.bashrc so you can call vim/gvim...
    PATH=$PATH:$HOME/Build/vim/bin
    
    #source your bashrc
    source ~/.bashrc
    
    #to uninstall
    cd $HOME/Sources/vim
    make uninstall 
    
    这就是你得到的:

    [statquant@localhost vim]$ vim --version
    VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Apr 19 2015 16:16:44)
    Included patches: 1-703
    Compiled by statquant
    Huge version with GTK2 GUI.  Features included (+) or not (-):
    +acl             +farsi           +mouse_netterm   +syntax
    +arabic          +file_in_path    +mouse_sgr       +tag_binary
    +autocmd         +find_in_path    -mouse_sysmouse  +tag_old_static
    +balloon_eval    +float           +mouse_urxvt     -tag_any_white
    +browse          +folding         +mouse_xterm     +tcl
    ++builtin_terms  -footer          +multi_byte      +terminfo
    +byte_offset     +fork()          +multi_lang      +termresponse
    +cindent         +gettext         -mzscheme        +textobjects
    +clientserver    -hangul_input    +netbeans_intg   +title
    +clipboard       +iconv           +path_extra      +toolbar
    +cmdline_compl   +insert_expand   +perl            +user_commands
    +cmdline_hist    +jumplist        +persistent_undo +vertsplit
    +cmdline_info    +keymap          +postscript      +virtualedit
    +comments        +langmap         +printer         +visual
    +conceal         +libcall         +profile         +visualextra
    +cryptv          +linebreak       +python/dyn      +viminfo
    +cscope          +lispindent      +python3/dyn     +vreplace
    +cursorbind      +listcmds        +quickfix        +wildignore
    +cursorshape     +localmap        +reltime         +wildmenu
    +dialog_con_gui  +lua             +rightleft       +windows
    +diff            +menu            +ruby            +writebackup
    +digraphs        +mksession       +scrollbind      +X11
    +dnd             +modify_fname    +signs           -xfontset
    -ebcdic          +mouse           +smartindent     +xim
    +emacs_tags      +mouseshape      -sniff           +xsmp_interact
    +eval            +mouse_dec       +startuptime     +xterm_clipboard
    +ex_extra        -mouse_gpm       +statusline      -xterm_save
    +extra_search    -mouse_jsbterm   -sun_workshop    +xpm
    

    这是完整的说明

    #install all packages
    sudo yum install -y ruby ruby-devel \
        lua lua-devel luajit luajit-devel \
        ctags mercurial tcl-devel \
        python python-devel python3 python3-devel \
        perl perl-devel perl-ExtUtils-ParseXS \
        perl-ExtUtils-XSpp perl-ExtUtils-CBuilder \
        perl-ExtUtils-Embed
    
    需要此步骤来纠正Fedora 20如何安装XSubPP的问题

    #symlink xsubpp (perl) from /usr/bin to the perl dir
    sudo ln -s /usr/bin/xsubpp /usr/share/perl5/ExtUtils/xsubpp 
    
    来源可通过mercurial获得

    #download the sources in $HOME/Sources
    mkdir $HOME/Sources
    cd $HOME/Sources
    hg clone https://code.google.com/p/vim/
    cd vim
    
    我们构建的vim应该具有所有功能

    #configure the install, vim will be located at $HOME/Build/vim 
    mkdir $HOME/Build/vim
    ./configure --with-features=huge \
                --enable-fail-if-missing \
                --enable-luainterp=yes \
                --enable-mzschemeinterp \
                --enable-perlinterp \
                --enable-pythoninterp=yes \
                --with-python-config-dir=/usr/lib64/python2.7/config \
                --enable-python3interp=yes \
                --enable-tclinterp=yes \
                --enable-rubyinterp=yes \
                --enable-cscope \
                --enable-multibyte \
                --enable-gui=gtk2 \
                --prefix=$HOME/Build/vim \
                --with-compiledby=YOU
    
    然后是安装

    #install 
    make install
    
    应该是这样的

    #check the install
    [statquant@localhost vim]$ tree -L 3 $HOME/Build/vim/
    home/statquant/Build/vim
    ├── bin
    │   ├── eview -> vim
    │   ├── evim -> vim
    │   ├── ex -> vim
    │   ├── gview -> vim
    │   ├── gvim -> vim
    │   ├── gvimdiff -> vim
    │   ├── gvimtutor
    │   ├── rgview -> vim
    │   ├── rgvim -> vim
    │   ├── rview -> vim
    │   ├── rvim -> vim
    │   ├── view -> vim
    │   ├── vim
    │   ├── vimdiff -> vim
    │   ├── vimtutor
    │   └── xxd
    └── share
        ├── man
        │   ├── fr
        │   ├── fr.ISO8859-1
        │   ├── fr.UTF-8
        │   ├── it
        │   ├── it.ISO8859-1
        │   ├── it.UTF-8
        │   ├── ja
        │   ├── man1
        │   ├── pl
        │   ├── pl.ISO8859-2
        │   ├── pl.UTF-8
        │   ├── ru.KOI8-R
        │   └── ru.UTF-8
        └── vim
            └── vim74
    
    最后:

    #change ~/.bashrc so you can call vim/gvim...
    PATH=$PATH:$HOME/Build/vim/bin
    
    #source your bashrc
    source ~/.bashrc
    
    #to uninstall
    cd $HOME/Sources/vim
    make uninstall 
    
    这就是你得到的:

    [statquant@localhost vim]$ vim --version
    VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Apr 19 2015 16:16:44)
    Included patches: 1-703
    Compiled by statquant
    Huge version with GTK2 GUI.  Features included (+) or not (-):
    +acl             +farsi           +mouse_netterm   +syntax
    +arabic          +file_in_path    +mouse_sgr       +tag_binary
    +autocmd         +find_in_path    -mouse_sysmouse  +tag_old_static
    +balloon_eval    +float           +mouse_urxvt     -tag_any_white
    +browse          +folding         +mouse_xterm     +tcl
    ++builtin_terms  -footer          +multi_byte      +terminfo
    +byte_offset     +fork()          +multi_lang      +termresponse
    +cindent         +gettext         -mzscheme        +textobjects
    +clientserver    -hangul_input    +netbeans_intg   +title
    +clipboard       +iconv           +path_extra      +toolbar
    +cmdline_compl   +insert_expand   +perl            +user_commands
    +cmdline_hist    +jumplist        +persistent_undo +vertsplit
    +cmdline_info    +keymap          +postscript      +virtualedit
    +comments        +langmap         +printer         +visual
    +conceal         +libcall         +profile         +visualextra
    +cryptv          +linebreak       +python/dyn      +viminfo
    +cscope          +lispindent      +python3/dyn     +vreplace
    +cursorbind      +listcmds        +quickfix        +wildignore
    +cursorshape     +localmap        +reltime         +wildmenu
    +dialog_con_gui  +lua             +rightleft       +windows
    +diff            +menu            +ruby            +writebackup
    +digraphs        +mksession       +scrollbind      +X11
    +dnd             +modify_fname    +signs           -xfontset
    -ebcdic          +mouse           +smartindent     +xim
    +emacs_tags      +mouseshape      -sniff           +xsmp_interact
    +eval            +mouse_dec       +startuptime     +xterm_clipboard
    +ex_extra        -mouse_gpm       +statusline      -xterm_save
    +extra_search    -mouse_jsbterm   -sun_workshop    +xpm
    

    这是完整的说明

    #install all packages
    sudo yum install -y ruby ruby-devel \
        lua lua-devel luajit luajit-devel \
        ctags mercurial tcl-devel \
        python python-devel python3 python3-devel \
        perl perl-devel perl-ExtUtils-ParseXS \
        perl-ExtUtils-XSpp perl-ExtUtils-CBuilder \
        perl-ExtUtils-Embed
    
    需要此步骤来纠正Fedora 20如何安装XSubPP的问题

    #symlink xsubpp (perl) from /usr/bin to the perl dir
    sudo ln -s /usr/bin/xsubpp /usr/share/perl5/ExtUtils/xsubpp 
    
    来源可通过mercurial获得

    #download the sources in $HOME/Sources
    mkdir $HOME/Sources
    cd $HOME/Sources
    hg clone https://code.google.com/p/vim/
    cd vim
    
    我们构建的vim应该具有所有功能

    #configure the install, vim will be located at $HOME/Build/vim 
    mkdir $HOME/Build/vim
    ./configure --with-features=huge \
                --enable-fail-if-missing \
                --enable-luainterp=yes \
                --enable-mzschemeinterp \
                --enable-perlinterp \
                --enable-pythoninterp=yes \
                --with-python-config-dir=/usr/lib64/python2.7/config \
                --enable-python3interp=yes \
                --enable-tclinterp=yes \
                --enable-rubyinterp=yes \
                --enable-cscope \
                --enable-multibyte \
                --enable-gui=gtk2 \
                --prefix=$HOME/Build/vim \
                --with-compiledby=YOU
    
    然后是安装

    #install 
    make install
    
    应该是这样的

    #check the install
    [statquant@localhost vim]$ tree -L 3 $HOME/Build/vim/
    home/statquant/Build/vim
    ├── bin
    │   ├── eview -> vim
    │   ├── evim -> vim
    │   ├── ex -> vim
    │   ├── gview -> vim
    │   ├── gvim -> vim
    │   ├── gvimdiff -> vim
    │   ├── gvimtutor
    │   ├── rgview -> vim
    │   ├── rgvim -> vim
    │   ├── rview -> vim
    │   ├── rvim -> vim
    │   ├── view -> vim
    │   ├── vim
    │   ├── vimdiff -> vim
    │   ├── vimtutor
    │   └── xxd
    └── share
        ├── man
        │   ├── fr
        │   ├── fr.ISO8859-1
        │   ├── fr.UTF-8
        │   ├── it
        │   ├── it.ISO8859-1
        │   ├── it.UTF-8
        │   ├── ja
        │   ├── man1
        │   ├── pl
        │   ├── pl.ISO8859-2
        │   ├── pl.UTF-8
        │   ├── ru.KOI8-R
        │   └── ru.UTF-8
        └── vim
            └── vim74
    
    最后:

    #change ~/.bashrc so you can call vim/gvim...
    PATH=$PATH:$HOME/Build/vim/bin
    
    #source your bashrc
    source ~/.bashrc
    
    #to uninstall
    cd $HOME/Sources/vim
    make uninstall 
    
    这就是你得到的:

    [statquant@localhost vim]$ vim --version
    VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Apr 19 2015 16:16:44)
    Included patches: 1-703
    Compiled by statquant
    Huge version with GTK2 GUI.  Features included (+) or not (-):
    +acl             +farsi           +mouse_netterm   +syntax
    +arabic          +file_in_path    +mouse_sgr       +tag_binary
    +autocmd         +find_in_path    -mouse_sysmouse  +tag_old_static
    +balloon_eval    +float           +mouse_urxvt     -tag_any_white
    +browse          +folding         +mouse_xterm     +tcl
    ++builtin_terms  -footer          +multi_byte      +terminfo
    +byte_offset     +fork()          +multi_lang      +termresponse
    +cindent         +gettext         -mzscheme        +textobjects
    +clientserver    -hangul_input    +netbeans_intg   +title
    +clipboard       +iconv           +path_extra      +toolbar
    +cmdline_compl   +insert_expand   +perl            +user_commands
    +cmdline_hist    +jumplist        +persistent_undo +vertsplit
    +cmdline_info    +keymap          +postscript      +virtualedit
    +comments        +langmap         +printer         +visual
    +conceal         +libcall         +profile         +visualextra
    +cryptv          +linebreak       +python/dyn      +viminfo
    +cscope          +lispindent      +python3/dyn     +vreplace
    +cursorbind      +listcmds        +quickfix        +wildignore
    +cursorshape     +localmap        +reltime         +wildmenu
    +dialog_con_gui  +lua             +rightleft       +windows
    +diff            +menu            +ruby            +writebackup
    +digraphs        +mksession       +scrollbind      +X11
    +dnd             +modify_fname    +signs           -xfontset
    -ebcdic          +mouse           +smartindent     +xim
    +emacs_tags      +mouseshape      -sniff           +xsmp_interact
    +eval            +mouse_dec       +startuptime     +xterm_clipboard
    +ex_extra        -mouse_gpm       +statusline      -xterm_save
    +extra_search    -mouse_jsbterm   -sun_workshop    +xpm
    

    这是完整的说明

    #install all packages
    sudo yum install -y ruby ruby-devel \
        lua lua-devel luajit luajit-devel \
        ctags mercurial tcl-devel \
        python python-devel python3 python3-devel \
        perl perl-devel perl-ExtUtils-ParseXS \
        perl-ExtUtils-XSpp perl-ExtUtils-CBuilder \
        perl-ExtUtils-Embed
    
    需要此步骤来纠正Fedora 20如何安装XSubPP的问题

    #symlink xsubpp (perl) from /usr/bin to the perl dir
    sudo ln -s /usr/bin/xsubpp /usr/share/perl5/ExtUtils/xsubpp 
    
    来源可通过mercurial获得

    #download the sources in $HOME/Sources
    mkdir $HOME/Sources
    cd $HOME/Sources
    hg clone https://code.google.com/p/vim/
    cd vim
    
    我们构建的vim应该具有所有功能

    #configure the install, vim will be located at $HOME/Build/vim 
    mkdir $HOME/Build/vim
    ./configure --with-features=huge \
                --enable-fail-if-missing \
                --enable-luainterp=yes \
                --enable-mzschemeinterp \
                --enable-perlinterp \
                --enable-pythoninterp=yes \
                --with-python-config-dir=/usr/lib64/python2.7/config \
                --enable-python3interp=yes \
                --enable-tclinterp=yes \
                --enable-rubyinterp=yes \
                --enable-cscope \
                --enable-multibyte \
                --enable-gui=gtk2 \
                --prefix=$HOME/Build/vim \
                --with-compiledby=YOU
    
    然后是安装

    #install 
    make install
    
    应该是这样的

    #check the install
    [statquant@localhost vim]$ tree -L 3 $HOME/Build/vim/
    home/statquant/Build/vim
    ├── bin
    │   ├── eview -> vim
    │   ├── evim -> vim
    │   ├── ex -> vim
    │   ├── gview -> vim
    │   ├── gvim -> vim
    │   ├── gvimdiff -> vim
    │   ├── gvimtutor
    │   ├── rgview -> vim
    │   ├── rgvim -> vim
    │   ├── rview -> vim
    │   ├── rvim -> vim
    │   ├── view -> vim
    │   ├── vim
    │   ├── vimdiff -> vim
    │   ├── vimtutor
    │   └── xxd
    └── share
        ├── man
        │   ├── fr
        │   ├── fr.ISO8859-1
        │   ├── fr.UTF-8
        │   ├── it
        │   ├── it.ISO8859-1
        │   ├── it.UTF-8
        │   ├── ja
        │   ├── man1
        │   ├── pl
        │   ├── pl.ISO8859-2
        │   ├── pl.UTF-8
        │   ├── ru.KOI8-R
        │   └── ru.UTF-8
        └── vim
            └── vim74
    
    最后:

    #change ~/.bashrc so you can call vim/gvim...
    PATH=$PATH:$HOME/Build/vim/bin
    
    #source your bashrc
    source ~/.bashrc
    
    #to uninstall
    cd $HOME/Sources/vim
    make uninstall 
    
    这就是你得到的:

    [statquant@localhost vim]$ vim --version
    VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Apr 19 2015 16:16:44)
    Included patches: 1-703
    Compiled by statquant
    Huge version with GTK2 GUI.  Features included (+) or not (-):
    +acl             +farsi           +mouse_netterm   +syntax
    +arabic          +file_in_path    +mouse_sgr       +tag_binary
    +autocmd         +find_in_path    -mouse_sysmouse  +tag_old_static
    +balloon_eval    +float           +mouse_urxvt     -tag_any_white
    +browse          +folding         +mouse_xterm     +tcl
    ++builtin_terms  -footer          +multi_byte      +terminfo
    +byte_offset     +fork()          +multi_lang      +termresponse
    +cindent         +gettext         -mzscheme        +textobjects
    +clientserver    -hangul_input    +netbeans_intg   +title
    +clipboard       +iconv           +path_extra      +toolbar
    +cmdline_compl   +insert_expand   +perl            +user_commands
    +cmdline_hist    +jumplist        +persistent_undo +vertsplit
    +cmdline_info    +keymap          +postscript      +virtualedit
    +comments        +langmap         +printer         +visual
    +conceal         +libcall         +profile         +visualextra
    +cryptv          +linebreak       +python/dyn      +viminfo
    +cscope          +lispindent      +python3/dyn     +vreplace
    +cursorbind      +listcmds        +quickfix        +wildignore
    +cursorshape     +localmap        +reltime         +wildmenu
    +dialog_con_gui  +lua             +rightleft       +windows
    +diff            +menu            +ruby            +writebackup
    +digraphs        +mksession       +scrollbind      +X11
    +dnd             +modify_fname    +signs           -xfontset
    -ebcdic          +mouse           +smartindent     +xim
    +emacs_tags      +mouseshape      -sniff           +xsmp_interact
    +eval            +mouse_dec       +startuptime     +xterm_clipboard
    +ex_extra        -mouse_gpm       +statusline      -xterm_save
    +extra_search    -mouse_jsbterm   -sun_workshop    +xpm
    

    我一直使用
    --prefix
    ,不需要安装后环境设置。请尝试此选项以查看其是否有效?预计您不需要使用
    sudo
    。请确认您正在按照我在更新的答案中描述的步骤进行操作。我一直使用
    --prefix
    ,不需要安装后环境设置。请尝试此选项以查看其是否有效?预计您不需要使用
    sudo
    。请确认您正在按照我在更新的答案中描述的步骤进行操作。我一直使用
    --prefix
    ,不需要安装后环境设置。请尝试此选项以查看其是否有效?预计您不需要使用
    sudo
    。请确认您正在按照我在更新的答案中描述的步骤进行操作。我一直使用
    --prefix
    ,不需要安装后环境设置。请尝试此选项以查看其是否有效?预计您不需要使用
    sudo
    。请确认您正在按照我在更新的答案中描述的确切步骤进行操作。