diff src/Make_mvc.mak @ 21662:21304d9c47e9 v8.2.1381

patch 8.2.1381: MS-Windows: crash with Python 3.5 when stdin is redirected Commit: https://github.com/vim/vim/commit/56b8dc331dc7f499c8221ed7d1c7795ad5e3bdeb Author: Bram Moolenaar <Bram@vim.org> Date: Thu Aug 6 21:47:11 2020 +0200 patch 8.2.1381: MS-Windows: crash with Python 3.5 when stdin is redirected Problem: MS-Windows: crash with Python 3.5 when stdin is redirected. Solution: Reconnect stdin. (Yasuhiro Matsumoto, Ken Takata, closes https://github.com/vim/vim/issues/6641)
author Bram Moolenaar <Bram@vim.org>
date Thu, 06 Aug 2020 22:00:04 +0200
parents b32b67a108f2
children d2dee69de7c7
line wrap: on
line diff
--- a/src/Make_mvc.mak
+++ b/src/Make_mvc.mak
@@ -1026,6 +1026,9 @@ PYTHON_LIB = $(PYTHON)\libs\python$(PYTH
 ! ifndef PYTHON3_VER
 PYTHON3_VER = 36
 ! endif
+! ifndef DYNAMIC_PYTHON3_DLL
+DYNAMIC_PYTHON3_DLL = python$(PYTHON3_VER).dll
+! endif
 ! message Python3 requested (version $(PYTHON3_VER)) - root dir is "$(PYTHON3)"
 ! if "$(DYNAMIC_PYTHON3)" == "yes"
 !  message Python3 DLL will be loaded dynamically
@@ -1035,9 +1038,10 @@ PYTHON3_OBJ = $(OUTDIR)\if_python3.obj
 PYTHON3_INC = /I "$(PYTHON3)\Include" /I "$(PYTHON3)\PC"
 ! if "$(DYNAMIC_PYTHON3)" == "yes"
 CFLAGS = $(CFLAGS) -DDYNAMIC_PYTHON3 \
-		-DDYNAMIC_PYTHON3_DLL=\"python$(PYTHON3_VER).dll\"
+		-DDYNAMIC_PYTHON3_DLL=\"$(DYNAMIC_PYTHON3_DLL)\"
 PYTHON3_LIB = /nodefaultlib:python$(PYTHON3_VER).lib
 ! else
+CFLAGS = $(CFLAGS) -DPYTHON3_DLL=\"$(DYNAMIC_PYTHON3_DLL)\"
 PYTHON3_LIB = $(PYTHON3)\libs\python$(PYTHON3_VER).lib
 ! endif
 !endif