- 论坛徽章:
- 0
|
版主你好!
因为看到大家对FastDFS的评论很好,所以我也想尝试的使用一下,可是在编译和安装php_client的时候发生下列问题,不知道该如何解决,本人对编程不懂。
我的操作系统是linux enterprise 5 (32bit),php是用源码包安装的php-5.2.9,服务器为IBM X M2,已经分别在不同的服务器上面成功安装了1台tracker服务器,和2台storage服务器。按照php_client文件夹里的README的安装说明,在成功执行phpize后,使用./configure --with-fastdfs_client进行编译,接着执行make的时候出现如下错误。(所有操作都是以root用户执行)
/bin/sh /root/Desktop/FastDFS/php_client/libtool --mode=compile cc -I. -I/root/Desktop/FastDFS/php_client -DPHP_ATOM_INC -I/root/Desktop/FastDFS/php_client/include -I/root/Desktop/FastDFS/php_client/main -I/root/Desktop/FastDFS/php_client -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 -I/usr/local/include -DHAVE_CONFIG_H -g -O2 -Werror -Wall -c /root/Desktop/FastDFS/php_client/fastdfs_client.c -o fastdfs_client.lo
mkdir .libs
cc -I. -I/root/Desktop/FastDFS/php_client -DPHP_ATOM_INC -I/root/Desktop/FastDFS/php_client/include -I/root/Desktop/FastDFS/php_client/main -I/root/Desktop/FastDFS/php_client -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 -I/usr/local/include -DHAVE_CONFIG_H -g -O2 -Werror -Wall -c /root/Desktop/FastDFS/php_client/fastdfs_client.c -fPIC -DPIC -o .libs/fastdfs_client.o
/root/Desktop/FastDFS/php_client/fastdfs_client.c:21:25: error: fdfs_client.h: No such file or directory
/root/Desktop/FastDFS/php_client/fastdfs_client.c:22:20: error: logger.h: No such file or directory
/root/Desktop/FastDFS/php_client/fastdfs_client.c:23:25: error: fdfs_global.h: No such file or directory
/root/Desktop/FastDFS/php_client/fastdfs_client.c:24:25: error: shared_func.h: No such file or directory
/root/Desktop/FastDFS/php_client/fastdfs_client.c:25:27: error: client_global.h: No such file or directory
/root/Desktop/FastDFS/php_client/fastdfs_client.c:27:30: error: fdfs_http_shared.h: No such file or directory
/root/Desktop/FastDFS/php_client/fastdfs_client.c:31: error: expected specifier-qualifier-list before ‘TrackerServerGroup’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:36: error: expected specifier-qualifier-list before ‘TrackerServerGroup’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:50: error: ‘g_tracker_group’ undeclared here (not in a function)
cc1: warnings being treated as errors
/root/Desktop/FastDFS/php_client/fastdfs_client.c:50: warning: excess elements in struct initializer
/root/Desktop/FastDFS/php_client/fastdfs_client.c:50: warning: (near initialization for ‘php_context’)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:50: warning: excess elements in struct initializer
/root/Desktop/FastDFS/php_client/fastdfs_client.c:50: warning: (near initialization for ‘php_context’)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:139: error: expected declaration specifiers or ‘...’ before ‘FDFSMetaData’
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘fastdfs_convert_metadata_to_array’:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:151: error: ‘FDFSMetaData’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:151: error: (Each undeclared identifier is reported only once
/root/Desktop/FastDFS/php_client/fastdfs_client.c:151: error: for each function it appears in.)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:151: error: ‘pMetaData’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:157: error: ‘meta_list’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:161: error: expected expression before ‘)’ token
/root/Desktop/FastDFS/php_client/fastdfs_client.c:164: warning: implicit declaration of function ‘logError’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:192: error: ‘FDFS_MAX_META_NAME_LEN’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:203: error: ‘FDFS_MAX_META_VALUE_LEN’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘php_fdfs_tracker_get_connection_impl’:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:239: error: ‘TrackerServerInfo’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:239: error: ‘pTrackerServer’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:247: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:248: error: ‘false’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:251: warning: implicit declaration of function ‘tracker_get_connection_ex’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:251: error: ‘FDFSPhpContext’ has no member named ‘pTrackerGroup’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:254: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:258: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘php_fdfs_tracker_make_all_connections_impl’:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:280: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:281: error: ‘false’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:284: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:284: warning: implicit declaration of function ‘tracker_get_all_connections_ex’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:284: error: ‘FDFSPhpContext’ has no member named ‘pTrackerGroup’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:286: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:288: error: ‘true’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘php_fdfs_tracker_close_all_connections_impl’:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:307: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:308: error: ‘false’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:311: warning: implicit declaration of function ‘tracker_close_all_connections_ex’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:311: error: ‘FDFSPhpContext’ has no member named ‘pTrackerGroup’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:312: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:313: error: ‘true’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘php_fdfs_connect_server_impl’:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:323: error: ‘TrackerServerInfo’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:323: error: expected ‘;’ before ‘server_info’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:331: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:332: error: ‘false’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:340: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:344: error: ‘server_info’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:348: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:348: warning: implicit declaration of function ‘tracker_connect_server’
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘php_fdfs_disconnect_server_impl’:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:380: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:381: error: ‘false’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:389: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:399: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:413: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:414: error: ‘true’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:421: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c: At top level:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:426: error: expected declaration specifiers or ‘...’ before ‘TrackerServerInfo’
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘php_fdfs_get_server_from_hash’:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:434: error: ‘pTrackerServer’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:434: error: ‘TrackerServerInfo’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:454: error: ‘IP_ADDRESS_SIZE’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘php_fdfs_tracker_list_groups_impl’:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:505: error: ‘TrackerServerInfo’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:505: error: expected ‘;’ before ‘tracker_server’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:506: error: ‘pTrackerServer’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:507: error: ‘FDFSGroupStat’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:507: error: expected ‘;’ before ‘group_stats’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:508: error: ‘pGroupStat’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:509: error: ‘pGroupEnd’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:514: error: ‘FDFSStorageInfo’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:514: error: expected ‘;’ before ‘storage_infos’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:515: error: ‘pStorage’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:516: error: ‘pStorageEnd’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:517: error: ‘FDFSStorageStat’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:517: error: ‘pStorageStat’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:525: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:526: error: ‘false’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:537: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:543: error: ‘FDFSPhpContext’ has no member named ‘pTrackerGroup’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:546: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:555: error: ‘tracker_server’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:557: error: too many arguments to function ‘php_fdfs_get_server_from_hash’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:560: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:567: warning: implicit declaration of function ‘tracker_list_groups’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:567: error: ‘group_stats’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:567: error: ‘FDFS_MAX_GROUPS’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:577: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:581: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:621: warning: implicit declaration of function ‘tracker_list_servers’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:621: error: ‘storage_infos’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:621: error: ‘FDFS_MAX_SERVERS_EACH_GROUP’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:627: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘php_fdfs_tracker_query_storage_store_impl’:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:752: error: ‘TrackerServerInfo’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:752: error: expected ‘;’ before ‘tracker_server’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:753: error: expected ‘;’ before ‘storage_server’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:754: error: ‘pTrackerServer’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:765: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:766: error: ‘false’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:777: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:783: error: ‘FDFSPhpContext’ has no member named ‘pTrackerGroup’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:786: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:794: error: ‘tracker_server’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:796: error: too many arguments to function ‘php_fdfs_get_server_from_hash’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:799: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:807: warning: implicit declaration of function ‘tracker_query_storage_store_with_group’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:807: error: ‘storage_server’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:812: warning: implicit declaration of function ‘tracker_query_storage_store_without_group’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:822: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c: At top level:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:840: warning: type defaults to ‘int’ in declaration of ‘byte’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:840: error: expected ‘;’, ‘,’ or ‘)’ before ‘cmd’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:974: warning: type defaults to ‘int’ in declaration of ‘bool’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:974: error: expected ‘;’, ‘,’ or ‘)’ before ‘bFileId’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:1126: warning: type defaults to ‘int’ in declaration of ‘bool’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:1126: error: expected ‘;’, ‘,’ or ‘)’ before ‘bFileId’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:1305: warning: type defaults to ‘int’ in declaration of ‘bool’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:1305: error: expected ‘;’, ‘,’ or ‘)’ before ‘bFileId’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:1471: warning: type defaults to ‘int’ in declaration of ‘bool’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:1471: error: expected ‘;’, ‘,’ or ‘)’ before ‘bFileId’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:1641: warning: type defaults to ‘int’ in declaration of ‘bool’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:1641: error: expected ‘;’, ‘,’ or ‘)’ before ‘bFileId’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:1792: warning: type defaults to ‘int’ in declaration of ‘byte’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:1792: error: expected ‘;’, ‘,’ or ‘)’ before ‘cmd’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:2030: warning: type defaults to ‘int’ in declaration of ‘byte’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:2030: error: expected ‘;’, ‘,’ or ‘)’ before ‘cmd’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:2313: warning: type defaults to ‘int’ in declaration of ‘bool’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:2313: error: expected ‘;’, ‘,’ or ‘)’ before ‘bFileId’
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘php_fdfs_http_gen_token_impl’:
/root/Desktop/FastDFS/php_client/fastdfs_client.c:2534: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:2535: error: ‘false’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:2543: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:2547: warning: implicit declaration of function ‘fdfs_http_gen_token’
/root/Desktop/FastDFS/php_client/fastdfs_client.c:2547: error: ‘g_anti_steal_secret_key’ undeclared (first use in this function)
/root/Desktop/FastDFS/php_client/fastdfs_client.c:2549: error: ‘FDFSPhpContext’ has no member named ‘err_no’
/root/Desktop/FastDFS/php_client/fastdfs_client.c: In function ‘php_fdfs_get_file_info_impl’: |
|