swoole / phpx
C++ wrapper for Zend API
v2.1.0
2026-03-27 03:36 UTC
Requires
- league/climate: ^3.10
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.75
- phpunit/phpunit: ^10.0
README
C++ wrapper for Zend API
Requirements
- PHP 8.1 or later
- Linux/macOS/Windows
- GCC 4.8 or later
- Composer
Build libphpx.so
cmake .
make -j 4
sudo make install
sudo ldconfig
Create Project
# extension composer create-project swoole/phpx-ext test
Generate ArgInfo & Function Entires
php vendor/swoole/phpx/bin/gen_stub.php your_stub_dir
Build extension
cd test cmake . make -j 4 make install
Load your extension
Edit php.ini, add extension=test.so
Run
php echo.php
