当前位置: 首页 > 工具软件 > FileInfo > 使用案例 >

php7.1安装fileinfo_php7.1.7源码安装Fileinfo扩展时,make时报错 make: *** [fileinfo.lo] Error 1...

岑叶秋
2023-12-01

我在centos上源码安装fileinfo扩展,make时报错 make: * [fileinfo.lo] Error 1,在各大平台都搜不到解决方案,求大神指点

我的安装步骤是这样的:

wget下载了fileinfo-1.0.4.tgz包到/usr/local目录

tar zxvf Fileinfo-1.0.4.tgz

cd Fileinfo-1.0.4

/usr/local/php/bin/phpize

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

到这一切都很正常,然后,我继续第五步make && make install时报make: * [fileinfo.lo] Error 1的错误,错误详情具体如下:我想知道这是什么错和怎么解决这个问题,拜托了!

/bin/sh /usr/local/Fileinfo-1.0.4/libtool --mode=compile cc -I. -I/usr/local/Fileinfo-1.0.4 -DPHP_ATOM_INC -I/usr/local/Fileinfo-1.0.4/include -I/usr/local/Fileinfo-1.0.4/main -I/usr/local/Fileinfo-1.0.4 -I/usr/local/php/include/php -I/usr/local/php/include/php/main -I/usr/local/php/include/php/TSRM -I/usr/local/php/include/php/Zend -I/usr/local/php/include/php/ext -I/usr/local/php/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /usr/local/Fileinfo-1.0.4/fileinfo.c -o fileinfo.lo

cc -I. -I/usr/local/Fileinfo-1.0.4 -DPHP_ATOM_INC -I/usr/local/Fileinfo-1.0.4/include -I/usr/local/Fileinfo-1.0.4/main -I/usr/local/Fileinfo-1.0.4 -I/usr/local/php/include/php -I/usr/local/php/include/php/main -I/usr/local/php/include/php/TSRM -I/usr/local/php/include/php/Zend -I/usr/local/php/include/php/ext -I/usr/local/php/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /usr/local/Fileinfo-1.0.4/fileinfo.c -fPIC -DPIC -o .libs/fileinfo.o

/usr/local/Fileinfo-1.0.4/fileinfo.c:159:32: error: unknown type name 'zend_rsrc_list_entry'

void finfo_resource_destructor(zend_rsrc_list_entry *rsrc TSRMLS_DC)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:171:1: error: unknown type name 'function_entry'

function_entry fileinfo_functions[] = {

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: braces around scalar initializer [enabled by default]

PHP_FE(finfo_open, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: initialization makes integer from pointer without a cast [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: error: initializer element is not computable at load time

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: error: (near initialization for 'fileinfo_functions[0]')

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

In file included from /usr/local/php/include/php/main/php.h:39:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_open, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_open, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_open, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_open, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: braces around scalar initializer [enabled by default]

PHP_FE(finfo_close, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: initialization makes integer from pointer without a cast [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: error: initializer element is not computable at load time

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: error: (near initialization for 'fileinfo_functions[1]')

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

In file included from /usr/local/php/include/php/main/php.h:39:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_close, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_close, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_close, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_close, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: braces around scalar initializer [enabled by default]

PHP_FE(finfo_set_flags, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: initialization makes integer from pointer without a cast [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: error: initializer element is not computable at load time

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: error: (near initialization for 'fileinfo_functions[2]')

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

In file included from /usr/local/php/include/php/main/php.h:39:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_set_flags, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_set_flags, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_set_flags, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_set_flags, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: braces around scalar initializer [enabled by default]

PHP_FE(finfo_file, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: (near initialization for 'fileinfo_functions[3]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: initialization makes integer from pointer without a cast [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: (near initialization for 'fileinfo_functions[3]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: error: initializer element is not computable at load time

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: error: (near initialization for 'fileinfo_functions[3]')

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: (near initialization for 'fileinfo_functions[3]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: (near initialization for 'fileinfo_functions[3]') [enabled by default]

In file included from /usr/local/php/include/php/main/php.h:39:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_file, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[3]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_file, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_file, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[3]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_file, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: warning: braces around scalar initializer [enabled by default]

PHP_FE(finfo_buffer, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: warning: (near initialization for 'fileinfo_functions[4]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: warning: initialization makes integer from pointer without a cast [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: warning: (near initialization for 'fileinfo_functions[4]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: error: initializer element is not computable at load time

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: error: (near initialization for 'fileinfo_functions[4]')

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: warning: (near initialization for 'fileinfo_functions[4]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: warning: (near initialization for 'fileinfo_functions[4]') [enabled by default]

In file included from /usr/local/php/include/php/main/php.h:39:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_buffer, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[4]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_buffer, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_buffer, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[4]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:176:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_buffer, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:177:2: warning: braces around scalar initializer [enabled by default]

{NULL, NULL, NULL}

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:177:2: warning: (near initialization for 'fileinfo_functions[5]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:177:2: warning: initialization makes integer from pointer without a cast [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:177:2: warning: (near initialization for 'fileinfo_functions[5]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:177:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:177:2: warning: (near initialization for 'fileinfo_functions[5]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:177:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:177:2: warning: (near initialization for 'fileinfo_functions[5]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c: In function 'zm_startup_finfo':

/usr/local/Fileinfo-1.0.4/fileinfo.c:195:50: error: 'finfo_resource_destructor' undeclared (first use in this function)

le_fileinfo = zend_register_list_destructors_ex(finfo_resource_destructor, NULL, "file_info", module_number);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:195:50: note: each undeclared identifier is reported only once for each function it appears in

/usr/local/Fileinfo-1.0.4/fileinfo.c:195:2: warning: passing argument 1 of 'zend_register_list_destructors_ex' from incompatible pointer type [enabled by default]

le_fileinfo = zend_register_list_destructors_ex(finfo_resource_destructor, NULL, "file_info", module_number);

^

In file included from /usr/local/php/include/php/Zend/zend_API.h:28:0,

from /usr/local/php/include/php/main/php.h:39,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_list.h:44:14: note: expected 'rsrc_dtor_func_t' but argument is of type 'int *'

ZEND_API int zend_register_list_destructors_ex(rsrc_dtor_func_t ld, rsrc_dtor_func_t pld, const char *type_name, int module_number);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c: At top level:

/usr/local/Fileinfo-1.0.4/fileinfo.c:221:2: warning: initialization from incompatible pointer type [enabled by default]

fileinfo_functions,

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:221:2: warning: (near initialization for 'fileinfo_module_entry.functions') [enabled by default]

In file included from /usr/local/php/include/php/main/fopen_wrappers.h:25:0,

from /usr/local/php/include/php/main/php.h:407,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/Fileinfo-1.0.4/fileinfo.c: In function 'zif_finfo_open':

/usr/local/php/include/php/main/php_globals.h:32:29: error: 'struct _php_core_globals' has no member named 'safe_mode'

# define PG(v) (core_globals.v)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:269:8: note: in expansion of macro 'PG'

if ((PG(safe_mode) && (!php_checkuid(file, NULL, CHECKUID_CHECK_FILE_AND_DIR))) || php_check_open_basedir(file TSRMLS_CC)) {

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:269:52: error: 'CHECKUID_CHECK_FILE_AND_DIR' undeclared (first use in this function)

if ((PG(safe_mode) && (!php_checkuid(file, NULL, CHECKUID_CHECK_FILE_AND_DIR))) || php_check_open_basedir(file TSRMLS_CC)) {

^

/usr/local/Fileinfo-1.0.4/fileinfo.c: In function 'zif_finfo_close':

/usr/local/Fileinfo-1.0.4/fileinfo.c:310:29: error: expected expression before 'struct'

ZEND_FETCH_RESOURCE(finfo, struct php_fileinfo *, &zfinfo, -1, "file_info", le_fileinfo);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:312:2: warning: passing argument 1 of 'zend_list_delete' makes pointer from integer without a cast [enabled by default]

zend_list_delete(Z_RESVAL_P(zfinfo));

^

In file included from /usr/local/php/include/php/Zend/zend_API.h:28:0,

from /usr/local/php/include/php/main/php.h:39,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_list.h:59:14: note: expected 'struct zend_resource *' but argument is of type 'int'

ZEND_API int zend_list_delete(zend_resource *res);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c: In function 'zif_finfo_set_flags':

/usr/local/Fileinfo-1.0.4/fileinfo.c:336:30: error: expected expression before 'struct'

ZEND_FETCH_RESOURCE(finfo, struct php_fileinfo *, &zfinfo, -1, "file_info", le_fileinfo);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c: In function '_php_finfo_get_type':

/usr/local/Fileinfo-1.0.4/fileinfo.c:364:30: error: expected expression before 'struct'

ZEND_FETCH_RESOURCE(finfo, struct php_fileinfo *, &zfinfo, -1, "file_info", le_fileinfo);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:375:3: warning: passing argument 2 of 'php_stream_locate_url_wrapper' from incompatible pointer type [enabled by default]

php_stream_wrapper *wrap = php_stream_locate_url_wrapper(buffer, &tmp2, 0 TSRMLS_CC);

^

In file included from /usr/local/php/include/php/main/php.h:405:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/main/php_streams.h:565:28: note: expected 'const char **' but argument is of type 'char **'

PHPAPI php_stream_wrapper *php_stream_locate_url_wrapper(const char *path, const char **path_for_open, int options);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:383:6: error: 'ENFORCE_SAFE_MODE' undeclared (first use in this function)

ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL, context);

^

/usr/local/php/include/php/main/php_streams.h:569:119: note: in definition of macro 'php_stream_open_wrapper_ex'

#define php_stream_open_wrapper_ex(path, mode, options, opened, context) _php_stream_open_wrapper_ex((path), (mode), (options), (opened), (context) STREAMS_CC)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:383:24: error: invalid operands to binary | (have 'int *' and 'int')

ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL, context);

^

/usr/local/php/include/php/main/php_streams.h:569:119: note: in definition of macro 'php_stream_open_wrapper_ex'

#define php_stream_open_wrapper_ex(path, mode, options, opened, context) _php_stream_open_wrapper_ex((path), (mode), (options), (opened), (context) STREAMS_CC)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:382:4: warning: passing argument 3 of '_php_stream_open_wrapper_ex' makes integer from pointer without a cast [enabled by default]

php_stream *stream = php_stream_open_wrapper_ex(buffer, "rb",

^

In file included from /usr/local/php/include/php/main/php.h:405:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/main/php_streams.h:564:20: note: expected 'int' but argument is of type 'int *'

PHPAPI php_stream *_php_stream_open_wrapper_ex(const char *path, const char *mode, int options, zend_string **opened_path, php_stream_context *context STREAMS_DC);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:387:64: error: macro "php_stream_copy_to_mem" passed 4 arguments, but takes just 3

buffer_len = php_stream_copy_to_mem(stream, &tmp, HOWMANY, 0);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:387:17: error: 'php_stream_copy_to_mem' undeclared (first use in this function)

buffer_len = php_stream_copy_to_mem(stream, &tmp, HOWMANY, 0);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:387:15: warning: assignment makes integer from pointer without a cast [enabled by default]

buffer_len = php_stream_copy_to_mem(stream, &tmp, HOWMANY, 0);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:421:27: error: macro "RETURN_STRING" passed 2 arguments, but takes just 1

RETURN_STRING(ret_val, 1);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:421:3: error: 'RETURN_STRING' undeclared (first use in this function)

RETURN_STRING(ret_val, 1);

^

make: *** [fileinfo.lo] Error 1

[root@6cb6d0a4f516 Fileinfo-1.0.4]# make

/bin/sh /usr/local/Fileinfo-1.0.4/libtool --mode=compile cc -I. -I/usr/local/Fileinfo-1.0.4 -DPHP_ATOM_INC -I/usr/local/Fileinfo-1.0.4/include -I/usr/local/Fileinfo-1.0.4/main -I/usr/local/Fileinfo-1.0.4 -I/usr/local/php/include/php -I/usr/local/php/include/php/main -I/usr/local/php/include/php/TSRM -I/usr/local/php/include/php/Zend -I/usr/local/php/include/php/ext -I/usr/local/php/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /usr/local/Fileinfo-1.0.4/fileinfo.c -o fileinfo.lo

cc -I. -I/usr/local/Fileinfo-1.0.4 -DPHP_ATOM_INC -I/usr/local/Fileinfo-1.0.4/include -I/usr/local/Fileinfo-1.0.4/main -I/usr/local/Fileinfo-1.0.4 -I/usr/local/php/include/php -I/usr/local/php/include/php/main -I/usr/local/php/include/php/TSRM -I/usr/local/php/include/php/Zend -I/usr/local/php/include/php/ext -I/usr/local/php/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /usr/local/Fileinfo-1.0.4/fileinfo.c -fPIC -DPIC -o .libs/fileinfo.o

/usr/local/Fileinfo-1.0.4/fileinfo.c:159:32: error: unknown type name 'zend_rsrc_list_entry'

void finfo_resource_destructor(zend_rsrc_list_entry *rsrc TSRMLS_DC)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:171:1: error: unknown type name 'function_entry'

function_entry fileinfo_functions[] = {

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: braces around scalar initializer [enabled by default]

PHP_FE(finfo_open, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: initialization makes integer from pointer without a cast [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: error: initializer element is not computable at load time

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: error: (near initialization for 'fileinfo_functions[0]')

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

In file included from /usr/local/php/include/php/main/php.h:39:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_open, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_open, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_open, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[0]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:172:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_open, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: braces around scalar initializer [enabled by default]

PHP_FE(finfo_close, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: initialization makes integer from pointer without a cast [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: error: initializer element is not computable at load time

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: error: (near initialization for 'fileinfo_functions[1]')

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

In file included from /usr/local/php/include/php/main/php.h:39:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_close, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_close, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_close, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[1]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:173:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_close, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: braces around scalar initializer [enabled by default]

PHP_FE(finfo_set_flags, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: initialization makes integer from pointer without a cast [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: error: initializer element is not computable at load time

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: error: (near initialization for 'fileinfo_functions[2]')

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

In file included from /usr/local/php/include/php/main/php.h:39:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_set_flags, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_set_flags, NULL)

^

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: (near initialization for 'fileinfo_functions[2]') [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

^

/usr/local/php/include/php/Zend/zend_API.h:76:38: note: in expansion of macro 'ZEND_FENTRY'

#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)

^

/usr/local/php/include/php/main/php.h:359:18: note: in expansion of macro 'ZEND_FE'

#define PHP_FE ZEND_FE

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:174:2: note: in expansion of macro 'PHP_FE'

PHP_FE(finfo_set_flags, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: braces around scalar initializer [enabled by default]

PHP_FE(finfo_file, NULL)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: (near initialization for 'fileinfo_functions[3]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: initialization makes integer from pointer without a cast [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: (near initialization for 'fileinfo_functions[3]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: error: initializer element is not computable at load time

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: error: (near initialization for 'fileinfo_functions[3]')

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: (near initialization for 'fileinfo_functions[3]') [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: excess elements in scalar initializer [enabled by default]

/usr/local/Fileinfo-1.0.4/fileinfo.c:175:2: warning: (near initialization for 'fileinfo_functions[3]') [enabled by default]

In file included from /usr/local/php/include/php/main/php.h:39:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/Zend/zend_API.h:70:128: warning: excess elements in scalar initializer [enabled by default]

#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1), flags },

/usr/local/php/include/php/main/php_streams.h:569:119: note: in definition of macro 'php_stream_open_wrapper_ex'

#define php_stream_open_wrapper_ex(path, mode, options, opened, context) _php_stream_open_wrapper_ex((path), (mode), (options), (opened), (context) STREAMS_CC)

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:382:4: warning: passing argument 3 of '_php_stream_open_wrapper_ex' makes integer from pointer without a cast [enabled by default]

php_stream *stream = php_stream_open_wrapper_ex(buffer, "rb",

^

In file included from /usr/local/php/include/php/main/php.h:405:0,

from /usr/local/Fileinfo-1.0.4/fileinfo.c:24:

/usr/local/php/include/php/main/php_streams.h:564:20: note: expected 'int' but argument is of type 'int *'

PHPAPI php_stream *_php_stream_open_wrapper_ex(const char *path, const char *mode, int options, zend_string **opened_path, php_stream_context *context STREAMS_DC);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:387:64: error: macro "php_stream_copy_to_mem" passed 4 arguments, but takes just 3

buffer_len = php_stream_copy_to_mem(stream, &tmp, HOWMANY, 0);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:387:17: error: 'php_stream_copy_to_mem' undeclared (first use in this function)

buffer_len = php_stream_copy_to_mem(stream, &tmp, HOWMANY, 0);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:387:15: warning: assignment makes integer from pointer without a cast [enabled by default]

buffer_len = php_stream_copy_to_mem(stream, &tmp, HOWMANY, 0);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:421:27: error: macro "RETURN_STRING" passed 2 arguments, but takes just 1

RETURN_STRING(ret_val, 1);

^

/usr/local/Fileinfo-1.0.4/fileinfo.c:421:3: error: 'RETURN_STRING' undeclared (first use in this function)

RETURN_STRING(ret_val, 1);

^

make: *** [fileinfo.lo] Error 1

你期待的结果是什么?实际看到的错误信息又是什么?

 类似资料: