VC2008配置CppUnit错误!

黑泡泡选手 2009-09-11 11:24:45
error LNK2001: 无法解析的外部符号 "public: static class CppUnit::TestFactoryRegistry & __cdecl CppUnit::TestFactoryRegistry::getRegistry(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (?getRegistry@TestFactoryRegistry@CppUnit@@SAAAV12@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) PlusTestCase.obj UnitTest

error LNK2001: 无法解析的外部符号 "public: __thiscall CppUnit::TestNamer::TestNamer(class type_info const &)" (??0TestNamer@CppUnit@@QAE@ABVtype_info@@@Z) PlusTestCase.obj UnitTest

错误 6 error LNK2001: 无法解析的外部符号 "public: void __thiscall CppUnit::TestSuiteBuilderContextBase::addTest(class CppUnit::Test *)" (?addTest@TestSuiteBuilderContextBase@CppUnit@@QAEXPAVTest@2@@Z) PlusTestCase.obj UnitTest
错误 7 error LNK2001: 无法解析的外部符号 "public: class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall CppUnit::TestSuiteBuilderContextBase::getTestNameFor(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)const " (?getTestNameFor@TestSuiteBuilderContextBase@CppUnit@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@ABV34@@Z) PlusTestCase.obj UnitTest
错误 8 error LNK2001: 无法解析的外部符号 "public: __thiscall CppUnit::TestSuite::TestSuite(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (??0TestSuite@CppUnit@@QAE@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) PlusTestCase.obj UnitTest
错误 9 error LNK2001: 无法解析的外部符号 "public: __thiscall CppUnit::TestSuiteBuilderContextBase::TestSuiteBuilderContextBase(class CppUnit::TestSuite &,class CppUnit::TestNamer const &,class CppUnit::TestFixtureFactory &)" (??0TestSuiteBuilderContextBase@CppUnit@@QAE@AAVTestSuite@1@ABVTestNamer@1@AAVTestFixtureFactory@1@@Z) PlusTestCase.obj UnitTest
错误 10 error LNK2001: 无法解析的外部符号 "public: virtual __thiscall CppUnit::TestSuiteBuilderContextBase::~TestSuiteBuilderContextBase(void)" (??1TestSuiteBuilderContextBase@CppUnit@@UAE@XZ) PlusTestCase.obj UnitTest
错误 11 error LNK2001: 无法解析的外部符号 "public: virtual __thiscall CppUnit::TestNamer::~TestNamer(void)" (??1TestNamer@CppUnit@@UAE@XZ) PlusTestCase.obj UnitTest
错误 12 error LNK2001: 无法解析的外部符号 "public: __thiscall CppUnit::TestCase::TestCase(void)" (??0TestCase@CppUnit@@QAE@XZ) PlusTestCase.obj UnitTest
错误 13 error LNK2001: 无法解析的外部符号 "public: virtual __thiscall CppUnit::TestCase::~TestCase(void)" (??1TestCase@CppUnit@@UAE@XZ) PlusTestCase.obj UnitTest
错误 14 error LNK2001: 无法解析的外部符号 "public: __thiscall CppUnit::SourceLine::SourceLine(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,int)" (??0SourceLine@CppUnit@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@H@Z) PlusTestCase.obj UnitTest
错误 15 error LNK2001: 无法解析的外部符号 "public: virtual __thiscall CppUnit::SourceLine::~SourceLine(void)" (??1SourceLine@CppUnit@@UAE@XZ) PlusTestCase.obj UnitTest
错误 16 error LNK2001: 无法解析的外部符号 "protected: class CppUnit::TestFixture * __thiscall CppUnit::TestSuiteBuilderContextBase::makeTestFixture(void)const " (?makeTestFixture@TestSuiteBuilderContextBase@CppUnit@@IBEPAVTestFixture@2@XZ) PlusTestCase.obj UnitTest
错误 17 error LNK2001: 无法解析的外部符号 "public: __thiscall CppUnit::TestCase::TestCase(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (??0TestCase@CppUnit@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) PlusTestCase.obj UnitTest
错误 18 error LNK2001: 无法解析的外部符号 "public: void __thiscall CppUnit::TestFactoryRegistry::registerFactory(class CppUnit::TestFactory *)" (?registerFactory@TestFactoryRegistry@CppUnit@@QAEXPAVTestFactory@2@@Z) PlusTestCase.obj UnitTest
错误 19 error LNK2001: 无法解析的外部符号 "public: static bool __cdecl CppUnit::TestFactoryRegistry::isValid(void)" (?isValid@TestFactoryRegistry@CppUnit@@SA_NXZ) PlusTestCase.obj UnitTest
错误 20 error LNK2001: 无法解析的外部符号 "public: void __thiscall CppUnit::TestFactoryRegistry::unregisterFactory(class CppUnit::TestFactory *)" (?unregisterFactory@TestFactoryRegistry@CppUnit@@QAEXPAVTestFactory@2@@Z) PlusTestCase.obj UnitTest
错误 21 error LNK2001: 无法解析的外部符号 "public: static void __cdecl CppUnit::Asserter::failNotEqual(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class CppUnit::SourceLine const &,class CppUnit::AdditionalMessage const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?failNotEqual@Asserter@CppUnit@@SAXV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0ABVSourceLine@2@ABVAdditionalMessage@2@0@Z) PlusTestCase.obj UnitTest
错误 22 error LNK2001: 无法解析的外部符号 "public: __thiscall CppUnit::AdditionalMessage::AdditionalMessage(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (??0AdditionalMessage@CppUnit@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) PlusTestCase.obj UnitTest
错误 23 error LNK2001: 无法解析的外部符号 "public: virtual class CppUnit::Test * __thiscall CppUnit::Test::getChildTestAt(int)const " (?getChildTestAt@Test@CppUnit@@UBEPAV12@H@Z) PlusTestCase.obj UnitTest
错误 24 error LNK2001: 无法解析的外部符号 "public: virtual bool __thiscall CppUnit::Test::findTestPath(class CppUnit::Test const *,class CppUnit::TestPath &)const " (?findTestPath@Test@CppUnit@@UBE_NPBV12@AAVTestPath@2@@Z) PlusTestCase.obj UnitTest
错误 25 error LNK2001: 无法解析的外部符号 "public: virtual bool __thiscall CppUnit::Test::findTestPath(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class CppUnit::TestPath &)const " (?findTestPath@Test@CppUnit@@UBE_NABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AAVTestPath@2@@Z) PlusTestCase.obj UnitTest
错误 26 error LNK2001: 无法解析的外部符号 "public: virtual class CppUnit::Test * __thiscall CppUnit::Test::findTest(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)const " (?findTest@Test@CppUnit@@UBEPAV12@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) PlusTestCase.obj UnitTest
错误 27 error LNK2001: 无法解析的外部符号 "public: virtual class CppUnit::TestPath __thiscall CppUnit::Test::resolveTestPath(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)const " (?resolveTestPath@Test@CppUnit@@UBE?AVTestPath@2@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) PlusTestCase.obj UnitTest
错误 28 error LNK2001: 无法解析的外部符号 "protected: virtual void __thiscall CppUnit::Test::checkIsValidIndex(int)const " (?checkIsValidIndex@Test@CppUnit@@MBEXH@Z) PlusTestCase.obj UnitTest
错误 29 error LNK2001: 无法解析的外部符号 "public: virtual void __thiscall CppUnit::TestCase::run(class CppUnit::TestResult *)" (?run@TestCase@CppUnit@@UAEXPAVTestResult@2@@Z) PlusTestCase.obj UnitTest
错误 30 error LNK2001: 无法解析的外部符号 "public: virtual int __thiscall CppUnit::TestLeaf::countTestCases(void)const " (?countTestCases@TestLeaf@CppUnit@@UBEHXZ) PlusTestCase.obj UnitTest
错误 31 error LNK2001: 无法解析的外部符号 "public: virtual int __thiscall CppUnit::TestLeaf::getChildTestCount(void)const " (?getChildTestCount@TestLeaf@CppUnit@@UBEHXZ) PlusTestCase.obj UnitTest
错误 32 error LNK2001: 无法解析的外部符号 "public: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall CppUnit::TestCase::getName(void)const " (?getName@TestCase@CppUnit@@UBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ) PlusTestCase.obj UnitTest
错误 33 error LNK2001: 无法解析的外部符号 "public: virtual class CppUnit::Test * __thiscall CppUnit::TestLeaf::doGetChildTestAt(int)const " (?doGetChildTestAt@TestLeaf@CppUnit@@UBEPAVTest@2@H@Z) PlusTestCase.obj UnitTest
错误 34 error LNK2001: 无法解析的外部符号 "public: virtual void __thiscall CppUnit::TestCase::runTest(void)" (?runTest@TestCase@CppUnit@@UAEXXZ) PlusTestCase.obj UnitTest
错误 35 error LNK2001: 无法解析的外部符号 "__declspec(dllimport) public: __thiscall CppUnit::MfcTestRunner::MfcTestRunner(void)" (__imp_??0MfcTestRunner@CppUnit@@QAE@XZ) UnitTest.obj UnitTest
错误 36 error LNK2001: 无法解析的外部符号 "__declspec(dllimport) public: virtual __thiscall CppUnit::MfcTestRunner::~MfcTestRunner(void)" (__imp_??1MfcTestRunner@CppUnit@@UAE@XZ) UnitTest.obj UnitTest
错误 37 error LNK2001: 无法解析的外部符号 "__declspec(dllimport) public: void __thiscall CppUnit::MfcTestRunner::addTest(class CppUnit::Test *)" (__imp_?addTest@MfcTestRunner@CppUnit@@QAEXPAVTest@2@@Z) UnitTest.obj UnitTest
错误 38 error LNK2001: 无法解析的外部符号 "__declspec(dllimport) public: void __thiscall CppUnit::MfcTestRunner::run(void)" (__imp_?run@MfcTestRunner@CppUnit@@QAEXXZ) UnitTest.obj UnitTest
错误 39 fatal error LNK1120: 35 个无法解析的外部命令 D:\UnitTest\Release\UnitTest.exe 1 UnitTest
...全文
235 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
pomelowu 2009-09-11
  • 打赏
  • 举报
回复
cppunit好像连vc05都不支持吧……
黑泡泡选手 2009-09-11
  • 打赏
  • 举报
回复
确实是库文件和路径导入的问题,刚使用VC2008,不太熟悉这个IDE。
黑泡泡选手 2009-09-11
  • 打赏
  • 举报
回复
啊?是嘛?反正是VC6可以配置,我觉得这问题好像是库函数没导入,但是我做了,不知道什么原因!

16,472

社区成员

发帖
与我相关
我的任务
社区描述
VC/MFC相关问题讨论
社区管理员
  • 基础类社区
  • Web++
  • encoderlee
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

        VC/MFC社区版块或许是CSDN最“古老”的版块了,记忆之中,与CSDN的年龄几乎差不多。随着时间的推移,MFC技术渐渐的偏离了开发主流,若干年之后的今天,当我们面对着微软的这个经典之笔,内心充满着敬意,那些曾经的记忆,可以说代表着二十年前曾经的辉煌……
        向经典致敬,或许是老一代程序员内心里面难以释怀的感受。互联网大行其道的今天,我们期待着MFC技术能够恢复其曾经的辉煌,或许这个期待会永远成为一种“梦想”,或许一切皆有可能……
        我们希望这个版块可以很好的适配Web时代,期待更好的互联网技术能够使得MFC技术框架得以重现活力,……

试试用AI创作助手写篇文章吧