1.下载源码包
2.windows下
php ext_skel_win32.php --extname=myplus
linux下
ext_skel --extname=myplus
3.修改配置文件 linux config.m4 删除下面三行的dnl
dnl PHP_ARG_WITH(myplus, for myplus support, dnl Make sure that the comment is aligned: dnl [ --with-myplus Include myplus support])
config.w32 删除下面一行的注释
ARG_ENABLE("myplus", "enable myplus support", "no");
4.编写具体方法函数
myplus.c
5.编译
phpize
6.配置
./configure
7.生成拓展,在modules目录下
make
本文为看恩吧原创文章,转载无需和我联系,但请注明来自knsay.com