libfastcommon icon indicating copy to clipboard operation
libfastcommon copied to clipboard

libfastcommon编译不通过

Open hhlehh opened this issue 3 years ago • 3 comments

common_define.h文件中: #define st_atimensec st_atim.tv_nsec #define st_mtimensec st_mtim.tv_nsec #define st_ctimensec st_ctim.tv_nsec 这几行内容编译时报错:error: expected ':', ',', ';', '}' or 'attribute' before '.' token,这是什么原因呢,这些内容的作用是什么,注释掉有什么影响吗

hhlehh avatar Apr 15 '21 05:04 hhlehh

你用的什么编译器及版本呢?

happyfish100 avatar Apr 16 '21 23:04 happyfish100

gcc -Wall -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -g -O1 -DDEBUG_FLAG -c -o ../common/fdfs_global.o ../common/fdfs_global.c -I../common -I/usr/local/include In file included from ../common/fdfs_global.c:21:0: ../common/fdfs_global.h:15:26: 致命错误:sf/sf_global.h:没有那个文件或目录 拉取最新的安装fastDfs不成功,少了很多文件

SakuraLQY avatar Sep 17 '22 02:09 SakuraLQY

需要先编译和安装 libserverframe,v6.09新引入的网络框架库。

happyfish100 avatar Sep 17 '22 03:09 happyfish100