COMPILE MACVIM & YCM ON OSX

Compiling Youcompleteme and Macvim on MacOSX once beaten me down for several nights.

I eventually found out that this is because the interference from pyenv and [homebrew][brew].

[homebrew][brew] installs packages into a unconventional path, which makes MacVim and Youcompleteme can found buidling dependencies in default paths.

While pyenv will shadow Macvim’s default python …

Preparation

Compile YCM

On MacOSX using native clang package has proven to be very stable, besides, it drastically accelerates the installing process – leaving install.sh no need to download the prebuild binaries from LLVM’s site.

cd /to/ycm/root/directory/
    ./install.sh --clang-completer --system-libclang

Compile MacVim

make distclean
./configure               \
    --with-features=huge  \
    -with-macarchs=x86_64 \
    --enable-perlinterp   \
    --enable-rubyinterp   \
    --enable-pythoninterp \
    --enable-luainterp    \
    --enable-perlinterp   \
    --enable-cscope       \
    --with-lua-prefix=/usr/local/Cellar/lua/<current_version> >/tmp/log
make