Help: Linking Error in MFC
Xu Zhou
xuzhou at comp.nus.edu.sg
Wed Jan 8 21:51:50 EST 2003
Dear All,
I am installing the Galib in MFC. I have update the
gaconfig.h with following information,
#if defined(_MSC_VER)
#pragma warning (disable : 4244)
#pragma warning (disable : 4305)
#endif
#define USE_OLD_STREAMS
but when I compiled the ex1, the following link errors happened,
Linking...
ex1.obj : error LNK2001: unresolved external symbol "public: virtual __thiscall GA2DBinaryStringGenome::~GA2DBinaryStringGenome(void)" (??1GA2DBinaryStringGenome@@UAE at XZ)
ex1.obj : error LNK2001: unresolved external symbol "public: virtual __thiscall GASimpleGA::~GASimpleGA(void)" (??1GASimpleGA@@UAE at XZ)
ex1.obj : error LNK2001: unresolved external symbol "public: class GAGenome const & __thiscall GAStatistics::bestIndividual(unsigned int)const " (?bestIndividual at GAStatistics@@QBEABVGAGenome@@I at Z)
ex1.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall GASimpleGA::populationSize(unsigned int)" (?populationSize at GASimpleGA@@UAEHI at Z)
ex1.obj : error LNK2001: unresolved external symbol "public: __thiscall GASimpleGA::GASimpleGA(class GAGenome const &)" (??0GASimpleGA@@QAE at ABVGAGenome@@@Z)
ex1.obj : error LNK2001: unresolved external symbol "public: __thiscall GA2DBinaryStringGenome::GA2DBinaryStringGenome(unsigned int,unsigned int,float (__cdecl*)(class GAGenome &),void *)" (??0GA2DBinaryStringGenome@@QAE at IIP6AMAAVGAGenome@@@ZPAX at Z)
ex1.obj : error LNK2001: unresolved external symbol "void __cdecl GARandomSeed(unsigned int)" (?GARandomSeed@@YAXI at Z)
ex1.obj : error LNK2001: unresolved external symbol "public: void __thiscall GAStatistics::flushScores(void)" (?flushScores at GAStatistics@@QAEXXZ)
ex1.obj : error LNK2001: unresolved external symbol "public: int __thiscall GAParameterList::set(char const *,void const *)" (?set at GAParameterList@@QAEHPBDPBX at Z)
ex1.obj : error LNK2001: unresolved external symbol "public: int __thiscall GAParameterList::set(char const *,double)" (?set at GAParameterList@@QAEHPBDN at Z)
Debug/testGA1.exe : fatal error LNK1120: 10 unresolved externals
Error executing link.exe.
testGA1.exe - 11 error(s), 0 warning(s)
Would you help me to resolve it?
Thanks,
Zhou
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.mit.edu/pipermail/galib/attachments/20030109/5fe04dad/attachment.htm
More information about the galib
mailing list