downloading xboard

Nice!

now I entered this command: kimon@Host-001:~/Downloads/stockfish-dd-src/src> sudo make install
root’s password:
mkdir -p -m 755 /usr/local/bin
cp stockfish /usr/local/bin
strip /usr/local/bin/stockfish
kimon@Host-001:~/Downloads/stockfish-dd-src/src>

Now the stockfish is installed too? btw I think xboard needs polyglot for UCI-engines but never heard of configuring xboard. If you can do it at some point that`s good also. I want stockfish run with xboard and after that connect to ics.

Oh, right. stockfish20 is available at Packman as well. (Somehow I didn’t find it…)
http://packman.links2linux.de/package/stockfish20

So I would suggest to just add the Packman repo (as I already explained in http://forums.opensuse.org/showthread.php/495509-downloading-xboard?p=2624994#post2624994) and install polyglot and stockfish20 from there with “sudo zypper in polyglot stockfish20”
Then try what oldcpu posted.

You can uninstall your self-compiled version with:

sudo rm /usr/local/bin/stockfish

I have to confess that I never really used xboard myself (although I have it installed). I prefer knights (a KDE application which also supports the XBoard protocol), but only ever used the phalanx and crafty engines.

Nice!

maybe it would be wise to use stockfish DD already compiled and installed. Polyglot distribution comes also with Linux and compiling should not be necessary on those systems unless you want to make change in the program. Installation: On Linux and
Mac OS X only the file “polyglot_linux” or “polyglot_mac” is required. Not sure if my files meet this requirement I have polyglot_linux in downloads> polyglot_14> polyglot_linux. Next I tried this command in the terminal window: xboard -fUCI -fcp stockfish -sUCI -scp stockfish
After that it opens xboard and says: Failed to start first chess program polyglot -noini -ec “stockfish” -ed “.” -uci NalimovCache=4 on localhost: polyglot: No such file or directory. So something is missing I have not put the stockfish executable in /usr/games directory (how is this done?) or polyglot is in wrong folder?

Hope this is somewaht helpful: http://rybkaforum.net/cgi-bin/rybkaforum/topic_show.pl?tid=15759

thx

You only have it in the Downloads folder, it’s not found there.

But again, better use the packages from the Packman repo. Add the repo like described in post#8
You can then install polyglot and stockfish with:

sudo zypper in polyglot stockfish20

And according to oldcpu you should then run xboard like this:

xboard -fd '/usr/share/stockfish20' -fcp 'polyglot stockfish20.ini'

(the “-size medium” is not necessary, this just specifies the board size)
And I just tried that, it works fine here.
You can change the polyglot engine settings inside xboard then.

Ok i will try that one later…

Now, however, my
Unix implementation does not search the current directory as PATH. I tried to prepend “./“ to command lines like ./polyglot …
./stockfish …
etc

That didnt work I tried http://www.gnu.org/software/xboard/FAQ.html#tag-C.2 but I cant type configure in terminal for some reason.

Suggestions for improvements are welcome!

That’s normal. You can configure this in YaST->Security and Users->Security Center and System Hardening.
But there are good reasons why this is off by default.

I tried to prepend “./“ to command lines like ./polyglot …
./stockfish …
etc

Are they in the current directory?
Are they marked as executable?

ls -l ./polyglot ./stockfish

That didnt work I tried http://www.gnu.org/software/xboard/FAQ.html#tag-C.2 but I cant type configure in terminal for some reason.

???
Why are you trying to compile xboard yourself now? I thought you already installed it using zypper.

You have to cd to the correct directory first, and then run ./configure, that should work. (as you already noticed yourself, the current directory is not in the PATH by default)

Ok I went to security center and hardering -> security overview -> security settings there was use current directory in root`s path status:unknown. I was unable to change that setting. Then there was use current directory in path of regular users. I changed that from disabled to enabled. Then I went back to the terminal window and tried the command:
ls -l ./polyglot ./stockfish and there was ls: cannot access ./polyglot: No such file or directory
ls: cannot access ./stockfish: No such file or directory

I have stockfish + polyglot files in downloads (which is the current directory), maybe I should create a separate directory for them? Now the only directory for them is downloads.

On 2014-02-17 15:56, matrix wrote:
>
> Ok I went to security center and hardering -> security overview ->
> security settings there was use current directory in root`s path
> status:unknown. I was unable to change that setting. Then there was use
> current directory in path of regular users. I changed that from disabled
> to enabled.

That’s a very bad idea.


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))

If they are in the Downloads folder, you could also use something like ~/Downloads/polyglot. Then it doesn’t matter what is the current directory.

But are they really in Downloads? Apparently not, if Downloads is the current directory.
Most likely they are in a subdirectory. Please post the output of:

ls ~/Downloads

(~ means your home directory btw)

But why don’t you just use the RPMs like I told you before? Would be far easier I guess, and you would get eventual updates automatically.

Ok

I will try to keep things brief here. I have installed xboard as RPMs like I was told to do from this link: http://software.opensuse.org/package/xboard. So it is RPMs and not compiled and installed like stockfish-dd-src is in my downloads. To make stockfish source code and xboard work together with the command xboard -fUCI -fcp stockfish -sUCI -scp stockfish I think I need to uninstall my one-click installed xboard and instead download the sources of xboard from here: http://www.gnu.org/software/xboard/ compile and install like stockfish.

Then I can go Downloads/stockfish-dd-src or xboard-4.7.2 and what important have them all in the same directory. Tell me if I`m too wrong on this. Also next what I would like to do is to uninstall the xboard downloaded from here: http://software.opensuse.org/package/xboard
so general instructions how to do that are also welcomed.

Thx

No, you don’t have to uninstall xboard and compile it yourself.
That line (or similar) should just work fine with the already installed xboard.

Why don’t you try to install polyglot and stockfish20 from the Packman repo as I already wrote how to do?
Then this should work to run xboard with stockfish as first and second engine as you apparently want to achieve:

xboard -fd '/usr/share/stockfish20' -fcp 'polyglot stockfish20.ini' -sd '/usr/share/stockfish20' -scp 'polyglot stockfish20.ini'

Actually this should work as well:

xboard -fcp 'polyglot stockfish20.ini' -scp 'polyglot stockfish20.ini'

The -fd (and -sd) options are already part of that stockfish20.ini file.
And you don’t need -fUCI if you specify -fcp ‘polyglot stockfish20.ini’. (the same with -sUCI and -scp ‘polyglot stockfish20.ini’)

Ok

Now I have stockfish in xboard, I added the packman repo and installed polyglot and stockfish with sudo zypper in polyglot stockfish20. After that I entered
xboard -fd ‘/usr/share/stockfish20’ -fcp ‘polyglot stockfish20.ini’ -sd ‘/usr/share/stockfish20’ -scp ‘polyglot stockfish20.ini’

thx now working. Next question-> how can I connect to internet chess server like (icc) I have an account there.

I would also like to have (good) opening book with xboard, last time there was polyglot book not valid (need to work a little to be able to create own book!)

Sorry, I can’t really answer that, as I never tried it. And I don’t have an account.

Maybe someone else could help here. oldcpu maybe? :wink:

You might have to give yourself write permissions to /usr/share/stockfish20/Book.bin (I think that’s the opening book):

sudo chmod +w /usr/share/stockfish20/Book.bin

Or maybe it’s possible to create and use a new one in your home directory, but I can’t tell you how, sorry.

I do not believe opening books are associated with Xboard. Xboard to the best of my knowledge is just a front end to chess engines. I believe one needs to search for opening books with specific chess engines or with Polygot.

With my Packman packaged stockfish20, I note it comes with an opening Book:


-rw-r--r-- 1 root root 15364320 Jan  8 09:09 /usr/share/stockfish20/Book.bin 

I don’t know if that book was put there by the Packman packager, or if it comes with the basic Stockfish.

Now I’ve never tried to install an opening book with a chess engine, but for example I note Stockfish is based on Glaurung, and from the Glaurung readme.txt I note:


3. Opening books
----------------

This version of Glaurung has experimental support for PolyGlot opening
books.  For information about how to create such books, consult the
PolyGlot documentation.  The book file can be selected by setting the
UCI parameter "Book File".

A book file contributed by Salvo Spitaleri can be found on the
Glaurung web page

So one needs to go to the PolyGlot documentation to create one’s own book (… could be time consuming and difficult) … and to get a head start one could go to the Glaurung web page. I did go to the Glaurung web page and I could not see a link to an opening book. I did note this page on Salvo Spialeri: http://chessprogramming.wikispaces.com/Salvo+Spitaleri That in turn takes one here: http://wbec-ridderkerk.nl/html/download.htm where in turn there is a ZIP file here. Inside the ZIP file are three PGN files, which I assume correspond to an opening book. I also note from what I have read is that this book is limited to 8-moves deep, which is not very deep for an opening book.

Anyway, assuming one wishes to further with the Salvo Spialeri 8-move deep book, then I note from the Polygot web page:


Opening Book
------------

PolyGlot 1.4 provides a simplistic opening-book implementation.

The following options can be added to the [PolyGlot] section:

- "Book" (default: false)

Indicates whether a PolyGlot book should be used.  This has no effect
on the engine own book (which can be controlled with the UCI option
"OwnBook" in the [Engine] section).  In particular, it is possible to
use both a PolyGlot book and an engine book.  In that case, the engine
book will be used whenever PolyGlot is out of book.  Remember that
PolyGlot is unaware of whether the engine is itself using a book or
not.

- "BookFile"

The name of the (binary) book file.  Note that PolyGlot will look for
it in the directory it was launched from, not in the engine directory.
Of course, full path can be used in which case the current directory
does not matter.

Note that there is no option to control book usage.  All parameters
are fixed when compiling a PGN file into a binary book (see below).
This is purposeful and is not likely to change.

Using a book does not require any additional memory, this can be
important for memory-limited tournaments.

A default book "fruit.bin" is provided in the archive.  Note that this
book is very small and should probably not be used in serious games.
I hope that users will make other books available in the future.

so one needs to ‘compile’ the PGN files , and if I then read further I note:


Book Making
-----------

You can compile a PGN file into a binary book using PolyGlot on the
command line.  At the moment, only a main (random) book is provided.
It is not yet possible to control opening lines manually.  I am
working on it though.

Usage: "polyglot make-book ".

"make-book" options are:

- "-pgn"

Name of the input PGN file.  PolyGlot should support any
standard-conforming file.  Let me know if you encounter a problem.

- "-bin"

Name of the output binary file.  I suggest ".bin" as the extension but
in fact PolyGlot does not care.

- "-max-ply" (default: infinite)

How many plies (half moves) to read for each game.  E.g. if set to
"20", only the first 10 full moves of each game will be scanned.

- "-min-game" (default: 3)

How many times must a move be played to be kept in the book.  In other
words, moves that were played too rarely will be left out.  If you
scan full games "2" seems a minimum, but if you selected lines
manually "1" will make sense.

- "-only-white" *** NEW ***

Save only white moves.  This allows to use different parameters for
white and black books, and merge them into a single file with the
"merge-book" command, see below.

- "-only-black" *** NEW ***

Same for black moves.

- "-uniform" *** NEW ***

By default, a probability is calculated by PolyGlot for each move
depending on how popular it is (how often it was playing in the
provided PGN file) and how much it "scored".  This option bypasses the
default mechanism and affects equal probability to all moves.  This
allows more variety of play.

This option is normally used only with hand-selected lines (e.g. "user
books").

---

Example: "polyglot make-book -pgn games.pgn -bin book.bin -max-ply 30".

Building a book is usually very fast (a few minutes at most).  Note
however that a lot of memory may be required.  To reduce memory usage,
select a ply limit.

and one can read more here: http://wbec-ridderkerk.nl/html/details1/PolyGlot.html

Again, I have not done this myself, but it does not read to be too difficult. If you discover an easy guide somewhere , please advise and I’ll link to it from my chess page.

wrt ICS, I’ve never tried to connect to an ICS server with a GNU/Linux program, so I can not provide any advice there.

Ignoring the above post of mine, if you simply search with google for ‘Polygot chess opening book’ you will get a lot of hits.

http://www.gnu.org/software/xboard/manual/html_node/ICS-options.html

Ok next I entered in the terminal window ->
#!/bin/sh -f
# configure modem and fire up XBoard

      # configure modem
      (
        stty 2400 ; stty raw ; stty hupcl ; stty -clocal
        stty ignbrk ; stty ignpar ; stty ixon ; stty ixoff
        stty -iexten ; stty -echo
      ) < /dev/modem
      xboard -ics -icscomm /dev/modem

xboard: Could not open comm port /dev/modem: No such file or directory

Ok first if possible I should be able to connect to ics and then maybe create changes in the book file, change engine etc.

Well, I don’t think you want to connect to a server via an old telephone modem, do you?
You’d rather do it via the Internet I guess. :wink:

If you have an Internet connection you shouldn’t have to do anything special I think.
Just use something like:

xboard -ics -icshost *name_of_chessserver*

Maybe you would need the -icsport option as well, depending on the server.
But as I said, I never tried this either.

Yes!

I originally wanted stockfish DD engine (which is the latest version and stronger than stockfish 2 which is currently installed). I still have stockfish DD in my downloads compiled and installed so I wonder if its possible to transfer that engine to xboard. I tried to go to downloads-> polyglot rpm to change the stockfish20 ini file to stockfish DD but there are all those rpm files I dont know what to do with my data processing skills.

  1. One option would be to construct xboard on my own and get stockfishDD source code somehow to working with it and after that somehow to connect to ics maybe with the command:
    xboard -ics -icshost Main … And after that somehow specify the -ics port option
  2. I don`t even know how to uninstall files/programs using terminal window in opensuse13.1 (how do I know which command I should use every time?)

Anyway thx