From 9f63836cf444ea5f96d74e4008f392a09bf0b99b Mon Sep 17 00:00:00 2001 From: Peter Kokot Date: Fri, 7 Jun 2024 22:59:30 +0200 Subject: [PATCH] Remove redundant _WIN32 compile definitions (#14458) _WIN32 is defined by all compilers on Windows when targeting 32-bit ARM, 64-bit ARM, x86, or x64. This removes redundant definition in ext/zip and erroneous CFLAG_ENCHANT variable (should be CFLAGS_ENCHANT). --- ext/enchant/config.w32 | 1 - ext/zip/config.w32 | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/ext/enchant/config.w32 b/ext/enchant/config.w32 index 57a32ee2199..25f088bba47 100644 --- a/ext/enchant/config.w32 +++ b/ext/enchant/config.w32 @@ -18,7 +18,6 @@ if (PHP_ENCHANT == "yes") { EXTENSION("enchant", "enchant.c"); AC_DEFINE('HAVE_ENCHANT', 1, 'Have Enchant support', false); AC_DEFINE('HAVE_ENCHANT_GET_VERSION', 1); - ADD_FLAG("CFLAG_ENCHANT", "/D _WIN32"); } } else { WARNING('Could not find enchant.h; skipping'); diff --git a/ext/zip/config.w32 b/ext/zip/config.w32 index 05bd99e55a3..0b5448c8e89 100644 --- a/ext/zip/config.w32 +++ b/ext/zip/config.w32 @@ -17,7 +17,7 @@ if (PHP_ZIP != "no") { } AC_DEFINE('HAVE_ZIP', 1); - ADD_FLAG("CFLAGS_ZIP", "/D _WIN32 /D HAVE_SET_MTIME /D HAVE_ENCRYPTION /D HAVE_LIBZIP_VERSION /D HAVE_PROGRESS_CALLBACK /D HAVE_CANCEL_CALLBACK /D HAVE_METHOD_SUPPORTED /D LZMA_API_STATIC"); + ADD_FLAG("CFLAGS_ZIP", "/D HAVE_SET_MTIME /D HAVE_ENCRYPTION /D HAVE_LIBZIP_VERSION /D HAVE_PROGRESS_CALLBACK /D HAVE_CANCEL_CALLBACK /D HAVE_METHOD_SUPPORTED /D LZMA_API_STATIC"); } else { WARNING("zip not enabled; libraries and headers not found"); }