我正在尝试在 Fedora 17 上为我的 php 安装 json 扩展。
我从这里下载了包
http://pecl.php.net/get/json-1.2.1.tgz
并phpize
在目录中运行,然后配置,一切正常。
但是当我运行make时,会出现这个错误。
我已经搜索了错误,但没有出现任何解决方案。
有什么建议吗?
我必须这样做,因为在我的 php.ini 配置中我得到了“--disable-json”
当我运行 pecl install json 以启用扩展时,请向我显示 pecl 的其他错误。我想从 pecl 手动编译包!
谢谢!
谢谢
[juan@fedoris json-1.2.1]$ sudo make
[sudo] password for juan:
/bin/sh /home/juan/recursos/json-php/json-1.2.1/libtool --mode=compile cc -I. -I/home/juan/recursos/json-php/json-1.2.1 -DPHP_ATOM_INC -I/home/juan/recursos/json-php/json-1.2.1/include -I/home/juan/recursos/json-php/json-1.2.1/main -I/home/juan/recursos/json-php/json-1.2.1 -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/juan/recursos/json-php/json-1.2.1/json.c -o json.lo
cc -I. -I/home/juan/recursos/json-php/json-1.2.1 -DPHP_ATOM_INC -I/home/juan/recursos/json-php/json-1.2.1/include -I/home/juan/recursos/json-php/json-1.2.1/main -I/home/juan/recursos/json-php/json-1.2.1 -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/juan/recursos/json-php/json-1.2.1/json.c -fPIC -DPIC -o .libs/json.o
/home/juan/recursos/json-php/json-1.2.1/json.c:44:1: error: unknown type name ‘function_entry’
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: braces around scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: (near initialization for ‘json_functions[0]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: initialization makes integer from pointer without a cast [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: (near initialization for ‘json_functions[0]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: excess elements in scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: (near initialization for ‘json_functions[0]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: excess elements in scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: (near initialization for ‘json_functions[0]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: excess elements in scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: (near initialization for ‘json_functions[0]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: excess elements in scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:45:5: warning: (near initialization for ‘json_functions[0]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: braces around scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: (near initialization for ‘json_functions[1]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: initialization makes integer from pointer without a cast [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: (near initialization for ‘json_functions[1]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: excess elements in scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: (near initialization for ‘json_functions[1]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: excess elements in scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: (near initialization for ‘json_functions[1]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: excess elements in scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: (near initialization for ‘json_functions[1]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: excess elements in scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:46:5: warning: (near initialization for ‘json_functions[1]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:47:5: warning: braces around scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:47:5: warning: (near initialization for ‘json_functions[2]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:47:5: warning: initialization makes integer from pointer without a cast [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:47:5: warning: (near initialization for ‘json_functions[2]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:47:5: warning: excess elements in scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:47:5: warning: (near initialization for ‘json_functions[2]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:47:5: warning: excess elements in scalar initializer [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:47:5: warning: (near initialization for ‘json_functions[2]’) [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:58:5: warning: initialization from incompatible pointer type [enabled by default]
/home/juan/recursos/json-php/json-1.2.1/json.c:58:5: warning: (near initialization for ‘json_module_entry.functions’) [enabled by default]
make: *** [json.lo] Error 1