dpbf62565 2012-07-03 23:39
浏览 79
已采纳

APC(主干)使用PHP 5.4在CentOS上安装

Has anybody successfully installed APC on php 5.4? According to another thread I found on StackOverflow, seems possible using the latest trunk.

I grabbed trunk, phpize, ./configure, but when I try and run make I get the following errors:

>/bin/sh /root/trunk/libtool --mode=compile cc  -I. -I/root/trunk -DPHP_ATOM_INC -I/root/trunk/include -I/root/trunk/main -I/root/trunk -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib  -DHAVE_CONFIG_H  -g -O2   -c /root/trunk/apc.c -o apc.lo   
libtool: compile:  cc -I. -I/root/trunk -DPHP_ATOM_INC -I/root/trunk/include -I/root/trunk/main -I/root/trunk -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /root/trunk/apc.c  -fPIC -DPIC -o .libs/apc.o    
In file included from /root/trunk/apc.c:44:
/usr/include/php/ext/pcre/php_pcre.h:29:18: error: pcre.h: No such file or directory    
In file included from /root/trunk/apc.c:44:
/usr/include/php/ext/pcre/php_pcre.h:37: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
/usr/include/php/ext/pcre/php_pcre.h:38: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
/usr/include/php/ext/pcre/php_pcre.h:44: error: expected specifier-qualifier-list before ‘pcre’
/root/trunk/apc.c: In function ‘apc_search_paths’:
/root/trunk/apc.c:361: warning: assignment discards qualifiers from pointer target type
/root/trunk/apc.c: At top level:
/root/trunk/apc.c:394: error: expected specifier-qualifier-list before ‘pcre’
/root/trunk/apc.c: In function ‘apc_regex_compile_array’:
/root/trunk/apc.c:455: error: ‘apc_regex’ has no member named ‘preg’
/root/trunk/apc.c:455: error: ‘apc_regex’ has no member named ‘preg’
/root/trunk/apc.c:456: error: ‘apc_regex’ has no member named ‘nreg’
/root/trunk/apc.c:456: error: ‘apc_regex’ has no member named ‘nreg’
/root/trunk/apc.c: In function ‘apc_regex_match_array’:
/root/trunk/apc.c:488: error: ‘apc_regex’ has no member named ‘preg’
/root/trunk/apc.c:488: error: ‘apc_regex’ has no member named ‘preg’
/root/trunk/apc.c:489: error: ‘apc_regex’ has no member named ‘nreg’
/root/trunk/apc.c:489: error: ‘apc_regex’ has no member named ‘nreg’
make: *** [apc.lo] Error 1
  • 写回答

1条回答 默认 最新

  • dopnpoh056622 2012-07-04 01:08
    关注

    You need to have the development headers for PCRE installed.

    If you're on Centos or Fedora (or REPL or ...) you can get them with an:

    • yum install pcre-devel

    If you're on Debian or Ubuntu, you can get them with an:

    • apt-get install libpcre3-dev
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥20 腾讯企业邮箱邮件可以恢复么
  • ¥15 有人知道怎么将自己的迁移策略布到edgecloudsim上使用吗?
  • ¥15 错误 LNK2001 无法解析的外部符号
  • ¥50 安装pyaudiokits失败
  • ¥15 计组这些题应该咋做呀
  • ¥60 更换迈创SOL6M4AE卡的时候,驱动要重新装才能使用,怎么解决?
  • ¥15 让node服务器有自动加载文件的功能
  • ¥15 jmeter脚本回放有的是对的有的是错的
  • ¥15 r语言蛋白组学相关问题
  • ¥15 Python时间序列如何拟合疏系数模型