Compiling vim with specific version of Python

前端 未结 5 1129
感动是毒
感动是毒 2021-01-31 03:58

I\'m working on several Python projects who run on various versions of Python. I\'m hoping to set up my vim environment to use ropevim, pyflakes, and pylint but I\'ve run into s

5条回答
  •  别那么骄傲
    2021-01-31 04:36

    I would like to give a similar solution to crowder's that works quite well for me.

    Imagine you have Python installed in /opt/Python-2.7.5 and that the structure of that folder is

    $ tree -d -L 1 /opt/Python-2.7.5/
    /opt/Python-2.7.5/
    ├── bin
    ├── include
    ├── lib
    └── share
    

    and you would like to build vim with that version of Python. All you need to do is

    $ vi_cv_path_python=/opt/Python-2.7.5/bin/python ./configure  --enable-pythoninterp --prefix=/SOME/FOLDER
    

    Thus, just by explicitly giving vi_cv_path_python variable to configure the script will deduce everything on it's own (even the config-dir).

    This was tested multiple times on vim 7.4+ and lately with vim-7-4-324.

提交回复
热议问题