摘要: <!--?xml version="1.0" encoding="UTF-8" standalone="no"?--> warning C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s in 阅读全文
posted @ 2016-03-23 15:52 imarno 阅读(281) 评论(0) 推荐(0) 编辑
摘要: <!--?xml version="1.0" encoding="UTF-8" standalone="no"?--> 1. 定义 //定义PHP常量REGISTER_STRINGL_CONSTANT("SIMPLE_VERSION", PHP_SIMPLE_VERSION, sizeof(PHP_ 阅读全文
posted @ 2016-03-23 15:47 imarno 阅读(799) 评论(2) 推荐(0) 编辑
摘要: 话说用了就要有点产出,要不然过段时间又忘了,所以在这里就记录一下试用Kafka的安装过程和php扩展的试用。 实话说,如果用于队列的话,跟PHP比较配的,还是Redis。用的顺手,呵呵,只是Redis不能有多个consumer。但Kafka官方对PHP不支持,PHP扩展是爱好者或使用者写的。下面就开 阅读全文
posted @ 2016-02-18 17:58 imarno 阅读(20802) 评论(0) 推荐(0) 编辑
摘要: cd /usr/local git remote set-url origin git://mirrors.tuna.tsinghua.edu.cn/homebrew.git brew update 如果速度还是很慢,可以尝试以下操作: 然后重试update。 cd ~/tmp git clone 阅读全文
posted @ 2016-01-29 16:44 imarno 阅读(24939) 评论(1) 推荐(0) 编辑
摘要: 由于函数和单类的扩展,网上一搜一大片,这里就不再叙述了。这里特别感谢laruence(鸟哥)开源的yaf扩展,解决困扰我多时的多类问题,还在看他的代码学习中,这里是对多类写法学习的一个阶段总结。1. 修改php_simple.h增加:#define SIMPLE_STARTUP (module) ... 阅读全文
posted @ 2016-01-25 10:07 imarno 阅读(1426) 评论(0) 推荐(0) 编辑
摘要: 1. 宏命令 1.1. dnl 注释 1.2. 扩展的工作方式 1.2.1) PHP_ARG_WITH不需要第三方库 1.2.2) PHP_ARG_ENABLE依赖第三方库 1.3. PHP_REQUIRE_CXX 用于指定这个扩展用到C++ 1.4. PHP_ADD_INC... 阅读全文
posted @ 2016-01-25 10:04 imarno 阅读(745) 评论(0) 推荐(0) 编辑
摘要: 1. 安装VS20132. Cygwin安装3. 下载Windows的PHP源码4. 修改~/ext/ext_skel_win32.php 加上 $cygwin_path = 'c:\cygwin\bin';5. 生成扩展框架 php.exe ext_skel_win32.php --extnam... 阅读全文
posted @ 2016-01-21 16:47 imarno 阅读(825) 评论(0) 推荐(0) 编辑
摘要: 生成PHP扩展开发的基础框架。一、Linux下$>cd ~/{php源码}/ext$>./ext_skel --extname=simpleCreating directory simpleCreating basic files: config.m4 config.w32 .svnignore s... 阅读全文
posted @ 2016-01-20 19:03 imarno 阅读(529) 评论(0) 推荐(0) 编辑