Linux搭建Fastdfs文件服务器安装nginx问题
    /home/jumper/fastdfs-nginx-module/src//ngx_http_fastdfs_module.c

In file included from /home/jumper/fastdfs-nginx-module/src//ngx_http_fastdfs_module.c:6:0:
/home/jumper/fastdfs-nginx-module/src//common.c:43:2: error: unknown type name ‘FDFSStorePaths’
FDFSStorePaths store_paths;
^
/home/jumper/fastdfs-nginx-module/src//common.c: In function ‘fdfs_load_groups_store_paths’:
/home/jumper/fastdfs-nginx-module/src//common.c:123:35: error: request for member ‘paths’ in something not a structure or union
group_store_paths[i].store_paths.paths = \
^
/home/jumper/fastdfs-nginx-module/src//common.c:123:3: error: implicit declaration of function ‘storage_load_paths_from_conf_file_ex’ [-Werror=implicit-function-declaration]
group_store_paths[i].store_paths.paths = \
^
/home/jumper/fastdfs-nginx-module/src//common.c:125:58: error: request for member ‘count’ in something not a structure or union
section_name, false, &group_store_paths[i].store_paths.count, \
^
/home/jumper/fastdfs-nginx-module/src//common.c: In function ‘fdfs_mod_init’:
/home/jumper/fastdfs-nginx-module/src//common.c:338:43: error: request for member ‘count’ in something not a structure or union
storage_server_port, g_fdfs_store_paths.count);
^
/home/jumper/fastdfs-nginx-module/src//common.c:339:33: error: request for member ‘count’ in something not a structure or union
for (i=0; i ^
/home/jumper/fastdfs-nginx-module/src//common.c:343:23: error: request for member ‘paths’ in something not a structure or union
g_fdfs_store_paths.paths[i]);
^
/home/jumper/fastdfs-nginx-module/src//common.c:392:48: error: request for member ‘count’ in something not a structure or union
for (i=0; i ^
/home/jumper/fastdfs-nginx-module/src//common.c:396:38: error: request for member ‘paths’ in something not a structure or union
group_store_paths[k].store_paths.paths[i]);
^
/home/jumper/fastdfs-nginx-module/src//common.c:403:16: error: request for member ‘count’ in something not a structure or union
store_paths.count, buff);
^
/home/jumper/fastdfs-nginx-module/src//common.c: In function ‘fdfs_http_request_handler’:
/home/jumper/fastdfs-nginx-module/src//common.c:556:2: error: unknown type name ‘FDFSStorePaths’
FDFSStorePaths *pStorePaths;
^
/home/jumper/fastdfs-nginx-module/src//common.c:651:15: error: assignment from incompatible pointer type [-Werror]
pStorePaths = &g_fdfs_store_paths;
^
/home/jumper/fastdfs-nginx-module/src//common.c:684:15: error: assignment from incompatible pointer type [-Werror]
pStorePaths = &g_fdfs_store_paths;
^
/home/jumper/fastdfs-nginx-module/src//common.c:763:35: error: request for member ‘count’ in something not a structure or union
store_path_index >= pStorePaths->count)
^
/home/jumper/fastdfs-nginx-module/src//common.c:769:34: error: request for member ‘count’ in something not a structure or union
store_path_index, pStorePaths->count);
^
/home/jumper/fastdfs-nginx-module/src//common.c:808:3: error: implicit declaration of function ‘trunk_file_stat_ex1’ [-Werror=implicit-function-declaration]
if ((result=trunk_file_stat_ex1(pStorePaths, store_path_index, \
^
/home/jumper/fastdfs-nginx-module/src//common.c:868:17: error: request for member ‘paths’ in something not a structure or union
pStorePaths->paths[store_path_index], \
^
/home/jumper/fastdfs-nginx-module/src//common.c:973:2: error: implicit declaration of function ‘fdfs_http_get_file_extension’ [-Werror=implicit-function-declaration]
ext_name = fdfs_http_get_file_extension(true_filename, \
^
/home/jumper/fastdfs-nginx-module/src//common.c:973:11: error: assignment makes pointer from integer without a cast [-Werror]
ext_name = fdfs_http_get_file_extension(true_filename, \
^
/home/jumper/fastdfs-nginx-module/src//common.c:977:2: error: passing argument 3 of ‘fdfs_http_get_content_type_by_extname’ makes pointer from integer without a cast [-Werror]
if (fdfs_http_get_content_type_by_extname(&g_http_params, \
^
In file included from /home/jumper/fastdfs-nginx-module/src//common.c:27:0,
from /home/jumper/fastdfs-nginx-module/src//ngx_http_fastdfs_module.c:6:
/usr/local/include/fastdfs/fdfs_http_shared.h:103:5: note: expected ‘char ’ but argument is of type ‘int’
int fdfs_http_get_content_type_by_extname(FDFSHTTPParams *pParams, \
^
In file included from /home/jumper/fastdfs-nginx-module/src//ngx_http_fastdfs_module.c:6:0:
/home/jumper/fastdfs-nginx-module/src//common.c:977:2: error: passing argument 4 of ‘fdfs_http_get_content_type_by_extname’ makes integer from pointer without a cast [-Werror]
if (fdfs_http_get_content_type_by_extname(&g_http_params, \
^
In file included from /home/jumper/fastdfs-nginx-module/src//common.c:27:0,
from /home/jumper/fastdfs-nginx-module/src//ngx_http_fastdfs_module.c:6:
/usr/local/include/fastdfs/fdfs_http_shared.h:103:5: note: expected ‘int’ but argument is of type ‘char *’
int fdfs_http_get_content_type_by_extname(FDFSHTTPParams *pParams, \
^
In file included from /home/jumper/fastdfs-nginx-module/src//ngx_http_fastdfs_module.c:6:0:
/home/jumper/fastdfs-nginx-module/src//common.c:977:2: error: too many arguments to function ‘fdfs_http_get_content_type_by_extname’
if (fdfs_http_get_content_type_by_extname(&g_http_params, \
^
In file included from /home/jumper/fastdfs-nginx-module/src//common.c:27:0,
from /home/jumper/fastdfs-nginx-module/src//ngx_http_fastdfs_module.c:6:
/usr/local/include/fastdfs/fdfs_http_shared.h:103:5: note: declared here
int fdfs_http_get_content_type_by_extname(FDFSHTTPParams *pParams, \
^
In file included from /home/jumper/fastdfs-nginx-module/src//ngx_http_fastdfs_module.c:6:0:
/home/jumper/fastdfs-nginx-module/src//common.c:1092:3: error: unknown type name ‘ConnectionInfo’
ConnectionInfo storage_server;
^
/home/jumper/fastdfs-nginx-module/src//common.c:1096:24: error: request for member ‘ip_addr’ in something not a structure or union
strcpy(storage_server.ip_addr, file_info.source_ip_addr);
^
/home/jumper/fastdfs-nginx-module/src//common.c:1097:17: error: request for member ‘port’ in something not a structure or union
storage_server.port = the_storage_port;
^
/home/jumper/fastdfs-nginx-module/src//common.c:1098:17: error: request for member ‘sock’ in something not a structure or union
storage_server.sock = -1;
^
/home/jumper/fastdfs-nginx-module/src//common.c:1104:3: error: passing argument 2 of ‘storage_download_file_ex1’ from incompatible pointer type [-Werror]
result = storage_download_file_ex1(NULL, \
^
In file included from /usr/local/include/fastdfs/fdfs_client.h:17:0,
from /home/jumper/fastdfs-nginx-module/src//common.c:28,
from /home/jumper/fastdfs-nginx-module/src//ngx_http_fastdfs_module.c:6:
/usr/local/include/fastdfs/storage_client1.h:274:5: note: expected ‘struct TrackerServerInfo *’ but argument is of type ‘int *’
int storage_download_file_ex1(TrackerServerInfo *pTrackerServer, \
^
In file included from /home/jumper/fastdfs-nginx-module/src//ngx_http_fastdfs_module.c:6:0:
/home/jumper/fastdfs-nginx-module/src//common.c:1133:3: error: implicit declaration of function ‘trunk_get_full_filename_ex’ [-Werror=implicit-function-declaration]
trunk_get_full_filename_ex(pStorePaths, &trunkInfo, \
^
/home/jumper/fastdfs-nginx-module/src//common.c:1143:16: error: request for member ‘paths’ in something not a structure or union
pStorePaths->paths[store_path_index], \
^
cc1: all warnings being treated as errors
make[1]: *
* [objs/addon/src/ngx_http_fastdfs_module.o] Error 1
make[1]: Leaving directory `/home/jumper/nginx-1.0.11'
make: *** [build] Error 2

1个回答

implicit declaration of function ‘storage_download_file_ex1’
我也遇到这种问题,怎么解决的啊

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问
相关内容推荐