Compiling Skaki 1.19 problems

Programming Topics (Computer Chess) and technical aspects as test techniques, book building, program tuning etc

Moderator: Andres Valverde

Compiling Skaki 1.19 problems

Postby Jim Ablett » 21 Feb 2005, 09:09

I'm attempting a bugfix of Skaki 1.19, but I'm having trouble compiling it. I'm using MSVC++ 6. It's compiling the source ok, but when it comes to linking it's throwing up all sorts of errors (about 30).

Any help suggestions would be appreciated.

Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: Compiling Skaki 1.19 problems

Postby Rémi Coulom » 21 Feb 2005, 10:46

Jim Ablett wrote:I'm attempting a bugfix of Skaki 1.19, but I'm having trouble compiling it. I'm using MSVC++ 6. It's compiling the source ok, but when it comes to linking it's throwing up all sorts of errors (about 30).

Any help suggestions would be appreciated.

Jim.

I'd suggest that you post the error messages you get.

R?mi
Rémi Coulom
 
Posts: 96
Joined: 12 Nov 2004, 13:47
Location: Lille, France

Re: Compiling Skaki 1.19 problems

Postby Jim Ablett » 21 Feb 2005, 12:06

Hi Remi,

Here's what I'm getting. (excuse me if I'm doing something
fundamentally stupid - I'm new to MSVC! :? )

Code: Select all
--------------------Configuration: Skaki - Win32 Debug--------------------
Compiling...
Skaki.cpp

Skaki.obj - 0 error(s), 0 warning(s)


--------------------Configuration: Skaki - Win32 Debug--------------------
Linking...
link: executing 'C:\PROGRA~1\MICROS~2\VC98\Bin\link.exe'
LINK : warning LNK4224: /PDBTYPE is no longer supported;  ignored
Skaki.obj : error LNK2001: unresolved external symbol "class OurQueue CommandQ" (?CommandQ@@3VOurQueue@@A)
Skaki.obj : error LNK2019: unresolved external symbol "bool __cdecl QueueMove(enum CommandEnum,class CString)" (?QueueMove@@YA_NW4CommandEnum@@VCString@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "bool __cdecl QueueEdit(class CString)" (?QueueEdit@@YA_NVCString@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "bool __cdecl QueueEp(class CString)" (?QueueEp@@YA_NVCString@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "bool __cdecl QueueCastle(class CString)" (?QueueCastle@@YA_NVCString@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "bool __cdecl QueueRating(class CString)" (?QueueRating@@YA_NVCString@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "bool __cdecl QueueName(class CString)" (?QueueName@@YA_NVCString@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "bool __cdecl QueueResult(class CString)" (?QueueResult@@YA_NVCString@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "bool __cdecl QueuePonder(class CString)" (?QueuePonder@@YA_NVCString@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "bool __cdecl QueueTimeOtim(class CString)" (?QueueTimeOtim@@YA_NVCString@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "bool __cdecl QueueLevel(class CString)" (?QueueLevel@@YA_NVCString@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "void __cdecl QueueSimple(enum CommandEnum)" (?QueueSimple@@YAXW4CommandEnum@@@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "void __cdecl DebugOut(char *,class CString,class CString)" (?DebugOut@@YAXPADVCString@@1@Z) referenced in function _main
Skaki.obj : error LNK2001: unresolved external symbol "class CSingleLock commLock" (?commLock@@3VCSingleLock@@A)
Skaki.obj : error LNK2019: unresolved external symbol "unsigned int __cdecl Engine(void *)" (?Engine@@YAIPAX@Z) referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol "void __cdecl PrintOut(class CString)" (?PrintOut@@YAXVCString@@@Z) referenced in function _main
Skaki.obj : error LNK2001: unresolved external symbol "class CString * Exclude" (?Exclude@@3PAVCString@@A)
Skaki.obj : error LNK2001: unresolved external symbol "int OppTimeAdv" (?OppTimeAdv@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int AspirationWindow" (?AspirationWindow@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int QSkipMargin" (?QSkipMargin@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int MediumEvalDepth" (?MediumEvalDepth@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int FastEvalDepth" (?FastEvalDepth@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int NullDepthEnd" (?NullDepthEnd@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int NullDepthStart" (?NullDepthStart@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int LateEndingValue" (?LateEndingValue@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int EarlyEndingValue" (?EarlyEndingValue@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int OpeningCount" (?OpeningCount@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int SoloQueenFactorS" (?SoloQueenFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int HotSpotFactorS" (?HotSpotFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int KingAttackFactorS" (?KingAttackFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int QueenMobFactorS" (?QueenMobFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int RookMobFactorS" (?RookMobFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int BishopMobFactorS" (?BishopMobFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int KnightMobFactorS" (?KnightMobFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int DevFactorS" (?DevFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int BishopOutpostFactorS" (?BishopOutpostFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int KnightOutpostFactorS" (?KnightOutpostFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int BishopTrapFactorS" (?BishopTrapFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int CastlesFactorS" (?CastlesFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int RookPairFactorS" (?RookPairFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int RatioFactorS" (?RatioFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int TwoBishopFactorS" (?TwoBishopFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int PosKingFactorS" (?PosKingFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int PosRookFactorS" (?PosRookFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int PosKnightFactorS" (?PosKnightFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int PosBishopFactorS" (?PosBishopFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int PosPawnFactorS" (?PosPawnFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int RandomFactorS" (?RandomFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int MaterialFactorS" (?MaterialFactorS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "int NormalizeS" (?NormalizeS@@3HA)
Skaki.obj : error LNK2001: unresolved external symbol "class CString BookFileName" (?BookFileName@@3VCString@@A)
Skaki.obj : error LNK2001: unresolved external symbol "class CFile fDebug" (?fDebug@@3VCFile@@A)
Skaki.obj : error LNK2001: unresolved external symbol "bool GotDebugFile" (?GotDebugFile@@3_NA)
Skaki.obj : error LNK2019: unresolved external symbol @_RTC_CheckStackVars@8 referenced in function _main
Skaki.obj : error LNK2019: unresolved external symbol __RTC_CheckEsp referenced in function _main
Skaki.obj : error LNK2001: unresolved external symbol __RTC_Shutdown
Skaki.obj : error LNK2001: unresolved external symbol __RTC_InitBase
Skaki.obj : error LNK2019: unresolved external symbol "public: __thiscall std::_Lockit::_Lockit(int)" (??0_Lockit@std@@QAE@H@Z) referenced in function "public: class std::locale::facet * __thiscall std::locale::facet::_Decref(void)" (?_Decref@facet@
locale@std@@QAEPAV123@XZ)
Skaki.obj : error LNK2019: unresolved external symbol "public: void __thiscall std::_Mutex::_Unlock(void)" (?_Unlock@_Mutex@std@@QAEXXZ) referenced in function "public: void __thiscall std::basic_streambuf<char,struct std::char_traits<char> >::_Unlo
ck(void)" (?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ)
Skaki.obj : error LNK2019: unresolved external symbol "public: void __thiscall std::_Mutex::_Lock(void)" (?_Lock@_Mutex@std@@QAEXXZ) referenced in function "public: void __thiscall std::basic_streambuf<char,struct std::char_traits<char> >::_Lock(voi
d)" (?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ)
Skaki.obj : error LNK2019: unresolved external symbol "public: void __thiscall std::locale::facet::_Register(void)" (?_Register@facet@locale@std@@QAEXXZ) referenced in function "class std::ctype<char> const & __cdecl std::use_facet<class std::ctype<
char> >(class std::locale const &)" (??$use_facet@V?$ctype@D@std@@@std@@YAABV?$ctype@D@0@ABVlocale@0@@Z)
Skaki.obj : error LNK2019: unresolved external symbol "public: __thiscall bad_cast::bad_cast(char const *)" (??0bad_cast@@QAE@PBD@Z) referenced in function "class std::ctype<char> const & __cdecl std::use_facet<class std::ctype<char> >(class std::lo
cale const &)" (??$use_facet@V?$ctype@D@std@@@std@@YAABV?$ctype@D@0@ABVlocale@0@@Z)
Skaki.obj : error LNK2019: unresolved external symbol "public: class std::locale::facet const * __thiscall std::locale::_Getfacet(unsigned int)const " (?_Getfacet@locale@std@@QBEPBVfacet@12@I@Z) referenced in function "class std::ctype<char> const &
 __cdecl std::use_facet<class std::ctype<char> >(class std::locale const &)" (??$use_facet@V?$ctype@D@std@@@std@@YAABV?$ctype@D@0@ABVlocale@0@@Z)
Skaki.obj : error LNK2019: unresolved external symbol "void __cdecl operator delete(void *,struct std::_DebugHeapTag_t const &,char *,int)" (??3@YAXPAXABU_DebugHeapTag_t@std@@PADH@Z) referenced in function __unwindfunclet$?_Getcat@?$ctype@D@std@@SAI
PAPBVfacet@locale@2@@Z$0
Skaki.obj : error LNK2019: unresolved external symbol "void * __cdecl operator new(unsigned int,struct std::_DebugHeapTag_t const &,char *,int)" (??2@YAPAXIABU_DebugHeapTag_t@std@@PADH@Z) referenced in function "public: static unsigned int __cdecl s
td::ctype<char>::_Getcat(class std::locale::facet const * *)" (?_Getcat@?$ctype@D@std@@SAIPAPBVfacet@locale@2@@Z)
Skaki.obj : error LNK2001: unresolved external symbol "struct std::_DebugHeapTag_t const std::_DebugHeapTag" (?_DebugHeapTag@std@@3U_DebugHeapTag_t@1@B)
Skaki.obj : error LNK2019: unresolved external symbol "void __cdecl operator delete[](void *)" (??_V@YAXPAX@Z) referenced in function "protected: void __thiscall std::ctype<char>::_Tidy(void)" (?_Tidy@?$ctype@D@std@@IAEXXZ)
Debug/Skaki.exe : fatal error LNK1120: 67 unresolved externals
Error executing link.exe.

Skaki.exe - 68 error(s), 1 warning(s)



Jim
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: Compiling Skaki 1.19 problems

Postby Rémi Coulom » 21 Feb 2005, 20:04

It is very likely that the program that you are trying to compile contains other .cpp files besides Skaki.cpp. Those files should contain the definition of QueueEdit, etc. If this is the case, then you should include them into the project along with Skaki.cpp.

The errors at the end of the list tend to indicate that there are other problems.

R?mi
Rémi Coulom
 
Posts: 96
Joined: 12 Nov 2004, 13:47
Location: Lille, France

Re: Compiling Skaki 1.19 problems

Postby Jim Ablett » 21 Feb 2005, 23:19

Thanks for the reply Remi,

Maybe you (or some other kind soul) could maybe
have a go at compiling the source code, then show me how
to do it.

http://homepages.tesco.net/henry.ablett/skaki.zip


Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: Compiling Skaki 1.19 problems

Postby Dann Corbit » 21 Feb 2005, 23:44

Just use the project and code in here:
ftp://cap.connx.com/pub/chess-engines/n ... ki-src.zip

Works fine for me.
Dann Corbit
 

Re: Compiling Skaki 1.19 problems

Postby Sven Schüle » 21 Feb 2005, 23:53

Hi Jim,

the project file Skaki.dsp references two cpp files, Skaki.cpp and skakif.cpp. The latter in turn #include-s all other cpp files. So I think that it should work if you just build the whole Skaki project. Are you working with the MSDevStudio or with the commandline compiler only?

Sven
User avatar
Sven Schüle
 
Posts: 240
Joined: 26 Sep 2004, 20:19
Location: Berlin, Germany

Re: Compiling Skaki 1.19 problems

Postby Jim Ablett » 22 Feb 2005, 10:06

Cracked it!
I appreciate everyone's help - Remi, Dann, Sven.
Compiling ok using Dann's source code.

Thanks,
Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: Compiling Skaki 1.19 problems

Postby Dann Corbit » 22 Feb 2005, 18:59

I forgot to mention that some changes were needed to use modern compilers.

For instance, the include files were old style (e.g.):
Code: Select all
#include <iostream.h>

instead of:
Code: Select all
#include <iostream>
using namespace std; // OK, I'm lazy.
Dann Corbit
 


Return to Programming and Technical Discussions

Who is online

Users browsing this forum: No registered users and 1 guest