[php 拓展开发] hello world
2024-09-05 23:28:34
1、下载php源码包
2、在php-7.0.9/ext 下执行 ./ext_skel --extname=hello
3、
4、拓展代码
5、
6、编译
多了分号,出错。
重新编译成功,但是生成的文件(.so)没有移动到php拓展目录下。还需手动移动。
上图可以看到 modules 目录下生成的hello.so文件。
使用 php -info | more 查看php配置信息,可看到拓展路径。
配置php.ini,加上extensions = hello.so
最后,使用hello()
来源:http://www.bo56.com/php7%E6%89%A9%E5%B1%95%E5%BC%80%E5%8F%91%E4%B9%8Bhello-word/
最新文章
- 为什么需要Bundler
- RadioButtonList单选和RequiredFieldValidator验证是否选中
- 【CCS仿真】如何将CCS仿真时memory中的数据以Hex、Integer、 Long 、Float、 Addressable Unit类型保存到PC
- openstack学习线路指导
- java计算一个月有多少天和多少周
- Android 监听wifi广播的两种方式
- 使用PHP从web访问mysql数据库
- c++中参数传递和函数返回简析
- 201521123119 《Java程序设计》第13周学习总结
- ACM 畅通工程
- windows pe
- HttpClient 通过代理访问验证服务器
- 在 Ubuntu14.04 上搭建 Spark 2.3.1(latest version)
- python requests 模块
- pycharm python3.5 神奇的导入问题
- DB2日志清理
- 屏蔽windows快捷键的方法
- CM005-逆向分析过程(上篇)
- 开源项目PullToRefresh详解(四)——PullToRefreshListView和ViewPager的结合使用
- C++ 定时器任务类实现
热门文章
- mpvue 未找到app.json入口文件
- ORACLE Physical Standby DG 之fail over
- r hive
- malloc(50) 内存泄露 内存溢出 memory leak会最终会导致out of memory
- create react app的 css loader 进行局部配置
- ContentProvider,ContentResolver和ContentObserver 使用
- 阶段1 语言基础+高级_1-3-Java语言高级_1-常用API_1_第5节 String类_1_字符串概述和特点
- CentOS 6 安装Syslog-ng
- myeclipse的修改背景颜色和字体
- 007/Docker(一)