略微加速

PHP官方手册 - 互联网笔记

PHP - Manual: PECL 扩展库安装

2024-11-14

add a noteadd a note

User Contributed Notes 1 note

up
-1
Boruta.info
1 year ago
I was able to run it on Ubuntu + PHP 8.0. Currently newest version 0.5.0 is not adapted to PHP 8.0, although it seems to work. You have to download the source version and compile it manually (based on https://www.php.net/manual/en/install.pecl.phpize.php), but you will probably get compilation errors. In my case, there were a few minor bugs due to the missing `;` at the end of the return statement. There were also errors related to the removal of TSRM from PHP 8, but it was enough to add macros to the `.c` files.

May be useful (adds macros to the first line of all `.c` files in the current directory):

sed -i '1s / ^ / \ # ifndef \ TSRMLS_D \ n \ #define \ TSRMLS_D \ void \ n \ #define \ TSRMLS_DC \ n \ #define \ TSRMLS_C \ n \ #define \ TSRMLS_CC \ n \ #define \ TSRMLS_FETCH \ (\) \ n \ #endif \ n / '* .c

官方地址:https://www.php.net/manual/en/install.pecl.php

北京半月雨文化科技有限公司.版权所有 京ICP备12026184号-3