1.在官网下载了yaf扩展包 yaf-3.0.3.tgz

  2.开始安装yaf扩展   

tar zxvf yaf-3.0.3.tgz 

cd yaf-3.0.3

phpize

./configure --with-php-config=/usr/local/php/bin/php-config 

make

make install
//php.ini配置文件中加入pcntl配置文件
[root@centos src]# echo "extension=/usr/local/php/lib/php/extensions/no-debug-non-zts-20121212/yaf.so" >> /usr/local/php/etc/php.ini //重启服务

  报错:

In file included from /data1/study/yaf-3.0.2/yaf.c:28:
/data1/study/yaf-3.0.2/php_yaf.h:72: error: expected specifier-qualifier-list before ‘zend_string’
In file included from /data1/study/yaf-3.0.2/yaf.c:30:
/data1/study/yaf-3.0.2/yaf_loader.h:72: error: expected declaration specifiers or ‘...’ before ‘zend_string’
/data1/study/yaf-3.0.2/yaf_loader.h:72: error: expected declaration specifiers or ‘...’ before ‘zend_string’
In file included from /data1/study/yaf-3.0.2/yaf.c:32:
/data1/study/yaf-3.0.2/yaf_application.h:31: error: expected ‘)’ before ‘*’ token
In file included from /data1/study/yaf-3.0.2/yaf.c:35:
/data1/study/yaf-3.0.2/yaf_view.h:34: error: expected declaration specifiers or ‘...’ before ‘zend_string’
In file included from /data1/study/yaf-3.0.2/yaf.c:36:
/data1/study/yaf-3.0.2/yaf_controller.h:34: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
In file included from /data1/study/yaf-3.0.2/yaf.c:38:
/data1/study/yaf-3.0.2/yaf_request.h:47: error: expected declaration specifiers or ‘...’ before ‘zend_string’
/data1/study/yaf-3.0.2/yaf_request.h:48: error: expected declaration specifiers or ‘...’ before ‘zend_string’
/data1/study/yaf-3.0.2/yaf_request.h:48: error: expected declaration specifiers or ‘...’ before ‘zend_string’
/data1/study/yaf-3.0.2/yaf_request.h:52: error: expected declaration specifiers or ‘...’ before ‘zend_string’
/data1/study/yaf-3.0.2/yaf_request.h:59: error: expected declaration specifiers or ‘...’ before ‘zend_string’
In file included from /data1/study/yaf-3.0.2/yaf.c:39:
/data1/study/yaf-3.0.2/yaf_response.h:35: error: expected declaration specifiers or ‘...’ before ‘zend_string’
/data1/study/yaf-3.0.2/yaf_response.h:35: error: expected declaration specifiers or ‘...’ before ‘zend_string’
/data1/study/yaf-3.0.2/yaf_response.h:38: error: expected declaration specifiers or ‘...’ before ‘zend_string’
/data1/study/yaf-3.0.2/yaf.c: In function ‘OnUpdateSeparator’:
/data1/study/yaf-3.0.2/yaf.c:58: error: ‘zend_yaf_globals’ has no member named ‘name_separator’
/data1/study/yaf-3.0.2/yaf.c:59: error: ‘zend_yaf_globals’ has no member named ‘name_separator_len’
/data1/study/yaf-3.0.2/yaf.c: At top level:
/data1/study/yaf-3.0.2/yaf.c:67: error: ‘zend_yaf_globals’ has no member named ‘global_library’
/data1/study/yaf-3.0.2/yaf.c:68: error: ‘zend_yaf_globals’ has no member named ‘action_prefer’
/data1/study/yaf-3.0.2/yaf.c:69: error: ‘zend_yaf_globals’ has no member named ‘lowcase_path’
/data1/study/yaf-3.0.2/yaf.c:70: error: ‘zend_yaf_globals’ has no member named ‘use_spl_autoload’
/data1/study/yaf-3.0.2/yaf.c:71: error: ‘zend_yaf_globals’ has no member named ‘forward_limit’
/data1/study/yaf-3.0.2/yaf.c:72: error: ‘zend_yaf_globals’ has no member named ‘name_suffix’
/data1/study/yaf-3.0.2/yaf.c:75: error: ‘zend_yaf_globals’ has no member named ‘st_compatible’
/data1/study/yaf-3.0.2/yaf.c:77: error: ‘zend_yaf_globals’ has no member named ‘environ_name’
/data1/study/yaf-3.0.2/yaf.c:78: error: ‘zend_yaf_globals’ has no member named ‘use_namespace’
/data1/study/yaf-3.0.2/yaf.c: In function ‘zm_startup_yaf’:
/data1/study/yaf-3.0.2/yaf.c:96: error: ‘zend_yaf_globals’ has no member named ‘use_namespace’
/data1/study/yaf-3.0.2/yaf.c:99: error: ‘zend_yaf_globals’ has no member named ‘environ_name’
/data1/study/yaf-3.0.2/yaf.c:99: error: ‘zend_yaf_globals’ has no member named ‘environ_name’
/data1/study/yaf-3.0.2/yaf.c:99: warning: passing argument 1 of ‘strlen’ from incompatible pointer type
/usr/include/string.h:399: note: expected ‘const char *’ but argument is of type ‘const struct zend_ini_entry *’
/data1/study/yaf-3.0.2/yaf.c:99: warning: passing argument 3 of ‘zend_register_stringl_constant’ from incompatible pointer type
/usr/local/sinasrv2/include/php/Zend/zend_constants.h:68: note: expected ‘char *’ but argument is of type ‘const struct zend_ini_entry *’
/data1/study/yaf-3.0.2/yaf.c:114: error: ‘zend_yaf_globals’ has no member named ‘environ_name’
/data1/study/yaf-3.0.2/yaf.c:114: error: ‘zend_yaf_globals’ has no member named ‘environ_name’
/data1/study/yaf-3.0.2/yaf.c:114: warning: passing argument 1 of ‘strlen’ from incompatible pointer type
/usr/include/string.h:399: note: expected ‘const char *’ but argument is of type ‘const struct zend_ini_entry *’
/data1/study/yaf-3.0.2/yaf.c:114: warning: passing argument 3 of ‘zend_register_stringl_constant’ from incompatible pointer type
/usr/local/sinasrv2/include/php/Zend/zend_constants.h:68: note: expected ‘char *’ but argument is of type ‘const struct zend_ini_entry *’
/data1/study/yaf-3.0.2/yaf.c: In function ‘zm_shutdown_yaf’:
/data1/study/yaf-3.0.2/yaf.c:155: error: ‘zend_yaf_globals’ has no member named ‘configs’
/data1/study/yaf-3.0.2/yaf.c:156: error: ‘zend_yaf_globals’ has no member named ‘configs’
/data1/study/yaf-3.0.2/yaf.c:156: warning: passing argument 1 of ‘zend_hash_destroy’ from incompatible pointer type
/usr/local/sinasrv2/include/php/Zend/zend_hash.h:101: note: expected ‘struct HashTable *’ but argument is of type ‘const struct zend_ini_entry *’
/data1/study/yaf-3.0.2/yaf.c:157: error: ‘zend_yaf_globals’ has no member named ‘configs’
/data1/study/yaf-3.0.2/yaf.c:157: warning: passing argument 1 of ‘free’ discards qualifiers from pointer target type
/usr/include/stdlib.h:488: note: expected ‘void *’ but argument is of type ‘const struct zend_ini_entry *’
/data1/study/yaf-3.0.2/yaf.c:157: error: ‘zend_yaf_globals’ has no member named ‘configs’
/data1/study/yaf-3.0.2/yaf.c:157: warning: passing argument 1 of ‘_efree’ discards qualifiers from pointer target type
/usr/local/sinasrv2/include/php/Zend/zend_alloc.h:60: note: expected ‘void *’ but argument is of type ‘const struct zend_ini_entry *’
/data1/study/yaf-3.0.2/yaf.c: In function ‘zm_activate_yaf’:
/data1/study/yaf-3.0.2/yaf.c:168: error: ‘zend_yaf_globals’ has no member named ‘throw_exception’
/data1/study/yaf-3.0.2/yaf.c:169: error: ‘zend_yaf_globals’ has no member named ‘ext’
/data1/study/yaf-3.0.2/yaf.c:170: error: ‘zend_yaf_globals’ has no member named ‘view_ext’
/data1/study/yaf-3.0.2/yaf.c:171: error: ‘zend_yaf_globals’ has no member named ‘default_module’
/data1/study/yaf-3.0.2/yaf.c:173: error: ‘zend_yaf_globals’ has no member named ‘default_controller’
/data1/study/yaf-3.0.2/yaf.c:175: error: ‘zend_yaf_globals’ has no member named ‘default_action’
/data1/study/yaf-3.0.2/yaf.c: In function ‘zm_deactivate_yaf’:
/data1/study/yaf-3.0.2/yaf.c:185: error: ‘zend_yaf_globals’ has no member named ‘running’
/data1/study/yaf-3.0.2/yaf.c:186: error: ‘zend_yaf_globals’ has no member named ‘in_exception’
/data1/study/yaf-3.0.2/yaf.c:187: error: ‘zend_yaf_globals’ has no member named ‘catch_exception’
/data1/study/yaf-3.0.2/yaf.c:189: error: ‘zend_yaf_globals’ has no member named ‘directory’
/data1/study/yaf-3.0.2/yaf.c:190: error: ‘zend_yaf_globals’ has no member named ‘directory’
/data1/study/yaf-3.0.2/yaf.c:191: error: ‘zend_yaf_globals’ has no member named ‘directory’
/data1/study/yaf-3.0.2/yaf.c:193: error: ‘zend_yaf_globals’ has no member named ‘local_library’
/data1/study/yaf-3.0.2/yaf.c:194: error: ‘zend_yaf_globals’ has no member named ‘local_library’
/data1/study/yaf-3.0.2/yaf.c:195: error: ‘zend_yaf_globals’ has no member named ‘local_library’
/data1/study/yaf-3.0.2/yaf.c:197: error: ‘zend_yaf_globals’ has no member named ‘local_namespaces’
/data1/study/yaf-3.0.2/yaf.c:198: error: ‘zend_yaf_globals’ has no member named ‘local_namespaces’
/data1/study/yaf-3.0.2/yaf.c:199: error: ‘zend_yaf_globals’ has no member named ‘local_namespaces’
/data1/study/yaf-3.0.2/yaf.c:201: error: ‘zend_yaf_globals’ has no member named ‘bootstrap’
/data1/study/yaf-3.0.2/yaf.c:202: error: ‘zend_yaf_globals’ has no member named ‘bootstrap’
/data1/study/yaf-3.0.2/yaf.c:203: error: ‘zend_yaf_globals’ has no member named ‘bootstrap’
/data1/study/yaf-3.0.2/yaf.c:205: error: ‘zend_yaf_globals’ has no member named ‘modules’
/data1/study/yaf-3.0.2/yaf.c:205: error: request for member ‘type’ in something not a structure or union
/data1/study/yaf-3.0.2/yaf.c:205: warning: comparison between pointer and integer
/data1/study/yaf-3.0.2/yaf.c:206: error: ‘zend_yaf_globals’ has no member named ‘modules’
/data1/study/yaf-3.0.2/yaf.c:206: warning: passing argument 1 of ‘_zval_ptr_dtor’ from incompatible pointer type
/usr/local/sinasrv2/include/php/Zend/zend_variables.h:51: note: expected ‘struct zval **’ but argument is of type ‘const struct zend_ini_entry (*)[1]’
/data1/study/yaf-3.0.2/yaf.c:207: error: ‘zend_yaf_globals’ has no member named ‘modules’
/data1/study/yaf-3.0.2/yaf.c:209: error: ‘zend_yaf_globals’ has no member named ‘base_uri’
/data1/study/yaf-3.0.2/yaf.c:210: error: ‘zend_yaf_globals’ has no member named ‘base_uri’
/data1/study/yaf-3.0.2/yaf.c:211: error: ‘zend_yaf_globals’ has no member named ‘base_uri’
/data1/study/yaf-3.0.2/yaf.c:213: error: ‘zend_yaf_globals’ has no member named ‘view_directory’
/data1/study/yaf-3.0.2/yaf.c:214: error: ‘zend_yaf_globals’ has no member named ‘view_directory’
/data1/study/yaf-3.0.2/yaf.c:215: error: ‘zend_yaf_globals’ has no member named ‘view_directory’
/data1/study/yaf-3.0.2/yaf.c:217: error: ‘zend_yaf_globals’ has no member named ‘view_ext’
/data1/study/yaf-3.0.2/yaf.c:218: error: ‘zend_yaf_globals’ has no member named ‘view_ext’
/data1/study/yaf-3.0.2/yaf.c:220: error: ‘zend_yaf_globals’ has no member named ‘default_module’
/data1/study/yaf-3.0.2/yaf.c:221: error: ‘zend_yaf_globals’ has no member named ‘default_module’
/data1/study/yaf-3.0.2/yaf.c:223: error: ‘zend_yaf_globals’ has no member named ‘default_controller’
/data1/study/yaf-3.0.2/yaf.c:224: error: ‘zend_yaf_globals’ has no member named ‘default_controller’
/data1/study/yaf-3.0.2/yaf.c:226: error: ‘zend_yaf_globals’ has no member named ‘default_action’
/data1/study/yaf-3.0.2/yaf.c:227: error: ‘zend_yaf_globals’ has no member named ‘default_action’
/data1/study/yaf-3.0.2/yaf.c:229: error: ‘zend_yaf_globals’ has no member named ‘ext’
/data1/study/yaf-3.0.2/yaf.c:230: error: ‘zend_yaf_globals’ has no member named ‘ext’
/data1/study/yaf-3.0.2/yaf.c:232: error: ‘zend_yaf_globals’ has no member named ‘default_route’
make: *** [yaf.lo] Error 1

  分析原因:搜索下了类似的结果 都说 缺少 pcre

  建议:yum install pcre-dev  但是我这里已经显示安装pcre扩展成功,然并卵 没啥用。

经过再三的测试安装 发现竟然是yaf版本问题, 目前php版本是 5.5.35 , 然后去官网下载了 yaf-2.2.8

安装上面步骤重新安装  搞定!!

Linux 下安装Yaf扩展的更多相关文章

  1. linux下安装opcache扩展

    linux下安装opcache扩展   参考:http://www.php.net/manual/zh/opcache.installation.php 1 2 3 4 5 6 7 wget http ...

  2. 总结 Linux 下安装 PHP 扩展步骤

    总结一下 Linux 下安装 PHP 扩展步骤,这里以安装 PHP 的 redis 扩展为例. 一.拿到扩展包下载地址,下载扩展包 pecl 上搜索 redis wget http://pecl.ph ...

  3. linux 下安装php扩展

    linux下安装php扩展 步骤: 1.在扩展解压包目录执行 phpize 2.执行 ./configure --with-php-config=/usr/local/php/bin/php-conf ...

  4. linux下安装PHP扩展memcache

    公司的服务器 CentOS 7.5,PHP 5.6 下面都是最新的版本(支持到PHP5.6) 如需php7  下支持memcache扩展,请移步   https://www.cnblogs.com/h ...

  5. Linux下安装php 扩展fileinfo

    在项目初始部署环境的时候,可能考虑的并不全面,就会少装一些扩展,这里讲解如何添加fileinfo扩展 1.找到php安装的压缩包 2.将压缩包cp到 /data目录下,并解压 cp php-7.0.3 ...

  6. php7.2 下安装yaf扩展

    wget http://pecl.php.net/get/yaf-3.0.7.tgz  解压并进入目录: 1 tar -zxvf yaf-3.0.7* && cd yaf-3.0.7  ...

  7. linux下安装swoole扩展

    一.下载swoole 地址:https://github.com/swoole/swoole-src二.将下载好的压缩包放在linux服务器下三.解压压缩包到任意目录 # unzip swoole-s ...

  8. redis在linux下安装以及扩展

    安装过redis后发现回头忘了,今天重新安装记录下 首先 我是在home下创建redis文件   mkdir  redis 然后直接用wget安装 wget http://download.redis ...

  9. Redis linux 下安装 及扩展配置

    1.首先在/usr/local/ 创建文件夹 reids Cd /usr/local/ mkdir redis 2.把redis安装包放在redis目录下面进行解压phpredis-2.2.4.tar ...

随机推荐

  1. FastAdmin 学习线路 (2018-09-09 增加 Layer 组件)

    FastAdmin 学习线路 (2018-09-09 增加 Layer 组件) 基础 HTML CSS DIV Javascript 基础 jQuery php 基础 对象 命名空间 Apache 或 ...

  2. FPGA中计数器设计探索

    FPGA中计数器设计探索,以计数器为32位为例: 第一种方式,直接定义32位计数器. reg [31:0]count; quartus ii 下的编译,资源消耗情况. 85C模型下的时钟频率. 0C模 ...

  3. Mac电脑Tomcat下载及安装(详细)

    下载Tomcat 1.打开Apache Tomcat官网,选择你需要的版本进行下载: 地址http://tomcat.apache.org/download-70.cgi   2.解压apache-t ...

  4. Vue.js:样式绑定

    ylbtech-Vue.js:样式绑定 1.返回顶部 1. Vue.js 样式绑定 Vue.js class class 与 style 是 HTML 元素的属性,用于设置元素的样式,我们可以用 v- ...

  5. RPC框架简易实现

           RPC(Remote Procedure Call Protocol)——远程过程调用协议,它是一种通过网络从远程计算机程序上请求服务,而不需要了解底层网络技术的协议.RPC协议假定某些 ...

  6. python开发面向对象基础:封装

    一,封装 [封装] 隐藏对象的属性和实现细节,仅对外提供公共访问方式. [好处] 1. 将变化隔离: 2. 便于使用: 3. 提高复用性: 4. 提高安全性: [封装原则] 1. 将不需要对外提供的内 ...

  7. 浏览器访问IPv6地址

    http://[IPv6]:port/index.html http://[3ffe:3201:1200:1::91]:8080/index.html 目前现在的网络运营商基本都不支持基于IPv6地址 ...

  8. IDA Pro 权威指南学习笔记(一) - 启动 IDA

    启动 IDA 启动 IDA,有一个欢迎界面 之后有一个对话框 选择 New 将启动一个对话框来选择将要分析的文件 选择 Go 将使 IDA 打开一个空白的工作区 如果要选择分析的文件,可以直接拖到 I ...

  9. 基于JNI,JAVA 调用 C++入门

    1.步骤一览 2.步骤详情 2.1. 编写Java类 native package com.ibugs.jni; /** * * @author i_bugs * */ public class CP ...

  10. BurpSuite—-Sequencer模块(定序器)

    一.简介 Burp Sequencer是一种用于分析数据项的一个样本中的随机性质量的工具.你可以用它来测试应用程序的session tokens(会话tokens)或其他重要数据项的本意是不可预测的, ...