[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[XBoard-devel] Engine-install options

From: h . g . muller
Subject: [XBoard-devel] Engine-install options
Date: Sat, 26 Oct 2013 10:43:32 +0200
User-agent: SquirrelMail

I have conceived a few new options for XBoard, which are intended to offer
better possibilities for installing new engines:

-versionNumber N

This option is always saved into the settings file as the actual
compiled-in version number of the binary. This allows XBoard to recognize
if a user settings file was created by another version, i.e. if the
current session is the first one after an upgrade

-installEngine STRING

This option belongs to a new class (ArgInstall) of options, which, stead
of setting the value of a string variable, append their argument to a
string variable, as a new line (i.e. also adding an extra linefeed at the
end). In this case the string variable it refers to is
  The appending is conditional, and only done when STRING is not already
in the the string to which it should be appended (avoiding duplicates),
and when the value of -versionNumber (read from the settings file)
differs from the version of the binary. So that it is possible to
include -installEngine options in the distributed xboard.conf master
settings file, to add new default engines to the user's engine list
without overwriting the latter.


This (ArgTrue) option makes XBoard close immediately after reading its
settings file and command-line arguments, (before it brings up the GUI),
saving the settings on exit as usual, so that changes to the settings
specified on the command line will be incorporated into the saved
settings. Because the presence of this option also enables execution of
options of the ArgInstall class (like a versionNumber difference would
do), it can be used to call XBoard from install scripts of engine packages
such as GNU Shogi. These could specify the command

xboard -installEngine '"GNU Shogi" -fcp "gnushogi --xboard-mode" -variant
shogi' -autoClose

to add GNU Shogi automatically and silently to XBoard's engine list
without causing other side effects.

I also introduced a new convention in interpreting Linux file names: a
file-name option that starts with ~~ will get the ~~ expanded to
$(datadir)/games/xboard (-D'ed to DATADIR in the build process), so that
it can be used to refer to XBoard's private data files in a
configuration-indpendent way. This is mainly for use of settings files to
be supplied with the XBoard install to configure it for special tasks
9e.g. oriental shogi display, to refer to the shogi SVG pieces that came
with the install).

XBoard will now look for settings files specified on the command line
(e.g. with @FILENAME) that it cannot find in the user's directory in
~~/themes/conf, where we can install files like 'shogi' to define an
oriental shogi display theme.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]