2 Star 0 Fork 53

openMajun/vim

forked from src-openEuler/vim 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
backport-configure-cannot-detect-Python-3.10.patch 1.56 KB
一键复制 编辑 原始数据 按行查看 历史
shixuantong 提交于 2021-11-27 14:40 . fix build fail for python3-3.10.0
From 23c0192166760b0d73bd39252ca72e3cfe596f6e Mon Sep 17 00:00:00 2001
From: Bram Moolenaar <Bram@vim.org>
Date: Fri, 21 May 2021 11:43:58 +0200
Subject: [PATCH] patch 8.2.2876: configure cannot detect Python 3.10
Problem: Configure cannot detect Python 3.10.
Solution: Use sys.version_info. (closes #8233)
---
src/auto/configure | 2 +-
src/configure.ac | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/auto/configure b/src/auto/configure
index 0b423a65775..5702a217188 100755
--- a/src/auto/configure
+++ b/src/auto/configure
@@ -6673,7 +6673,7 @@ if ${vi_cv_var_python3_version+:} false; then :
$as_echo_n "(cached) " >&6
else
vi_cv_var_python3_version=`
- ${vi_cv_path_python3} -c 'import sys; print(sys.version[:3])'`
+ ${vi_cv_path_python3} -c 'import sys; print("{}.{}".format(sys.version_info.major, sys.version_info.minor))'`
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python3_version" >&5
diff --git a/src/configure.ac b/src/configure.ac
index cc8d61f7f8b..2db04496ff1 100644
--- a/src/configure.ac
+++ b/src/configure.ac
@@ -1436,7 +1436,7 @@ if test "$enable_python3interp" = "yes" -o "$enable_python3interp" = "dynamic";
dnl -- get its version number
AC_CACHE_CHECK(Python version,vi_cv_var_python3_version,
[[vi_cv_var_python3_version=`
- ${vi_cv_path_python3} -c 'import sys; print(sys.version[:3])'`
+ ${vi_cv_path_python3} -c 'import sys; print("{}.{}".format(sys.version_info.major, sys.version_info.minor))'`
]])
dnl -- it must be at least version 3
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/openMajun/vim.git
git@gitee.com:openMajun/vim.git
openMajun
vim
vim
master

搜索帮助