I have download the source code of vim7.4 and decide to upgrade the vim to 7.4. However, I can not add python support to it:
./configure --enable-pythoninterp --enable-rubyinterp --enable-gui=no --without-x --enable-cscope --enable-multibyte --prefix=/usr
While checking src/auto/config.log, I found:
configure:5592: checking Python's configuration directory
configure:5614: result:·
configure:5620: result: can't find it!
Installed python info:
dpkg-query -l python
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Description
+++-================================-================================- ================================================================================
ii python 2.7.3-0ubuntu2.2 interactive high-level object-oriented language (default version)
After invoking make in the src dir:
./vim --version | grep python
+cryptv +linebreak -python +viminfo
+cscope +lispindent -python3 +vreplace
It seems that it's caused by vim unable to locate the config dir for python. How to fix it?
Thanks for your insights in advance.
Make sure you have the python development packages installed (python-devel or python-dev I think). You can specify the python config directory by passing, to ./configure
, something like:
--with-python-config-dir=/usr/lib64/python2.7/config
To find the config directory (you may need to do updatedb
first):
locate python | grep '/config$'
From your error messages you don't have python-dev
installed
sudo apt-get install python-dev
this should fix your problem
Make sure you have installed the development packages for python and point towards the appropriate config
directory.
ex: ./configure --enable-pythoninterp --with-python-config-dir=/usr/lib/python2.7/config
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With