From f1702d2bb1a8431e289a6ce9e7fc2734dc6e305c Mon Sep 17 00:00:00 2001 From: "Christoph M. Becker" Date: Sat, 1 Feb 2025 14:57:39 +0100 Subject: [PATCH] Suppress MSVC C4995 warnings (deprecations) These have the same meaning as C4996[1] (which we already suppress), but are triggered by a different mechanism[2]. It makes no sense to suppress one, but not both. Of course it would be better not to suppress either, but wrt the two C4995 warnings we see in php-src, that requires deprecation of using the ODBC cursor library[3], so might take a while. [1] [2] [3] Closes GH-17664. --- win32/build/confutils.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/win32/build/confutils.js b/win32/build/confutils.js index 5a03ea10205..0f97a1a2d29 100644 --- a/win32/build/confutils.js +++ b/win32/build/confutils.js @@ -3269,9 +3269,9 @@ function toolset_setup_common_cflags() // disable annoying warnings. In addition, time_t defaults // to 64-bit. Ask for 32-bit. if (TARGET_ARCH == 'x86') { - ADD_FLAG('CFLAGS', ' /wd4996 /D_USE_32BIT_TIME_T=1 '); + ADD_FLAG('CFLAGS', ' /wd4995 /wd4996 /D_USE_32BIT_TIME_T=1 '); } else { - ADD_FLAG('CFLAGS', ' /wd4996 '); + ADD_FLAG('CFLAGS', ' /wd4995 /wd4996 '); } if (PHP_DEBUG == "yes") {