From b0ba368d538ba2193e19e98ea8176f6ce63cbd44 Mon Sep 17 00:00:00 2001 From: Niels Dossche <7771979+nielsdos@users.noreply.github.com> Date: Thu, 22 Jun 2023 17:47:42 +0200 Subject: [PATCH] Fix GH-11408: Unable to build PHP 8.3.0 alpha 1 / fileinfo extension On some configurations, the COMPILE_DL_FILEINFO must come from the config.h file. If the COMPILE_DL_FILEINFO macro is not set, the build won't include the ZEND_GET_MODULE block necessary for building this extension as a shared object. Closes GH-11505. --- NEWS | 4 ++++ ext/fileinfo/fileinfo.c | 3 +++ 2 files changed, 7 insertions(+) diff --git a/NEWS b/NEWS index 9171f2c5ae3..9ddffdd5833 100644 --- a/NEWS +++ b/NEWS @@ -6,6 +6,10 @@ PHP NEWS . Fixed bug GH-11507 (String concatenation performance regression in 8.3). (nielsdos) +- Fileinfo: + . Fix GH-11408 (Unable to build PHP 8.3.0 alpha 1 / fileinfo extension). + (nielsdos) + - MBString: . Implement mb_str_pad() RFC. (nielsdos) diff --git a/ext/fileinfo/fileinfo.c b/ext/fileinfo/fileinfo.c index a6f3e64db6b..c3047233dbb 100644 --- a/ext/fileinfo/fileinfo.c +++ b/ext/fileinfo/fileinfo.c @@ -14,6 +14,9 @@ +----------------------------------------------------------------------+ */ +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif #include "php.h" #include "libmagic/magic.h"