belvine
码农博士
采纳率0%
2017-07-15 15:19 阅读 3.2k

fastdfs报错undefined reference to `g_exe_name'

make: Nothing to be done for all'.
cc -Wall -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -g -O -DDEBUG_FLAG -o fdfs_storaged fdfs_storaged.c ../common/fdfs_global.o ../tracker/fdfs_shared_func.o ../tracker/tracker_proto.o tracker_client_thread.o storage_global.o storage_func.o storage_service.o storage_sync.o storage_nio.o storage_dio.o storage_ip_changed_dealer.o storage_param_getter.o storage_disk_recovery.o trunk_mgr/trunk_mem.o trunk_mgr/trunk_shared.o trunk_mgr/trunk_sync.o trunk_mgr/trunk_client.o trunk_mgr/trunk_free_block_checker.o ../client/client_global.o ../client/tracker_client.o ../client/storage_client.o ../client/client_func.o fdht_client/fdht_proto.o fdht_client/fdht_client.o fdht_client/fdht_func.o fdht_client/fdht_global.o storage_dump.o -L/usr/lib64 -lpthread -lfastcommon -I. -Itrunk_mgr -I../common -I../tracker -I../client -Ifdht_client -I/usr/include/fastcommon
/tmp/ccWmwyMo.o: In function
main':
/home/centos/fastdfs-5.10/storage/fdfs_storaged.c:130: undefined reference to g_exe_name'
storage_dump.o: In function
fdfs_dump_global_vars':
/home/centos/fastdfs-5.10/storage/storage_dump.c:36: undefined reference to g_exe_name'
collect2: error: ld returned 1 exit status
make: *** [fdfs_storaged] Error 1
make: Nothing to be done for
all'.

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 复制链接分享

3条回答 默认 最新

  • nainiu8888 nainiu8888 2018-06-15 16:12

    https://github.com/happyfish100/fastdfs/issues/133
    估计是因为你后来修改了编译参数,在这种情况下,要先执行 ./make.sh clean,然后再重新编译即可。

    点赞 3 评论 复制链接分享
  • caozhy 从今以后生命中的每一秒都属于我爱的人 2017-07-16 02:12
    点赞 1 评论 复制链接分享
  • u011492805 专业遛狗师 2018-04-07 13:22

    me to,一开始下载的是fastdfs_master那个包,然后编译了出现同样错误,然后也安装了libevent,并没什么卵用,最后去下载了fastdfs_5.x.x,然后编译,ok了

    点赞 1 评论 复制链接分享

相关推荐