LoginSignup
2
2

More than 5 years have passed since last update.

WSL上でWindows用のVimをクロスビルド

Last updated at Posted at 2018-07-12

概要

俺用Vimのビルド環境をWSL上に移行したのでメモ

主なfeature

+terminal +directx +lua/dyn +python/dyn +python3/dyn

環境

WSL + Ubuntu-18.04

ビルドスクリプト

build
#!/bin/bash

sudo apt install -y build-essential mingw-w64

git clone --depth 1 https://github.com/LuaJit/LuaJit LuaJit
git clone --depth 1 --single-branch -b 2.7 https://github.com/python/cpython python27
git clone --depth 1 --single-branch -b 3.7 https://github.com/python/cpython python37
cp python27/PC/pyconfig.h python27/Include
cp python37/PC/pyconfig.h python37/Include

git clone https://github.com/vim/vim
pushd vim

make -C src -f Make_ming.mak \
    CROSS_COMPILE=x86_64-w64-mingw32- WINDRES=x86_64-w64-mingw32-windres \
    GUI=no \
    LUA=../../LuaJit/src DYNAMIC_LUA=yes LUA_VER=51 \
    PYTHON=yes PYTHONINC=-I../../python27/Include PYTHON_VER=27 \
    PYTHON3=yes PYTHON3INC=-I../../python37/Include PYTHON3_VER=37 \
    STATIC_STDCPLUS=yes \
    -j 4

make -C src -f Make_ming.mak \
    CROSS_COMPILE=x86_64-w64-mingw32- WINDRES=x86_64-w64-mingw32-windres \
    GUI=yes \
    LUA=../../LuaJit/src DYNAMIC_LUA=yes LUA_VER=51 \
    PYTHON=yes PYTHONINC=-I../../python27/Include PYTHON_VER=27 \
    PYTHON3=yes PYTHON3INC=-I../../python37/Include PYTHON3_VER=37 \
    STATIC_STDCPLUS=yes \
    -j 4

popd
  • src/vim.exe
  • src/gvim.exe
  • src/vimrun.exe
  • runtime/

を適当な場所に設置する。

2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2