Bug #81572 [Opn]: PHP 8.0.12 fails to compile with ICU 70.1 - patch included
| From: | jpbion at gmail dot com | Date: | Sat, 30 Oct 2021 19:19:36 +0000 |
| Subject: | Bug #81572 [Opn]: 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-237439@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
User updated by: jpbion at gmail dot com
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:
I've included a better patch, which accounts for the ICU version number. It is in the
attachment named "icu70betterpatch"
Previous Comments:
------------------------------------------------------------------------
[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