Compiling Sjeng 7.0-11.2

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

outAtime
Posts: 226
Joined: Sun Mar 08, 2009 3:08 pm
Location: Canada

Compiling Sjeng 7.0-11.2

Post by outAtime »

Ive been trying to compile (any) version of sjeng with cygwin and have
it run in arena. Ive tried a multitude of versions and find the engines will either load and then not move, or simply not load at all. I also noticed there is call for a gdbm library and automake and autoconfig etc in some versions and Im not sure how they work in cygwin. Any help or advice
about how to get any sjeng source to compile in cygwin and run in arena would be greatly appreciated. Is it even possible? So far ./configue
followed by make install has created .o and .exe but nothing runs. What do I need to do to make this run?
outAtime
Dann Corbit
Posts: 12537
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: Compiling Sjeng 7.0-11.2

Post by Dann Corbit »

When you run the binary from the command line, what happens?

Wild guess:
You did not copy the cygwin dll file to the folder where you are launching the program from. The cygwin binaries will only run under the cygwin interface unless you have the cygwin dll in your path somewhere.
outAtime
Posts: 226
Joined: Sun Mar 08, 2009 3:08 pm
Location: Canada

Re: Compiling Sjeng 7.0-11.2

Post by outAtime »

I have the cygwin.dll and have used it for other compiles, however I havent run a binary from a command line, so I dont know how or what it might say. This is the info from the debug window:


271.922********Starting engine 2 Sjeng [001]
272.250*2*-----------------------Starting engine 2 Sjeng [001]------------------------
272.250*2*Configured Engine 2 Type: UCI
272.250**Loading book: D:\Arena\Books\Books\Balanced-14.abk
272.470*2*Engine 2 dir: D:\cygwin\home\Owner\Sjeng-old\Sjeng-7.0
272.500*2*Engine 2 commandline: D:\cygwin\home\Owner\Sjeng-old\Sjeng-7.0\sjeng.exe
272.703*2*Engine 2 ProcessID: 24132
272.735<--2:No opening book found.
272.735<--2:Sjeng version 7.0, Copyright (C) 2000 Gian-Carlo Pascutto
272.735<--2:Sjeng comes with ABSOLUTELY NO WARRANTY; for details type 'warranty'
272.735<--2:This is free software, and you are welcome to redistribute it
272.735<--2:under certain conditions; type 'distribution'
272.735<--2:+----+----+----+----+----+----+----+----+
272.735<--2:8 | *R | *N | *B | *Q | *K | *B | *N | *R |
272.735<--2:+----+----+----+----+----+----+----+----+
272.735<--2:7 | *P | *P | *P | *P | *P | *P | *P | *P |
272.735<--2:+----+----+----+----+----+----+----+----+
272.735<--2:6 | | | | | | | | |
272.735<--2:+----+----+----+----+----+----+----+----+
272.735<--2:5 | | | | | | | | |
272.735<--2:+----+----+----+----+----+----+----+----+
272.735<--2:4 | | | | | | | | |
272.735<--2:+----+----+----+----+----+----+----+----+
272.735<--2:3 | | | | | | | | |
272.735<--2:+----+----+----+----+----+----+----+----+
272.735<--2:2 | P | P | P | P | P | P | P | P |
272.735<--2:+----+----+----+----+----+----+----+----+
272.735<--2:1 | R | N | B | Q | K | B | N | R |
272.735<--2:+----+----+----+----+----+----+----+----+
272.735<--2:a b c d e f g h
272.860-->2:uci
272.953<--2:Sjeng: Illegal move: uci

so the engine is not making any move, from the book or otherwise. Somthing must be missing in the compile? It would be great to have this working.
outAtime
outAtime
Posts: 226
Joined: Sun Mar 08, 2009 3:08 pm
Location: Canada

Re: Compiling Sjeng 7.0-11.2

Post by outAtime »

I really do wish all I had to do was include the cygwin dll :)
I hope the solution will prove similarly simple.
I was somewhat confused when you asked what happens when you run
the binary from the command line and I had already posted again by the time I realized what you meant, however I managed to include some info from the debug window. Thanks again I appreciate any help on this.
outAtime
User avatar
Robert
Posts: 20
Joined: Tue Oct 07, 2008 2:53 am
Location: Brasil

Re: Compiling Sjeng 7.0-11.2

Post by Robert »

Sjeng is a "xboard" engine and not "UCI" right?
:roll:
outAtime
Posts: 226
Joined: Sun Mar 08, 2009 3:08 pm
Location: Canada

Re: Compiling Sjeng 7.0-11.2

Post by outAtime »

Arena is listed as a supported interface at Sjeng site. There is no mention
there about needing Wb2Uci or anything like that, I think that would be
mainly for running wb engines in fritz or something.
outAtime
User avatar
Zach Wegner
Posts: 1922
Joined: Thu Mar 09, 2006 12:51 am
Location: Earth

Re: Compiling Sjeng 7.0-11.2

Post by Zach Wegner »

because Arena supports Xboard engines natively, of course...
User avatar
Robert
Posts: 20
Joined: Tue Oct 07, 2008 2:53 am
Location: Brasil

Re: Compiling Sjeng 7.0-11.2

Post by Robert »

Arena support both protocols, i know.
But you must properly configure the interface telling wich engine is UCI and wich is XBoard.
Seems Sjeng is configured as UCI in your Arena.

sorry about my poor english :cry:
Gian-Carlo Pascutto
Posts: 1243
Joined: Sat Dec 13, 2008 7:00 pm

Re: Compiling Sjeng 7.0-11.2

Post by Gian-Carlo Pascutto »

outAtime wrote: 272.953<--2:Sjeng: Illegal move: uci

so the engine is not making any move, from the book or otherwise. Somthing must be missing in the compile? It would be great to have this working.
As somebody else correctly diagnosed, your compile is working correctly, but you have your graphical interface set up wrong. Sjeng-Free does not support UCI, you have to set the GUI to winboard/xboard protocol.
outAtime
Posts: 226
Joined: Sun Mar 08, 2009 3:08 pm
Location: Canada

Re: Compiling Sjeng 7.0-11.2

Post by outAtime »

It works! It works! Thanks! I knew it would be somthing simple...

Do I need the libGBDM? cygwin searches for automake autoheader etc
which I dont have. Would I place those in one of the cygwin directories
or in the engine file? Will having them improve the performance of any of these engines? Sjeng-Free 7.0 is working without them, so Im not sure why config is looking for them.

Thanks again for saving me so much time for somthing simple I was unaware of the UCI/WB setting.

:D
outAtime