从带有makefile的终端编译时出现错误

error when compiling from a Terminal with a makefile

本文关键字:错误 编译 终端 makefile      更新时间:2023-10-16

我正在尝试在Mac OS X 10.10中重新编译命令行程序。我上次这么做是在几年前,效果很好。我现在得到以下错误:

  HapList::Output(std::ostream&, std::vector<int, std::allocator<int> > const*, double, bool) in HapList2.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [PHASE] Error 1

我在这方面是个新手,除了在命令行提示符下输入"make"之外,我所知甚少。很明显,这与x86_64架构有关,但它在OS X Lion下编译得很好。有没有人有任何线索如何解决这个问题?

马特

错误说明函数HapList::Output已经声明,但是在构建过程中没有找到它的定义(函数体)。

找到该函数的定义所在的位置,并使用它来找出为什么它没有被包含在构建中