commit: 91dcbea9e37241ce74bf5613ccbe3cfca5b23429 Author: Brian Evans <grknight <AT> gentoo <DOT> org> AuthorDate: Wed Nov 24 14:14:27 2021 +0000 Commit: Brian Evans <grknight <AT> gentoo <DOT> org> CommitDate: Wed Nov 24 14:14:27 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=91dcbea9
dev-lang/php: Backport patch from upstream for ICU 70 changes Already fixed in 7.4.26, 8.0.13 and 8.1.0_rc6 Signed-off-by: Brian Evans <grknight <AT> gentoo.org> dev-lang/php/files/php-icu-70.patch | 45 +++++++++++++++++++++++++++++++++++++ dev-lang/php/php-7.3.32.ebuild | 1 + dev-lang/php/php-7.3.33.ebuild | 1 + dev-lang/php/php-7.4.25.ebuild | 1 + dev-lang/php/php-8.0.12.ebuild | 1 + dev-lang/php/php-8.1.0_rc5.ebuild | 1 + 6 files changed, 50 insertions(+) diff --git a/dev-lang/php/files/php-icu-70.patch b/dev-lang/php/files/php-icu-70.patch new file mode 100644 index 000000000000..63bcb8533f7a --- /dev/null +++ b/dev-lang/php/files/php-icu-70.patch @@ -0,0 +1,45 @@ +diff --git a/ext/intl/locale/locale_methods.c b/ext/intl/locale/locale_methods.c +index 1c4ba327bd83..1bdfb27b7e2e 100644 +--- a/ext/intl/locale/locale_methods.c ++++ b/ext/intl/locale/locale_methods.c +@@ -1326,7 +1326,7 @@ PHP_FUNCTION(locale_filter_matches) + if( token && (token==cur_lang_tag) ){ + /* check if the char. after match is SEPARATOR */ + chrcheck = token + (strlen(cur_loc_range)); +- if( isIDSeparator(*chrcheck) || isEndOfTag(*chrcheck) ){ ++ if( isIDSeparator(*chrcheck) || isKeywordSeparator(*chrcheck) || isEndOfTag(*chrcheck) ){ + efree( cur_lang_tag ); + efree( cur_loc_range ); + if( can_lang_tag){ +diff --git a/ext/intl/breakiterator/codepointiterator_internal.cpp b/ext/intl/breakiterator/codepointiterator_internal.cpp +index bf44678efc06..143c181590e9 100644 +--- a/ext/intl/breakiterator/codepointiterator_internal.cpp ++++ b/ext/intl/breakiterator/codepointiterator_internal.cpp +@@ -75,7 +75,11 @@ CodePointBreakIterator::~CodePointBreakIterator() + clearCurrentCharIter(); + } + ++#if U_ICU_VERSION_MAJOR_NUM >= 70 ++bool CodePointBreakIterator::operator==(const BreakIterator& that) const ++#else + UBool CodePointBreakIterator::operator==(const BreakIterator& that) const ++#endif + { + if (typeid(*this) != typeid(that)) { + return FALSE; +diff --git a/ext/intl/breakiterator/codepointiterator_internal.h b/ext/intl/breakiterator/codepointiterator_internal.h +index 7ecf12deb5ae..0baf607782d0 100644 +--- a/ext/intl/breakiterator/codepointiterator_internal.h ++++ b/ext/intl/breakiterator/codepointiterator_internal.h +@@ -39,7 +39,11 @@ namespace PHP { + + virtual ~CodePointBreakIterator(); + ++#if U_ICU_VERSION_MAJOR_NUM >= 70 ++ virtual bool operator==(const BreakIterator& that) const; ++#else + virtual UBool operator==(const BreakIterator& that) const; ++#endif + + virtual CodePointBreakIterator* clone(void) const; + diff --git a/dev-lang/php/php-7.3.32.ebuild b/dev-lang/php/php-7.3.32.ebuild index 80c4f1c7d3d8..eb176b40cd3d 100644 --- a/dev-lang/php/php-7.3.32.ebuild +++ b/dev-lang/php/php-7.3.32.ebuild @@ -152,6 +152,7 @@ RESTRICT="!test? ( test )" PATCHES=( "${FILESDIR}/php-freetype-2.9.1.patch" + "${FILESDIR}/php-icu-70.patch" ) PHP_MV="$(ver_cut 1)" diff --git a/dev-lang/php/php-7.3.33.ebuild b/dev-lang/php/php-7.3.33.ebuild index 0f10af29f7a5..e1ab493e57a6 100644 --- a/dev-lang/php/php-7.3.33.ebuild +++ b/dev-lang/php/php-7.3.33.ebuild @@ -152,6 +152,7 @@ RESTRICT="!test? ( test )" PATCHES=( "${FILESDIR}/php-freetype-2.9.1.patch" + "${FILESDIR}/php-icu-70.patch" ) PHP_MV="$(ver_cut 1)" diff --git a/dev-lang/php/php-7.4.25.ebuild b/dev-lang/php/php-7.4.25.ebuild index 7c74bdd02981..ea60a2d13396 100644 --- a/dev-lang/php/php-7.4.25.ebuild +++ b/dev-lang/php/php-7.4.25.ebuild @@ -146,6 +146,7 @@ PHP_MV="$(ver_cut 1)" PATCHES=( "${FILESDIR}"/php-iodbc-header-location.patch + "${FILESDIR}/php-icu-70.patch" ) php_install_ini() { diff --git a/dev-lang/php/php-8.0.12.ebuild b/dev-lang/php/php-8.0.12.ebuild index 38aa05d3df7a..fa6e96581f24 100644 --- a/dev-lang/php/php-8.0.12.ebuild +++ b/dev-lang/php/php-8.0.12.ebuild @@ -146,6 +146,7 @@ PHP_MV="$(ver_cut 1)" PATCHES=( "${FILESDIR}/php-iodbc-header-location.patch" "${FILESDIR}/php80-firebird-warnings.patch" + "${FILESDIR}/php-icu-70.patch" ) php_install_ini() { diff --git a/dev-lang/php/php-8.1.0_rc5.ebuild b/dev-lang/php/php-8.1.0_rc5.ebuild index 0233f090d637..7d840eb22182 100644 --- a/dev-lang/php/php-8.1.0_rc5.ebuild +++ b/dev-lang/php/php-8.1.0_rc5.ebuild @@ -146,6 +146,7 @@ PHP_MV="$(ver_cut 1)" PATCHES=( "${FILESDIR}/php-iodbc-header-location.patch" + "${FILESDIR}/php-icu-70.patch" ) php_install_ini() {