From d8950adef437f684f7d80499c9d26300e686797c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Milo=C5=A1=20Komar=C4=8Devi=C4=87?= Date: Tue, 2 Feb 2021 13:18:19 +0100 Subject: [PATCH] Enable libtiff Win32 I/O correctly --- setup.py | 2 +- winbuild/tiff.opt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 10992779e..2b457cf05 100755 --- a/setup.py +++ b/setup.py @@ -729,7 +729,7 @@ class pil_build_ext(build_ext): defs.append(("HAVE_LIBTIFF", None)) # FIXME the following define should be detected automatically # based on system libtiff, see #4237 - if PLATFORM_MINGW: + if sys.platform == "win32": defs.append(("USE_WIN32_FILEIO", None)) if feature.xcb: libs.append(feature.xcb) diff --git a/winbuild/tiff.opt b/winbuild/tiff.opt index d82c51678..d6e7a8ed4 100644 --- a/winbuild/tiff.opt +++ b/winbuild/tiff.opt @@ -124,7 +124,7 @@ OPTFLAGS = /Ox /MD /EHsc /W3 /D_CRT_SECURE_NO_DEPRECATE # instead of Windows specific system calls. See notes on top of tif_unix.c # module for details. # -USE_WIN_CRT_LIB = 1 +#USE_WIN_CRT_LIB = 1 # Compiler specific options. You may probably want to adjust compilation # parameters in CFLAGS variable. Refer to your compiler documentation