Generates a PHP fatal error: autoload() is no longer supported, use spl_autoload_register() Code: function __autoload($class) { return HTMLPurifier_Bootstrap::autoload($class); } Suggested fix: function spl_autoload_register($class) { return HTMLPurifier_Bootstrap::autoload($class); }
Has upstream already fixed this? Same question for your other PR: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=272939
Already fixed in 4.14.0: https://github.com/ezyang/htmlpurifier/commit/4285590c90a1eaf36eb6ae147cc1cbfa7aa546a6 So probably we just need to update old 4.9.2 to current release 4.16.0.
Created attachment 243841 [details] update to 4.15.0 Can you test the patch?
4.15.0, released 2022-09-18 ! PHP 8.1 and 8.2 support, esp. fixes for deprecation warnings. https://github.com/ezyang/htmlpurifier/blob/master/NEWS
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=94ea65b1037c4e04fb2d2a6e0ee1480f0b254179 commit 94ea65b1037c4e04fb2d2a6e0ee1480f0b254179 Author: Vladimir Druzenko <vvd@FreeBSD.org> AuthorDate: 2023-08-04 17:53:44 +0000 Commit: Vladimir Druzenko <vvd@FreeBSD.org> CommitDate: 2023-08-04 17:53:44 +0000 devel/pear-htmlpurifier: update to 4.15.0 for support PHP 8+ Runtime errors with PHP 8.1: "Generates a PHP fatal error: autoload() is no longer supported, use spl_autoload_register()" "Generates a PHP fatal error: Array and string offset access syntax with curly braces is no longer supported" Changelog: https://github.com/ezyang/htmlpurifier/blob/master/NEWS 4.15.0, released 2022-09-18 ! PHP 8.1 and 8.2 support, esp. fixes for deprecation warnings. PR: 272938 272939 Approved by: adamw (mentor) Differential Revision: https://reviews.freebsd.org/D41323 MFH: 2023Q3 devel/pear-htmlpurifier/Makefile | 3 +-- devel/pear-htmlpurifier/distinfo | 6 +++--- 2 files changed, 4 insertions(+), 5 deletions(-)
A commit in branch 2023Q3 references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=c0e935c195d85458402cd70a1fc8708dc8227aab commit c0e935c195d85458402cd70a1fc8708dc8227aab Author: Vladimir Druzenko <vvd@FreeBSD.org> AuthorDate: 2023-08-04 17:53:44 +0000 Commit: Vladimir Druzenko <vvd@FreeBSD.org> CommitDate: 2023-08-04 18:02:56 +0000 devel/pear-htmlpurifier: update to 4.15.0 for support PHP 8+ Runtime errors with PHP 8.1: "Generates a PHP fatal error: autoload() is no longer supported, use spl_autoload_register()" "Generates a PHP fatal error: Array and string offset access syntax with curly braces is no longer supported" Changelog: https://github.com/ezyang/htmlpurifier/blob/master/NEWS 4.15.0, released 2022-09-18 ! PHP 8.1 and 8.2 support, esp. fixes for deprecation warnings. PR: 272938 272939 Approved by: adamw (mentor) Differential Revision: https://reviews.freebsd.org/D41323 MFH: 2023Q3 (cherry picked from commit 94ea65b1037c4e04fb2d2a6e0ee1480f0b254179) devel/pear-htmlpurifier/Makefile | 3 +-- devel/pear-htmlpurifier/distinfo | 6 +++--- 2 files changed, 4 insertions(+), 5 deletions(-)
Commited new version.