Bug #81572 [PATCH]: PHP 8.0.12 fails to compile with ICU 70.1 - patch included

From: Date: Tue, 02 Nov 2021 09:58:35 +0000
Subject: Bug #81572 [PATCH]: PHP 8.0.12 fails to compile with ICU 70.1 - patch included
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-237498@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=81572&edit=1 ID: 81572 Patch added by: cmb@php.net Reported by: jpbion at gmail dot com Summary: PHP 8.0.12 fails to compile with ICU 70.1 - patch included Status: Open Type: Bug Package: *Unicode Issues Operating System: Linux PHP Version: 8.1Git-2021-10-30 (Git) Block user comment: N Private report: N New Comment: The following pull request has been associated: Patch Name: [intl] Support ICU 70.1 On GitHub: https://github.com/php/php-src/pull/7596 Patch: https://github.com/php/php-src/pull/7596.patch Previous Comments: ------------------------------------------------------------------------ [2021-10-30 19:21:04] jpbion at gmail dot com The following patch has been added/updated: Patch Name: icu70betterpatch Revision: 1635621664 URL: https://bugs.php.net/patch-display.php?bug=81572&patch=icu70betterpatch&revision=1635621664 ------------------------------------------------------------------------ [2021-10-30 19:19:36] jpbion at gmail dot com I've included a better patch, which accounts for the ICU version number. It is in the attachment named "icu70betterpatch" ------------------------------------------------------------------------ [2021-10-30 13:57:53] jpbion at gmail dot com Description: ------------ Running on Linux, GLIBC 2.34, GCC 11.2, ICU 70.1, compiling PHP 'master' from GIT, not a snapshot. Configure command used included in script, below. ICU 70.1 notes on https://icu.unicode.org/download/70 ICU4C Specific Changes documented there include: . ICU operator==() and operator!=() functions now return bool instead of UBool Because of this change, PHP with intl support enabled will not compile on a system with ICU >= 70.1 installed. To fix this a patch is needed, which I include as an attachment. HOWEVER, it is entirely possible that this patch would break compilations using ICU versions older than ICU 70.1! Therefore, a better patch is needed, one that checks the ICU version and conditionally compiles with UBool or bool based on that. Test script: --------------- git clone https://github.com/php/php-src.git cd php-src/ git checkout master ./buildconf ./configure --enable-intl make Expected result: ---------------- I want it to compile. It won't without the patch I provide. However, the patch I provide would, as written, probably make it so PHP cannot be compiled with versions of ICU4C that are older than 70.1. A better patch would check the installed ICU version and use UBool for < 70.1 and bool for >= 70.1. ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=81572&edit=1

« previous php.bugs (#237498) next »