Skip to content

Instantly share code, notes, and snippets.

@wordijp
Last active December 29, 2017 08:21
Show Gist options
  • Save wordijp/1888170b3259cb589dca85ebed569e60 to your computer and use it in GitHub Desktop.
Save wordijp/1888170b3259cb589dca85ebed569e60 to your computer and use it in GitHub Desktop.
WindowsのKaoriya版Vim8 64bit版でValloric/YouCompleteMeを使う手順
参考にしたサイト:
- https://linuxcommand.net/vim-youcompleteme/
手順は少し違う
事前に下記をインストール
- 3.5の64bit版
- llvm 5.0.0
- Visual Studio 2017
- Windows SDK 7 for Windows 7
  - win32.makがここに入っている
  - vimprocのdllビルドに利用
  - https://www.microsoft.com/en-us/download/details.aspx?id=8279
1. path/to/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/CMakeLists.txtの
 set( PATH_TO_LLVM_ROOT "【LLVMのパス】" CACHE PATH "Path to the root of a LLVM+Clang binary distribution" )
 をセット
2. Visual Studio 2017のMSBuild.exeにパスを通したコマンドプロンプトを開く
C#のビルドに使用する
3. git submodule update --init --recursive
python3 install.py --all
 警告は大量に出るがエラーなくビルド成功するはず
ここまでで使えるようになるが、デフォルトの設定ファイルを指定しておく、
path/to/.vim/bundle/YouCompleteMe/third_party/ycmd/examples/.ycm_extra_conf.py
をコピーする。
C++の為に
flags = [
'-I',
'C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/include',
]
を加える
4. vimrcに
 let g:ycm_global_ycm_extra_conf = $VIM . '/.ycm_extra_conf.py'
 をセット
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment