Created
June 18, 2014 19:14
-
-
Save ldong/9a22fe008e896d574ade to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function python_finder { | |
| python_library="-DPYTHON_LIBRARY=" | |
| python_include="-DPYTHON_INCLUDE_DIR=" | |
| # python_library="/Users/ldong/.pyenv/versions/2.7.6/lib/python2.7/config" | |
| # python_include="/Users/ldong/.pyenv/versions/2.7.6/lib/python2.7/site-packages" | |
| # The CMake 'FindPythonLibs' Module does not work properly. | |
| # So we are forced to do its job for it. | |
| python_prefix=$(python-config --prefix | sed 's/^[ \t]*//') | |
| if [ -f "${python_prefix}/Python" ]; then | |
| python_library+="${python_prefix}/Python" | |
| python_include+="${python_prefix}/Headers" | |
| else | |
| which_python=$(python -c 'import sys;print(sys.version)' | sed 's/^[ \t]*//') | |
| which_python="python${which_python:0:3}" | |
| lib_python="${python_prefix}/lib/lib${which_python}" | |
| if [ -f "${lib_python}.a" ]; then | |
| python_library+="${lib_python}.a" | |
| # This check is for for CYGWIN | |
| elif [ -f "${lib_python}.dll.a" ]; then | |
| python_library+="${lib_python}.dll.a" | |
| else | |
| python_library+="${lib_python}.dylib" | |
| fi | |
| python_include+="${python_prefix}/include/${which_python}" | |
| fi | |
| python_library="-DPYTHON_LIBRARY=" | |
| python_include="-DPYTHON_INCLUDE_DIR=" | |
| python_prefix="/System/Library/Frameworks/Python.framework/Versions/2.7" | |
| python_library+="${python_prefix}/Python" | |
| python_include+="${python_prefix}/Headers" | |
| #python_library="/Users/ldong/.pyenv/versions/2.7.6/lib/python2.7/config" | |
| #python_include="/Users/ldong/.pyenv/versions/2.7.6/lib/python2.7/site-packages" | |
| #python_library+="/Users/ldong/.pyenv/versions/2.7.6/lib/libpython2.7.a" | |
| #python_include+="/Users/ldong/.pyenv/versions/2.7.6/include/python2.7" | |
| echo "${python_library} ${python_include}" | |
| } |
Author
Author
mine
/var/folders/jk/8dtll3q94tl33p291bw8_76c0000gn/T/ycm_build.XXXXXX.kO5BbIb2 ~/.vim/bundle/vim_youcompleteme
Path
/Users/ldong/.pyenv/versions/2.7.6/lib/libpython2.7.a /Users/ldong/.pyenv/versions/2.7.6/lib/python2.7/site-packages/Users/ldong/.pyenv/versions/2.7.6/include/python2.7
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
My version of YCM
New version of YCM