发布时间:2026-07-25阅读(1)
最近尝试了一下deepin系统,感觉还是很不错的,开箱即用,软件源只有一个deepin的官方源,直接用apt安装的vim不支持python,所以很多插件都不能用,所以我就自己编译安装了一下,记录一下过程。
# 克隆vimgit clone https://github.com/vim/vim.git# 安装编译需要用到的工具sudo apt install build-essensial# 安装依赖sudo apt install python3-dev libncurses5-dev build-essential# 开始编译cd vim/srcsudo make clean# --with-python3-config-dir需要更改为自己的python config路径./configure --with-features=huge \--enable-multibyte \--enable-rubyinterp=yes \--enable-python3interp=yes \--with-python3-config-dir=/usr/lib/python3.5/config-3.5m-x86_64-linux-gnu \--enable-perlinterp=yes \--enable-luainterp=yes \--enable-gui=gtk2 \--enable-cscope \--prefix=/usr/local/vimsudo make install # 没有错误的话,把编译好的文件复制到系统路径sudo cp /usr/local/vim/bin/vim /usr/local/bin/
最后使用vim --version查看是否已经支持python3了。

Copyright © 2024 有趣生活 All Rights Reserve吉ICP备19000289号-5 TXT地图HTML地图XML地图